Kjetil's Information Center: A Blog About My Projects

UDP P2P File Transfer

This is a highly experimental program to transfer files from one host to another using only UDP. It is not very fast (maybe about 4-5 times slower than a FTP transfer over TCP), but I can imagine that it may be useful in some rare cases where for instance TCP communications are blocked by a firewall. The program principle is similar to that of TFTP transfers, but this program contains a user interface to retrieve file listings, etc. Also, every program instance is both a client and a server, so it is more geared towards being a P2P application.

Be warned that the program probably contains a few bugs, and has at least the following known errors and problems:
- Files can become corrupted if some other source injects false UDP packages.
- Possible endianness problems. I had no way to test this, so there may be issues when using the application from a computer utilizing big endian.
- There is no check to prevent the same file from being shared twice.
- If the server changes a file, this is not detected by the client.

I have released the code under a MIT License here.

Topic: Open Source, by Kjetil @ 01/01-2010, Article Link