Python Processing of WWIVnet Packets

I’ve started writing some Python functions that read in WWIVnet packets. So far, so good. I can read in basic WWIV Network packets, identify their headers and their payload. The python functions can handle multiple message packets, but currently don’t do anything besides displaying the network record header and the raw message payload. I haven’t written anything to handle short or mangled packets yet. I’m basically just writing code blocks to be able to process the network packets, perhaps manipulate them, write or rewrite network packets. The next step would be to actually process the payloads as well. For now, I probably need more sample packets, but where do I get any. Hmmm…

A Step Back To Fundamentals

Instead of proceeding forward as fast as I can, I’ve decided to take a step back and relearn some basics. In particular, I’ve started reading through “Linux Systems Programming” by Robert Love to give me better grounding in writing C code for Linux.

I’ve finished the first chapters on files, open(), read(), write(), fsync(), fdatasync(), lseek() and proceeding slowly. I don’t intend to rush through this to allow myself enough time to absorb all the new information, and to make sure that I understand all the nice little details.

Parallel to this, I’m also reading “Test Driven Development Using Python.”

WWIV net38b3 on aliens

I updated WWIV networking software from NET37 to NET38b3. Rushfan is maintaining the official networking stack. I have some ideas for doing a complete rewrite for Linux, but am not sure if I can manage to write a portable rewrite.

The network stack of WWIV consists of several components. I’m planning to rewrite one component at a time, so that we can actually run the entire WWIV BBS + WWIV Network + WWIVToss (FTN<->WWIV) on Linux without resorting to dosemu.

Currently, the WWIV BBS software itself already runs on Linux. See WWIV BBS v5.0 Project.

The NET37/NET38 WWIV networking stuff runs mostly under DOS, so requires Linux WWIV sysops to use dosemu and some creative scripting to get it to work.

There is already a stub NETWORK.EXE replacement in the WWIV BBS project tree, which in turn calls NETWORK0.EXE, NETWORKB (Rushfan’s Binkp WWIV transport replacement) or NETWORKP.

NETWORKP (or the WWIV PPP Project component) has some parts of it that have already been replaced with a bunch of scripts which require Python to handle the transport of network files from the WWIV BBS to the hub via SMTP, and fetchmail to retrieve from the hub to the WWIV BBS via POP3. I’m currently working on replacing NETWORKP completely with a Python script to do the conversion of files from their Sx.NET format to their UUencoded format along with their mail headers. Once this is done,  NETWORKP.exe can be replaced on Linux.

NETWORKB is an option, of course. But I’m all for flexibility and having alternatives. Besides, it’s something I like working on while learning in the process.