Snort mailing list archives

Re: Snort 2.9.6.2 inline mode problem


From: Debason Shockre <demonsdebason () gmail com>
Date: Wed, 27 Aug 2014 20:13:42 +0200

Here is the full snort.conf:

ipvar HOME_NET any
ipvar EXTERNAL_NET any
ipvar DNS_SERVERS $HOME_NET
ipvar SMTP_SERVERS $HOME_NET
ipvar HTTP_SERVERS $HOME_NET
ipvar SQL_SERVERS $HOME_NET
ipvar TELNET_SERVERS $HOME_NET
ipvar SSH_SERVERS $HOME_NET
ipvar FTP_SERVERS $HOME_NET
ipvar SIP_SERVERS $HOME_NET
portvar HTTP_PORTS
[36,80,81,82,83,84,85,86,87,88,89,90,311,383,555,591,593,631,801,808,818,901,972,1158,1220,1414,1533,1741,1830,1942,2231,2301,2381,2809,2980,3029,3037,3057,3128,3443,3702,4000,4343,4848,5000,5117,5250,5600,6080,6173,6988,7000,7001,7071,7144,7145,7510,7770,7777,7778,7779,8000,8008,8014,8028,8080,8081,8082,8085,8088,8090,8118,8123,8180,8181,8222,8243,8280,8300,8333,8344,8500,8509,8800,8888,8899,8983,9000,9060,9080,9090,9091,9111,9290,9443,9999,10000,11371,12601,13014,15489,29991,33300,34412,34443,34444,41080,44449,50000,50002,51423,53331,55252,55555,56712]

portvar SHELLCODE_PORTS !80
portvar ORACLE_PORTS 1024:
portvar SSH_PORTS 22
portvar FTP_PORTS [21,2100,3535]
portvar SIP_PORTS [5060,5061,5600]
portvar FILE_DATA_PORTS [$HTTP_PORTS,110,143]
portvar GTP_PORTS [2123,2152,3386]
ipvar AIM_SERVERS [
64.12.24.0/23,64.12.28.0/23,64.12.161.0/24,64.12.163.0/24,64.12.200.0/24,205.188.3.0/24,205.188.5.0/24,205.188.7.0/24,205.188.9.0/24,205.188.153.0/24,205.188.179.0/24,205.188.248.0/24
]
var RULE_PATH /etc/snort/rules
var SO_RULE_PATH /etc/snort/rules/so_rules
var PREPROC_RULE_PATH /etc/snort/rules/preproc_rules
var WHITE_LIST_PATH /etc/snort/rules
var BLACK_LIST_PATH /etc/snort/rules
config disable_decode_alerts
config disable_tcpopt_experimental_alerts
config disable_tcpopt_obsolete_alerts
config disable_tcpopt_ttcp_alerts
config disable_tcpopt_alerts
config disable_ipopt_alerts
config checksum_mode: all
config policy_mode:inline
config daq: afpacket
config daq_dir: /usr/lib64/daq
config daq_mode: inline
config daq_var: buffer_size_mb=1024
config set_gid:504
config set_uid:504
config logdir:/var/log/snort
config pcre_match_limit: 3500
config pcre_match_limit_recursion: 1500
config detection: search-method ac-split search-optimize max-pattern-len 20
config event_queue: max_queue 8 log 5 order_events content_length
config paf_max: 16000
dynamicpreprocessor directory /usr/lib64/snort-2.9.6.2_dynamicpreprocessor/
dynamicengine /usr/lib64/snort-2.9.6.2_dynamicengine/libsf_engine.so
dynamicdetection directory /usr/local/lib/snort_dynamicrules
preprocessor normalize_ip4
preprocessor normalize_tcp: ips ecn stream
preprocessor normalize_icmp4
preprocessor frag3_global: max_frags 65536
preprocessor frag3_engine: policy windows detect_anomalies overlap_limit 10
min_fragment_length 100 timeout 180
preprocessor stream5_global: track_tcp yes, \
   track_udp yes, \
   track_icmp no, \
   max_tcp 262144, \
   max_udp 131072, \
   max_active_responses 2, \
   min_response_seconds 5
