pybitmessage.highlevelcrypto module

src/highlevelcrypto.py

decrypt(msg, hexPrivkey)[source]

Decrypts message with hex private key

decryptFast(msg, cryptor)[source]

Decrypts message with an existing pyelliptic.ECC.ECC object

encrypt(msg, hexPubkey)[source]

Encrypts message with hex public key

hexToPubkey(pubkey)[source]

Convert a pubkey from hex to binary

makeCryptor(privkey)[source]

Return a private pyelliptic.ECC() instance

makePubCryptor(pubkey)[source]

Return a public pyelliptic.ECC() instance

pointMult(secret)[source]

Does an EC point multiplication; turns a private key into a public key.

Evidently, this type of error can occur very rarely:

>>> File "highlevelcrypto.py", line 54, in pointMult
>>>  group = OpenSSL.EC_KEY_get0_group(k)
>>> WindowsError: exception: access violation reading 0x0000000000000008
privToPub(privkey)[source]

Converts hex private key into hex public key

sign(msg, hexPrivkey)[source]

Signs with hex private key

verify(msg, sig, hexPubkey)[source]

Verifies with hex public key