1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-01 20:08:26 +00:00

trezorlib: drop support for EncryptMessage and DecryptMessage

This commit is contained in:
matejcik 2018-07-09 13:43:06 +02:00
parent fd39692ec9
commit 2f3a32f8e8
2 changed files with 3 additions and 13 deletions

View File

@ -17,6 +17,9 @@ _At the moment, the project does __not__ adhere to [Semantic Versioning](http://
- protobuf classes are no longer part of the source distribution and must be compiled locally - protobuf classes are no longer part of the source distribution and must be compiled locally
- Stellar: addresses are always strings - Stellar: addresses are always strings
### Removed
- `EncryptMessage` and `DecryptMessage` actions are gone
### Fixed: ### Fixed:
- Stellar: several bugs in the XDR parser were fixed - Stellar: several bugs in the XDR parser were fixed

View File

@ -728,19 +728,6 @@ class ProtocolMixin(object):
return True return True
return False return False
@expect(proto.EncryptedMessage)
def encrypt_message(self, pubkey, message, display_only, coin_name, n):
if coin_name and n:
n = self._convert_prime(n)
return self.call(proto.EncryptMessage(pubkey=pubkey, message=message, display_only=display_only, coin_name=coin_name, address_n=n))
else:
return self.call(proto.EncryptMessage(pubkey=pubkey, message=message, display_only=display_only))
@expect(proto.DecryptedMessage)
def decrypt_message(self, n, nonce, message, msg_hmac):
n = self._convert_prime(n)
return self.call(proto.DecryptMessage(address_n=n, nonce=nonce, message=message, hmac=msg_hmac))
@field('value') @field('value')
@expect(proto.CipheredKeyValue) @expect(proto.CipheredKeyValue)
def encrypt_keyvalue(self, n, key, value, ask_on_encrypt=True, ask_on_decrypt=True, iv=b''): def encrypt_keyvalue(self, n, key, value, ask_on_encrypt=True, ask_on_decrypt=True, iv=b''):