preprocessor stream5_tcp: policy windows, detect_anomalies, require_3whs
180, \
   #overlap_limit 10, small_segments 3 bytes 150, timeout 180, \
   overlap_limit 10, small_segments 3 bytes 32, timeout 180, \
    ports client 21 22 23 25 42 53 70 79 109 110 111 113 119 135 136 137
139 143 \
        161 445 513 514 587 593 691 1433 1521 1741 2100 3306 6070 6665 6666
6667 6668 6669 \
        7000 8181 32770 32771 32772 32773 32774 32775 32776 32777 32778
32779, \
    ports both 36 80 81 82 83 84 85 86 87 88 89 90 110 311 383 443 465 563
555 591 593 631 636 801 808 818 901 972 989 992 993 994 995 1158 1220 1414
1533 1741 1830 1942 2231 2301 2381 2809 2980 3029 3037 3057 3128 3443 3702
4000 4343 4848 5000 5117 5250 5600 6080 6173 6988 7907 7000 7001 7071 7144
7145 7510 7802 7770 7777 7778 7779 \
        7801 7900 7901 7902 7903 7904 7905 7906 7908 7909 7910 7911 7912
7913 7914 7915 7916 \
        7917 7918 7919 7920 8000 8008 8014 8028 8080 8081 8082 8085 8088
8090 8118 8123 8180 8181 8222 8243 8280 8300 8333 8344 8500 8509 8800 8888
8899 8983 9000 9060 9080 9090 9091 9111 9290 9443 9999 10000 11371 12601
13014 15489 29991 33300 34412 34443 34444 41080 44449 50000 50002 51423
53331 55252 55555 56712
preprocessor stream5_udp: timeout 180
preprocessor http_inspect: global iis_unicode_map unicode.map 1252
compress_depth 65535 decompress_depth 65535
preprocessor http_inspect_server: server default \
    http_methods { GET POST PUT SEARCH MKCOL COPY MOVE LOCK UNLOCK NOTIFY
POLL BCOPY BDELETE BMOVE LINK UNLINK OPTIONS HEAD DELETE TRACE TRACK
CONNECT SOURCE SUBSCRIBE UNSUBSCRIBE PROPFIND PROPPATCH BPROPFIND
BPROPPATCH RPC_CONNECT PROXY_SUCCESS BITS_POST CCM_POST SMS_POST
RPC_IN_DATA RPC_OUT_DATA RPC_ECHO_DATA } \
    chunk_length 500000 \
    server_flow_depth 0 \
    client_flow_depth 0 \
    post_depth 65495 \
    oversize_dir_length 500 \
    max_header_length 750 \
    max_headers 100 \
    max_spaces 200 \
    small_chunk_length { 10 5 } \
    ports { 36 80 81 82 83 84 85 86 87 88 89 90 311 383 555 591 593 631 801
808 818 901 972 1158 1220 1414 1533 1741 1830 1942 2231 2301 2381 2809 2980
3029 3037 3057 3128 3443 3702 4000 4343 4848 5000 5117 5250 5600 6080 6173
6988 7000 7001 7071 7144 7145 7510 7770 7777 7778 7779 8000 8008 8014 8028
8080 8081 8082 8085 8088 8090 8118 8123 8180 8181 8222 8243 8280 8300 8333
8344 8500 8509 8800 8888 8899 8983 9000 9060 9080 9090 9091 9111 9290 9443
9999 10000 11371 12601 13014 15489 29991 33300 34412 34443 34444 41080
44449 50000 50002 51423 53331 55252 55555 56712 } \
    non_rfc_char { 0x00 0x01 0x02 0x03 0x04 0x05 0x06 0x07 } \
    enable_cookie \
    extended_response_inspection \
    inspect_gzip \
    normalize_utf \
    unlimited_decompress \
    normalize_javascript \
    apache_whitespace no \
    ascii no \
    bare_byte no \
    directory no \
    double_decode no \
    iis_backslash no \
    iis_delimiter no \
    iis_unicode no \
    multi_slash no \
    utf_8 no \
    u_encode yes \
    webroot no
