This project simulates a simple local area network communication using Python. The project introduction is here. The report is here.
When new source/destination is from an old mac with new interface/old interface with new mac, it will be update.
Key changes in add_mac(self, mac, interface).
The packages are encrypted and decrypted.
Key changes in send_packet(self, dst_mac, payload, switch), receive_packet(self, packet).
Using python to do modulation, we can transfer the string to digits and transmitt them. Write modulation module and demoulation module.
Key changes in string2digital(message), digital2string(message)
Firewall is very important for the true network. The program allows adding firewall rule and block them.
Key changes in check_firewall(self, packet)
All works are integrated into here.