SOLVED Non https is redirecting to cPanel interface on port 80

rewritecond

Registered
May 31, 2017
2
0
1
Australia
cPanel Access Level
Root Administrator
Hi all,

I'm running cPanel & WHM 64.0 (build 24).

I have a valid wildcard ssl cert for the domain.

I had some basic redirects setup in cpanel and a custom rule setup in .htaccess as I'm running a drupal multi-site instance.

The majority of redirects in cpanel were to force visitors to use SSL for the various domains. There was also one to redirect visitors to the 'www.' of a site.

These rules have been working well for close to a year.

Today, during my daily routine checks, I noticed that when visiting one of the URLs without the https:// prefix I was being redirected to the cpanel web gui on port 80! This should not be happening. It appears to have happened after a cpanel update when /usr/local/cpanel/scripts/upcp --cron ran early this morning.

I also noticed a strange entry inside the cpanel redirects section that cannot be deleted:

Domain Dir. Rule Type Wildcard Permanent
(.+) / http%{ENV:protossl}://%1 permanent yes yes

This rule does not appear in .htaccess. Even when I remove the cpanel generated .htaccess and replace it with a clean .htaccess and then attemp to remove the rule, it will just reappear again.

I've restarted the cpanel service. Ran WHM updates. Checked cpanel.config (couldn't see anything out of the ordinary). Checked this mornings update log (couldn't see anything out of the ordinary).

Any ideas on how to stop this redirect to the cpanel gui from happening? It's quite the security risk.

Any help would be much appreciated.

Cheers,

rewritecond
 
Last edited by a moderator:

rewritecond

Registered
May 31, 2017
2
0
1
Australia
cPanel Access Level
Root Administrator
Just in case anyone else experiences this strange behavior. This was caused by a licensing error in CPNignx. Once that was resolved, everything else worked as it should.

Hope this helps someone in the future.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,225
463
Hello,

I'm happy to see you were able to address the issue. Thank you for updating us with the outcome.