mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-26 16:18:22 +00:00
trezorlib: drop support for EncryptMessage and DecryptMessage
This commit is contained in:
parent
fd39692ec9
commit
2f3a32f8e8
@ -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
|
||||
- Stellar: addresses are always strings
|
||||
|
||||
### Removed
|
||||
- `EncryptMessage` and `DecryptMessage` actions are gone
|
||||
|
||||
### Fixed:
|
||||
- Stellar: several bugs in the XDR parser were fixed
|
||||
|
||||
|
@ -728,19 +728,6 @@ class ProtocolMixin(object):
|
||||
return True
|
||||
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')
|
||||
@expect(proto.CipheredKeyValue)
|
||||
def encrypt_keyvalue(self, n, key, value, ask_on_encrypt=True, ask_on_decrypt=True, iv=b''):
|
||||
|
Loading…
Reference in New Issue
Block a user