jteerman

Member
Jul 30, 2008
14
0
51
We recently started using cPanel and WHMCS. In testing account suspensions for exceeding bandwidth usage, it appears that we are not catching usage for an account when the account is accessed via an IP address. If my test account is 'test' with a domain of test.com, ftp and web traffic is counted if accessed using test.com. If I access the website via 206.111.111.111/~test or ftp into my account with the IP for the host, bandmin is not including the usage into the totals.

Can anyone tell me if this in normal and how I can get around this? My concern is that an account will misuse the server and bypass bandwidth limits by using the IP address rather than their account.

Thanks in advance for any help!
 

cPanelDavidG

Technical Product Specialist
Nov 29, 2006
11,212
15
313
Houston, TX
cPanel Access Level
Root Administrator
We recently started using cPanel and WHMCS. In testing account suspensions for exceeding bandwidth usage, it appears that we are not catching usage for an account when the account is accessed via an IP address. If my test account is 'test' with a domain of test.com, ftp and web traffic is counted if accessed using test.com. If I access the website via 206.111.111.111/~test or ftp into my account with the IP for the host, bandmin is not including the usage into the totals.

Can anyone tell me if this in normal and how I can get around this? My concern is that an account will misuse the server and bypass bandwidth limits by using the IP address rather than their account.

Thanks in advance for any help!
Being able to access websites via ~username is a known issue with proper bandwidth tracking in cPanel/WHM environments. Hence, many hosting providers use our mod_userdir tweak to prevent this. Further description of this issue as well as settings for disabling this is available in WHM -> Security -> Security Center -> Apache mod_userdir Tweak
 

jteerman

Member
Jul 30, 2008
14
0
51
Bandwin config

Thanks for the quick reply! Enabling the mod_usrdir will prevent web access via ~accountname, but will this also prevent someone from using ftp with an IP address for the host name rather than their domain name? I also assume that the customer would have to wait to load their web content until their domain name resolves to our servers?
 

cPanelDavidG

Technical Product Specialist
Nov 29, 2006
11,212
15
313
Houston, TX
cPanel Access Level
Root Administrator
Thanks for the quick reply! Enabling the mod_usrdir will prevent web access via ~accountname, but will this also prevent someone from using ftp with an IP address for the host name rather than their domain name? I also assume that the customer would have to wait to load their web content until their domain name resolves to our servers?
As this only affects mod_userdir in Apache, it will have no impact on FTP.