It is free and open-source software, under <x id="START_LINK" ctype="x-a" equiv-text="<a href="https://github.com/Chocobozzz/PeerTube/blob/develop/LICENSE">"/>AGPLv3 licence<x id="CLOSE_LINK" ctype="x-a" equiv-text="</a>"/>.
PeerTube uses the BitTorrent protocol to share bandwidth between users by default to help lower the load on the server, but ultimately leaves you the choice to switch back to regular streaming exclusively from the server of the video. What follows applies only if you want to keep using the P2P mode of PeerTube.
In theory, someone with enough technical skills could create a script that tracks which IP is downloading which video. In practice, this is much more difficult because:
An HTTP request has to be sent on each tracker for each video to spy. If we want to spy all PeerTube's videos, we have to send as many requests as there are videos (so potentially a lot)
For each request sent, the tracker returns random peers at a limited number. For instance, if there are 1000 peers in the swarm and the tracker sends only 20 peers for each request, there must be at least 50 requests sent to know every peer in the swarm