C
Chris
Hi,
I am trying to group packets by their TCP connection, this is more of
a logic question so I hope this is the relevant group. In a tcp
connection A-B, I would like to put a packet in a container for A->B
or B->A (depending on the source and destination).
To do this I overloaded the < operator below.
if (one.src_addr < two.src_addr)
if (one.dst_addr < two.dst_addr)
if (one.src_port < two.src_port)
if (one.dst_port < two.dst_port)
return true;
/*else*/
return false;
However a packet going from b->a will be put in the same container as
a packet going from a->b. Why is this?
Thanks for any help
Chris
I am trying to group packets by their TCP connection, this is more of
a logic question so I hope this is the relevant group. In a tcp
connection A-B, I would like to put a packet in a container for A->B
or B->A (depending on the source and destination).
To do this I overloaded the < operator below.
if (one.src_addr < two.src_addr)
if (one.dst_addr < two.dst_addr)
if (one.src_port < two.src_port)
if (one.dst_port < two.dst_port)
return true;
/*else*/
return false;
However a packet going from b->a will be put in the same container as
a packet going from a->b. Why is this?
Thanks for any help
Chris