Results 1 to 7 of 7

Thread: Problems with APF

  1. #1
    borce's Avatar
    borce is offline Newbie Net Builder
    Join Date
    Dec 2008
    Posts
    74
    Thanks
    8
    Thanked 7 Times in 6 Posts

    Problems with APF

    Hello, I started APF but I got the following error.

    Code:
    [root@***** /]# /usr/local/sbin/apf -s
    : command not foundline 13:
    : command not foundline 21:
    : command not foundline 24:
    : command not foundline 28:
    : command not foundline 30:
    : command not foundline 34:
    : command not foundline 40:
    : command not foundline 52:
    : command not foundline 58:
    : command not foundline 66:
    : command not foundline 72:
    : command not foundline 78:
    : command not foundline 83:
    : command not foundline 89:
    : command not foundline 93:
    : command not foundline 100:
    : command not foundline 113:
    : command not foundline 118:
    : command not foundline 127:
    : command not foundline 132:
    : command not foundline 136:
    : command not foundline 140:
    : command not foundline 144:
    : command not foundline 149:
    : command not foundline 159:
    : command not foundline 167:
    : command not foundline 173:
    : command not foundline 181:
    : command not foundline 187:
    : command not foundline 191:
    : command not foundline 195:
    : command not foundline 200:
    : command not foundline 206:
    : command not foundline 209:
    : command not foundline 212:
    : command not foundline 215:
    : command not foundline 218:
    : command not foundline 221:
    : command not foundline 224:
    : command not foundline 229:
    : command not foundline 235:
    : command not foundline 241:
    : command not foundline 247:
    : command not foundline 255:
    : command not foundline 262:
    : command not foundline 268:
    : command not foundline 275:
    : command not foundline 282:
    : command not foundline 288:
    : command not foundline 295:
    : command not foundline 300:
    : command not foundline 304:
    : command not foundline 309:
    : command not foundline 314:
    : command not foundline 321:
    : command not foundline 333:
    : command not foundline 342:
    : command not foundline 351:
    : command not foundline 355:
    : command not foundline 365:
    : command not foundline 368:
    : command not foundline 371:
    : command not foundline 375:
    : command not foundline 389:
    : command not foundline 392:
    : command not foundline 395:
    : command not foundline 398:
    : command not foundline 402:
    : command not foundline 414:
    : command not foundline 417:
    : command not foundline 420:
    : command not foundline 431:
    : command not foundline 434:
    : command not foundline 443:
    : command not foundline 444:
    : command not foundline 445:
    : command not foundline 446:
    : command not foundline 452:
    : command not foundline 453:
    : command not foundline 454:
    : command not foundline 455:
    : command not foundline 461:
    : command not foundline 462:
    : command not foundline 463:
    : command not foundline 464:
    : command not foundline 472:
    : command not foundline 474:
    : command not foundline 475:
    : command not foundline 484:
    : command not foundline 485:
    : command not foundline 486:
    : command not foundline 487:
    : command not foundline 497:
    : command not foundline 498:
    : command not foundline 499:
    : command not foundline 500:
    : command not foundline 501:
    : command not foundline 502:
    : command not foundline 503:
    : command not foundline 509:
    : command not foundline 513:
    : command not foundline 518:
    : command not foundline 522:
    : command not foundline 525:
    : command not foundline 529:
    : command not foundline 533:
    : command not foundline 537:
    : No such file or directory: /etc/apf
    /usr/local/sbin/apf: line 136: eout: command not found
    /internals/.last.full: No such file or directory
    touch: missing file operand
    Try `touch --help' for more information.
    chmod: missing operand after `600'
    Try `chmod --help' for more information.
    touch: missing file operand
    Try `touch --help' for more information.
    chmod: missing operand after `600'
    Try `chmod --help' for more information.
    touch: missing file operand
    Try `touch --help' for more information.
    chmod: missing operand after `600'
    Try `chmod --help' for more information.
    /usr/local/sbin/apf: line 152: devm: command not found
    /vnet/vnetgen: No such file or directory
    /firewall: No such file or directoryapf
    /usr/local/sbin/apf: line 160: bandmin: command not found
    /usr/local/sbin/apf: line 162: eout: command not found
    [root@bacroot /]#
    What directories/files should I chmod for APF to work?

  2. #2
    Will.Spencer's Avatar
    Will.Spencer is offline Retired
    Join Date
    Dec 2008
    Posts
    5,033
    Blog Entries
    1
    Thanks
    1,010
    Thanked 2,329 Times in 1,259 Posts
    What makes you think this is a file permissions issues?

    I would run apf again, but this time with verbose debugging and command tracing:
    sh -x -v apf -s
    What does that show you?
    Submit Your Webmaster Related Sites to the NB Directory
    I swear, by my life and my love of it, that I will never live for the sake of another man, nor ask another man to live for mine.

  3. Thanked by:

    borce (1 February, 2009)

  4. #3
    borce's Avatar
    borce is offline Newbie Net Builder
    Join Date
    Dec 2008
    Posts
    74
    Thanks
    8
    Thanked 7 Times in 6 Posts
    This time the VPS is down... RAID updating they say..

  5. #4
    borce's Avatar
    borce is offline Newbie Net Builder
    Join Date
    Dec 2008
    Posts
    74
    Thanks
    8
    Thanked 7 Times in 6 Posts
    Okay,

    Code:
    # the executable CMD name in the log chain. This is A FILTERING FEATURE, not an
    # ACCESS CONTROL feature. That means EG_DROP_CMD is intended to DENY outbound
    # access for specified programs, not ALLOW.
    #
    # Format is comma separated list of executable names you wish to ban from being
    # able to transmit data out of your server.
    
    ++ $'\r'
    : command not foundline 431:
    # CMD-Match outbound (egress) denied applications
    EG_DROP_CMD="eggdrop psybnc bitchx BitchX init udp.pl"
    '+ EG_DROP_CMD='eggdrop psybnc bitchx BitchX init udp.pl
    
    ++ $'\r'
    : command not foundline 434:
    ##
    # [Remote Rule Imports]
    ##
    # Project Honey Pot is the first and only distributed system for identifying
    # spammers and the spambots they use to scrape addresses from your website.
    # This aggregate list combines Harvesters, Spammers and SMTP Dictionary attacks
    # from the PHP IP Data at:  http://www.projecthoneypot.org/list_of_ips.php
    DLIST_PHP="1"
    ++ DLIST_PHP=$'1\r'
    
    ++ $'\r'
    : command not foundline 443:
    DLIST_PHP_URL="rfxn.com/downloads/php_list"
    ++ DLIST_PHP_URL=rfxn.com/downloads/php_list
    ++ $'\r'
    : command not foundline 444:
    DLIST_PHP_URL_PROT="http"
    ++ DLIST_PHP_URL_PROT=http
    ++ $'\r'
    : command not foundline 445:
    
    ++ $'\r'
    : command not foundline 446:
    # The Spamhaus Don't Route Or Peer List (DROP) is an advisory "drop all
    # traffic" list, consisting of stolen 'zombie' netblocks and netblocks
    # controlled entirely by professional spammers. For more information please
    # see http://www.spamhaus.org/drop/.
    DLIST_SPAMHAUS="1"
    ++ DLIST_SPAMHAUS=$'1\r'
    
    ++ $'\r'
    : command not foundline 452:
    DLIST_SPAMHAUS_URL="www.spamhaus.org/drop/drop.lasso"
    ++ DLIST_SPAMHAUS_URL=www.spamhaus.org/drop/drop.lasso
    ++ $'\r'
    : command not foundline 453:
    DLIST_SPAMHAUS_URL_PROT="http"
    ++ DLIST_SPAMHAUS_URL_PROT=http
    ++ $'\r'
    : command not foundline 454:
    
    ++ $'\r'
    : command not foundline 455:
    # DShield collects data about malicious activity from across the Internet.
    # This data is cataloged, summarized and can be used to discover trends in
    # activity, confirm widespread attacks, or assist in preparing better firewall
    # rules. This is a list of top networks that have exhibited suspicious activity.
    DLIST_DSHIELD="1"
    ++ DLIST_DSHIELD=$'1\r'
    
    ++ $'\r'
    : command not foundline 461:
    DLIST_DSHIELD_URL="feeds.dshield.org/top10-2.txt"
    ++ DLIST_DSHIELD_URL=feeds.dshield.org/top10-2.txt
    ++ $'\r'
    : command not foundline 462:
    DLIST_DSHIELD_URL_PROT="http"
    ++ DLIST_DSHIELD_URL_PROT=http
    ++ $'\r'
    : command not foundline 463:
    
    ++ $'\r'
    : command not foundline 464:
    # The reserved networks list is addresses which ARIN has marked as reserved
    # for future assignement and have no business as valid traffic on the internet.
    # Such addresses are often used as spoofed (Fake) hosts during attacks, this
    # will update the reserved networks list in order to prevent new ip assignments
    # on the internet from getting blocked; this option is only important when
    # BLK_RESNET is set to enabled.
    DLIST_RESERVED="1"
    ++ DLIST_RESERVED=$'1\r'
    
    ++ $'\r'
    : command not foundline 472:
    DLIST_RESERVED_URL="rfxn.com/downloads/reserved.networks"
    ++ DLIST_RESERVED_URL=$'rfxn.com/downloads/reserved.networks\r'
    DLIST_RESERVED_URL_PROT="http"
    ++ DLIST_RESERVED_URL_PROT=http
    ++ $'\r'
    : command not foundline 474:
    
    ++ $'\r'
    : command not foundline 475:
    # ECN is an extension which helps reduce congestion. Unfortunately some
    # clueless software/hardware vendors have setup their sites or implemented
    # TCP/IP in a very broken manner. If you try to talk to these sites with ECN
    # turned on, they will drop all packets from you. This feature uses the ECN
    # hall of shame list to turn off ECN in packets to these hosts so your traffic
    # is accepted as intended. This option is dependent on setting SYSCTL_ECN="1"
    # otherwise it stays disabled.
    DLIST_ECNSHAME="1"
    ++ DLIST_ECNSHAME=$'1\r'
    
    ++ $'\r'
    : command not foundline 484:
    DLIST_ECNSHAME_URL="rfxn.com/downloads/ecnshame.lst"
    ++ DLIST_ECNSHAME_URL=rfxn.com/downloads/ecnshame.lst
    ++ $'\r'
    : command not foundline 485:
    DLIST_ECNSHAME_URL_PROT="http"
    ++ DLIST_ECNSHAME_URL_PROT=http
    ++ $'\r'
    : command not foundline 486:
    
    ++ $'\r'
    : command not foundline 487:
    ##
    # Global Trust
    ##
    # This is an implementation of the trust rules (allow/deny_hosts) but
    # on a global perspective. You can define below remote addresses from
    # which the glob_allow/deny.rules files should be downloaded from on
    # a daily basis. The files can be maintained in a static fashion by
    # leaving USE_RGT=0, ideal for a host serving the files.
    USE_RGT="0"
    ++ USE_RGT=$'0\r'
    
    ++ $'\r'
    : command not foundline 497:
    GA_URL="yourhost.com/glob_allow.rules"
    ++ GA_URL=yourhost.com/glob_allow.rules
    ++ $'\r'
    : command not foundline 498:
    GA_URL_PROT="http"
    ++ GA_URL_PROT=http
    ++ $'\r'
    : command not foundline 499:
    
    ++ $'\r'
    : command not foundline 500:
    GD_URL="yourhost.com/glob_deny.rules"
    ++ GD_URL=yourhost.com/glob_deny.rules
    ++ $'\r'
    : command not foundline 501:
    GD_URL_PROT="http"
    ++ GD_URL_PROT=http
    ++ $'\r'
    : command not foundline 502:
    
    ++ $'\r'
    : command not foundline 503:
    ##
    # [Logging and control settings]
    ##
    # Log all traffic that is filtered by the firewall
    LOG_DROP="0"
    ++ LOG_DROP=$'0\r'
    
    ++ $'\r'
    : command not foundline 509:
    # What log level should we send all log data too?
    # refer to man syslog.conf for levels
    LOG_LEVEL="crit"
    ++ LOG_LEVEL=$'crit\r'
    
    ++ $'\r'
    : command not foundline 513:
    # Where should we send all the logging data?
    # ULOG (Allow ulogd to handle the logging)
    # LOG (Default; sends logging to kernel log)
    LOG_TARGET="LOG"
    ++ LOG_TARGET=$'LOG\r'
    
    ++ $'\r'
    : command not foundline 518:
    # Log interactive access over telnet & ssh; uses
    # custom log prefix of ** SSH ** & ** TELNET **
    LOG_IA="1"
    ++ LOG_IA=$'1\r'
    
    ++ $'\r'
    : command not foundline 522:
    # Log all foreign gateway traffic
    LOG_LGATE="0"
    ++ LOG_LGATE=$'0\r'
    
    ++ $'\r'
    : command not foundline 525:
    # Extended logging information; this forces the output of tcp options and
    # ip options for packets passing through the log chains
    LOG_EXT="0"
    ++ LOG_EXT=$'0\r'
    
    ++ $'\r'
    : command not foundline 529:
    # Max firewall events to log per/minute. Log events exceeding these limits
    # will be lost (1440 minutes/day * 30 events/minute = 43200 events per/day)
    LOG_RATE="30"
    ++ LOG_RATE=$'30\r'
    
    ++ $'\r'
    : command not foundline 533:
    # Location of the apf status log; all startup, shutdown and runtime status
    # sends outputs to this file
    LOG_APF="/var/log/apf_log"
    ++ LOG_APF=$'/var/log/apf_log\r'
    
    ++ $'\r'
    : command not foundline 537:
    ##
    # [Import misc. conf]
    ##
    # Internal variable file
    CNFINT="$INSTALL_PATH/internals/internals.conf"
    ++ CNFINT=$'/etc/apf\r/internals/internals.conf\r'
    . $CNFINT
    ++ . $'/etc/apf\r/internals/internals.conf\r\r'
    : No such file or directory: /etc/apf

  6. #5
    Will.Spencer's Avatar
    Will.Spencer is offline Retired
    Join Date
    Dec 2008
    Posts
    5,033
    Blog Entries
    1
    Thanks
    1,010
    Thanked 2,329 Times in 1,259 Posts
    Something is seriously wrong. I'd delete apf entirely and reinstall it from scratch.

    Did the errors really not start until line 431?

    There seems to be a problem with return characters (\r). What operating system are you trying to run this on?
    Submit Your Webmaster Related Sites to the NB Directory
    I swear, by my life and my love of it, that I will never live for the sake of another man, nor ask another man to live for mine.

  7. #6
    borce's Avatar
    borce is offline Newbie Net Builder
    Join Date
    Dec 2008
    Posts
    74
    Thanks
    8
    Thanked 7 Times in 6 Posts
    CentOS 5 with DirectAdmin, also the same problem is with cPanel

  8. #7
    Will.Spencer's Avatar
    Will.Spencer is offline Retired
    Join Date
    Dec 2008
    Posts
    5,033
    Blog Entries
    1
    Thanks
    1,010
    Thanked 2,329 Times in 1,259 Posts
    Did the errors really not start until line 431?

    If you're using DirectAdmin or cPanel, that usually means that you're not the system administrator. Have you reported this issue to your hosting company?
    Submit Your Webmaster Related Sites to the NB Directory
    I swear, by my life and my love of it, that I will never live for the sake of another man, nor ask another man to live for mine.

Similar Threads

  1. Problems with laptop
    By Will.Spencer in forum Tech-Talk
    Replies: 2
    Last Post: 26 November, 2009, 00:56 AM
  2. Big Problems With Skype
    By Hellas in forum Tech-Talk
    Replies: 2
    Last Post: 14 September, 2009, 10:08 AM
  3. Adsense problems....
    By photoworldblog in forum Web Proxies
    Replies: 14
    Last Post: 27 August, 2009, 00:12 AM
  4. 7 Possible Problems With Your Blog
    By Farrhad A in forum Blogging
    Replies: 5
    Last Post: 15 July, 2009, 01:31 AM
  5. Facebook problems?
    By nux in forum Web Proxies
    Replies: 16
    Last Post: 18 April, 2009, 23:50 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •