|
|||||||||||
|
Re: [Snort-devel] Bug in ByteTest() function / byte_test keyword on little endian systems?
From: Chris Green <cmg(at)sourcefire.com>
Date: Thu Apr 24 2003 - 09:28:51 EDT "Jason V. Miller" <jmiller@securityfocus.com> writes:
[...] > I have a few questions about this.
I believe it comes from the | use for conversion and requiring knowledge of how the host stores it's ints. See comments below. > As the packet data is stored in memory as an array of unsigned chars
Yes I will agree that's a bug, stemming from almost all the test cases we'd performed were 4 byte values. The comment about most of us using big endian machines was accurate for when this was developed. However, everyone but Marty will be using little endian machines after this week. > Both little endian and big endian machines should be able to perform
Yes that is much easier to read. Thanks for the detailed analysis. I'll spend some time converting that and making byte_jump and byte_test use the same code path for this operation ( something that was already on my todo list )
Thanks,
-- Chris GreenReceived on Thu Apr 24 09:39:05 2003 This archive was generated by hypermail 2.1.8 : Wed Aug 23 2006 - 14:08:05 EDT |
||||||||||
|
|||||||||||