preprocessor rpc_decode: 111 32770 32771 32772 32773 32774 32775 32776
32777 32778 32779 no_alert_multiple_requests no_alert_large_fragments
no_alert_incomplete
preprocessor bo
preprocessor ftp_telnet: global inspection_type stateful encrypted_traffic
no check_encrypted
preprocessor ftp_telnet_protocol: telnet \
    ayt_attack_thresh 20 \
    normalize ports { 23 } \
    detect_anomalies
preprocessor ftp_telnet_protocol: ftp server default \
    def_max_param_len 100 \
    ports { 21 2100 3535 } \
    telnet_cmds yes \
    ignore_telnet_erase_cmds yes \
    ftp_cmds { ABOR ACCT ADAT ALLO APPE AUTH CCC CDUP } \
    ftp_cmds { CEL CLNT CMD CONF CWD DELE ENC EPRT } \
    ftp_cmds { EPSV ESTA ESTP FEAT HELP LANG LIST LPRT } \
    ftp_cmds { LPSV MACB MAIL MDTM MIC MKD MLSD MLST } \
    ftp_cmds { MODE NLST NOOP OPTS PASS PASV PBSZ PORT } \
    ftp_cmds { PROT PWD QUIT REIN REST RETR RMD RNFR } \
    ftp_cmds { RNTO SDUP SITE SIZE SMNT STAT STOR STOU } \
    ftp_cmds { STRU SYST TEST TYPE USER XCUP XCRC XCWD } \
    ftp_cmds { XMAS XMD5 XMKD XPWD XRCP XRMD XRSQ XSEM } \
    ftp_cmds { XSEN XSHA1 XSHA256 } \
    alt_max_param_len 0 { ABOR CCC CDUP ESTA FEAT LPSV NOOP PASV PWD QUIT
REIN STOU SYST XCUP XPWD } \
    alt_max_param_len 200 { ALLO APPE CMD HELP NLST RETR RNFR STOR STOU
XMKD } \
    alt_max_param_len 256 { CWD RNTO } \
    alt_max_param_len 400 { PORT } \
    alt_max_param_len 512 { SIZE } \
    chk_str_fmt { ACCT ADAT ALLO APPE AUTH CEL CLNT CMD } \
    chk_str_fmt { CONF CWD DELE ENC EPRT EPSV ESTP HELP } \
    chk_str_fmt { LANG LIST LPRT MACB MAIL MDTM MIC MKD } \
    chk_str_fmt { MLSD MLST MODE NLST OPTS PASS PBSZ PORT } \
    chk_str_fmt { PROT REST RETR RMD RNFR RNTO SDUP SITE } \
    chk_str_fmt { SIZE SMNT STAT STOR STRU TEST TYPE USER } \
    chk_str_fmt { XCRC XCWD XMAS XMD5 XMKD XRCP XRMD XRSQ } \
    chk_str_fmt { XSEM XSEN XSHA1 XSHA256 } \
    cmd_validity ALLO < int [ char R int ] > \
    cmd_validity EPSV < [ { char 12 | char A char L char L } ] > \
    cmd_validity MACB < string > \
    cmd_validity MDTM < [ date nnnnnnnnnnnnnn[.n[n[n]]] ] string > \
    cmd_validity MODE < char ASBCZ > \
    cmd_validity PORT < host_port > \
    cmd_validity PROT < char CSEP > \
    cmd_validity STRU < char FRPO [ string ] > \
    cmd_validity TYPE < { char AE [ char NTC ] | char I | char L [ number ]
} >
preprocessor ftp_telnet_protocol: ftp client default \
    max_resp_len 256 \
    bounce yes \
    ignore_telnet_erase_cmds yes \
    telnet_cmds yes
