1
0
Fork 0
mirror of https://github.com/lightning/bolts.git synced 2025-03-13 11:35:41 +01:00

Add test vector for (invalid) mixed-case offer encoding

The spec requires the bech32 offer encodings to be all upper- or
lowercase, but disallows mixed-case encodings.

Here, we add a test vector for this.
This commit is contained in:
Elias Rohrer 2025-01-07 09:13:27 +01:00
parent c41536829c
commit 4b85875694
No known key found for this signature in database
GPG key ID: 36153082BDF676FD

View file

@ -29,6 +29,11 @@
"valid": true,
"string": "LNO1PQPS7SJQPGT+ YZM3QV4UXZMTSD3JJQER9WD3HY6TSW3+ 5K7MSJZFPY7NZ5YQCN+\nYGRFDEJ82UM5WF5K2UCKYYPWA3EYT44H6TXTXQUQH7LZ5DJGE4AFGFJN7K4RGRKUAG0JSD+\r\n 5XVXG"
},
{
"comment": "Mixed case is invalid",
"valid": false,
"string": "LnO1PqPs7sJqPgTyZm3qV4UxZmTsD3JjQeR9Wd3hY6TsW35k7mSjZfPy7nZ5YqCnYgRfDeJ82uM5Wf5k2uCkYyPwA3EyT44h6tXtXqUqH7Lz5dJgE4AfGfJn7k4rGrKuAg0jSd5xVxG"
},
{
"comment": "+ must be surrounded by bech32 characters",
"valid": false,