graphenestorage.masterpassword module

class graphenestorage.masterpassword.MasterPassword(config=None, **kwargs)

Bases: object

The keys are encrypted with a Masterpassword that is stored in the configurationStore. It has a checksum to verify correctness of the password The encrypted private keys in keys are encrypted with a random masterkey/masterpassword that is stored in the configuration encrypted by the user-provided password.

Parameters:config (ConfigStore) – Configuration store to get access to the encrypted master password

Change the password that allows to decrypt the master key


Decrypt the content according to BIP38

Parameters:wif (str) – Encrypted key

Encrypt the content according to BIP38

Parameters:wif (str) – Unencrypted key

Tells us if the config store knows an encrypted masterpassword


Lock the store so that we can no longer decrypt the content of the store


Is the store locked. E.g. Is a valid password known that can be used to decrypt the master key?


Contains the decrypted master key


The password is used to encrypt this masterpassword. To decrypt the keys stored in the keys database, one must use BIP38, decrypt the masterpassword from the configuration store with the user password, and use the decrypted masterpassword to decrypt the BIP38 encrypted private keys from the keys storage!

Parameters:password (str) – Password to use for en-/de-cryption

Is the store unlocked so that I can decrypt the content?