Closed junderw closed 5 years ago
OR an f field with unknown version, OR p, h, or n fields that do NOT have data_lengths of 52, 52, or 53, respectively.
Might need to work on this more... We should avoid parsing the wrong-version fallback address and avoid parsing the p, h, n of wrong lengths, but still keep them in the tags for reconstruction.
unknownTag type should maybe be changed to "invalid tag" or something... Then we can pipe any incorrect tags into that format. (encode with bech32 should be fine)
Not just unknown tags, but tags that are invalid...
meh, on second thought. just allowing for unknown tags should be fine for now...
@cavanmflynn Published to npm in v1.2.5
Alternative to #15
There should be a way to encode unknown tags so that you can re-encode decoded payment requests.
canReconstruct check should make sure that people do not create random tags, but still allow for decoding and reconstructing with encode.