parsing packets

Dan Stromberg drsalists at
Mon Jul 11 19:16:32 EDT 2011

On Sun, Jul 10, 2011 at 1:59 PM, Littlefield, Tyler <tyler at>wrote:

> Hello all:
> I'm working on a server that will need to parse packets sent from a client,
> and construct it's own packets.

I like to use this module (I wrote while in the employ of UCI, so it's under
a UCI - BSDesque - license, but they've given redistribution permission so
long as the module is under their license) to extract pieces from a data
source with varied field lengths:

I use it often with TCP.  For UDP, I'd probably catentate the blocks
recieved and then pull data back out of the aggregate using bufsock - to
deal with the possibility of fragmentation or aggregation in transit.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Python-list mailing list