Ethereal-dev: Re: [Ethereal-dev] SMPP: Multiple PDU's within one TCP packet

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: "Olivier Biot" <ethereal@xxxxxxxxxx>
Date: Tue, 20 Jan 2004 19:05:11 +0100
From: "Chris Wilson"

| On Sun, 18 Jan 2004 04:42:49 -0800
| Guy Harris <guy@xxxxxxxxxxxx> wrote:
|
| > On Sun, Jan 18, 2004 at 12:16:23PM +0000, Chris Wilson wrote:
| > > Ok - I'll make things work that way.
| >
| > Note that if you make it use "tcp_dissect_pdus()" you'll get that
for
| > free.
|
| Yep, it's great :)
|
| Lets have another go then, this is much nicer... Attached is a patch
to packet-smpp.c (version 1.25 - that's before Olivier's last commit).
It uses tcp_dissect_pdus() if it's running on TCP (it checks that
pinfo->ptype==PT_TCP - which I hope is sensible!).

Checked in, along with a preference to select whether we want SMPP
reassembly or not (default: not).
I also removed the while loop for multiple PDU dissection from the PDU
dissector and moved it to the new dissect_smpp() method.

Note that we currently keep track of the first or subsequent PDUs by
means of a global variable which is siatic to the SMPP dissector. I
hope this is acceptable.

If you test the new dissector code with the two captures Chris sent
last Sunday, yuo'll see that the TCP reassembly code does not generate
a "Unreassembled packet" but rather a "Short packet" warning. I'm not
sure how to fix this.

Regards,

Olivier