--- /dev/null
+Test the http_request_line keyword
--- /dev/null
+alert http any any -> any any (http_request_line; bsize:>10; sid:1;)
+alert http any any -> any any (http_request_line; bsize:<100; sid:2;)
+alert http any any -> any any (http_request_line; bsize:10<>100; sid:3;)
+alert http any any -> any any (http_request_line; bsize:>100; sid:4;)
+alert http any any -> any any (http_request_line; content:"GET /index.html HTTP/1.0"; sid:5;)
--- /dev/null
+args:
+- --set stream.midstream=true
+
+checks:
+- filter:
+ count: 1
+ match:
+ event_type: alert
+ alert.signature_id: 1
+- filter:
+ count: 1
+ match:
+ event_type: alert
+ alert.signature_id: 2
+- filter:
+ count: 1
+ match:
+ event_type: alert
+ alert.signature_id: 3
+- filter:
+ count: 0
+ match:
+ event_type: alert
+ alert.signature_id: 4
+- filter:
+ count: 1
+ match:
+ event_type: alert
+ alert.signature_id: 5
+- filter:
+ count: 1
+ match:
+ event_type: flow
+- filter:
+ count: 1
+ match:
+ event_type: stats
--- /dev/null
+#!/usr/bin/env python
+from scapy.all import *
+
+pkts = []
+
+pkts += Ether(dst='ff:ff:ff:ff:ff:ff', src='00:01:02:03:04:05')/ \
+ Dot1Q(vlan=6)/ \
+ IP(dst='1.2.3.4', src='5.6.7.8')/TCP(sport=6666, dport=63, flags='P''A')/"GET /index.html HTTP/1.0\r\nHost: www.openinfosecfoundation.org\r\nUser-Agent: This is dummy message body\r\nContent-Type: text/html\r\n"
+
+wrpcap('input.pcap', pkts)