crazyaboutlinux

Well-Known Member
Nov 3, 2007
939
1
66
mod_userdir Protection:
Apache's mod_userdir allows users to view their sites by entering a tilde(~) and their username as the uri on a specific host. For example http://test.cpanel.net/~fred/ will bring up the user fred's domain. The disadvantage of this feature is that any bandwidth usage used by this site will be put on the domain it is accessed under (in this case test.cpanel.net). mod_userdir protection prevents this from happening. You may however want to disable it on specific virtual hosts (generally shared ssl hosts.)

We have enabled mod_userdir Protection for all our users but some our clients want to view their website via For example http://test.cpanel.net/~fred/

in this section there is mentioned that You may however want to disable it on specific virtual hosts (generally shared ssl hosts.)

but when i select a domain which i want to disable mod_userdir Protection & then ticked marked on Exclude Protection check box then i have restarted apache web server but still i am unable to view selected domain via IP based

now please tell what i m doing wrong ??

Please see attachment for further clarification
 

Spiral

BANNED
Jun 24, 2005
2,018
8
193
Allowing userdir access is not the greatest of ideas for a lot of reasons ...

Something you might want to consider is setting up a subdomain alias
in the Apache configuration for the accounts that need to access their
sites before their domain DNS propagates, etc

In example:
Code:
Instead of http://www.yourdomain.com/~username,
it would be http://username.yourdomain.com/
Setting up something like this can be done fairly easily to be added
automatically to new accounts upon creation with wildcard DNS and
a few virtualhost template adjustments or just manually updating
if you only have a few hosts.

If you think this is something that would interest you, I'll post more
details about exactly how to set this up.

PS: The exclude you were talking about in your post excludes the site from protection
but not from being about to be viewed by ~username
 
Last edited:

wesy

Registered
Dec 19, 2009
1
0
51
apache usermod protection

i m enabling apache usermod protection but still i can use it with tild~ and username on hostname i want it disable i think its not working i dont know why?
 

capoinfra

Well-Known Member
Oct 25, 2007
119
1
66
Uruguay
Hello,

I'm trying to preview the domains in the server but doesn't works.

From Main >> Security Center >> Apache mod_userdir Tweak I disable the "mod_userdir Protection" but I can not see the preview domain with http://serverIP/~ftpuser/

Please can you help me?

I really need preview the sites before the DNS propagation.

cPanel 11.25.0-R42399 - WHM 11.25.0 - X 3.9
CENTOS 5.4 i686 standard on cp5

Thanks in advance!
 

capoinfra

Well-Known Member
Oct 25, 2007
119
1
66
Uruguay
Hello,

I solved this problem...

The previews doesn't works if the sites has php index.

I disabled php open base dir protection for a site that I want to preview and the preview just works...

Thanks.-
 
  • Like
Reactions: x-origin

crazyaboutlinux

Well-Known Member
Nov 3, 2007
939
1
66
I have disabled this function though i am getting below error

404 Not Found

The server can not find the requested page:

75.96.11.154/~ashbourne/ (port 80)

Please forward this error screen to 65.98.11.154's WebMaster.
Apache/2.2.14 (Unix) mod_ssl/2.2.14 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4 Server at 75.96.11.154 Port 80