preprocessor smtp: ports { 25 465 587 691 } \
    inspection_type stateful \
    b64_decode_depth 0 \
    qp_decode_depth 0 \
    bitenc_decode_depth 0 \
    uu_decode_depth 0 \
    log_mailfrom \
    log_rcptto \
    log_filename \
    log_email_hdrs \
    normalize cmds \
    normalize_cmds { ATRN AUTH BDAT CHUNKING DATA DEBUG EHLO EMAL ESAM ESND
ESOM ETRN EVFY } \
    normalize_cmds { EXPN HELO HELP IDENT MAIL NOOP ONEX QUEU QUIT RCPT
RSET SAML SEND SOML } \
    normalize_cmds { STARTTLS TICK TIME TURN TURNME VERB VRFY X-ADAT X-DRCP
X-ERCP X-EXCH50 } \
    normalize_cmds { X-EXPS X-LINK2STATE XADR XAUTH XCIR XEXCH50 XGEN
XLICENSE XQUE XSTA XTRN XUSR } \
    max_command_line_len 512 \
    max_header_line_len 1000 \
    max_response_line_len 512 \
    alt_max_command_line_len 260 { MAIL } \
    alt_max_command_line_len 300 { RCPT } \
    alt_max_command_line_len 500 { HELP HELO ETRN EHLO } \
    alt_max_command_line_len 255 { EXPN VRFY ATRN SIZE BDAT DEBUG EMAL ESAM
ESND ESOM EVFY IDENT NOOP RSET } \
    alt_max_command_line_len 246 { SEND SAML SOML AUTH TURN ETRN DATA RSET
QUIT ONEX QUEU STARTTLS TICK TIME TURNME VERB X-EXPS X-LINK2STATE XADR
XAUTH XCIR XEXCH50 XGEN XLICENSE XQUE XSTA XTRN XUSR } \
    valid_cmds { ATRN AUTH BDAT CHUNKING DATA DEBUG EHLO EMAL ESAM ESND
ESOM ETRN EVFY } \
    valid_cmds { EXPN HELO HELP IDENT MAIL NOOP ONEX QUEU QUIT RCPT RSET
SAML SEND SOML } \
    valid_cmds { STARTTLS TICK TIME TURN TURNME VERB VRFY X-ADAT X-DRCP
X-ERCP X-EXCH50 } \
    valid_cmds { X-EXPS X-LINK2STATE XADR XAUTH XCIR XEXCH50 XGEN XLICENSE
XQUE XSTA XTRN XUSR } \
    xlink2state { enabled }
preprocessor ssh: server_ports { 22 } \
                  autodetect \
                  max_client_bytes 19600 \
                  max_encrypted_packets 20 \
                  max_server_version_len 100 \
                  enable_respoverflow enable_ssh1crc32 \
                  enable_srvoverflow enable_protomismatch
preprocessor dcerpc2: memcap 102400, events [co ]
preprocessor dcerpc2_server: default, policy WinXP, \
    detect [smb [139,445], tcp 135, udp 135, rpc-over-http-server 593], \
    autodetect [tcp 1025:, udp 1025:, rpc-over-http-server 1025:], \
    smb_max_chain 3, smb_invalid_shares ["C$", "D$", "ADMIN$"]
preprocessor dns: ports { 53 } enable_rdata_overflow
preprocessor ssl: ports { 443 465 563 636 989 992 993 994 995 7801 7802
7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914
7915 7916 7917 7918 7919 7920 }, trustservers, noinspect_encrypted
preprocessor sensitive_data: alert_threshold 25
preprocessor sip: max_sessions 40000, \
   ports { 5060 5061 5600 }, \
   methods { invite \
             cancel \
             ack \
             bye \
             register \
             options \
             refer \
             subscribe \
             update \
             join \
             info \
             message \
             notify \
             benotify \
             do \
             qauth \
             sprack \
             publish \
             service \
             unsubscribe \
             prack }, \
   max_uri_len 512, \
   max_call_id_len 80, \
   max_requestName_len 20, \
   max_from_len 256, \
   max_to_len 256, \
   max_via_len 1024, \
   max_contact_len 512, \
   max_content_len 2048
preprocessor imap: \
   ports { 143 } \
   b64_decode_depth 0 \
   qp_decode_depth 0 \
   bitenc_decode_depth 0 \
   uu_decode_depth 0
preprocessor pop: \
   ports { 110 } \
   b64_decode_depth 0 \
   qp_decode_depth 0 \
   bitenc_decode_depth 0 \
   uu_decode_depth 0
preprocessor modbus: ports { 502 }
preprocessor dnp3: ports { 20000 } \
   memcap 262144 \
   check_crc
preprocessor reputation: \
   memcap 500, \
   priority whitelist, \
   nested_ip inner, \
   whitelist $WHITE_LIST_PATH/white_list.rules, \
   blacklist $BLACK_LIST_PATH/black_list.rules
