diff --git a/tools/pb2py b/tools/pb2py index 587c8065a5..5188ec078c 100755 --- a/tools/pb2py +++ b/tools/pb2py @@ -68,7 +68,6 @@ def process_message(descriptor, protobuf_module, msg_id, indexfile, is_upy): types = { field.TYPE_UINT64: 'p.UVarintType', - field.TYPE_INT64: 'p.UVarintType', field.TYPE_UINT32: 'p.UVarintType', field.TYPE_ENUM: 'p.UVarintType', field.TYPE_SINT32: 'p.Sint32Type', diff --git a/trezorlib/messages/ApplySettings.py b/trezorlib/messages/ApplySettings.py index 32f8295414..fbb776e6ae 100644 --- a/trezorlib/messages/ApplySettings.py +++ b/trezorlib/messages/ApplySettings.py @@ -8,5 +8,7 @@ class ApplySettings(p.MessageType): 2: ('label', p.UnicodeType, 0), 3: ('use_passphrase', p.BoolType, 0), 4: ('homescreen', p.BytesType, 0), + 5: ('passphrase_source', p.UVarintType, 0), + 6: ('auto_lock_delay_ms', p.UVarintType, 0), } MESSAGE_WIRE_TYPE = 25 diff --git a/trezorlib/messages/DebugLinkDecision.py b/trezorlib/messages/DebugLinkDecision.py index 482d886c6a..e5016f304c 100644 --- a/trezorlib/messages/DebugLinkDecision.py +++ b/trezorlib/messages/DebugLinkDecision.py @@ -4,6 +4,8 @@ from .. import protobuf as p class DebugLinkDecision(p.MessageType): FIELDS = { - 1: ('yes_no', p.BoolType, 0), # required + 1: ('yes_no', p.BoolType, 0), + 2: ('up_down', p.BoolType, 0), + 3: ('input', p.UnicodeType, 0), } MESSAGE_WIRE_TYPE = 100 diff --git a/trezorlib/messages/DebugLinkState.py b/trezorlib/messages/DebugLinkState.py index 9438fe8c3a..ef671619ed 100644 --- a/trezorlib/messages/DebugLinkState.py +++ b/trezorlib/messages/DebugLinkState.py @@ -15,5 +15,6 @@ class DebugLinkState(p.MessageType): 8: ('reset_entropy', p.BytesType, 0), 9: ('recovery_fake_word', p.UnicodeType, 0), 10: ('recovery_word_pos', p.UVarintType, 0), + 11: ('reset_word_pos', p.UVarintType, 0), } MESSAGE_WIRE_TYPE = 102 diff --git a/trezorlib/messages/Features.py b/trezorlib/messages/Features.py index 878266dec7..d1eaaa39a9 100644 --- a/trezorlib/messages/Features.py +++ b/trezorlib/messages/Features.py @@ -31,5 +31,6 @@ class Features(p.MessageType): 24: ('fw_patch', p.UVarintType, 0), 25: ('fw_vendor', p.UnicodeType, 0), 26: ('fw_vendor_keys', p.BytesType, 0), + 27: ('unfinished_backup', p.BoolType, 0), } MESSAGE_WIRE_TYPE = 17 diff --git a/trezorlib/messages/StellarCreateAccountOp.py b/trezorlib/messages/StellarCreateAccountOp.py index c650c9c5be..e1fee62db6 100644 --- a/trezorlib/messages/StellarCreateAccountOp.py +++ b/trezorlib/messages/StellarCreateAccountOp.py @@ -6,6 +6,6 @@ class StellarCreateAccountOp(p.MessageType): FIELDS = { 1: ('source_account', p.BytesType, 0), 2: ('new_account', p.BytesType, 0), - 3: ('starting_balance', p.UVarintType, 0), + 3: ('starting_balance', p.Sint64Type, 0), } MESSAGE_WIRE_TYPE = 210 diff --git a/trezorlib/messages/StellarCreatePassiveOfferOp.py b/trezorlib/messages/StellarCreatePassiveOfferOp.py index c3ee4865cf..b84ab0662f 100644 --- a/trezorlib/messages/StellarCreatePassiveOfferOp.py +++ b/trezorlib/messages/StellarCreatePassiveOfferOp.py @@ -8,7 +8,7 @@ class StellarCreatePassiveOfferOp(p.MessageType): 1: ('source_account', p.BytesType, 0), 2: ('selling_asset', StellarAssetType, 0), 3: ('buying_asset', StellarAssetType, 0), - 4: ('amount', p.UVarintType, 0), + 4: ('amount', p.Sint64Type, 0), 5: ('price_n', p.UVarintType, 0), 6: ('price_d', p.UVarintType, 0), } diff --git a/trezorlib/messages/StellarManageOfferOp.py b/trezorlib/messages/StellarManageOfferOp.py index 858d92f639..8a77ad4417 100644 --- a/trezorlib/messages/StellarManageOfferOp.py +++ b/trezorlib/messages/StellarManageOfferOp.py @@ -8,7 +8,7 @@ class StellarManageOfferOp(p.MessageType): 1: ('source_account', p.BytesType, 0), 2: ('selling_asset', StellarAssetType, 0), 3: ('buying_asset', StellarAssetType, 0), - 4: ('amount', p.UVarintType, 0), + 4: ('amount', p.Sint64Type, 0), 5: ('price_n', p.UVarintType, 0), 6: ('price_d', p.UVarintType, 0), 7: ('offer_id', p.UVarintType, 0), diff --git a/trezorlib/messages/StellarPathPaymentOp.py b/trezorlib/messages/StellarPathPaymentOp.py index 4381ecce17..906bf3499a 100644 --- a/trezorlib/messages/StellarPathPaymentOp.py +++ b/trezorlib/messages/StellarPathPaymentOp.py @@ -7,10 +7,10 @@ class StellarPathPaymentOp(p.MessageType): FIELDS = { 1: ('source_account', p.BytesType, 0), 2: ('send_asset', StellarAssetType, 0), - 3: ('send_max', p.UVarintType, 0), + 3: ('send_max', p.Sint64Type, 0), 4: ('destination_account', p.BytesType, 0), 5: ('destination_asset', StellarAssetType, 0), - 6: ('destination_amount', p.UVarintType, 0), + 6: ('destination_amount', p.Sint64Type, 0), 7: ('paths', StellarAssetType, p.FLAG_REPEATED), } MESSAGE_WIRE_TYPE = 212 diff --git a/trezorlib/messages/StellarPaymentOp.py b/trezorlib/messages/StellarPaymentOp.py index d4706dcd1f..ca15f51a90 100644 --- a/trezorlib/messages/StellarPaymentOp.py +++ b/trezorlib/messages/StellarPaymentOp.py @@ -8,6 +8,6 @@ class StellarPaymentOp(p.MessageType): 1: ('source_account', p.BytesType, 0), 2: ('destination_account', p.BytesType, 0), 3: ('asset', StellarAssetType, 0), - 4: ('amount', p.UVarintType, 0), + 4: ('amount', p.Sint64Type, 0), } MESSAGE_WIRE_TYPE = 211 diff --git a/trezorlib/messages/__init__.py b/trezorlib/messages/__init__.py index 07dc3fc858..6c69004719 100644 --- a/trezorlib/messages/__init__.py +++ b/trezorlib/messages/__init__.py @@ -30,6 +30,7 @@ from . import ButtonRequestType from . import PinMatrixRequestType from . import RecoveryDeviceType from . import WordRequestType +from . import PassphraseSourceType from . import NEMMosaicLevy from . import NEMSupplyChangeType from . import NEMModificationType