I use cPanel for hosting my website. I have noticed that if anyone who visits my website happens to be a web developer, he can always reach my cPanel Login page via mydomain.com:2082, mydomain.com/cpanel, etc.. It is better to not let the visitors know what control panel I use. I want to disable these URLs. To myself log in to cpanel, I will use the alternate URL provided by my Web Host which is something like a.myhost.com/cpanel.
As a work around, I also changed the main domain and added my main website as an addon domain. But even that didn't work and addondomain.com:2082 and addondomain.com/cpanel showed up the cpanel login and I was able to login there using cpanel username and password.
Please help me hide these pages from the public world. At least addondomain.com:2082 or addondomain.com/cpanel should throw a 404(preferable) or 403 or anything.
I use cPanel 11/x3.
Even my hosting provider is not able to help me with this. Anybody who know anything about this, or implemented this, please help me.
Thanks in advance....
From a similar discussion raised on cPanel's Forums - "Changing cPanel URL?" (29 Nov 2010):
(With application, or package specific questions, your best port of call is initially their own forums/helpdesk rather than a general purpose community like StackOverflow.)
Can't you use cpanel to put a redirect on the /cpanel directory? Not sure how to get around 2082 w/o more privileges. Possibly your htaccess?
But really, chill out on the cpanel. No one cares that you make your life easier by using cpanel. Most people do. The only people who are going to know are, as you say, developers. And guess what, they use CPanel too.
I guess you are in a shared hosting environment. Your best shot is to use an htaccess file, be careful! the goal is to redirect any thing like : #http://your-site.tld/cpanel or to a #http://your-site.tld but do not redirect #http://your-provider.tld/cpanle
RedirectMatch 301 ^/cpanel/$ http://your-site.tld/
RewriteEngine On RewriteCond %{SERVER_PORT} !^2082$ RewriteRule ^(.*)$ http://your-site.tld/folder/$1 [L,R]
As I said, test carefully!