output unified2: filename snort.log, limit 128
include classification.config
include reference.config
include $RULE_PATH/local.rules
include $RULE_PATH/app-detect.rules
include $RULE_PATH/attack-responses.rules
include $RULE_PATH/backdoor.rules
include $RULE_PATH/bad-traffic.rules
include $RULE_PATH/blacklist.rules
include $RULE_PATH/botnet-cnc.rules
include $RULE_PATH/browser-chrome.rules
include $RULE_PATH/browser-firefox.rules
include $RULE_PATH/browser-ie.rules
include $RULE_PATH/browser-other.rules
include $RULE_PATH/browser-plugins.rules
include $RULE_PATH/browser-webkit.rules
include $RULE_PATH/chat.rules
include $RULE_PATH/content-replace.rules
include $RULE_PATH/ddos.rules
include $RULE_PATH/dns.rules
include $RULE_PATH/dos.rules
include $RULE_PATH/experimental.rules
include $RULE_PATH/exploit-kit.rules
include $RULE_PATH/exploit.rules
include $RULE_PATH/file-executable.rules
include $RULE_PATH/file-flash.rules
include $RULE_PATH/file-identify.rules
include $RULE_PATH/file-image.rules
include $RULE_PATH/file-java.rules
include $RULE_PATH/file-multimedia.rules
include $RULE_PATH/file-office.rules
include $RULE_PATH/file-other.rules
include $RULE_PATH/file-pdf.rules
include $RULE_PATH/finger.rules
include $RULE_PATH/ftp.rules
include $RULE_PATH/icmp-info.rules
include $RULE_PATH/icmp.rules
include $RULE_PATH/imap.rules
include $RULE_PATH/indicator-compromise.rules
include $RULE_PATH/indicator-obfuscation.rules
include $RULE_PATH/indicator-scan.rules
include $RULE_PATH/indicator-shellcode.rules
include $RULE_PATH/info.rules
include $RULE_PATH/malware-backdoor.rules
include $RULE_PATH/malware-cnc.rules
include $RULE_PATH/malware-other.rules
include $RULE_PATH/malware-tools.rules
include $RULE_PATH/misc.rules
include $RULE_PATH/multimedia.rules
include $RULE_PATH/mysql.rules
include $RULE_PATH/netbios.rules
include $RULE_PATH/nntp.rules
include $RULE_PATH/oracle.rules
include $RULE_PATH/os-linux.rules
include $RULE_PATH/os-mobile.rules
include $RULE_PATH/os-other.rules
include $RULE_PATH/os-windows.rules
include $RULE_PATH/other-ids.rules
include $RULE_PATH/p2p.rules
include $RULE_PATH/phishing-spam.rules
include $RULE_PATH/policy-multimedia.rules
include $RULE_PATH/policy-other.rules
include $RULE_PATH/policy.rules
include $RULE_PATH/policy-social.rules
include $RULE_PATH/policy-spam.rules
include $RULE_PATH/pop2.rules
include $RULE_PATH/pop3.rules
include $RULE_PATH/protocol-dns.rules
include $RULE_PATH/protocol-finger.rules
include $RULE_PATH/protocol-ftp.rules
include $RULE_PATH/protocol-icmp.rules
include $RULE_PATH/protocol-imap.rules
include $RULE_PATH/protocol-nntp.rules
include $RULE_PATH/protocol-pop.rules
include $RULE_PATH/protocol-rpc.rules
include $RULE_PATH/protocol-scada.rules
include $RULE_PATH/protocol-services.rules
include $RULE_PATH/protocol-snmp.rules
include $RULE_PATH/protocol-telnet.rules
include $RULE_PATH/protocol-tftp.rules
include $RULE_PATH/pua-adware.rules
include $RULE_PATH/pua-other.rules
include $RULE_PATH/pua-p2p.rules
include $RULE_PATH/pua-toolbars.rules
include $RULE_PATH/rpc.rules
include $RULE_PATH/rservices.rules
include $RULE_PATH/scada.rules
include $RULE_PATH/scan.rules
include $RULE_PATH/server-apache.rules
include $RULE_PATH/server-mail.rules
include $RULE_PATH/server-mysql.rules
include $RULE_PATH/server-oracle.rules
include $RULE_PATH/server-other.rules
include $RULE_PATH/server-samba.rules
include $RULE_PATH/server-webapp.rules
include $RULE_PATH/shellcode.rules
include $RULE_PATH/smtp.rules
include $RULE_PATH/snmp.rules
include $RULE_PATH/specific-threats.rules
include $RULE_PATH/spyware-put.rules
include $RULE_PATH/sql.rules
include $RULE_PATH/telnet.rules
include $RULE_PATH/tftp.rules
include $RULE_PATH/virus.rules
include $RULE_PATH/web-activex.rules
include $RULE_PATH/web-attacks.rules
include $RULE_PATH/web-cgi.rules
include $RULE_PATH/web-client.rules
include $RULE_PATH/web-coldfusion.rules
include $RULE_PATH/web-frontpage.rules
include $RULE_PATH/web-iis.rules
include $RULE_PATH/web-misc.rules
include $RULE_PATH/web-php.rules
include $RULE_PATH/x11.rules
include $PREPROC_RULE_PATH/preprocessor.rules
include $PREPROC_RULE_PATH/decoder.rules
include $PREPROC_RULE_PATH/sensitive-data.rules
include $SO_RULE_PATH/bad-traffic.rules
include $SO_RULE_PATH/browser-ie.rules
include $SO_RULE_PATH/chat.rules
include $SO_RULE_PATH/dos.rules
include $SO_RULE_PATH/exploit.rules
include $SO_RULE_PATH/file-flash.rules
include $SO_RULE_PATH/icmp.rules
include $SO_RULE_PATH/imap.rules
include $SO_RULE_PATH/misc.rules
include $SO_RULE_PATH/multimedia.rules
include $SO_RULE_PATH/netbios.rules
include $SO_RULE_PATH/nntp.rules
include $SO_RULE_PATH/p2p.rules
include $SO_RULE_PATH/smtp.rules
include $SO_RULE_PATH/snmp.rules
include $SO_RULE_PATH/specific-threats.rules
include $SO_RULE_PATH/web-activex.rules
include $SO_RULE_PATH/web-client.rules
include $SO_RULE_PATH/web-iis.rules
include $SO_RULE_PATH/web-misc.rules
include threshold.conf

