Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 9 of 9
  1. #1
    BANNED
    Join Date
    Apr 2004
    Posts
    424

    Default block ip from accessing server in apf?

    How can I block an IP from accessing the server in general in APF firewall?

  2. #2
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,313
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    /sbin/iptables -I INPUT -s "IP Address" -j DROP

  3. #3
    BANNED
    Join Date
    Apr 2004
    Posts
    424

    Default

    Ok, I did that but it doesn't do anything in command (just shows root@server line again). Is this normal? Also, how can I check to make sure that APF is actually on and working? I forget the command line for that.

  4. #4
    BANNED
    Join Date
    Apr 2004
    Posts
    424

    Default

    I checked mail queue (reason for blocking IP's in first place). There is one message that is locked.

    Message 1Bovl7-0006Df-Vy is locked
    Mail Queue Removed


    Why and how do I delete it?

  5. #5
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,313
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    /usr/local/sbin/apf -l

  6. #6
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,313
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    In WHM>>Email>>Manage Mail Queue

  7. #7
    BANNED
    Join Date
    Apr 2004
    Posts
    424

    Default

    Please re-read what I said. I am already in there (mail queue) but it won't delete it.

  8. #8
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,313
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Try exim -Mrm <id>

  9. #9
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    It will be locked because exim is currently processing it. If you temporarily shutdown exim, you should then be able to delete the message.

    Also, you ought to use the following if you want to permanently block an IP through APF:

    apf -d 11.22.33.44
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

Similar Threads & Tags
Similar threads

  1. How can I block ping with the APF firewall?
    By BianchiDude in forum cPanel and WHM Discussions
    Replies: 6
    Last Post: 12-17-2007, 01:44 AM
  2. Need to block IPs use APF, how ?
    By jameshsi in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 08-03-2006, 10:04 AM
  3. APF block reasons
    By garak in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 05-02-2005, 10:12 AM
  4. APF and İp Block
    By MrNone in forum New User Questions
    Replies: 9
    Last Post: 11-16-2004, 01:02 PM
  5. How to block an ip for accessing cpanel or anything else on server
    By TheSpidre in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 07-29-2003, 05:06 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube