{"repo":"guggero/bip-schnorr","free":true,"listed":false,"github":"https://github.com/guggero/bip-schnorr","clone":"git clone https://github.com/guggero/bip-schnorr.git","description":"Pure JavaScript implementation of BIP340 Schnorr Signatures for secp256k1","language":"JavaScript","stars":130,"topics":["schnorr","signatures","bitcoin","bip340"],"license":"MIT","category":"blockchain-web3","readme_excerpt":"Pure JavaScript implementation of BIP340 Schnorr Signatures for secp256k1 This is a pure JavaScript implementation of the standard 64-byte Schnorr signature scheme over the elliptic curve secp256k1 . The code is based upon the BIP340 proposal. The current version passes all test vectors provided here. The MuSig implementation is based upon the C implementation in the secp256k1-zkp fork I am by no means an expert in high performance JavaScript or the underlying cryptography. This library is slow, not peer reviewed at all, not tested (outside of passing the official test vectors) against other, real implementations and should therefore only be used for educational purposes! Please do not use for production setups! How to install NPM : yarn : How to use NOTE: All parameters are either of type BigInteger or Buffer (or an array of those). Schnorr muSig API schnorr.sign(privateKey : BigInteger string, message : Buffer) : Buffer Sign a 32-byte message with the private key, returning a 64-byte signature. schnorr.verify(pubKey : Buffer, message : Buffer, signature : Buffer) : void Verify a 64-byte signature of a 32-byte message against the public key. Throws an Error if verification fails. schnorr.batchVerify(pubKeys : Buffer[], messages : Buffer[], signatures : Buffer[]) : void Verify a list of 64-byte signatures as a batch operation. Throws an Error if verification fails. schnorr.muSig.computeEll(pubKeys : Buffer[]) : Buffer Generate ell which is the hash over all public keys partic","default_branch":null,"files":null,"tree":[],"storefront":"/r/guggero","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/guggero/bip-schnorr/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}