diff --git a/src/trezor/messages/EosActionBuyRam.py b/src/trezor/messages/EosActionBuyRam.py new file mode 100644 index 0000000000..e8f17dc6b6 --- /dev/null +++ b/src/trezor/messages/EosActionBuyRam.py @@ -0,0 +1,26 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAsset import EosAsset + + +class EosActionBuyRam(p.MessageType): + + def __init__( + self, + payer: int = None, + receiver: int = None, + quantity: EosAsset = None, + ) -> None: + self.payer = payer + self.receiver = receiver + self.quantity = quantity + + @classmethod + def get_fields(cls): + return { + 1: ('payer', p.UVarintType, 0), + 2: ('receiver', p.UVarintType, 0), + 3: ('quantity', EosAsset, 0), + } diff --git a/src/trezor/messages/EosActionBuyRamBytes.py b/src/trezor/messages/EosActionBuyRamBytes.py new file mode 100644 index 0000000000..509631e369 --- /dev/null +++ b/src/trezor/messages/EosActionBuyRamBytes.py @@ -0,0 +1,24 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionBuyRamBytes(p.MessageType): + + def __init__( + self, + payer: int = None, + receiver: int = None, + bytes: int = None, + ) -> None: + self.payer = payer + self.receiver = receiver + self.bytes = bytes + + @classmethod + def get_fields(cls): + return { + 1: ('payer', p.UVarintType, 0), + 2: ('receiver', p.UVarintType, 0), + 3: ('bytes', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosActionCommon.py b/src/trezor/messages/EosActionCommon.py new file mode 100644 index 0000000000..ebe79d802a --- /dev/null +++ b/src/trezor/messages/EosActionCommon.py @@ -0,0 +1,32 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosPermissionLevel import EosPermissionLevel + +if __debug__: + try: + from typing import List + except ImportError: + List = None # type: ignore + + +class EosActionCommon(p.MessageType): + + def __init__( + self, + account: int = None, + name: int = None, + authorization: List[EosPermissionLevel] = None, + ) -> None: + self.account = account + self.name = name + self.authorization = authorization if authorization is not None else [] + + @classmethod + def get_fields(cls): + return { + 1: ('account', p.UVarintType, 0), + 2: ('name', p.UVarintType, 0), + 3: ('authorization', EosPermissionLevel, p.FLAG_REPEATED), + } diff --git a/src/trezor/messages/EosActionDelegate.py b/src/trezor/messages/EosActionDelegate.py new file mode 100644 index 0000000000..103aa91cda --- /dev/null +++ b/src/trezor/messages/EosActionDelegate.py @@ -0,0 +1,32 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAsset import EosAsset + + +class EosActionDelegate(p.MessageType): + + def __init__( + self, + sender: int = None, + receiver: int = None, + net_quantity: EosAsset = None, + cpu_quantity: EosAsset = None, + transfer: bool = None, + ) -> None: + self.sender = sender + self.receiver = receiver + self.net_quantity = net_quantity + self.cpu_quantity = cpu_quantity + self.transfer = transfer + + @classmethod + def get_fields(cls): + return { + 1: ('sender', p.UVarintType, 0), + 2: ('receiver', p.UVarintType, 0), + 3: ('net_quantity', EosAsset, 0), + 4: ('cpu_quantity', EosAsset, 0), + 5: ('transfer', p.BoolType, 0), + } diff --git a/src/trezor/messages/EosActionDeleteAuth.py b/src/trezor/messages/EosActionDeleteAuth.py new file mode 100644 index 0000000000..fc0bc57330 --- /dev/null +++ b/src/trezor/messages/EosActionDeleteAuth.py @@ -0,0 +1,21 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionDeleteAuth(p.MessageType): + + def __init__( + self, + account: int = None, + permission: int = None, + ) -> None: + self.account = account + self.permission = permission + + @classmethod + def get_fields(cls): + return { + 1: ('account', p.UVarintType, 0), + 2: ('permission', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosActionLinkAuth.py b/src/trezor/messages/EosActionLinkAuth.py new file mode 100644 index 0000000000..03f090ab00 --- /dev/null +++ b/src/trezor/messages/EosActionLinkAuth.py @@ -0,0 +1,27 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionLinkAuth(p.MessageType): + + def __init__( + self, + account: int = None, + code: int = None, + type: int = None, + requirement: int = None, + ) -> None: + self.account = account + self.code = code + self.type = type + self.requirement = requirement + + @classmethod + def get_fields(cls): + return { + 1: ('account', p.UVarintType, 0), + 2: ('code', p.UVarintType, 0), + 3: ('type', p.UVarintType, 0), + 4: ('requirement', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosActionNewAccount.py b/src/trezor/messages/EosActionNewAccount.py new file mode 100644 index 0000000000..8cc13487f4 --- /dev/null +++ b/src/trezor/messages/EosActionNewAccount.py @@ -0,0 +1,29 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAuthorization import EosAuthorization + + +class EosActionNewAccount(p.MessageType): + + def __init__( + self, + creator: int = None, + name: int = None, + owner: EosAuthorization = None, + active: EosAuthorization = None, + ) -> None: + self.creator = creator + self.name = name + self.owner = owner + self.active = active + + @classmethod + def get_fields(cls): + return { + 1: ('creator', p.UVarintType, 0), + 2: ('name', p.UVarintType, 0), + 3: ('owner', EosAuthorization, 0), + 4: ('active', EosAuthorization, 0), + } diff --git a/src/trezor/messages/EosActionRefund.py b/src/trezor/messages/EosActionRefund.py new file mode 100644 index 0000000000..99cf911905 --- /dev/null +++ b/src/trezor/messages/EosActionRefund.py @@ -0,0 +1,18 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionRefund(p.MessageType): + + def __init__( + self, + owner: int = None, + ) -> None: + self.owner = owner + + @classmethod + def get_fields(cls): + return { + 1: ('owner', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosActionSellRam.py b/src/trezor/messages/EosActionSellRam.py new file mode 100644 index 0000000000..18f3556258 --- /dev/null +++ b/src/trezor/messages/EosActionSellRam.py @@ -0,0 +1,21 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionSellRam(p.MessageType): + + def __init__( + self, + account: int = None, + bytes: int = None, + ) -> None: + self.account = account + self.bytes = bytes + + @classmethod + def get_fields(cls): + return { + 1: ('account', p.UVarintType, 0), + 2: ('bytes', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosActionTransfer.py b/src/trezor/messages/EosActionTransfer.py new file mode 100644 index 0000000000..0e1e5229ae --- /dev/null +++ b/src/trezor/messages/EosActionTransfer.py @@ -0,0 +1,29 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAsset import EosAsset + + +class EosActionTransfer(p.MessageType): + + def __init__( + self, + sender: int = None, + receiver: int = None, + quantity: EosAsset = None, + memo: str = None, + ) -> None: + self.sender = sender + self.receiver = receiver + self.quantity = quantity + self.memo = memo + + @classmethod + def get_fields(cls): + return { + 1: ('sender', p.UVarintType, 0), + 2: ('receiver', p.UVarintType, 0), + 3: ('quantity', EosAsset, 0), + 4: ('memo', p.UnicodeType, 0), + } diff --git a/src/trezor/messages/EosActionUndelegate.py b/src/trezor/messages/EosActionUndelegate.py new file mode 100644 index 0000000000..046f7ef419 --- /dev/null +++ b/src/trezor/messages/EosActionUndelegate.py @@ -0,0 +1,29 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAsset import EosAsset + + +class EosActionUndelegate(p.MessageType): + + def __init__( + self, + sender: int = None, + receiver: int = None, + net_quantity: EosAsset = None, + cpu_quantity: EosAsset = None, + ) -> None: + self.sender = sender + self.receiver = receiver + self.net_quantity = net_quantity + self.cpu_quantity = cpu_quantity + + @classmethod + def get_fields(cls): + return { + 1: ('sender', p.UVarintType, 0), + 2: ('receiver', p.UVarintType, 0), + 3: ('net_quantity', EosAsset, 0), + 4: ('cpu_quantity', EosAsset, 0), + } diff --git a/src/trezor/messages/EosActionUnknown.py b/src/trezor/messages/EosActionUnknown.py new file mode 100644 index 0000000000..001f4ba23a --- /dev/null +++ b/src/trezor/messages/EosActionUnknown.py @@ -0,0 +1,21 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionUnknown(p.MessageType): + + def __init__( + self, + data_size: int = None, + data_chunk: bytes = None, + ) -> None: + self.data_size = data_size + self.data_chunk = data_chunk + + @classmethod + def get_fields(cls): + return { + 1: ('data_size', p.UVarintType, 0), + 2: ('data_chunk', p.BytesType, 0), + } diff --git a/src/trezor/messages/EosActionUnlinkAuth.py b/src/trezor/messages/EosActionUnlinkAuth.py new file mode 100644 index 0000000000..c1378dc00a --- /dev/null +++ b/src/trezor/messages/EosActionUnlinkAuth.py @@ -0,0 +1,24 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosActionUnlinkAuth(p.MessageType): + + def __init__( + self, + account: int = None, + code: int = None, + type: int = None, + ) -> None: + self.account = account + self.code = code + self.type = type + + @classmethod + def get_fields(cls): + return { + 1: ('account', p.UVarintType, 0), + 2: ('code', p.UVarintType, 0), + 3: ('type', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosActionUpdateAuth.py b/src/trezor/messages/EosActionUpdateAuth.py new file mode 100644 index 0000000000..249d2026b0 --- /dev/null +++ b/src/trezor/messages/EosActionUpdateAuth.py @@ -0,0 +1,29 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAuthorization import EosAuthorization + + +class EosActionUpdateAuth(p.MessageType): + + def __init__( + self, + account: int = None, + permission: int = None, + parent: int = None, + auth: EosAuthorization = None, + ) -> None: + self.account = account + self.permission = permission + self.parent = parent + self.auth = auth + + @classmethod + def get_fields(cls): + return { + 1: ('account', p.UVarintType, 0), + 2: ('permission', p.UVarintType, 0), + 3: ('parent', p.UVarintType, 0), + 4: ('auth', EosAuthorization, 0), + } diff --git a/src/trezor/messages/EosActionVoteProducer.py b/src/trezor/messages/EosActionVoteProducer.py new file mode 100644 index 0000000000..709e44ddf0 --- /dev/null +++ b/src/trezor/messages/EosActionVoteProducer.py @@ -0,0 +1,30 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +if __debug__: + try: + from typing import List + except ImportError: + List = None # type: ignore + + +class EosActionVoteProducer(p.MessageType): + + def __init__( + self, + voter: int = None, + proxy: int = None, + producers: List[int] = None, + ) -> None: + self.voter = voter + self.proxy = proxy + self.producers = producers if producers is not None else [] + + @classmethod + def get_fields(cls): + return { + 1: ('voter', p.UVarintType, 0), + 2: ('proxy', p.UVarintType, 0), + 3: ('producers', p.UVarintType, p.FLAG_REPEATED), + } diff --git a/src/trezor/messages/EosAsset.py b/src/trezor/messages/EosAsset.py new file mode 100644 index 0000000000..1c3b66ef35 --- /dev/null +++ b/src/trezor/messages/EosAsset.py @@ -0,0 +1,21 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosAsset(p.MessageType): + + def __init__( + self, + amount: int = None, + symbol: int = None, + ) -> None: + self.amount = amount + self.symbol = symbol + + @classmethod + def get_fields(cls): + return { + 1: ('amount', p.SVarintType, 0), + 2: ('symbol', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosAuthorization.py b/src/trezor/messages/EosAuthorization.py new file mode 100644 index 0000000000..345fe3504e --- /dev/null +++ b/src/trezor/messages/EosAuthorization.py @@ -0,0 +1,37 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosAuthorizationAccount import EosAuthorizationAccount +from .EosAuthorizationKey import EosAuthorizationKey +from .EosAuthorizationWait import EosAuthorizationWait + +if __debug__: + try: + from typing import List + except ImportError: + List = None # type: ignore + + +class EosAuthorization(p.MessageType): + + def __init__( + self, + threshold: int = None, + keys: List[EosAuthorizationKey] = None, + accounts: List[EosAuthorizationAccount] = None, + waits: List[EosAuthorizationWait] = None, + ) -> None: + self.threshold = threshold + self.keys = keys if keys is not None else [] + self.accounts = accounts if accounts is not None else [] + self.waits = waits if waits is not None else [] + + @classmethod + def get_fields(cls): + return { + 1: ('threshold', p.UVarintType, 0), + 2: ('keys', EosAuthorizationKey, p.FLAG_REPEATED), + 3: ('accounts', EosAuthorizationAccount, p.FLAG_REPEATED), + 4: ('waits', EosAuthorizationWait, p.FLAG_REPEATED), + } diff --git a/src/trezor/messages/EosAuthorizationAccount.py b/src/trezor/messages/EosAuthorizationAccount.py new file mode 100644 index 0000000000..ddc5698f6d --- /dev/null +++ b/src/trezor/messages/EosAuthorizationAccount.py @@ -0,0 +1,23 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosPermissionLevel import EosPermissionLevel + + +class EosAuthorizationAccount(p.MessageType): + + def __init__( + self, + account: EosPermissionLevel = None, + weight: int = None, + ) -> None: + self.account = account + self.weight = weight + + @classmethod + def get_fields(cls): + return { + 1: ('account', EosPermissionLevel, 0), + 2: ('weight', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosAuthorizationKey.py b/src/trezor/messages/EosAuthorizationKey.py new file mode 100644 index 0000000000..fcada310e3 --- /dev/null +++ b/src/trezor/messages/EosAuthorizationKey.py @@ -0,0 +1,33 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +if __debug__: + try: + from typing import List + except ImportError: + List = None # type: ignore + + +class EosAuthorizationKey(p.MessageType): + + def __init__( + self, + type: int = None, + key: bytes = None, + address_n: List[int] = None, + weight: int = None, + ) -> None: + self.type = type + self.key = key + self.address_n = address_n if address_n is not None else [] + self.weight = weight + + @classmethod + def get_fields(cls): + return { + 1: ('type', p.UVarintType, 0), + 2: ('key', p.BytesType, 0), + 3: ('address_n', p.UVarintType, p.FLAG_REPEATED), + 4: ('weight', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosAuthorizationWait.py b/src/trezor/messages/EosAuthorizationWait.py new file mode 100644 index 0000000000..8c2d95d539 --- /dev/null +++ b/src/trezor/messages/EosAuthorizationWait.py @@ -0,0 +1,21 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosAuthorizationWait(p.MessageType): + + def __init__( + self, + wait_sec: int = None, + weight: int = None, + ) -> None: + self.wait_sec = wait_sec + self.weight = weight + + @classmethod + def get_fields(cls): + return { + 1: ('wait_sec', p.UVarintType, 0), + 2: ('weight', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosGetPublicKey.py b/src/trezor/messages/EosGetPublicKey.py new file mode 100644 index 0000000000..0d3ad22fa7 --- /dev/null +++ b/src/trezor/messages/EosGetPublicKey.py @@ -0,0 +1,28 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +if __debug__: + try: + from typing import List + except ImportError: + List = None # type: ignore + + +class EosGetPublicKey(p.MessageType): + MESSAGE_WIRE_TYPE = 600 + + def __init__( + self, + address_n: List[int] = None, + show_display: bool = None, + ) -> None: + self.address_n = address_n if address_n is not None else [] + self.show_display = show_display + + @classmethod + def get_fields(cls): + return { + 1: ('address_n', p.UVarintType, p.FLAG_REPEATED), + 2: ('show_display', p.BoolType, 0), + } diff --git a/src/trezor/messages/EosPermissionLevel.py b/src/trezor/messages/EosPermissionLevel.py new file mode 100644 index 0000000000..2420539525 --- /dev/null +++ b/src/trezor/messages/EosPermissionLevel.py @@ -0,0 +1,21 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosPermissionLevel(p.MessageType): + + def __init__( + self, + actor: int = None, + permission: int = None, + ) -> None: + self.actor = actor + self.permission = permission + + @classmethod + def get_fields(cls): + return { + 1: ('actor', p.UVarintType, 0), + 2: ('permission', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosPublicKey.py b/src/trezor/messages/EosPublicKey.py new file mode 100644 index 0000000000..3a97fd0e58 --- /dev/null +++ b/src/trezor/messages/EosPublicKey.py @@ -0,0 +1,22 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosPublicKey(p.MessageType): + MESSAGE_WIRE_TYPE = 601 + + def __init__( + self, + wif_public_key: str = None, + raw_public_key: bytes = None, + ) -> None: + self.wif_public_key = wif_public_key + self.raw_public_key = raw_public_key + + @classmethod + def get_fields(cls): + return { + 1: ('wif_public_key', p.UnicodeType, 0), + 2: ('raw_public_key', p.BytesType, 0), + } diff --git a/src/trezor/messages/EosSignTx.py b/src/trezor/messages/EosSignTx.py new file mode 100644 index 0000000000..e763be1f84 --- /dev/null +++ b/src/trezor/messages/EosSignTx.py @@ -0,0 +1,36 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosTxHeader import EosTxHeader + +if __debug__: + try: + from typing import List + except ImportError: + List = None # type: ignore + + +class EosSignTx(p.MessageType): + MESSAGE_WIRE_TYPE = 602 + + def __init__( + self, + address_n: List[int] = None, + chain_id: bytes = None, + header: EosTxHeader = None, + num_actions: int = None, + ) -> None: + self.address_n = address_n if address_n is not None else [] + self.chain_id = chain_id + self.header = header + self.num_actions = num_actions + + @classmethod + def get_fields(cls): + return { + 1: ('address_n', p.UVarintType, p.FLAG_REPEATED), + 2: ('chain_id', p.BytesType, 0), + 3: ('header', EosTxHeader, 0), + 4: ('num_actions', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosSignedTx.py b/src/trezor/messages/EosSignedTx.py new file mode 100644 index 0000000000..946ce57592 --- /dev/null +++ b/src/trezor/messages/EosSignedTx.py @@ -0,0 +1,25 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosSignedTx(p.MessageType): + MESSAGE_WIRE_TYPE = 605 + + def __init__( + self, + signature_v: int = None, + signature_r: bytes = None, + signature_s: bytes = None, + ) -> None: + self.signature_v = signature_v + self.signature_r = signature_r + self.signature_s = signature_s + + @classmethod + def get_fields(cls): + return { + 1: ('signature_v', p.UVarintType, 0), + 2: ('signature_r', p.BytesType, 0), + 3: ('signature_s', p.BytesType, 0), + } diff --git a/src/trezor/messages/EosTxActionAck.py b/src/trezor/messages/EosTxActionAck.py new file mode 100644 index 0000000000..09f46d7550 --- /dev/null +++ b/src/trezor/messages/EosTxActionAck.py @@ -0,0 +1,77 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + +from .EosActionBuyRam import EosActionBuyRam +from .EosActionBuyRamBytes import EosActionBuyRamBytes +from .EosActionCommon import EosActionCommon +from .EosActionDelegate import EosActionDelegate +from .EosActionDeleteAuth import EosActionDeleteAuth +from .EosActionLinkAuth import EosActionLinkAuth +from .EosActionNewAccount import EosActionNewAccount +from .EosActionRefund import EosActionRefund +from .EosActionSellRam import EosActionSellRam +from .EosActionTransfer import EosActionTransfer +from .EosActionUndelegate import EosActionUndelegate +from .EosActionUnknown import EosActionUnknown +from .EosActionUnlinkAuth import EosActionUnlinkAuth +from .EosActionUpdateAuth import EosActionUpdateAuth +from .EosActionVoteProducer import EosActionVoteProducer + + +class EosTxActionAck(p.MessageType): + MESSAGE_WIRE_TYPE = 604 + + def __init__( + self, + common: EosActionCommon = None, + transfer: EosActionTransfer = None, + delegate: EosActionDelegate = None, + undelegate: EosActionUndelegate = None, + refund: EosActionRefund = None, + buy_ram: EosActionBuyRam = None, + buy_ram_bytes: EosActionBuyRamBytes = None, + sell_ram: EosActionSellRam = None, + vote_producer: EosActionVoteProducer = None, + update_auth: EosActionUpdateAuth = None, + delete_auth: EosActionDeleteAuth = None, + link_auth: EosActionLinkAuth = None, + unlink_auth: EosActionUnlinkAuth = None, + new_account: EosActionNewAccount = None, + unknown: EosActionUnknown = None, + ) -> None: + self.common = common + self.transfer = transfer + self.delegate = delegate + self.undelegate = undelegate + self.refund = refund + self.buy_ram = buy_ram + self.buy_ram_bytes = buy_ram_bytes + self.sell_ram = sell_ram + self.vote_producer = vote_producer + self.update_auth = update_auth + self.delete_auth = delete_auth + self.link_auth = link_auth + self.unlink_auth = unlink_auth + self.new_account = new_account + self.unknown = unknown + + @classmethod + def get_fields(cls): + return { + 1: ('common', EosActionCommon, 0), + 2: ('transfer', EosActionTransfer, 0), + 3: ('delegate', EosActionDelegate, 0), + 4: ('undelegate', EosActionUndelegate, 0), + 5: ('refund', EosActionRefund, 0), + 6: ('buy_ram', EosActionBuyRam, 0), + 7: ('buy_ram_bytes', EosActionBuyRamBytes, 0), + 8: ('sell_ram', EosActionSellRam, 0), + 9: ('vote_producer', EosActionVoteProducer, 0), + 10: ('update_auth', EosActionUpdateAuth, 0), + 11: ('delete_auth', EosActionDeleteAuth, 0), + 12: ('link_auth', EosActionLinkAuth, 0), + 13: ('unlink_auth', EosActionUnlinkAuth, 0), + 14: ('new_account', EosActionNewAccount, 0), + 15: ('unknown', EosActionUnknown, 0), + } diff --git a/src/trezor/messages/EosTxActionRequest.py b/src/trezor/messages/EosTxActionRequest.py new file mode 100644 index 0000000000..c2c5cd41f5 --- /dev/null +++ b/src/trezor/messages/EosTxActionRequest.py @@ -0,0 +1,19 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosTxActionRequest(p.MessageType): + MESSAGE_WIRE_TYPE = 603 + + def __init__( + self, + data_size: int = None, + ) -> None: + self.data_size = data_size + + @classmethod + def get_fields(cls): + return { + 1: ('data_size', p.UVarintType, 0), + } diff --git a/src/trezor/messages/EosTxHeader.py b/src/trezor/messages/EosTxHeader.py new file mode 100644 index 0000000000..2ef7e881cf --- /dev/null +++ b/src/trezor/messages/EosTxHeader.py @@ -0,0 +1,33 @@ +# Automatically generated by pb2py +# fmt: off +import protobuf as p + + +class EosTxHeader(p.MessageType): + + def __init__( + self, + expiration: int = None, + ref_block_num: int = None, + ref_block_prefix: int = None, + max_net_usage_words: int = None, + max_cpu_usage_ms: int = None, + delay_sec: int = None, + ) -> None: + self.expiration = expiration + self.ref_block_num = ref_block_num + self.ref_block_prefix = ref_block_prefix + self.max_net_usage_words = max_net_usage_words + self.max_cpu_usage_ms = max_cpu_usage_ms + self.delay_sec = delay_sec + + @classmethod + def get_fields(cls): + return { + 1: ('expiration', p.UVarintType, 0), # required + 2: ('ref_block_num', p.UVarintType, 0), # required + 3: ('ref_block_prefix', p.UVarintType, 0), # required + 4: ('max_net_usage_words', p.UVarintType, 0), # required + 5: ('max_cpu_usage_ms', p.UVarintType, 0), # required + 6: ('delay_sec', p.UVarintType, 0), # required + } diff --git a/src/trezor/messages/EthereumAddress.py b/src/trezor/messages/EthereumAddress.py index 78af2afe2c..df54a4ab51 100644 --- a/src/trezor/messages/EthereumAddress.py +++ b/src/trezor/messages/EthereumAddress.py @@ -8,12 +8,12 @@ class EthereumAddress(p.MessageType): def __init__( self, - address: bytes = None, + address: str = None, ) -> None: self.address = address @classmethod def get_fields(cls): return { - 1: ('address', p.BytesType, 0), # required + 2: ('address', p.UnicodeType, 0), } diff --git a/src/trezor/messages/EthereumMessageSignature.py b/src/trezor/messages/EthereumMessageSignature.py index a2018889a2..04d5a36b45 100644 --- a/src/trezor/messages/EthereumMessageSignature.py +++ b/src/trezor/messages/EthereumMessageSignature.py @@ -8,15 +8,15 @@ class EthereumMessageSignature(p.MessageType): def __init__( self, - address: bytes = None, signature: bytes = None, + address: str = None, ) -> None: - self.address = address self.signature = signature + self.address = address @classmethod def get_fields(cls): return { - 1: ('address', p.BytesType, 0), 2: ('signature', p.BytesType, 0), + 3: ('address', p.UnicodeType, 0), } diff --git a/src/trezor/messages/EthereumPublicKey.py b/src/trezor/messages/EthereumPublicKey.py index 25b0bdc49e..e85ea10126 100644 --- a/src/trezor/messages/EthereumPublicKey.py +++ b/src/trezor/messages/EthereumPublicKey.py @@ -19,6 +19,6 @@ class EthereumPublicKey(p.MessageType): @classmethod def get_fields(cls): return { - 1: ('node', HDNodeType, 0), # required + 1: ('node', HDNodeType, 0), 2: ('xpub', p.UnicodeType, 0), } diff --git a/src/trezor/messages/EthereumSignMessage.py b/src/trezor/messages/EthereumSignMessage.py index 07df0bd116..7d8e9bf041 100644 --- a/src/trezor/messages/EthereumSignMessage.py +++ b/src/trezor/messages/EthereumSignMessage.py @@ -24,5 +24,5 @@ class EthereumSignMessage(p.MessageType): def get_fields(cls): return { 1: ('address_n', p.UVarintType, p.FLAG_REPEATED), - 2: ('message', p.BytesType, 0), # required + 2: ('message', p.BytesType, 0), } diff --git a/src/trezor/messages/EthereumSignTx.py b/src/trezor/messages/EthereumSignTx.py index 43a6df2138..42a35fae84 100644 --- a/src/trezor/messages/EthereumSignTx.py +++ b/src/trezor/messages/EthereumSignTx.py @@ -18,7 +18,7 @@ class EthereumSignTx(p.MessageType): nonce: bytes = None, gas_price: bytes = None, gas_limit: bytes = None, - to: bytes = None, + to: str = None, value: bytes = None, data_initial_chunk: bytes = None, data_length: int = None, @@ -43,7 +43,7 @@ class EthereumSignTx(p.MessageType): 2: ('nonce', p.BytesType, 0), 3: ('gas_price', p.BytesType, 0), 4: ('gas_limit', p.BytesType, 0), - 5: ('to', p.BytesType, 0), + 11: ('to', p.UnicodeType, 0), 6: ('value', p.BytesType, 0), 7: ('data_initial_chunk', p.BytesType, 0), 8: ('data_length', p.UVarintType, 0), diff --git a/src/trezor/messages/EthereumVerifyMessage.py b/src/trezor/messages/EthereumVerifyMessage.py index c5528190de..bf8d66d92b 100644 --- a/src/trezor/messages/EthereumVerifyMessage.py +++ b/src/trezor/messages/EthereumVerifyMessage.py @@ -8,18 +8,18 @@ class EthereumVerifyMessage(p.MessageType): def __init__( self, - address: bytes = None, signature: bytes = None, message: bytes = None, + address: str = None, ) -> None: - self.address = address self.signature = signature self.message = message + self.address = address @classmethod def get_fields(cls): return { - 1: ('address', p.BytesType, 0), 2: ('signature', p.BytesType, 0), 3: ('message', p.BytesType, 0), + 4: ('address', p.UnicodeType, 0), } diff --git a/src/trezor/messages/MessageType.py b/src/trezor/messages/MessageType.py index 4f83d25f6f..87b0cde0db 100644 --- a/src/trezor/messages/MessageType.py +++ b/src/trezor/messages/MessageType.py @@ -177,3 +177,9 @@ MoneroLiveRefreshStepRequest = 554 MoneroLiveRefreshStepAck = 555 MoneroLiveRefreshFinalRequest = 556 MoneroLiveRefreshFinalAck = 557 +EosGetPublicKey = 600 +EosPublicKey = 601 +EosSignTx = 602 +EosTxActionRequest = 603 +EosTxActionAck = 604 +EosSignedTx = 605