Ethical Hacking Learn to find vulnerabilities before the bad guys do! Gain real world hands on hacking experience in our state of the art hacking lab. Course designed and taught by expert instructors with years of penetration testing experience. 12 student maximum in every class. Certification attempt included in every package. | Computer Forensics Training at InfoSec Institute Gain the in-demand skills of a certified computer examiner, learn to recover trace data left behind by fraud, theft, and cybercrime perpetrators. Discover the source of computer crime and abuse at your organization so that it never happens again. All of our class sizes are guaranteed to be 12 students or less to facilitate one-on-one interaction with one of our expert instructors. |

| Subject: | [Snort-sigs] Question on function of "within" command |
|---|---|
| Date: | Mon, 31 Jul 2006 17:15:00 -0400 |
Although documented at:
http://www.snort.org/docs/snort_htmanuals/htmanual_233/node21.html#SECTION00457000000000000000
The "within" command seems a little confusing if used with the "distance" command, which I have seen before in some custom rules.
So, for example, if one has a rule such as:
content:"|XYZ|"; depth:3; content:"|1|"; distance:8; depth:1; content:"|2|"; distance:4; depth:1;
This obviously means "XYZ", skip 8 bytes, "1", skip 4 bytes, "2"
Now, if we add the "within" parameter:
content:"|XYZ|"; depth:3; content:"|1|"; distance:8; depth:1; content:"|2|"; distance:4; depth:1; within:2;
How is this really being inspected?
It seems from the documentation that this could mean that the value of "2" is normally 4 bytes from the value "1", but could also be encountered 2 bytes earlier. So effectively, the value of "2" could be 2 to 4 bytes from "1".
Is this correct?
If not, can someone explain how the "within" parameter functions when in combination with the "distance" paramter?
Thanks Al
------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________ Snort-sigs mailing list Snort-sigs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/snort-sigs
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [Snort-sigs] bad rule, Gentoo-Wally |
|---|---|
| Next by Date: | [Snort-sigs] Bleedingsnort.com Daily Update, bleeding |
| Previous by Thread: | [Snort-sigs] any way to disable these alerts:http_inspect: OVERSIZE REQUEST-URI DIRECTORY, Russell Fulton |
| Next by Thread: | Re: [Snort-sigs] Question on function of "within" command, Joel Esler |
| Indexes: | [Date] [Thread] [Top] [All Lists] |