As already posted I run it with:
 /usr/sbin/snort -D -i eth1:eth2 -u snort -g snort -c /etc/snort/snort.conf
-l /var/log/snort -Q --daq-mode inline -k none

James, as you can see, I'm using afpacket


On Mon, Aug 25, 2014 at 7:18 PM, Y M <snort () outlook com> wrote:

Please post your snort.conf, sanitizing any private info. Also the command
you use to run Snort.

YM

------------------------------
Date: Sun, 24 Aug 2014 19:58:22 +0200

Subject: Re: [Snort-users] Snort 2.9.6.2 inline mode problem
From: demonsdebason () gmail com
To: snort () outlook com
CC: snort-users () lists sourceforge net

I have already tried with this rule:
drop icmp 192.168.1.2 any -> 8.8.8.8 any (msg: "NEW TEST"; sid:10666;)

Also modified 384 ICMP rule:
drop icmp $EXTERNAL_NET any -> $HOME_NET any (msg:"PROTOCOL-ICMP PING";
icode:0; itype:8; metadata:ruleset community; classtype:misc-activity;
sid:384; rev:8;)

Set HOME_NET to any, restarted Snort and got the same crap:
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
From 8.8.8.8 icmp_seq=1 Destination Port Unreachable
64 bytes from 8.8.8.8: icmp_seq=1 ttl=46 time=40.6 ms
From 8.8.8.8 icmp_seq=2 Destination Port Unreachable
From 8.8.8.8 icmp_seq=3 Destination Port Unreachable
64 bytes from 8.8.8.8: icmp_seq=3 ttl=46 time=40.7 ms

I've set additional rule:
drop icmp any any -> any any (msg: "NEW TEST"; sid:10666;)

...and am getting:
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
From 8.8.8.8 icmp_seq=1 Destination Port Unreachable
64 bytes from 8.8.8.8: icmp_seq=1 ttl=46 time=40.2 ms
From 8.8.8.8 icmp_seq=2 Destination Port Unreachable
From 8.8.8.8 icmp_seq=3 Destination Port Unreachable
From 8.8.8.8 icmp_seq=4 Destination Port Unreachable
From 8.8.8.8 icmp_seq=5 Destination Port Unreachable
64 bytes from 8.8.8.8: icmp_seq=5 ttl=46 time=40.6 ms
From 8.8.8.8 icmp_seq=6 Destination Port Unreachable

Tried with and without normalization, works the same.

Snort is blocking, but seems not to be able to drop all the traffic:
08/24-19:56:03.511103  [Drop] [**] [1:10666:0] NEW TEST [**] [Priority: 0]
{ICMP} 192.168.1.2 -> 8.8.8.8
08/24-19:56:03.511145  [Drop] [**] [1:10666:0] NEW TEST [**] [Priority: 0]
{ICMP} x.x.x.x -> 8.8.8.8
08/24-19:56:03.551092  [Drop] [**] [1:10666:0] NEW TEST [**] [Priority: 0]
{ICMP} 8.8.8.8 -> 192.168.1.2
08/24-19:56:03.551058  [Drop] [**] [1:10666:0] NEW TEST [**] [Priority: 0]
{ICMP} 8.8.8.8 -> x.x.x.x



On Sun, Aug 24, 2014 at 6:29 PM, Y M <snort () outlook com> wrote:


Ok, assuming you are setup this way:

Internet <---> eth2 | IPS | eth1 <---> local, where eth1 and eth2 are the
listening (promiscuous) interfaces and through which traffic is passing.
When you force Snort into inline mode using afpacket, Snort (logically)
bridges the interfaces together to let the traffic pass, otherwise drop it
when matches occur. Looking again at the rule you have, both destinations
are local. What happens if you change both destinations (HOME_NET and
EXTERNAL_NET) to any/any? Better, take rule sid:384 and modify it and try
to ping an external source and see what happens. For troubleshooting
purposes only, run Snort with -A console or -A cmg so you can see whats
going directly on the console (without -D).

Also, do you have normalization enabled?

YM
------------------------------
Date: Sun, 24 Aug 2014 17:50:27 +0200

Subject: Re: [Snort-users] Snort 2.9.6.2 inline mode problem
From: demonsdebason () gmail com
To: snort () outlook com
CC: snort-users () lists sourceforge net


Here is the setup:

INTERNET <--> | IPS/router | <--> | local machines |

IPS box has 4 interfaces, where 2 have an address, others don't. It seemed
illogical to set Snort to listen on interfaces where no traffic is passing
through.
When I set Snort it to use unaddressed interfaces, nothing happens meaning
no alerts are recorded and ICMP echo test isn't working.
Tried setting up bride interfaces and assigning the two unaddressed
interface to Snort, same results.
The only results I get is having Snort listening the interfaces traffic
traverse though.


On Sun, Aug 24, 2014 at 4:24 PM, Y M <snort () outlook com> wrote:

How are you testing/connecting the client (icmp echo request sender), the
sensor, and the receiver of the icmp? The NICs that Snort is using to
receive --> pass/drop --> forward traffic should be inline with no IP
addresses. From your description, it seems that you are using the same
interface to ping the box as well as do the IPS work.

P.S.: Please respond to the list and not only to myself. Its a mutual
benefit.

YM

------------------------------
Date: Sun, 24 Aug 2014 14:00:20 +0200
Subject: Re: [Snort-users] Snort 2.9.6.2 inline mode problem
From: demonsdebason () gmail com
To: snort () outlook com


The same behavior when running with 'eth1:eth2'.
Yeah, the interfaces are in promiscuous, silly me.
Any ideas?


On Sun, Aug 24, 2014 at 7:34 AM, Y M <snort () outlook com> wrote:


inline.
------------------------------
Date: Sun, 24 Aug 2014 05:02:13 +0200
From: demonsdebason () gmail com
To: snort-users () lists sourceforge net
Subject: [Snort-users] Snort 2.9.6.2 inline mode problem


Hi all.
I've been working on my Snort IPS for some time now.
Noticed that 'drop' rules are working half-way, I have set the test rule
to drop ICMP coming to the sensor from local machine:
drop icmp 192.168.1.2 any -> 192.168.1.1 any (msg: "Test rule";
sid:110011;)

