p4 [![/space/notes.png](/space/notes.png)](/space/p4) For the impatient: [Download P4 0.3.1](/space/p4-0.3.1.tar.bz2) [Original project proposal](http://ryan.barrett.name/p4/doc/html/proposal.html) [Poster (with diagrams)](http://ryan.barrett.name/p4/doc/html/poster.html) [Protocol specification](http://ryan.barrett.name/p4/doc/html/protocol.html) [API documentation](http://ryan.barrett.name/p4/doc/html/p4plugin_8h.html) [P4](/space/p4) is a fully functional, self-organizing overlay network similar to [Gnutella](http://rfc-gnutella.sourceforge.net/) and [Freenet](http://freenet.sf.net/). However, P4 differs in that it provides an [API](http://ryan.barrett.name/p4/doc/html/p4plugin_8h.html) for developing plugin applications on top of the network. P4 handles the networking and exports functionality for unicast, multicast, user and plugin discovery, and strong encryption and authentication. This frees developers from worrying about networking, and allows them to focus on building real functionality. Since its release in early 2001, P4 has been surpassed by other general-purpose overlay platforms such as [JXTA](http://jxta.org/), [Groove](http://groove.net/), and Microsoft's [Windows Peer-to-Peer SDK](/space/windows+p2p). Furthermore, [many](http://overnet.com/) [other](http://freedom.net/) [file](http://freehaven.net/) [sharing](http://mnet.sourceforge.net/) [networks](http://en.wikipedia.org/wiki/FastTrack) have long been superior to P4 in terms of routing algorithms, bandwidth management, anonymity, maturity, etc. (They're mostly dedicated file-sharing networks, though, not general-purpose networks.) For these reasons, P4 is not currently as competitive as it was a few years ago. However, it's still a viable alternative, especially if you're looking for a simple, lightweight, embeddable networking solution. P4 requires only [Berkeley sockets](http://en.wikipedia.org/wiki/Berkeley_sockets) and [pthreads](http://www.llnl.gov/computing/tutorials/workshops/workshop/pthreads/MAIN.html), and the shared library weighs in at a slim 270K. P4 has been tested on RedHat 9, SUSE 8, Debian stable, Solaris/SunOS 5.8, and Mac OS X. It should build on most \*nix platforms without much modification. Windows Visual Studio project files are included for building on Windows, but they're not currently maintained. P4 is distributed under the [GPL](http://www.gnu.org/licenses/gpl.html). Copyright 2001-2004 [Ken Ashcraft](http://keeda.stanford.edu/~kash), [Ryan Barrett](http://ryan.barrett.name/), [Maulik Shah](http://maulik.net/), and [Nathan Stoll](http://cs.stanford.edu/~nstoll). See also: * [synchronizing mp3 playback](/space/synchronizing mp3 playback) * [libmsntp](/space/libmsntp) * [libwebserver shutdown patch](/space/libwebserver shutdown patch)