From rusty at rustcorp.com.au Sat Apr 29 00:57:32 2017 From: rusty at rustcorp.com.au (Rusty Russell) Date: Sat, 29 Apr 2017 10:27:32 +0930 Subject: [Lightning-dev] [RFC] Lightning payment format Message-ID: <87h918ghdv.fsf@rustcorp.com.au> Hi all! I threw together this draft format for requesting lightning payments, and an (incomplete) implementation: - https://github.com/rustyrussell/lightning-payencode The representation size ranges from ~181 characters upwards: we could squeeze at least 5 of those out if we cared. Bech32 only guarantees to detect 3 errors at these lengths (beyond 1024 it's only 1), but the signature is the final error detection. You'll notice one optimization for the common case: we use the 8-byte chanid (stealing 1 bit) to compactly refer to the destination. This is shorter than a full 33-byte pubkey, and relies on the fact that the network topology is well-known. We use these same style of IDs in the channel announcement messages already. I look forward to both the bikeshed comments, and more substantive feedback :) Thanks! Rusty.