top | item 46680256

A Serverless WebRTC Signaling Protocol Using QR Codes

4 points| martinprins | 1 month ago |magarcia.io

3 comments

order

martinprins|1 month ago

Author here. Started with a simple problem: sync data between two phones with no backend.

WebRTC signaling SDPs are ~2.5KB. Too large for practical QR scanning. When you control both endpoints, most of that is unnecessary ceremony.

Key insights: derive ICE credentials from DTLS fingerprint via HKDF, use binary encoding (IP as 4 bytes not ASCII), skip compression (DEFLATE increases size on high-entropy data), skip base64 (QR supports raw binary).

obiefernandez|1 month ago

Love the creativity and that you took the time to explain every step of the discovery.

martinprins|1 month ago

Thanks! The write-up took longer than the actual protocol design.