Revert "fix: allow HTTP LNURL for RFC1918/loopback baseurls (#2)"
Some checks failed
lint.yml / Revert "fix: allow HTTP LNURL for RFC1918/loopback baseurls (#2)" (push) Failing after 0s
Some checks failed
lint.yml / Revert "fix: allow HTTP LNURL for RFC1918/loopback baseurls (#2)" (push) Failing after 0s
This reverts commit66026ab. Closes #2 as resolved by switching the dev LNbits to TLS (self-signed cert) instead of carving out plain HTTP for RFC1918 hosts. With HTTPS the producer-side python-lnurl validation accepts any host, AND the lnbits-core consumer-side `lnurlscan` accepts it too — the symmetric problem the carve-out couldn't solve on its own. `create_lnurl_from_baseurl` (#1, `e9d911e`) is kept — it's orthogonal to the transport scheme and still wanted for the nostr-transport `lnurl=null` fix.
This commit is contained in:
parent
0e06ab2087
commit
2877cf6b20
3 changed files with 5 additions and 107 deletions
|
|
@ -211,7 +211,9 @@ def _populate_lnurl(link: WithdrawLink) -> WithdrawLink:
|
|||
duplicating state LNbits already knows. See aiolabs/withdraw#1.
|
||||
"""
|
||||
try:
|
||||
link.lnurl, link.lnurl_url = create_lnurl_from_baseurl(link)
|
||||
encoded = create_lnurl_from_baseurl(link)
|
||||
link.lnurl = str(encoded.bech32)
|
||||
link.lnurl_url = str(encoded.url)
|
||||
except ValueError:
|
||||
pass
|
||||
return link
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue