mirror of
https://github.com/bitcoin/bips.git
synced 2025-05-12 12:03:29 +00:00
BIP 72: Reduce the amount of escaping needed
RFC 3986 obsoletes RFC 1738, which this BIP was wrongly referencing. The new RFC requires far less escaping for query parameters.
This commit is contained in:
parent
c823eeb596
commit
820736896e
@ -22,8 +22,9 @@ bitcoin wallets.
|
|||||||
|
|
||||||
The bitcoin: URI scheme is extended with an additional, optional
|
The bitcoin: URI scheme is extended with an additional, optional
|
||||||
"r" parameter, whose value is a URL from which a PaymentRequest
|
"r" parameter, whose value is a URL from which a PaymentRequest
|
||||||
message should be fetched (unsafe and reserved octets in the URL value
|
message should be fetched (characters not allowed within the scope
|
||||||
must be encoded as described in RFC 1738).
|
of a query parameter must be percent-encoded as described in RFC 3986
|
||||||
|
and bip-0021).
|
||||||
|
|
||||||
If the "r" parameter is provided and backwards compatibility
|
If the "r" parameter is provided and backwards compatibility
|
||||||
is not required, then the bitcoin address portion of the URI may be
|
is not required, then the bitcoin address portion of the URI may be
|
||||||
@ -52,9 +53,9 @@ r parameter and will initiate a payment to bitcoin address.
|
|||||||
==Examples==
|
==Examples==
|
||||||
A backwards-compatible request:
|
A backwards-compatible request:
|
||||||
<pre>
|
<pre>
|
||||||
bitcoin:mq7se9wy2egettFxPbmn99cK8v5AFq55Lx?amount=0.11&r=https%3A%2F%2Fmerchant.com%2Fpay.php%3Fh%3D2a8628fc2fbe
|
bitcoin:mq7se9wy2egettFxPbmn99cK8v5AFq55Lx?amount=0.11&r=https://merchant.com/pay.php?h%3D2a8628fc2fbe
|
||||||
</pre>
|
</pre>
|
||||||
Non-backwards-compatible equivalent:
|
Non-backwards-compatible equivalent:
|
||||||
<pre>
|
<pre>
|
||||||
bitcoin:?r=https%3A%2F%2Fmerchant.com%2Fpay.php%3Fh%3D2a8628fc2fbe
|
bitcoin:?r=https://merchant.com/pay.php?h%3D2a8628fc2fbe
|
||||||
</pre>
|
</pre>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user