Twisted can do low-level networking, too.
Here's an example that tries to show the relationships of different classes and how data could flow for receiving packets.
FileWrapper | v PcapProtocol TuntapPort | | +------------+ v EthernetProtocol | +------------+-----------+---... v v v IPProtocol ARPProtocol IPv6Protocol | +-------------+----------------+---... v v v RawUDPProtocol RawICMPProtocol RawTCPProtocol | v DatagramProtocol
Of course, for writing, the picture would look pretty much identical, except all arrows would be reversed.
TODO
TODO
TODO
TODO