Giter Site home page Giter Site logo

wallet-decrypt's Introduction

Bitcoin Wallet Decrypt (BackupFile -> Mnemonic)

If you have been using the Bitcoin Wallet from Bitcoin Wallet developers, it is likely you want to get your Bitcoin Cash or take control of your private keys.

I wrote this script to simplify this process for myself. This script will obtain a BIP-39 mnemonic that can later be used to transfer Bitcoin or Bitcoin Cash to other wallets.

WARNING: You will be decrypting your wallet so the private key (mnemonic) might be compromised.

Instructions

In your mobile:

  • Go to Safety and remove the spending PIN.
  • Backup your wallet. Remember the password you use.
  • Connect your phone with a usb cable and copy the backup file to your computer.

In your computer

Install dependencies

pip install pycrypto protobuf

Run the script (replace with the appropriate FILENAME(backup file) and PASSWORD(your backup password))

wallet-decrypt.py FILENAME PASSWORD

You will get a mnemonic and derivation path that can be used in Electrum / Electrum Cash.

This software is provided under the Apache License Version 2.0 - Use at your own risk

wallet-decrypt's People

Contributors

jleni avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

wallet-decrypt's Issues

Errors when

I have a dogecoin protobuf wallet on Ubuntu. When I run
python wallet-decrypt.py encrypted-wallet password
I get this error:
"Traceback (most recent call last):
File "wallet-decrypt.py", line 59, in
main()
File "wallet-decrypt.py", line 50, in main
w = get_wallet(args.filename, args.password)
File "wallet-decrypt.py", line 39, in get_wallet
w.ParseFromString(pbdata)
google.protobuf.message.DecodeError: Error parsing message"

┆Issue is synchronized with this Asana task by Unito

Error During Run

Hey jleni,

Thanks for your contribution, can you please help with this error below. I'm using ubuntu to run your code on python2.7

Traceback (most recent call last):
  File "wallet-decrypt.py", line 56, in <module>
    main()
  File "wallet-decrypt.py", line 47, in main
    w = get_wallet(args.filename, args.password)
  File "wallet-decrypt.py", line 34, in get_wallet
    pbdata = padded_plain[:-pad_len]
TypeError: bad operand type for unary -: 'str'

Is it a known issue? When you say use filename as argument, do you mean backup file generated from bitcoin android wallet?

Make password argument optional

Passing a password through as an argument is poor security practice (as your password becomes stored in your .bash_history etc).

I suggest that the password argument be made optional (so it can still be provided for scripts if needed) and a user request is made using input('Please enter password: ') or similar if it is not supplied.

This script is great. Thanks so much!

┆Issue is synchronized with this Asana task by Unito

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.