{
"$type": "com.whtwnd.blog.entry",
"theme": "github-light",
"title": "How Streamplace Works: Signing and Segmentation",
"content": "## Step 1: Generate a Stream Key\n\nThe first thing you do to stream on Streamplace is generate a stream keypair. These keys are `secp256k1` keys, the same kind of keys used in Ethereum and ATProto. The public key gets posted publicly to your PDS as a `place.stream.key` record. The private key is used to authorize your broadcast; it gets pasted into your streaming software like OBS. (If you're streaming from an app or website, this all happens internally.)\n\n## Step 2: Stream \n\nSo we can model a livestream as somebody throwing a one-second video file in your face every second. In fact, for certain livestreaming protocols such as HLS and DASH, that's exactly what's happening behind the scenes: your computer is downloading a one-second video file every second and playing them back-to-back-to-back.\n\nSo that's what we do. As your stream comes in, we slice it up into one-second MP4 files. Later on, when the stream is played back, those MP4 files are stitched back together into a contigious WebRTC stream for you to watch.\n\n## Step 3: Sign\n\nEach of our freshly-sliced one-second MP4 files is signed using the private key generated in step 1. This signature is embedded within the file itself, making it both secure and easy to work with. Change a single bit of the file and it'll be rejected by the verifier as invalid.\n\n## Step 4: Broadcast\n\nLet's gooooooo! Now that your video is signed, it can be sent all over the world. Other Streamplace nodes can choose to syndicate your livestream, rebroadcasting your data.",
"createdAt": "2025-07-18T23:26:45.347Z",
"visibility": "author"
}