Skip to content

Commit 12d4343

Browse files
committed
BIP-304 Implementations
1 parent d2bba98 commit 12d4343

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

src/payment_envelope/envelope.md

+15-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ Use the following steps to decode and verify the payload.
6767
2. Decode the Base64-encoded `payload` field, yielding bytes.
6868
3. Decode the Hex-encoded `pubkey` and `sig` fields, yielding bytes.
6969
4. Compute the Double-SHA256 of the decoded payload bytes from step 2, i.e. `SHA-256(SHA-256(bytes))`
70-
5. Apply BIP-340 `lift_x` algorithm on the `pubkey` to recover the full Public Key.
70+
5. Apply BIP-340 `lift_x` algorithm on the `pubkey` bytes to recover the full Public Key.
7171
A BIP-304 library will supply this step (it's essentially parsing a compressed public key.)
7272
6. Verify the BIP-340 Schnorr signature, using the Double-SHA256 hash as the `message`, and the full Public Key and `sig`.
7373
A BIP-304 library will supply the signature verification algorithm.
@@ -82,3 +82,17 @@ signed by the _Payment Relay's_ public key, i.e. the envelope was created by the
8282

8383
A reference implementation of these algorithms exist at [github.com/dogeorg/dogeconnect-go](https://github.com/dogeorg/dogeconnect-go)
8484
which can be packaged for mobile using [gomobile bind](https://pkg.go.dev/golang.org/x/mobile/cmd/gobind).
85+
86+
### BIP-304 Implementations
87+
88+
| Language | BIP-304 Implementation |
89+
|----------|---------------------------------------------------------------------|
90+
| C/C++ | <https://github.com/bitcoin-core/secp256k1> |
91+
| Go | <https://pkg.go.dev/github.com/btcsuite/btcd/btcec/v2/schnorr> |
92+
| | <https://github.com/Yawning/secp256k1-voi> |
93+
| Rust | <https://lib.rs/crates/secp256k1> |
94+
| C# | <https://github.com/zone117x/Secp256k1.Net> |
95+
| Java | <https://github.com/SamouraiDev/BIP340_Schnorr> |
96+
| | <https://gitlab.com/bitcoinj/secp256k1-jdk> |
97+
| Dart | <https://pub.dev/packages/bip340> |
98+
| Python | <https://github.com/bitcoin/bips/blob/master/bip-0340/reference.py> |

0 commit comments

Comments
 (0)