problem accessing https//whm vs 2086

chanklish

Well-Known Member
May 22, 2015
63
0
6
kinshasa
cPanel Access Level
Root Administrator
hello awesome people
i have a question concerning my whm page
if i go to https://xxx/whm i received this error : NET::ERR_CERT_COMMON_NAME_INVALID
and if i proceed i am taken to the https://xxx:2086 where the https works normally

on the contrary if i go to http://xxx/whm it gives no error and redirects me directly to https://xxx:2086

why ? why doesnt the https://xxx/whm works ? i have autossl on it ?
please advise
 

Muhammed Fasal

Well-Known Member
Aug 9, 2017
54
9
8
India
cPanel Access Level
Root Administrator
In httpd.conf, just look for the following and make sure it is the same.
ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/"
ScriptAlias /cpanel /usr/local/cpanel/cgi-sys/redirect.cgi
ScriptAlias /whm /usr/local/cpanel/cgi-sys/whmredirect.cgi
After that, restart apache and all should be well. :)
 

cPanelMichael

Technical Support Community Manager
Staff member
Apr 11, 2011
47,910
2,233
363
cPanel Access Level
DataCenter Provider
Twitter
Hello,

You can browse to the "Redirection" tab in "WHM >> Tweak Settings" and verify the following option is enabled:

"Choose the closest matched domain for which that the system has a valid certificate when redirecting from non-SSL to SSL URLs. Formerly known as “Always redirect to SSL/TLS”"

Per it's description:

When a user visits /cpanel, /webmail, /whm, or visits other URLs that redirect to a cPanel service, the system will redirect to an SSL URL for the closest matched domain that the system has a valid certificate. If you disable this option, the system will redirect to the equivalent URL that they visited based on the original request made via HTTPS or HTTP. This option also controls how the system will redirect unencrypted cPanel, Webmail, WHM, and DAV requests to the best matched certificate for the domain when “Require SSL” is enabled. When enabled, it will redirect closest matched domain that the system has a valid certificate for. When it is disabled, it will simply redirect equivalent HTTPS URL.
Redirects will not occur when directly accessing the WHM service with the port specified in the URL.

Thank you.
 

chanklish

Well-Known Member
May 22, 2015
63
0
6
kinshasa
cPanel Access Level
Root Administrator
Hello,

You can browse to the "Redirection" tab in "WHM >> Tweak Settings" and verify the following option is enabled:

"Choose the closest matched domain for which that the system has a valid certificate when redirecting from non-SSL to SSL URLs. Formerly known as “Always redirect to SSL/TLS”"

Per it's description:



Redirects will not occur when directly accessing the WHM service with the port specified in the URL.

Thank you.
i have this enabled , i turned it off and on again then restarted the apache service but still same error occurs
if i go to https://xxx/whm i get an ssl error :
The hostname in the website’s security certificate differs from the website you are trying to visit.

Error Code: DLG_FLAGS_SEC_CERT_CN_INVALID or NET::ERR_CERT_COMMON_NAME_INVALID(different browser)