Does not redirect from http to https

Posted on

I have a problem with a web portal managed in jboss, the problem is this:

The site is consumed through an F5 balancer, in which two virtual servers were created. A virtual server is dedicated to the secure port (443) and the second virtual server is for the port (80) which should redirect to port 443.

If I access my web portal in the following way, the portal is displayed correctly:

But if I erase the final diagonal:

redirects me through port 80 and shows the insecure connection page:

An error occurred during a connection to SSL has received a record that exceeded the maximum allowed length. Error code: SSL_ERROR_RX_RECORD_TOO_LONG

Note: the certificate is loaded in the F5 balancer.