Results 1 to 13 of 13

Thread: Blocking Ip's, htaccess works, Host Access Control Dont-- WTF?

  1. #1
    Member
    Join Date
    Jul 2005
    Posts
    5

    Default Blocking Ip's, htaccess works, Host Access Control Dont-- WTF?

    Can't seem to get WHM 11 Host Access Control to block ip's. Went to a domain on the box using http://www.surf-anon.com , saw the ip in logs, blocked the IP in Host Access Control using rule:

    Daemon Access List ACTION
    ALL 208.76.240.226 deny

    surfed the site again, no block, cleared cache/refreshed, no block.

    HUH?

    Went to IP Deny Manager , added the IP , it blocked fine.

    Anyone know why Host Access Control ain't blockin? Isn't Host Access Control supposed to block all traffic to the box on any domain?

    WHM 11.15.0 cPanel 11.18.1-R20683
    FREEBSD 6.2-RELEASE i386 on standard - WHM X v3.1.0

  2. #2
    Member
    Join Date
    Jul 2005
    Posts
    5

    Default

    Hmmm. Looks like everyone else is just as stumped as i am..

  3. #3
    Member
    Join Date
    Apr 2004
    Location
    Colombia
    Posts
    24

    Default It DOESN'T WORK.

    Yes. This feature DOESN'T WORK at all. You can put as many rules as you like and the box will not obey.

    Does ANYONE know how to make it work?

    Thanks.

    M.

  4. #4
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    11,307
    cPanel/WHM Access Level

    Root Administrator

    Default

    Quote Originally Posted by moricio View Post
    Yes. This feature DOESN'T WORK at all. You can put as many rules as you like and the box will not obey.

    Does ANYONE know how to make it work?

    Thanks.

    M.
    This functionality is only intended for daemons that handle logins to the cPanel/WHM system, not to replace the IP Deny Manager functionality available in the cPanel interface.

  5. #5
    Member
    Join Date
    May 2003
    Location
    Texas
    Posts
    106

    Default

    Quote Originally Posted by cPanelDavidG View Post
    This functionality is only intended for daemons that handle logins to the cPanel/WHM system, not to replace the IP Deny Manager functionality available in the cPanel interface.
    It seems to work well for sshd but not at all for ftp. Is that intended?

  6. #6
    Member nyjimbo's Avatar
    Join Date
    Jan 2003
    Location
    New York
    Posts
    1,113

    Default

    If you just want to block a few IP's from doing anything and everything on your box you can use IPFW with a basic "ipfw add deny ip from xxx.xxx.xxx.xxx to any" and that would stop everything. Of course you would have to have ipfw/dummynet in the kernel and if you want to keep these rules you would have to add them to one of your startup scripts so you dont lose them on reboots.
    "A dog has raised it’s hind leg on the age of nevermore !"
    -- Rolf

  7. #7
    Member
    Join Date
    May 2003
    Location
    Texas
    Posts
    106

    Default

    Quote Originally Posted by nyjimbo View Post
    If you just want to block a few IP's from doing anything and everything on your box you can use IPFW with a basic "ipfw add deny ip from xxx.xxx.xxx.xxx to any" and that would stop everything. Of course you would have to have ipfw/dummynet in the kernel and if you want to keep these rules you would have to add them to one of your startup scripts so you dont lose them on reboots.
    Thanks. I have a firewall (CSF) running on this server which is used to block specific IP's, but the client wants to restrict FTP connections to certain IP's, and it seems like Host Access Control is the friendliest way for him to enter and update his IP list (it's a dedicated box and he has root access). For now I've suggested we close the FTP port 21 (assuming this doesn't create any unwanted side-effects) and then he can enter his rules for SSHD and use only SFTP.

  8. #8
    cPanel Development cPanelKenneth's Avatar
    Join Date
    Apr 2006
    Posts
    4,131
    cPanel/WHM Access Level

    Root Administrator

    Default

    This functionality relies upon the daemon being built with support for TCP Wrapper. If the daemon doesn't support that (such as pure-ftpd) then the Host Access Control simply will have no effect.

  9. #9
    Member
    Join Date
    May 2003
    Location
    Texas
    Posts
    106

    Default

    Quote Originally Posted by cpanelkenneth View Post
    This functionality relies upon the daemon being built with support for TCP Wrapper. If the daemon doesn't support that (such as pure-ftpd) then the Host Access Control simply will have no effect.
    Thanks for the explanation; that clears things up. It's hard to find documentation on new features, so I really appreciate it. Since it's basically non-functional for ftp, it would probably be a good idea to remove "ftp (Ftp Server)" from the dropdown list in "Host Access Control" or expand the on-screen instructions there to explain what does and doesn't work.

    It's a nice, friendly feature, so it's too bad my client can't use it. He wants to restrict access to most services to his office IP's.

  10. #10
    cPanel Development cPanelKenneth's Avatar
    Join Date
    Apr 2006
    Posts
    4,131
    cPanel/WHM Access Level

    Root Administrator

    Default

    Quote Originally Posted by PeteC View Post
    Thanks for the explanation; that clears things up. It's hard to find documentation on new features, so I really appreciate it. Since it's basically non-functional for ftp, it would probably be a good idea to remove "ftp (Ftp Server)" from the dropdown list in "Host Access Control" or expand the on-screen instructions there to explain what does and doesn't work.

    It's a nice, friendly feature, so it's too bad my client can't use it. He wants to restrict access to most services to his office IP's.
    ProFTPd support s TCP Wrapper. Likewise other FTP daemons, if you have Pure or Pro disabled.

  11. #11
    Member
    Join Date
    May 2003
    Location
    Texas
    Posts
    106

    Default

    Quote Originally Posted by cpanelkenneth View Post
    ProFTPd support s TCP Wrapper. Likewise other FTP daemons, if you have Pure or Pro disabled.
    Interesting. I haven't used ProFTPd in several years, but I'll put that to the customer as an option. Thanks again.

  12. #12
    Registered User
    Join Date
    Mar 2008
    Posts
    1

    Default

    After last update SSHD was updated with version that does not support Wrapper... no Host Access Control is available at the moment. I'm using

    WHM 11.23.2 cPanel 11.23.4-S26138
    CENTOS Enterprise 5.2 x86_64 on standard - WHM X v3.1.0

    even root ssh access is unable to be restricted from sshd_config...

  13. #13
    cPanel Development cPanelKenneth's Avatar
    Join Date
    Apr 2006
    Posts
    4,131
    cPanel/WHM Access Level

    Root Administrator

    Default

    Quote Originally Posted by quattr0 View Post
    After last update SSHD was updated with version that does not support Wrapper... no Host Access Control is available at the moment. I'm using

    WHM 11.23.2 cPanel 11.23.4-S26138
    CENTOS Enterprise 5.2 x86_64 on standard - WHM X v3.1.0

    even root ssh access is unable to be restricted from sshd_config...
    What you describe indicates a problem with the OpenSSH rpm from your Operating System vendor. You can attempt to re-install this rpm to resolve the issue, or open a support request at https://tickets.cpanel.net/submit/

Similar Threads

  1. Replies: 8
    Last Post: 06-24-2009, 06:20 PM
  2. Host Access Control (block IP access)
    By meeti in forum New User Questions
    Replies: 5
    Last Post: 05-13-2008, 12:39 AM
  3. host access control
    By salvatore333 in forum cPanel & WHM Discussions
    Replies: 1
    Last Post: 01-31-2008, 06:08 AM
  4. host access control
    By blargman in forum cPanel & WHM Discussions
    Replies: 4
    Last Post: 11-14-2007, 05:52 PM