Alerts get logged and can view them via BASE, but when I ping from .2 to
.1 I get this:
PING 192.168.1.1 (192.168.1.1) 56(84) bytes of data.
64 bytes from 192.168.1.1

: icmp_seq=1 ttl=64 time=0.216 ms
From 192.168.1.1 icmp_seq=1 Destination Port Unreachable
64 bytes from 192.168.1.1

: icmp_seq=2 ttl=64 time=0.269 ms
From 192.168.1.1 icmp_seq=2 Destination Port Unreachable
64 bytes from 192.168.1.1

: icmp_seq=3 ttl=64 time=0.221 ms

So some of them are getting 'blocked'.

When I shutdown Snort I's all fine:
64 bytes from 192.168.1.1

: icmp_seq=8 ttl=64 time=0.226 ms
64 bytes from 192.168.1.1

: icmp_seq=9 ttl=64 time=0.201 ms
64 bytes from 192.168.1.1

: icmp_seq=10 ttl=64 time=0.253 ms
64 bytes from 192.168.1.1

: icmp_seq=11 ttl=64 time=0.204 ms

Here is my info:

   ,,_     -*> Snort! <*-
  o"  )~   Version 2.9.6.2 GRE (Build 77)
   ''''    By Martin Roesch & The Snort Team:
http://www.snort.org/snort/snort-team
           Copyright (C) 2014 Cisco and/or its affiliates. All rights
reserved.
           Copyright (C) 1998-2013 Sourcefire, Inc., et al.
           Using libpcap version 1.4.0
           Using PCRE version: 7.8 2008-09-05
           Using ZLIB version: 1.2.3
+++++++++++++++++++++++++++
snort    41104  4.6  2.0 1675528 1342832 ?     Ssl  04:48   0:00
/usr/sbin/snort -D -i eth1::eth2 -u snort -g snort -c /etc/snort/snort.conf
-Q --daq-mode inline -k none
+++++++++++++++++++++++++++

# Looks like you have double colons "eth1::eth2", as opposed to one colon
"eth1:eth2". Not sure if the double colons are causing the partial drops.


snort --daq-list
Available DAQ modules:
pcap(v3): readback live multi unpriv
ipfw(v3): live inline multi unpriv
dump(v2): readback live inline multi unpriv
afpacket(v5): live inline multi unpriv

++++++++++++++++++++++++++
snort.conf:

config policy_mode:inline
config daq: afpacket
config daq_dir: /usr/lib64/daq
config daq_mode: inline
config daq_var: buffer_size_mb=1024


I've tried dropping all the ICMPs in the iptables, results are as
expected, but Snort still logs the alerts.
Do you have any idea what is the issue here?

# Does Snort log the requests or replies or both? I would image if the NIC
is promiscuous, then it would still see the requests.


--
Aut viam inveniam aut faciam
:wq!

------------------------------------------------------------------------------
Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/
_______________________________________________ Snort-users mailing list
Snort-users () lists sourceforge net Go to this URL to change user options
or unsubscribe: https://lists.sourceforge.net/lists/listinfo/snort-users
Snort-users
<https://lists.sourceforge.net/lists/listinfo/snort-usersSnort-users>
list archive:
http://sourceforge.net/mailarchive/forum.php?forum_name=snort-users
Please visit http://blog.snort.org to stay current on all the latest
Snort news!




--
Aut viam inveniam aut faciam
:wq!




--
Aut viam inveniam aut faciam
:wq!




--
Aut viam inveniam aut faciam
:wq!




-- 
Aut viam inveniam aut faciam
:wq!
------------------------------------------------------------------------------
Slashdot TV.  
Video for Nerds.  Stuff that matters.
http://tv.slashdot.org/
_______________________________________________
Snort-users mailing list
Snort-users () lists sourceforge net
Go to this URL to change user options or unsubscribe:
https://lists.sourceforge.net/lists/listinfo/snort-users
Snort-users list archive:
http://sourceforge.net/mailarchive/forum.php?forum_name=snort-users

Please visit http://blog.snort.org to stay current on all the latest Snort news!

Current thread: