Snort mailing list archives
TCP flags issue
From: sajjad purmohseni <spurmohseni () yahoo com>
Date: Tue, 3 Feb 2015 21:42:52 +0000 (UTC)
Hi all As you know TCP has 9 flags. But as you see TCP flags of snort is 8 bits defined in sf_snort_packet.h file: typedef struct _TCPHeader{... uint8_t flags; ...} TCPHeader; also predefinded flags are 9 bits as must be: #define TCPHEADER_FIN 0x01#define TCPHEADER_SYN 0x02... Now I am confused if I want to check TCP_SYN flag; how to do that. I have used this but it doesn't return correct answer: if (packet->tcp_header->flags & TCPHEADER_SYN){ ...} Can anybody guide me about this issue? Thank you. ---- kind regards;Sajad Pourmohseni
------------------------------------------------------------------------------ Dive into the World of Parallel Programming. The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________ Snort-devel mailing list Snort-devel () lists sourceforge net https://lists.sourceforge.net/lists/listinfo/snort-devel Archive: http://sourceforge.net/mailarchive/forum.php?forum_name=snort-devel Please visit http://blog.snort.org for the latest news about Snort!
Current thread:
- TCP flags issue sajjad purmohseni (Feb 03)
- Re: TCP flags issue Balasubramaniam Natarajan (Feb 04)
- Re: TCP flags issue Steven Sturges (Feb 04)
- Re: TCP flags issue sajjad purmohseni (Feb 05)
- Re: TCP flags issue Al Lewis (allewi) (Feb 09)
- Re: TCP flags issue Steven Sturges (Feb 04)
- Re: TCP flags issue Balasubramaniam Natarajan (Feb 04)