Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jimtje/walletlib
Unified interface to work with cryptocurrency wallet.dat, .wallet, .key files. Can automatically attempt to figure out what type of coin a .dat wallet contains via its prefix.
https://github.com/jimtje/walletlib
altcoin bitcoin bitcoin-wallet blockchain crypto cryptocurrency cryptocurrency-wallet dogecoin dogecoin-wallet litecoin litecoin-wallet python pywallet wallet wallet-files wallets wallets-management
Last synced: about 1 month ago
JSON representation
Unified interface to work with cryptocurrency wallet.dat, .wallet, .key files. Can automatically attempt to figure out what type of coin a .dat wallet contains via its prefix.
- Host: GitHub
- URL: https://github.com/jimtje/walletlib
- Owner: jimtje
- License: unlicense
- Created: 2020-01-01T05:08:19.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-02-20T18:04:01.000Z (over 2 years ago)
- Last Synced: 2024-09-28T20:23:12.115Z (about 2 months ago)
- Topics: altcoin, bitcoin, bitcoin-wallet, blockchain, crypto, cryptocurrency, cryptocurrency-wallet, dogecoin, dogecoin-wallet, litecoin, litecoin-wallet, python, pywallet, wallet, wallet-files, wallets, wallets-management
- Language: Python
- Homepage:
- Size: 295 KB
- Stars: 24
- Watchers: 4
- Forks: 13
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# walletlib
![PyPI - Python Version](https://img.shields.io/badge/python-3.7%20%7C%203.8%20%7C%203.9-blue)Unified interface to programmatically open and extract data from cryptocurrency wallet backup files
## Quick Start with Docker - Start here if you simply need to dump the contents of a wallet file
### Make sure that the files you are trying to open are in one directory.
```bash
$ docker pull jimzhou/walletlib:latest
$ docker run -v /path/to/your/wallet/folder:/app jimzhou/walletlib:latest wallet.dat -o wallet_output.txt --keys -p password
```
Output file will be in the directory with the wallet. --keys and -p are optional## Quick Start with installation
This module requires Python 3.7+
Note: prior to installation, make sure that BerkeleyDB 4.8+ is installed.
With Homebrew:
```bash
$ brew install berkeley-db@4
```On Ubuntu
```
$ sudo apt-get install libdb++-dev python3-bsddb3
``````bash
$ pip install walletlib
```
A convenient cli script is available after installation.
```bash
$ python -m dumpwallet wallet.dat -o output.txt
```
or
```bash
$ dumpwallet wallet.dat -o output.txt
$ dumpwallet wallet-protobuf -o output.txt --keys
```## Features
- Automatic reading of version byte and WIF prefix from default keys
- Dumping just keys or all data
- Read only access of wallet files## Installation
The simplest way to install walletlib is using pip.
```bash
$ pip install walletlib
```
You can also clone this repo and then run
```bash
$ python setup.py install
```
## Usage
```python
import walletlibwallet = walletlib.Walletdat.load("path/to/wallet.dat")
wallet.parse(passphrase="password")
wallet.dump_all(filepath="output.txt")
wallet.dump_keys(filepath="output_keys.txt")```
Bitcoinj wallets:```python
import walletlibwallet = walletlib.ProtobufWallet.load("path/to/wallet-protobuf")
wallet.parse()
wallet.dump_all(filepath="output.txt")
wallet.dump_keys(filepath="output_keys.txt")
```## Roadmap
- [x] wallet.dat
- [x] Encrypted keys
- [x] Auto-identify prefix
- [x] Decrypt encrypted keys
- [x] p2pkh Wallets
- [ ] Bech32 wallets
- [x] Bitcoinj/Dogecoinj/Altcoinj wallets
- [x] Open unencrypted wallet-protobuf/multibit .wallet/.key files
- [ ] Decrypt encrypted wallets
- [ ] Coinomi protobuf wallets
- [ ] Blockchain.com wallet.aes.json
- [ ] Documentation