Convert Taproot private keys to public keys.
This is a simple JavaScript application that allows you to convert Bitcoin Taproot private keys (64-character hex strings) to their corresponding public keys.
- Convert Taproot private keys to public keys
- Command-line interface
- Browser-based web interface (no server required)
- Simple and fast
The project has been simplified to use vanilla JavaScript with ES modules:
key2pub/
├── index.js # Main library functions
├── cli.js # Command-line interface
├── index.html # Web UI
├── script.js # Web UI JavaScript
└── styles.css # Web UI styling
npm install
Run directly:
node cli.js <private-key>
Or install globally:
npm install -g .
key2pub <private-key>
Simply open the index.html
file in any modern browser. No server is required as it uses ES modules to directly import the library functions.
Converts a Taproot private key to a public key.
-
privateKey
: A 64-character hex string representing the private key. - Returns: A 64-character hex string representing the public key.
Validates if a string is a valid Taproot private key.
-
privateKey
: The string to validate. - Returns: A boolean indicating whether the string is a valid private key.
Validates if a string is a valid Taproot public key.
-
publicKey
: The string to validate. - Returns: A boolean indicating whether the string is a valid public key.
MIT