Here’s the first release of a small program I wanted to write for various reasons including testing of firewall ACL’s. I’m sure there are other similar programs like this out there but I wanted one that I had intimate knowledge of so that I could expand it to fit my needs and I had a lot of fun working with the libnet library.
This is release 0.1 of what will hopefully be a project that gets updated often. I tested this with version 18.104.22.168 of libnet. To compile simply run ‘gcc pacman.c -lnet -o pacman’.
If you run the program with no arguments it will give you the current usage options which looks like this.
PacMan v.01 [Packet Generation Tool]
-m source mac address
-M destination mac address
-s source ip address
-d destination ip address
-p source port
-P destination port
-x tcp payload
Test it out let me know what you’d like added and look for lots of updates. I plan on changing the output a little as well as adding an option to do a walk through mode to prompt for all options to construct a full TCP packet.