Commit Graph

3 Commits

Author SHA1 Message Date
Rusty Russell c08ff167b2 decode: new generic API to decode bolt11 and bolt12.
This is experimental for now, but can eventually deprecated
'decodepay' and even decode other kinds of messages.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2021-01-09 14:34:35 +10:30
Rusty Russell 1293852542 common/bolt12: add calculations for offer periods.
It's not trivial, but fortunately gmtime and mktime exist already.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2020-12-23 14:24:39 +01:00
Rusty Russell 4d086e9939 common/bolt12: encode/decode for bolt12 offer, invoice_request and invoice
Note the collapse of '+\s*' and the test cases from the spec.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2020-12-09 16:40:13 +10:30