Revert "remove p2p stuff"

This reverts commit 485bb7310d4b8f03a83ec1b6487ab94e0aa06213.