From dde158395e32c0b270a006019199c294530331f9 Mon Sep 17 00:00:00 2001 From: DaniPopes <57450786+DaniPopes@users.noreply.github.com> Date: Wed, 22 Nov 2023 23:18:21 +0100 Subject: [PATCH] chore: re-generate bindings --- rust/trezor-client/Cargo.lock | 16 +- rust/trezor-client/Cargo.toml | 4 +- rust/trezor-client/scripts/build_messages | 2 +- .../src/protos/generated/messages.rs | 243 +++++++++++++++++- .../src/protos/generated/messages_binance.rs | 57 +++- .../src/protos/generated/messages_bitcoin.rs | 151 +++++++---- .../protos/generated/messages_bootloader.rs | 12 +- .../src/protos/generated/messages_cardano.rs | 184 ++++++++++--- .../src/protos/generated/messages_common.rs | 84 +++++- .../src/protos/generated/messages_crypto.rs | 26 +- .../src/protos/generated/messages_debug.rs | 62 +++-- .../src/protos/generated/messages_eos.rs | 60 ++--- .../src/protos/generated/messages_ethereum.rs | 32 +-- .../messages_ethereum_definitions.rs | 18 +- .../generated/messages_ethereum_eip712.rs | 32 ++- .../protos/generated/messages_management.rs | 170 ++++++++---- .../src/protos/generated/messages_monero.rs | 110 ++++---- .../src/protos/generated/messages_nem.rs | 68 +++-- .../src/protos/generated/messages_ripple.rs | 14 +- .../src/protos/generated/messages_stellar.rs | 71 +++-- .../src/protos/generated/messages_tezos.rs | 51 ++-- .../src/protos/generated/messages_webauthn.rs | 14 +- 22 files changed, 1097 insertions(+), 384 deletions(-) diff --git a/rust/trezor-client/Cargo.lock b/rust/trezor-client/Cargo.lock index d473e95de..a480a901a 100644 --- a/rust/trezor-client/Cargo.lock +++ b/rust/trezor-client/Cargo.lock @@ -404,9 +404,9 @@ dependencies = [ [[package]] name = "protobuf" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b55bad9126f378a853655831eb7363b7b01b81d19f8cb1218861086ca4a1a61e" +checksum = "b65f4a8ec18723a734e5dc09c173e0abf9690432da5340285d536edcb4dac190" dependencies = [ "once_cell", "protobuf-support", @@ -415,9 +415,9 @@ dependencies = [ [[package]] name = "protobuf-codegen" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dd418ac3c91caa4032d37cb80ff0d44e2ebe637b2fb243b6234bf89cdac4901" +checksum = "6e85514a216b1c73111d9032e26cc7a5ecb1bb3d4d9539e91fb72a4395060f78" dependencies = [ "anyhow", "once_cell", @@ -430,9 +430,9 @@ dependencies = [ [[package]] name = "protobuf-parse" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d39b14605eaa1f6a340aec7f320b34064feb26c93aec35d6a9a2272a8ddfa49" +checksum = "77d6fbd6697c9e531873e81cec565a85e226b99a0f10e1acc079be057fe2fcba" dependencies = [ "anyhow", "indexmap", @@ -446,9 +446,9 @@ dependencies = [ [[package]] name = "protobuf-support" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5d4d7b8601c814cfb36bcebb79f0e61e45e1e93640cf778837833bbed05c372" +checksum = "6872f4d4f4b98303239a2b5838f5bbbb77b01ffc892d627957f37a22d7cfe69c" dependencies = [ "thiserror", ] diff --git a/rust/trezor-client/Cargo.toml b/rust/trezor-client/Cargo.toml index d51fc80ed..544983832 100644 --- a/rust/trezor-client/Cargo.toml +++ b/rust/trezor-client/Cargo.toml @@ -28,8 +28,8 @@ members = ["build", "."] [workspace.dependencies] # important: keep in sync -protobuf = "=3.2.0" -protobuf-codegen = "=3.2.0" +protobuf = "=3.3.0" +protobuf-codegen = "=3.3.0" [dependencies] protobuf.workspace = true diff --git a/rust/trezor-client/scripts/build_messages b/rust/trezor-client/scripts/build_messages index ee8814764..4a434f8c7 100755 --- a/rust/trezor-client/scripts/build_messages +++ b/rust/trezor-client/scripts/build_messages @@ -56,7 +56,7 @@ def main(): if variants and feature: out += "\n" out += write_block(variants, feature) - print(out) + print(out.strip()) # Parse feature blocks based on comments in the `messages.proto` file diff --git a/rust/trezor-client/src/protos/generated/messages.rs b/rust/trezor-client/src/protos/generated/messages.rs index f127c09a8..fccf39f93 100644 --- a/rust/trezor-client/src/protos/generated/messages.rs +++ b/rust/trezor-client/src/protos/generated/messages.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,7 +23,7 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; #[derive(Clone,Copy,PartialEq,Eq,Debug,Hash)] // @@protoc_insertion_point(enum:hw.trezor.messages.MessageType) @@ -742,6 +742,245 @@ impl ::protobuf::Enum for MessageType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "MessageType_Initialize" => ::std::option::Option::Some(MessageType::MessageType_Initialize), + "MessageType_Ping" => ::std::option::Option::Some(MessageType::MessageType_Ping), + "MessageType_Success" => ::std::option::Option::Some(MessageType::MessageType_Success), + "MessageType_Failure" => ::std::option::Option::Some(MessageType::MessageType_Failure), + "MessageType_ChangePin" => ::std::option::Option::Some(MessageType::MessageType_ChangePin), + "MessageType_WipeDevice" => ::std::option::Option::Some(MessageType::MessageType_WipeDevice), + "MessageType_GetEntropy" => ::std::option::Option::Some(MessageType::MessageType_GetEntropy), + "MessageType_Entropy" => ::std::option::Option::Some(MessageType::MessageType_Entropy), + "MessageType_LoadDevice" => ::std::option::Option::Some(MessageType::MessageType_LoadDevice), + "MessageType_ResetDevice" => ::std::option::Option::Some(MessageType::MessageType_ResetDevice), + "MessageType_SetBusy" => ::std::option::Option::Some(MessageType::MessageType_SetBusy), + "MessageType_Features" => ::std::option::Option::Some(MessageType::MessageType_Features), + "MessageType_PinMatrixRequest" => ::std::option::Option::Some(MessageType::MessageType_PinMatrixRequest), + "MessageType_PinMatrixAck" => ::std::option::Option::Some(MessageType::MessageType_PinMatrixAck), + "MessageType_Cancel" => ::std::option::Option::Some(MessageType::MessageType_Cancel), + "MessageType_LockDevice" => ::std::option::Option::Some(MessageType::MessageType_LockDevice), + "MessageType_ApplySettings" => ::std::option::Option::Some(MessageType::MessageType_ApplySettings), + "MessageType_ButtonRequest" => ::std::option::Option::Some(MessageType::MessageType_ButtonRequest), + "MessageType_ButtonAck" => ::std::option::Option::Some(MessageType::MessageType_ButtonAck), + "MessageType_ApplyFlags" => ::std::option::Option::Some(MessageType::MessageType_ApplyFlags), + "MessageType_GetNonce" => ::std::option::Option::Some(MessageType::MessageType_GetNonce), + "MessageType_Nonce" => ::std::option::Option::Some(MessageType::MessageType_Nonce), + "MessageType_BackupDevice" => ::std::option::Option::Some(MessageType::MessageType_BackupDevice), + "MessageType_EntropyRequest" => ::std::option::Option::Some(MessageType::MessageType_EntropyRequest), + "MessageType_EntropyAck" => ::std::option::Option::Some(MessageType::MessageType_EntropyAck), + "MessageType_PassphraseRequest" => ::std::option::Option::Some(MessageType::MessageType_PassphraseRequest), + "MessageType_PassphraseAck" => ::std::option::Option::Some(MessageType::MessageType_PassphraseAck), + "MessageType_RecoveryDevice" => ::std::option::Option::Some(MessageType::MessageType_RecoveryDevice), + "MessageType_WordRequest" => ::std::option::Option::Some(MessageType::MessageType_WordRequest), + "MessageType_WordAck" => ::std::option::Option::Some(MessageType::MessageType_WordAck), + "MessageType_GetFeatures" => ::std::option::Option::Some(MessageType::MessageType_GetFeatures), + "MessageType_SdProtect" => ::std::option::Option::Some(MessageType::MessageType_SdProtect), + "MessageType_ChangeWipeCode" => ::std::option::Option::Some(MessageType::MessageType_ChangeWipeCode), + "MessageType_EndSession" => ::std::option::Option::Some(MessageType::MessageType_EndSession), + "MessageType_DoPreauthorized" => ::std::option::Option::Some(MessageType::MessageType_DoPreauthorized), + "MessageType_PreauthorizedRequest" => ::std::option::Option::Some(MessageType::MessageType_PreauthorizedRequest), + "MessageType_CancelAuthorization" => ::std::option::Option::Some(MessageType::MessageType_CancelAuthorization), + "MessageType_RebootToBootloader" => ::std::option::Option::Some(MessageType::MessageType_RebootToBootloader), + "MessageType_GetFirmwareHash" => ::std::option::Option::Some(MessageType::MessageType_GetFirmwareHash), + "MessageType_FirmwareHash" => ::std::option::Option::Some(MessageType::MessageType_FirmwareHash), + "MessageType_UnlockPath" => ::std::option::Option::Some(MessageType::MessageType_UnlockPath), + "MessageType_UnlockedPathRequest" => ::std::option::Option::Some(MessageType::MessageType_UnlockedPathRequest), + "MessageType_ShowDeviceTutorial" => ::std::option::Option::Some(MessageType::MessageType_ShowDeviceTutorial), + "MessageType_UnlockBootloader" => ::std::option::Option::Some(MessageType::MessageType_UnlockBootloader), + "MessageType_AuthenticateDevice" => ::std::option::Option::Some(MessageType::MessageType_AuthenticateDevice), + "MessageType_AuthenticityProof" => ::std::option::Option::Some(MessageType::MessageType_AuthenticityProof), + "MessageType_SetU2FCounter" => ::std::option::Option::Some(MessageType::MessageType_SetU2FCounter), + "MessageType_GetNextU2FCounter" => ::std::option::Option::Some(MessageType::MessageType_GetNextU2FCounter), + "MessageType_NextU2FCounter" => ::std::option::Option::Some(MessageType::MessageType_NextU2FCounter), + "MessageType_Deprecated_PassphraseStateRequest" => ::std::option::Option::Some(MessageType::MessageType_Deprecated_PassphraseStateRequest), + "MessageType_Deprecated_PassphraseStateAck" => ::std::option::Option::Some(MessageType::MessageType_Deprecated_PassphraseStateAck), + "MessageType_FirmwareErase" => ::std::option::Option::Some(MessageType::MessageType_FirmwareErase), + "MessageType_FirmwareUpload" => ::std::option::Option::Some(MessageType::MessageType_FirmwareUpload), + "MessageType_FirmwareRequest" => ::std::option::Option::Some(MessageType::MessageType_FirmwareRequest), + "MessageType_SelfTest" => ::std::option::Option::Some(MessageType::MessageType_SelfTest), + "MessageType_GetPublicKey" => ::std::option::Option::Some(MessageType::MessageType_GetPublicKey), + "MessageType_PublicKey" => ::std::option::Option::Some(MessageType::MessageType_PublicKey), + "MessageType_SignTx" => ::std::option::Option::Some(MessageType::MessageType_SignTx), + "MessageType_TxRequest" => ::std::option::Option::Some(MessageType::MessageType_TxRequest), + "MessageType_TxAck" => ::std::option::Option::Some(MessageType::MessageType_TxAck), + "MessageType_GetAddress" => ::std::option::Option::Some(MessageType::MessageType_GetAddress), + "MessageType_Address" => ::std::option::Option::Some(MessageType::MessageType_Address), + "MessageType_TxAckPaymentRequest" => ::std::option::Option::Some(MessageType::MessageType_TxAckPaymentRequest), + "MessageType_SignMessage" => ::std::option::Option::Some(MessageType::MessageType_SignMessage), + "MessageType_VerifyMessage" => ::std::option::Option::Some(MessageType::MessageType_VerifyMessage), + "MessageType_MessageSignature" => ::std::option::Option::Some(MessageType::MessageType_MessageSignature), + "MessageType_GetOwnershipId" => ::std::option::Option::Some(MessageType::MessageType_GetOwnershipId), + "MessageType_OwnershipId" => ::std::option::Option::Some(MessageType::MessageType_OwnershipId), + "MessageType_GetOwnershipProof" => ::std::option::Option::Some(MessageType::MessageType_GetOwnershipProof), + "MessageType_OwnershipProof" => ::std::option::Option::Some(MessageType::MessageType_OwnershipProof), + "MessageType_AuthorizeCoinJoin" => ::std::option::Option::Some(MessageType::MessageType_AuthorizeCoinJoin), + "MessageType_CipherKeyValue" => ::std::option::Option::Some(MessageType::MessageType_CipherKeyValue), + "MessageType_CipheredKeyValue" => ::std::option::Option::Some(MessageType::MessageType_CipheredKeyValue), + "MessageType_SignIdentity" => ::std::option::Option::Some(MessageType::MessageType_SignIdentity), + "MessageType_SignedIdentity" => ::std::option::Option::Some(MessageType::MessageType_SignedIdentity), + "MessageType_GetECDHSessionKey" => ::std::option::Option::Some(MessageType::MessageType_GetECDHSessionKey), + "MessageType_ECDHSessionKey" => ::std::option::Option::Some(MessageType::MessageType_ECDHSessionKey), + "MessageType_CosiCommit" => ::std::option::Option::Some(MessageType::MessageType_CosiCommit), + "MessageType_CosiCommitment" => ::std::option::Option::Some(MessageType::MessageType_CosiCommitment), + "MessageType_CosiSign" => ::std::option::Option::Some(MessageType::MessageType_CosiSign), + "MessageType_CosiSignature" => ::std::option::Option::Some(MessageType::MessageType_CosiSignature), + "MessageType_DebugLinkDecision" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkDecision), + "MessageType_DebugLinkGetState" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkGetState), + "MessageType_DebugLinkState" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkState), + "MessageType_DebugLinkStop" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkStop), + "MessageType_DebugLinkLog" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkLog), + "MessageType_DebugLinkMemoryRead" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkMemoryRead), + "MessageType_DebugLinkMemory" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkMemory), + "MessageType_DebugLinkMemoryWrite" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkMemoryWrite), + "MessageType_DebugLinkFlashErase" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkFlashErase), + "MessageType_DebugLinkLayout" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkLayout), + "MessageType_DebugLinkReseedRandom" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkReseedRandom), + "MessageType_DebugLinkRecordScreen" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkRecordScreen), + "MessageType_DebugLinkEraseSdCard" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkEraseSdCard), + "MessageType_DebugLinkWatchLayout" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkWatchLayout), + "MessageType_DebugLinkResetDebugEvents" => ::std::option::Option::Some(MessageType::MessageType_DebugLinkResetDebugEvents), + "MessageType_EthereumGetPublicKey" => ::std::option::Option::Some(MessageType::MessageType_EthereumGetPublicKey), + "MessageType_EthereumPublicKey" => ::std::option::Option::Some(MessageType::MessageType_EthereumPublicKey), + "MessageType_EthereumGetAddress" => ::std::option::Option::Some(MessageType::MessageType_EthereumGetAddress), + "MessageType_EthereumAddress" => ::std::option::Option::Some(MessageType::MessageType_EthereumAddress), + "MessageType_EthereumSignTx" => ::std::option::Option::Some(MessageType::MessageType_EthereumSignTx), + "MessageType_EthereumSignTxEIP1559" => ::std::option::Option::Some(MessageType::MessageType_EthereumSignTxEIP1559), + "MessageType_EthereumTxRequest" => ::std::option::Option::Some(MessageType::MessageType_EthereumTxRequest), + "MessageType_EthereumTxAck" => ::std::option::Option::Some(MessageType::MessageType_EthereumTxAck), + "MessageType_EthereumSignMessage" => ::std::option::Option::Some(MessageType::MessageType_EthereumSignMessage), + "MessageType_EthereumVerifyMessage" => ::std::option::Option::Some(MessageType::MessageType_EthereumVerifyMessage), + "MessageType_EthereumMessageSignature" => ::std::option::Option::Some(MessageType::MessageType_EthereumMessageSignature), + "MessageType_EthereumSignTypedData" => ::std::option::Option::Some(MessageType::MessageType_EthereumSignTypedData), + "MessageType_EthereumTypedDataStructRequest" => ::std::option::Option::Some(MessageType::MessageType_EthereumTypedDataStructRequest), + "MessageType_EthereumTypedDataStructAck" => ::std::option::Option::Some(MessageType::MessageType_EthereumTypedDataStructAck), + "MessageType_EthereumTypedDataValueRequest" => ::std::option::Option::Some(MessageType::MessageType_EthereumTypedDataValueRequest), + "MessageType_EthereumTypedDataValueAck" => ::std::option::Option::Some(MessageType::MessageType_EthereumTypedDataValueAck), + "MessageType_EthereumTypedDataSignature" => ::std::option::Option::Some(MessageType::MessageType_EthereumTypedDataSignature), + "MessageType_EthereumSignTypedHash" => ::std::option::Option::Some(MessageType::MessageType_EthereumSignTypedHash), + "MessageType_NEMGetAddress" => ::std::option::Option::Some(MessageType::MessageType_NEMGetAddress), + "MessageType_NEMAddress" => ::std::option::Option::Some(MessageType::MessageType_NEMAddress), + "MessageType_NEMSignTx" => ::std::option::Option::Some(MessageType::MessageType_NEMSignTx), + "MessageType_NEMSignedTx" => ::std::option::Option::Some(MessageType::MessageType_NEMSignedTx), + "MessageType_NEMDecryptMessage" => ::std::option::Option::Some(MessageType::MessageType_NEMDecryptMessage), + "MessageType_NEMDecryptedMessage" => ::std::option::Option::Some(MessageType::MessageType_NEMDecryptedMessage), + "MessageType_TezosGetAddress" => ::std::option::Option::Some(MessageType::MessageType_TezosGetAddress), + "MessageType_TezosAddress" => ::std::option::Option::Some(MessageType::MessageType_TezosAddress), + "MessageType_TezosSignTx" => ::std::option::Option::Some(MessageType::MessageType_TezosSignTx), + "MessageType_TezosSignedTx" => ::std::option::Option::Some(MessageType::MessageType_TezosSignedTx), + "MessageType_TezosGetPublicKey" => ::std::option::Option::Some(MessageType::MessageType_TezosGetPublicKey), + "MessageType_TezosPublicKey" => ::std::option::Option::Some(MessageType::MessageType_TezosPublicKey), + "MessageType_StellarSignTx" => ::std::option::Option::Some(MessageType::MessageType_StellarSignTx), + "MessageType_StellarTxOpRequest" => ::std::option::Option::Some(MessageType::MessageType_StellarTxOpRequest), + "MessageType_StellarGetAddress" => ::std::option::Option::Some(MessageType::MessageType_StellarGetAddress), + "MessageType_StellarAddress" => ::std::option::Option::Some(MessageType::MessageType_StellarAddress), + "MessageType_StellarCreateAccountOp" => ::std::option::Option::Some(MessageType::MessageType_StellarCreateAccountOp), + "MessageType_StellarPaymentOp" => ::std::option::Option::Some(MessageType::MessageType_StellarPaymentOp), + "MessageType_StellarPathPaymentStrictReceiveOp" => ::std::option::Option::Some(MessageType::MessageType_StellarPathPaymentStrictReceiveOp), + "MessageType_StellarManageSellOfferOp" => ::std::option::Option::Some(MessageType::MessageType_StellarManageSellOfferOp), + "MessageType_StellarCreatePassiveSellOfferOp" => ::std::option::Option::Some(MessageType::MessageType_StellarCreatePassiveSellOfferOp), + "MessageType_StellarSetOptionsOp" => ::std::option::Option::Some(MessageType::MessageType_StellarSetOptionsOp), + "MessageType_StellarChangeTrustOp" => ::std::option::Option::Some(MessageType::MessageType_StellarChangeTrustOp), + "MessageType_StellarAllowTrustOp" => ::std::option::Option::Some(MessageType::MessageType_StellarAllowTrustOp), + "MessageType_StellarAccountMergeOp" => ::std::option::Option::Some(MessageType::MessageType_StellarAccountMergeOp), + "MessageType_StellarManageDataOp" => ::std::option::Option::Some(MessageType::MessageType_StellarManageDataOp), + "MessageType_StellarBumpSequenceOp" => ::std::option::Option::Some(MessageType::MessageType_StellarBumpSequenceOp), + "MessageType_StellarManageBuyOfferOp" => ::std::option::Option::Some(MessageType::MessageType_StellarManageBuyOfferOp), + "MessageType_StellarPathPaymentStrictSendOp" => ::std::option::Option::Some(MessageType::MessageType_StellarPathPaymentStrictSendOp), + "MessageType_StellarSignedTx" => ::std::option::Option::Some(MessageType::MessageType_StellarSignedTx), + "MessageType_CardanoGetPublicKey" => ::std::option::Option::Some(MessageType::MessageType_CardanoGetPublicKey), + "MessageType_CardanoPublicKey" => ::std::option::Option::Some(MessageType::MessageType_CardanoPublicKey), + "MessageType_CardanoGetAddress" => ::std::option::Option::Some(MessageType::MessageType_CardanoGetAddress), + "MessageType_CardanoAddress" => ::std::option::Option::Some(MessageType::MessageType_CardanoAddress), + "MessageType_CardanoTxItemAck" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxItemAck), + "MessageType_CardanoTxAuxiliaryDataSupplement" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxAuxiliaryDataSupplement), + "MessageType_CardanoTxWitnessRequest" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxWitnessRequest), + "MessageType_CardanoTxWitnessResponse" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxWitnessResponse), + "MessageType_CardanoTxHostAck" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxHostAck), + "MessageType_CardanoTxBodyHash" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxBodyHash), + "MessageType_CardanoSignTxFinished" => ::std::option::Option::Some(MessageType::MessageType_CardanoSignTxFinished), + "MessageType_CardanoSignTxInit" => ::std::option::Option::Some(MessageType::MessageType_CardanoSignTxInit), + "MessageType_CardanoTxInput" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxInput), + "MessageType_CardanoTxOutput" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxOutput), + "MessageType_CardanoAssetGroup" => ::std::option::Option::Some(MessageType::MessageType_CardanoAssetGroup), + "MessageType_CardanoToken" => ::std::option::Option::Some(MessageType::MessageType_CardanoToken), + "MessageType_CardanoTxCertificate" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxCertificate), + "MessageType_CardanoTxWithdrawal" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxWithdrawal), + "MessageType_CardanoTxAuxiliaryData" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxAuxiliaryData), + "MessageType_CardanoPoolOwner" => ::std::option::Option::Some(MessageType::MessageType_CardanoPoolOwner), + "MessageType_CardanoPoolRelayParameters" => ::std::option::Option::Some(MessageType::MessageType_CardanoPoolRelayParameters), + "MessageType_CardanoGetNativeScriptHash" => ::std::option::Option::Some(MessageType::MessageType_CardanoGetNativeScriptHash), + "MessageType_CardanoNativeScriptHash" => ::std::option::Option::Some(MessageType::MessageType_CardanoNativeScriptHash), + "MessageType_CardanoTxMint" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxMint), + "MessageType_CardanoTxCollateralInput" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxCollateralInput), + "MessageType_CardanoTxRequiredSigner" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxRequiredSigner), + "MessageType_CardanoTxInlineDatumChunk" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxInlineDatumChunk), + "MessageType_CardanoTxReferenceScriptChunk" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxReferenceScriptChunk), + "MessageType_CardanoTxReferenceInput" => ::std::option::Option::Some(MessageType::MessageType_CardanoTxReferenceInput), + "MessageType_RippleGetAddress" => ::std::option::Option::Some(MessageType::MessageType_RippleGetAddress), + "MessageType_RippleAddress" => ::std::option::Option::Some(MessageType::MessageType_RippleAddress), + "MessageType_RippleSignTx" => ::std::option::Option::Some(MessageType::MessageType_RippleSignTx), + "MessageType_RippleSignedTx" => ::std::option::Option::Some(MessageType::MessageType_RippleSignedTx), + "MessageType_MoneroTransactionInitRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionInitRequest), + "MessageType_MoneroTransactionInitAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionInitAck), + "MessageType_MoneroTransactionSetInputRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionSetInputRequest), + "MessageType_MoneroTransactionSetInputAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionSetInputAck), + "MessageType_MoneroTransactionInputViniRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionInputViniRequest), + "MessageType_MoneroTransactionInputViniAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionInputViniAck), + "MessageType_MoneroTransactionAllInputsSetRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionAllInputsSetRequest), + "MessageType_MoneroTransactionAllInputsSetAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionAllInputsSetAck), + "MessageType_MoneroTransactionSetOutputRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionSetOutputRequest), + "MessageType_MoneroTransactionSetOutputAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionSetOutputAck), + "MessageType_MoneroTransactionAllOutSetRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionAllOutSetRequest), + "MessageType_MoneroTransactionAllOutSetAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionAllOutSetAck), + "MessageType_MoneroTransactionSignInputRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionSignInputRequest), + "MessageType_MoneroTransactionSignInputAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionSignInputAck), + "MessageType_MoneroTransactionFinalRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionFinalRequest), + "MessageType_MoneroTransactionFinalAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroTransactionFinalAck), + "MessageType_MoneroKeyImageExportInitRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroKeyImageExportInitRequest), + "MessageType_MoneroKeyImageExportInitAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroKeyImageExportInitAck), + "MessageType_MoneroKeyImageSyncStepRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroKeyImageSyncStepRequest), + "MessageType_MoneroKeyImageSyncStepAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroKeyImageSyncStepAck), + "MessageType_MoneroKeyImageSyncFinalRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroKeyImageSyncFinalRequest), + "MessageType_MoneroKeyImageSyncFinalAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroKeyImageSyncFinalAck), + "MessageType_MoneroGetAddress" => ::std::option::Option::Some(MessageType::MessageType_MoneroGetAddress), + "MessageType_MoneroAddress" => ::std::option::Option::Some(MessageType::MessageType_MoneroAddress), + "MessageType_MoneroGetWatchKey" => ::std::option::Option::Some(MessageType::MessageType_MoneroGetWatchKey), + "MessageType_MoneroWatchKey" => ::std::option::Option::Some(MessageType::MessageType_MoneroWatchKey), + "MessageType_DebugMoneroDiagRequest" => ::std::option::Option::Some(MessageType::MessageType_DebugMoneroDiagRequest), + "MessageType_DebugMoneroDiagAck" => ::std::option::Option::Some(MessageType::MessageType_DebugMoneroDiagAck), + "MessageType_MoneroGetTxKeyRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroGetTxKeyRequest), + "MessageType_MoneroGetTxKeyAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroGetTxKeyAck), + "MessageType_MoneroLiveRefreshStartRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroLiveRefreshStartRequest), + "MessageType_MoneroLiveRefreshStartAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroLiveRefreshStartAck), + "MessageType_MoneroLiveRefreshStepRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroLiveRefreshStepRequest), + "MessageType_MoneroLiveRefreshStepAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroLiveRefreshStepAck), + "MessageType_MoneroLiveRefreshFinalRequest" => ::std::option::Option::Some(MessageType::MessageType_MoneroLiveRefreshFinalRequest), + "MessageType_MoneroLiveRefreshFinalAck" => ::std::option::Option::Some(MessageType::MessageType_MoneroLiveRefreshFinalAck), + "MessageType_EosGetPublicKey" => ::std::option::Option::Some(MessageType::MessageType_EosGetPublicKey), + "MessageType_EosPublicKey" => ::std::option::Option::Some(MessageType::MessageType_EosPublicKey), + "MessageType_EosSignTx" => ::std::option::Option::Some(MessageType::MessageType_EosSignTx), + "MessageType_EosTxActionRequest" => ::std::option::Option::Some(MessageType::MessageType_EosTxActionRequest), + "MessageType_EosTxActionAck" => ::std::option::Option::Some(MessageType::MessageType_EosTxActionAck), + "MessageType_EosSignedTx" => ::std::option::Option::Some(MessageType::MessageType_EosSignedTx), + "MessageType_BinanceGetAddress" => ::std::option::Option::Some(MessageType::MessageType_BinanceGetAddress), + "MessageType_BinanceAddress" => ::std::option::Option::Some(MessageType::MessageType_BinanceAddress), + "MessageType_BinanceGetPublicKey" => ::std::option::Option::Some(MessageType::MessageType_BinanceGetPublicKey), + "MessageType_BinancePublicKey" => ::std::option::Option::Some(MessageType::MessageType_BinancePublicKey), + "MessageType_BinanceSignTx" => ::std::option::Option::Some(MessageType::MessageType_BinanceSignTx), + "MessageType_BinanceTxRequest" => ::std::option::Option::Some(MessageType::MessageType_BinanceTxRequest), + "MessageType_BinanceTransferMsg" => ::std::option::Option::Some(MessageType::MessageType_BinanceTransferMsg), + "MessageType_BinanceOrderMsg" => ::std::option::Option::Some(MessageType::MessageType_BinanceOrderMsg), + "MessageType_BinanceCancelMsg" => ::std::option::Option::Some(MessageType::MessageType_BinanceCancelMsg), + "MessageType_BinanceSignedTx" => ::std::option::Option::Some(MessageType::MessageType_BinanceSignedTx), + "MessageType_WebAuthnListResidentCredentials" => ::std::option::Option::Some(MessageType::MessageType_WebAuthnListResidentCredentials), + "MessageType_WebAuthnCredentials" => ::std::option::Option::Some(MessageType::MessageType_WebAuthnCredentials), + "MessageType_WebAuthnAddResidentCredential" => ::std::option::Option::Some(MessageType::MessageType_WebAuthnAddResidentCredential), + "MessageType_WebAuthnRemoveResidentCredential" => ::std::option::Option::Some(MessageType::MessageType_WebAuthnRemoveResidentCredential), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [MessageType] = &[ MessageType::MessageType_Initialize, MessageType::MessageType_Ping, diff --git a/rust/trezor-client/src/protos/generated/messages_binance.rs b/rust/trezor-client/src/protos/generated/messages_binance.rs index b4adf3afa..0f5a29d0d 100644 --- a/rust/trezor-client/src/protos/generated/messages_binance.rs +++ b/rust/trezor-client/src/protos/generated/messages_binance.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceGetAddress.address_n) @@ -224,8 +224,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceAddress.address) @@ -385,8 +385,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceGetPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceGetPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceGetPublicKey.address_n) @@ -547,8 +547,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceGetPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinancePublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinancePublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinancePublicKey.public_key) @@ -708,8 +708,8 @@ impl ::protobuf::reflect::ProtobufValue for BinancePublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceSignTx.address_n) @@ -1138,8 +1138,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceSignTx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceTxRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceTxRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.binance.BinanceTxRequest.special_fields) @@ -1241,8 +1241,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceTxRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceTransferMsg) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceTransferMsg { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceTransferMsg.inputs) @@ -1432,8 +1432,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceTransferMsg { /// Nested message and enums of message `BinanceTransferMsg` pub mod binance_transfer_msg { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceTransferMsg.BinanceInputOutput) + #[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceInputOutput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceTransferMsg.BinanceInputOutput.address) @@ -1617,8 +1617,8 @@ pub mod binance_transfer_msg { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceTransferMsg.BinanceCoin) + #[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceCoin { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceTransferMsg.BinanceCoin.amount) @@ -1819,8 +1819,8 @@ pub mod binance_transfer_msg { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceOrderMsg) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceOrderMsg { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceOrderMsg.id) @@ -2326,6 +2326,16 @@ pub mod binance_order_msg { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "OT_UNKNOWN" => ::std::option::Option::Some(BinanceOrderType::OT_UNKNOWN), + "MARKET" => ::std::option::Option::Some(BinanceOrderType::MARKET), + "LIMIT" => ::std::option::Option::Some(BinanceOrderType::LIMIT), + "OT_RESERVED" => ::std::option::Option::Some(BinanceOrderType::OT_RESERVED), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [BinanceOrderType] = &[ BinanceOrderType::OT_UNKNOWN, BinanceOrderType::MARKET, @@ -2385,6 +2395,15 @@ pub mod binance_order_msg { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "SIDE_UNKNOWN" => ::std::option::Option::Some(BinanceOrderSide::SIDE_UNKNOWN), + "BUY" => ::std::option::Option::Some(BinanceOrderSide::BUY), + "SELL" => ::std::option::Option::Some(BinanceOrderSide::SELL), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [BinanceOrderSide] = &[ BinanceOrderSide::SIDE_UNKNOWN, BinanceOrderSide::BUY, @@ -2446,6 +2465,16 @@ pub mod binance_order_msg { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "TIF_UNKNOWN" => ::std::option::Option::Some(BinanceTimeInForce::TIF_UNKNOWN), + "GTE" => ::std::option::Option::Some(BinanceTimeInForce::GTE), + "TIF_RESERVED" => ::std::option::Option::Some(BinanceTimeInForce::TIF_RESERVED), + "IOC" => ::std::option::Option::Some(BinanceTimeInForce::IOC), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [BinanceTimeInForce] = &[ BinanceTimeInForce::TIF_UNKNOWN, BinanceTimeInForce::GTE, @@ -2479,8 +2508,8 @@ pub mod binance_order_msg { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceCancelMsg) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceCancelMsg { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceCancelMsg.refid) @@ -2745,8 +2774,8 @@ impl ::protobuf::reflect::ProtobufValue for BinanceCancelMsg { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.binance.BinanceSignedTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BinanceSignedTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.binance.BinanceSignedTx.signature) diff --git a/rust/trezor-client/src/protos/generated/messages_bitcoin.rs b/rust/trezor-client/src/protos/generated/messages_bitcoin.rs index cd5acf594..bef000429 100644 --- a/rust/trezor-client/src/protos/generated/messages_bitcoin.rs +++ b/rust/trezor-client/src/protos/generated/messages_bitcoin.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.MultisigRedeemScriptType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MultisigRedeemScriptType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.MultisigRedeemScriptType.pubkeys) @@ -258,8 +258,8 @@ impl ::protobuf::reflect::ProtobufValue for MultisigRedeemScriptType { /// Nested message and enums of message `MultisigRedeemScriptType` pub mod multisig_redeem_script_type { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.MultisigRedeemScriptType.HDNodePathType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct HDNodePathType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.MultisigRedeemScriptType.HDNodePathType.node) @@ -411,8 +411,8 @@ pub mod multisig_redeem_script_type { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.GetPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.GetPublicKey.address_n) @@ -758,8 +758,8 @@ impl ::protobuf::reflect::ProtobufValue for GetPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.PublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.PublicKey.node) @@ -983,8 +983,8 @@ impl ::protobuf::reflect::ProtobufValue for PublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.GetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.GetAddress.address_n) @@ -1337,8 +1337,8 @@ impl ::protobuf::reflect::ProtobufValue for GetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.Address) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Address { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.Address.address) @@ -1552,8 +1552,8 @@ impl ::protobuf::reflect::ProtobufValue for Address { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.GetOwnershipId) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetOwnershipId { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.GetOwnershipId.address_n) @@ -1795,8 +1795,8 @@ impl ::protobuf::reflect::ProtobufValue for GetOwnershipId { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.OwnershipId) +#[derive(PartialEq,Clone,Default,Debug)] pub struct OwnershipId { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.OwnershipId.ownership_id) @@ -1956,8 +1956,8 @@ impl ::protobuf::reflect::ProtobufValue for OwnershipId { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.SignMessage) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SignMessage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.SignMessage.address_n) @@ -2306,8 +2306,8 @@ impl ::protobuf::reflect::ProtobufValue for SignMessage { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.MessageSignature) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MessageSignature { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.MessageSignature.address) @@ -2524,8 +2524,8 @@ impl ::protobuf::reflect::ProtobufValue for MessageSignature { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.VerifyMessage) +#[derive(PartialEq,Clone,Default,Debug)] pub struct VerifyMessage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.VerifyMessage.address) @@ -2890,8 +2890,8 @@ impl ::protobuf::reflect::ProtobufValue for VerifyMessage { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.SignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.SignTx.outputs_count) @@ -3564,8 +3564,8 @@ impl ::protobuf::reflect::ProtobufValue for SignTx { /// Nested message and enums of message `SignTx` pub mod sign_tx { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.SignTx.CoinJoinRequest) + #[derive(PartialEq,Clone,Default,Debug)] pub struct CoinJoinRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.SignTx.CoinJoinRequest.fee_rate) @@ -3903,8 +3903,8 @@ pub mod sign_tx { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxRequest.request_type) @@ -4087,8 +4087,8 @@ impl ::protobuf::reflect::ProtobufValue for TxRequest { /// Nested message and enums of message `TxRequest` pub mod tx_request { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxRequest.TxRequestDetailsType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxRequestDetailsType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxRequest.TxRequestDetailsType.request_index) @@ -4356,8 +4356,8 @@ pub mod tx_request { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxRequest.TxRequestSerializedType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxRequestSerializedType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxRequest.TxRequestSerializedType.signature_index) @@ -4647,6 +4647,20 @@ pub mod tx_request { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "TXINPUT" => ::std::option::Option::Some(RequestType::TXINPUT), + "TXOUTPUT" => ::std::option::Option::Some(RequestType::TXOUTPUT), + "TXMETA" => ::std::option::Option::Some(RequestType::TXMETA), + "TXFINISHED" => ::std::option::Option::Some(RequestType::TXFINISHED), + "TXEXTRADATA" => ::std::option::Option::Some(RequestType::TXEXTRADATA), + "TXORIGINPUT" => ::std::option::Option::Some(RequestType::TXORIGINPUT), + "TXORIGOUTPUT" => ::std::option::Option::Some(RequestType::TXORIGOUTPUT), + "TXPAYMENTREQ" => ::std::option::Option::Some(RequestType::TXPAYMENTREQ), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [RequestType] = &[ RequestType::TXINPUT, RequestType::TXOUTPUT, @@ -4684,8 +4698,8 @@ pub mod tx_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAck.tx) @@ -4814,8 +4828,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAck { /// Nested message and enums of message `TxAck` pub mod tx_ack { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAck.TransactionType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TransactionType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAck.TransactionType.version) @@ -5416,8 +5430,8 @@ pub mod tx_ack { /// Nested message and enums of message `TransactionType` pub mod transaction_type { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAck.TransactionType.TxInputType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxInputType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAck.TransactionType.TxInputType.address_n) @@ -6251,8 +6265,8 @@ pub mod tx_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAck.TransactionType.TxOutputBinType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxOutputBinType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAck.TransactionType.TxOutputBinType.amount) @@ -6489,8 +6503,8 @@ pub mod tx_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAck.TransactionType.TxOutputType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxOutputType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAck.TransactionType.TxOutputType.address) @@ -6956,8 +6970,8 @@ pub mod tx_ack { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxInput.address_n) @@ -7794,8 +7808,8 @@ impl ::protobuf::reflect::ProtobufValue for TxInput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxOutput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxOutput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxOutput.address) @@ -8259,8 +8273,8 @@ impl ::protobuf::reflect::ProtobufValue for TxOutput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.PrevTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PrevTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.PrevTx.version) @@ -8708,8 +8722,8 @@ impl ::protobuf::reflect::ProtobufValue for PrevTx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.PrevInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PrevInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.PrevInput.prev_hash) @@ -9043,8 +9057,8 @@ impl ::protobuf::reflect::ProtobufValue for PrevInput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.PrevOutput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PrevOutput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.PrevOutput.amount) @@ -9281,8 +9295,8 @@ impl ::protobuf::reflect::ProtobufValue for PrevOutput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPaymentRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPaymentRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPaymentRequest.nonce) @@ -9616,8 +9630,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckPaymentRequest { /// Nested message and enums of message `TxAckPaymentRequest` pub mod tx_ack_payment_request { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPaymentRequest.PaymentRequestMemo) + #[derive(PartialEq,Clone,Default,Debug)] pub struct PaymentRequestMemo { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPaymentRequest.PaymentRequestMemo.text_memo) @@ -9792,8 +9806,8 @@ pub mod tx_ack_payment_request { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPaymentRequest.TextMemo) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TextMemo { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPaymentRequest.TextMemo.text) @@ -9953,8 +9967,8 @@ pub mod tx_ack_payment_request { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPaymentRequest.RefundMemo) + #[derive(PartialEq,Clone,Default,Debug)] pub struct RefundMemo { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPaymentRequest.RefundMemo.address) @@ -10171,8 +10185,8 @@ pub mod tx_ack_payment_request { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPaymentRequest.CoinPurchaseMemo) + #[derive(PartialEq,Clone,Default,Debug)] pub struct CoinPurchaseMemo { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPaymentRequest.CoinPurchaseMemo.coin_type) @@ -10487,8 +10501,8 @@ pub mod tx_ack_payment_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckInput.tx) @@ -10620,8 +10634,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckInput { /// Nested message and enums of message `TxAckInput` pub mod tx_ack_input { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckInput.TxAckInputWrapper) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckInputWrapper { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckInput.TxAckInputWrapper.input) @@ -10752,8 +10766,8 @@ pub mod tx_ack_input { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckOutput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckOutput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckOutput.tx) @@ -10885,8 +10899,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckOutput { /// Nested message and enums of message `TxAckOutput` pub mod tx_ack_output { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckOutput.TxAckOutputWrapper) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckOutputWrapper { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckOutput.TxAckOutputWrapper.output) @@ -11017,8 +11031,8 @@ pub mod tx_ack_output { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevMeta) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevMeta { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevMeta.tx) @@ -11148,8 +11162,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckPrevMeta { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevInput.tx) @@ -11281,8 +11295,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckPrevInput { /// Nested message and enums of message `TxAckPrevInput` pub mod tx_ack_prev_input { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevInput.TxAckPrevInputWrapper) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevInputWrapper { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevInput.TxAckPrevInputWrapper.input) @@ -11413,8 +11427,8 @@ pub mod tx_ack_prev_input { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevOutput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevOutput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevOutput.tx) @@ -11546,8 +11560,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckPrevOutput { /// Nested message and enums of message `TxAckPrevOutput` pub mod tx_ack_prev_output { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevOutput.TxAckPrevOutputWrapper) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevOutputWrapper { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevOutput.TxAckPrevOutputWrapper.output) @@ -11678,8 +11692,8 @@ pub mod tx_ack_prev_output { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevExtraData) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevExtraData { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevExtraData.tx) @@ -11811,8 +11825,8 @@ impl ::protobuf::reflect::ProtobufValue for TxAckPrevExtraData { /// Nested message and enums of message `TxAckPrevExtraData` pub mod tx_ack_prev_extra_data { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.TxAckPrevExtraData.TxAckPrevExtraDataWrapper) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TxAckPrevExtraDataWrapper { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.TxAckPrevExtraData.TxAckPrevExtraDataWrapper.extra_data_chunk) @@ -11973,8 +11987,8 @@ pub mod tx_ack_prev_extra_data { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.GetOwnershipProof) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetOwnershipProof { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.GetOwnershipProof.address_n) @@ -12325,8 +12339,8 @@ impl ::protobuf::reflect::ProtobufValue for GetOwnershipProof { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.OwnershipProof) +#[derive(PartialEq,Clone,Default,Debug)] pub struct OwnershipProof { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.OwnershipProof.ownership_proof) @@ -12543,8 +12557,8 @@ impl ::protobuf::reflect::ProtobufValue for OwnershipProof { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bitcoin.AuthorizeCoinJoin) +#[derive(PartialEq,Clone,Default,Debug)] pub struct AuthorizeCoinJoin { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bitcoin.AuthorizeCoinJoin.coordinator) @@ -13015,6 +13029,18 @@ impl ::protobuf::Enum for InputScriptType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "SPENDADDRESS" => ::std::option::Option::Some(InputScriptType::SPENDADDRESS), + "SPENDMULTISIG" => ::std::option::Option::Some(InputScriptType::SPENDMULTISIG), + "EXTERNAL" => ::std::option::Option::Some(InputScriptType::EXTERNAL), + "SPENDWITNESS" => ::std::option::Option::Some(InputScriptType::SPENDWITNESS), + "SPENDP2SHWITNESS" => ::std::option::Option::Some(InputScriptType::SPENDP2SHWITNESS), + "SPENDTAPROOT" => ::std::option::Option::Some(InputScriptType::SPENDTAPROOT), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [InputScriptType] = &[ InputScriptType::SPENDADDRESS, InputScriptType::SPENDMULTISIG, @@ -13088,6 +13114,19 @@ impl ::protobuf::Enum for OutputScriptType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "PAYTOADDRESS" => ::std::option::Option::Some(OutputScriptType::PAYTOADDRESS), + "PAYTOSCRIPTHASH" => ::std::option::Option::Some(OutputScriptType::PAYTOSCRIPTHASH), + "PAYTOMULTISIG" => ::std::option::Option::Some(OutputScriptType::PAYTOMULTISIG), + "PAYTOOPRETURN" => ::std::option::Option::Some(OutputScriptType::PAYTOOPRETURN), + "PAYTOWITNESS" => ::std::option::Option::Some(OutputScriptType::PAYTOWITNESS), + "PAYTOP2SHWITNESS" => ::std::option::Option::Some(OutputScriptType::PAYTOP2SHWITNESS), + "PAYTOTAPROOT" => ::std::option::Option::Some(OutputScriptType::PAYTOTAPROOT), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [OutputScriptType] = &[ OutputScriptType::PAYTOADDRESS, OutputScriptType::PAYTOSCRIPTHASH, @@ -13147,6 +13186,14 @@ impl ::protobuf::Enum for DecredStakingSpendType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "SSGen" => ::std::option::Option::Some(DecredStakingSpendType::SSGen), + "SSRTX" => ::std::option::Option::Some(DecredStakingSpendType::SSRTX), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [DecredStakingSpendType] = &[ DecredStakingSpendType::SSGen, DecredStakingSpendType::SSRTX, @@ -13207,6 +13254,16 @@ impl ::protobuf::Enum for AmountUnit { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "BITCOIN" => ::std::option::Option::Some(AmountUnit::BITCOIN), + "MILLIBITCOIN" => ::std::option::Option::Some(AmountUnit::MILLIBITCOIN), + "MICROBITCOIN" => ::std::option::Option::Some(AmountUnit::MICROBITCOIN), + "SATOSHI" => ::std::option::Option::Some(AmountUnit::SATOSHI), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [AmountUnit] = &[ AmountUnit::BITCOIN, AmountUnit::MILLIBITCOIN, diff --git a/rust/trezor-client/src/protos/generated/messages_bootloader.rs b/rust/trezor-client/src/protos/generated/messages_bootloader.rs index 705409a70..6c328a173 100644 --- a/rust/trezor-client/src/protos/generated/messages_bootloader.rs +++ b/rust/trezor-client/src/protos/generated/messages_bootloader.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bootloader.FirmwareErase) +#[derive(PartialEq,Clone,Default,Debug)] pub struct FirmwareErase { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bootloader.FirmwareErase.length) @@ -166,8 +166,8 @@ impl ::protobuf::reflect::ProtobufValue for FirmwareErase { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bootloader.FirmwareRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct FirmwareRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bootloader.FirmwareRequest.offset) @@ -350,8 +350,8 @@ impl ::protobuf::reflect::ProtobufValue for FirmwareRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bootloader.FirmwareUpload) +#[derive(PartialEq,Clone,Default,Debug)] pub struct FirmwareUpload { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bootloader.FirmwareUpload.payload) @@ -565,8 +565,8 @@ impl ::protobuf::reflect::ProtobufValue for FirmwareUpload { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.bootloader.SelfTest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SelfTest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.bootloader.SelfTest.payload) diff --git a/rust/trezor-client/src/protos/generated/messages_cardano.rs b/rust/trezor-client/src/protos/generated/messages_cardano.rs index 7142a9a4b..da2d0c7e5 100644 --- a/rust/trezor-client/src/protos/generated/messages_cardano.rs +++ b/rust/trezor-client/src/protos/generated/messages_cardano.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoBlockchainPointerType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoBlockchainPointerType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoBlockchainPointerType.block_index) @@ -249,8 +249,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoBlockchainPointerType { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoNativeScript) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoNativeScript { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoNativeScript.type) @@ -606,8 +606,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoNativeScript { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoGetNativeScriptHash) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoGetNativeScriptHash { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoGetNativeScriptHash.script) @@ -823,8 +823,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoGetNativeScriptHash { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoNativeScriptHash) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoNativeScriptHash { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoNativeScriptHash.script_hash) @@ -984,8 +984,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoNativeScriptHash { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoAddressParametersType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoAddressParametersType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoAddressParametersType.address_type) @@ -1359,8 +1359,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoAddressParametersType { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoGetAddress.show_display) @@ -1687,8 +1687,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoAddress.address) @@ -1848,8 +1848,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoGetPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoGetPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoGetPublicKey.address_n) @@ -2053,8 +2053,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoGetPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoPublicKey.xpub) @@ -2241,8 +2241,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoSignTxInit) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoSignTxInit { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoSignTxInit.signing_mode) @@ -3224,8 +3224,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoSignTxInit { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxInput.prev_hash) @@ -3425,8 +3425,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxInput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxOutput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxOutput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxOutput.address) @@ -3855,8 +3855,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxOutput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoAssetGroup) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoAssetGroup { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoAssetGroup.policy_id) @@ -4056,8 +4056,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoAssetGroup { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoToken) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoToken { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoToken.asset_name_bytes) @@ -4291,8 +4291,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoToken { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxInlineDatumChunk) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxInlineDatumChunk { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxInlineDatumChunk.data) @@ -4452,8 +4452,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxInlineDatumChunk { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxReferenceScriptChunk) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxReferenceScriptChunk { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxReferenceScriptChunk.data) @@ -4613,8 +4613,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxReferenceScriptChunk { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoPoolOwner) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoPoolOwner { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoPoolOwner.staking_key_path) @@ -4792,8 +4792,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoPoolOwner { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoPoolRelayParameters) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoPoolRelayParameters { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoPoolRelayParameters.type) @@ -5138,8 +5138,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoPoolRelayParameters { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoPoolMetadataType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoPoolMetadataType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoPoolMetadataType.url) @@ -5356,8 +5356,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoPoolMetadataType { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoPoolParametersType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoPoolParametersType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoPoolParametersType.pool_id) @@ -5895,8 +5895,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoPoolParametersType { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxCertificate) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxCertificate { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxCertificate.type) @@ -6249,8 +6249,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxCertificate { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxWithdrawal) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxWithdrawal { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxWithdrawal.path) @@ -6522,8 +6522,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxWithdrawal { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoCVoteRegistrationDelegation) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoCVoteRegistrationDelegation { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoCVoteRegistrationDelegation.vote_public_key) @@ -6723,8 +6723,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoCVoteRegistrationDelegation { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoCVoteRegistrationParametersType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoCVoteRegistrationParametersType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoCVoteRegistrationParametersType.vote_public_key) @@ -7121,8 +7121,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoCVoteRegistrationParametersTy type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxAuxiliaryData) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxAuxiliaryData { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxAuxiliaryData.cvote_registration_parameters) @@ -7303,8 +7303,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxAuxiliaryData { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxMint) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxMint { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxMint.asset_groups_count) @@ -7447,8 +7447,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxMint { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxCollateralInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxCollateralInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxCollateralInput.prev_hash) @@ -7648,8 +7648,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxCollateralInput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxRequiredSigner) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxRequiredSigner { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxRequiredSigner.key_hash) @@ -7827,8 +7827,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxRequiredSigner { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxReferenceInput) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxReferenceInput { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxReferenceInput.prev_hash) @@ -8028,8 +8028,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxReferenceInput { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxItemAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxItemAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.cardano.CardanoTxItemAck.special_fields) @@ -8131,8 +8131,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxItemAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxAuxiliaryDataSupplement) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxAuxiliaryDataSupplement { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxAuxiliaryDataSupplement.type) @@ -8386,8 +8386,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxAuxiliaryDataSupplement { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxWitnessRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxWitnessRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxWitnessRequest.path) @@ -8511,8 +8511,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxWitnessRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxWitnessResponse) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxWitnessResponse { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxWitnessResponse.type) @@ -8826,8 +8826,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxWitnessResponse { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxHostAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxHostAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.cardano.CardanoTxHostAck.special_fields) @@ -8929,8 +8929,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxHostAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoTxBodyHash) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoTxBodyHash { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.cardano.CardanoTxBodyHash.tx_hash) @@ -9090,8 +9090,8 @@ impl ::protobuf::reflect::ProtobufValue for CardanoTxBodyHash { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.cardano.CardanoSignTxFinished) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CardanoSignTxFinished { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.cardano.CardanoSignTxFinished.special_fields) @@ -9220,6 +9220,15 @@ impl ::protobuf::Enum for CardanoDerivationType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "LEDGER" => ::std::option::Option::Some(CardanoDerivationType::LEDGER), + "ICARUS" => ::std::option::Option::Some(CardanoDerivationType::ICARUS), + "ICARUS_TREZOR" => ::std::option::Option::Some(CardanoDerivationType::ICARUS_TREZOR), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoDerivationType] = &[ CardanoDerivationType::LEDGER, CardanoDerivationType::ICARUS, @@ -9302,6 +9311,23 @@ impl ::protobuf::Enum for CardanoAddressType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "BASE" => ::std::option::Option::Some(CardanoAddressType::BASE), + "BASE_SCRIPT_KEY" => ::std::option::Option::Some(CardanoAddressType::BASE_SCRIPT_KEY), + "BASE_KEY_SCRIPT" => ::std::option::Option::Some(CardanoAddressType::BASE_KEY_SCRIPT), + "BASE_SCRIPT_SCRIPT" => ::std::option::Option::Some(CardanoAddressType::BASE_SCRIPT_SCRIPT), + "POINTER" => ::std::option::Option::Some(CardanoAddressType::POINTER), + "POINTER_SCRIPT" => ::std::option::Option::Some(CardanoAddressType::POINTER_SCRIPT), + "ENTERPRISE" => ::std::option::Option::Some(CardanoAddressType::ENTERPRISE), + "ENTERPRISE_SCRIPT" => ::std::option::Option::Some(CardanoAddressType::ENTERPRISE_SCRIPT), + "BYRON" => ::std::option::Option::Some(CardanoAddressType::BYRON), + "REWARD" => ::std::option::Option::Some(CardanoAddressType::REWARD), + "REWARD_SCRIPT" => ::std::option::Option::Some(CardanoAddressType::REWARD_SCRIPT), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoAddressType] = &[ CardanoAddressType::BASE, CardanoAddressType::BASE_SCRIPT_KEY, @@ -9389,6 +9415,18 @@ impl ::protobuf::Enum for CardanoNativeScriptType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "PUB_KEY" => ::std::option::Option::Some(CardanoNativeScriptType::PUB_KEY), + "ALL" => ::std::option::Option::Some(CardanoNativeScriptType::ALL), + "ANY" => ::std::option::Option::Some(CardanoNativeScriptType::ANY), + "N_OF_K" => ::std::option::Option::Some(CardanoNativeScriptType::N_OF_K), + "INVALID_BEFORE" => ::std::option::Option::Some(CardanoNativeScriptType::INVALID_BEFORE), + "INVALID_HEREAFTER" => ::std::option::Option::Some(CardanoNativeScriptType::INVALID_HEREAFTER), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoNativeScriptType] = &[ CardanoNativeScriptType::PUB_KEY, CardanoNativeScriptType::ALL, @@ -9450,6 +9488,15 @@ impl ::protobuf::Enum for CardanoNativeScriptHashDisplayFormat { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "HIDE" => ::std::option::Option::Some(CardanoNativeScriptHashDisplayFormat::HIDE), + "BECH32" => ::std::option::Option::Some(CardanoNativeScriptHashDisplayFormat::BECH32), + "POLICY_ID" => ::std::option::Option::Some(CardanoNativeScriptHashDisplayFormat::POLICY_ID), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoNativeScriptHashDisplayFormat] = &[ CardanoNativeScriptHashDisplayFormat::HIDE, CardanoNativeScriptHashDisplayFormat::BECH32, @@ -9505,6 +9552,14 @@ impl ::protobuf::Enum for CardanoTxOutputSerializationFormat { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "ARRAY_LEGACY" => ::std::option::Option::Some(CardanoTxOutputSerializationFormat::ARRAY_LEGACY), + "MAP_BABBAGE" => ::std::option::Option::Some(CardanoTxOutputSerializationFormat::MAP_BABBAGE), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoTxOutputSerializationFormat] = &[ CardanoTxOutputSerializationFormat::ARRAY_LEGACY, CardanoTxOutputSerializationFormat::MAP_BABBAGE, @@ -9565,6 +9620,16 @@ impl ::protobuf::Enum for CardanoCertificateType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "STAKE_REGISTRATION" => ::std::option::Option::Some(CardanoCertificateType::STAKE_REGISTRATION), + "STAKE_DEREGISTRATION" => ::std::option::Option::Some(CardanoCertificateType::STAKE_DEREGISTRATION), + "STAKE_DELEGATION" => ::std::option::Option::Some(CardanoCertificateType::STAKE_DELEGATION), + "STAKE_POOL_REGISTRATION" => ::std::option::Option::Some(CardanoCertificateType::STAKE_POOL_REGISTRATION), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoCertificateType] = &[ CardanoCertificateType::STAKE_REGISTRATION, CardanoCertificateType::STAKE_DEREGISTRATION, @@ -9624,6 +9689,15 @@ impl ::protobuf::Enum for CardanoPoolRelayType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "SINGLE_HOST_IP" => ::std::option::Option::Some(CardanoPoolRelayType::SINGLE_HOST_IP), + "SINGLE_HOST_NAME" => ::std::option::Option::Some(CardanoPoolRelayType::SINGLE_HOST_NAME), + "MULTIPLE_HOST_NAME" => ::std::option::Option::Some(CardanoPoolRelayType::MULTIPLE_HOST_NAME), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoPoolRelayType] = &[ CardanoPoolRelayType::SINGLE_HOST_IP, CardanoPoolRelayType::SINGLE_HOST_NAME, @@ -9679,6 +9753,14 @@ impl ::protobuf::Enum for CardanoTxAuxiliaryDataSupplementType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "NONE" => ::std::option::Option::Some(CardanoTxAuxiliaryDataSupplementType::NONE), + "CVOTE_REGISTRATION_SIGNATURE" => ::std::option::Option::Some(CardanoTxAuxiliaryDataSupplementType::CVOTE_REGISTRATION_SIGNATURE), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoTxAuxiliaryDataSupplementType] = &[ CardanoTxAuxiliaryDataSupplementType::NONE, CardanoTxAuxiliaryDataSupplementType::CVOTE_REGISTRATION_SIGNATURE, @@ -9733,6 +9815,14 @@ impl ::protobuf::Enum for CardanoCVoteRegistrationFormat { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "CIP15" => ::std::option::Option::Some(CardanoCVoteRegistrationFormat::CIP15), + "CIP36" => ::std::option::Option::Some(CardanoCVoteRegistrationFormat::CIP36), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoCVoteRegistrationFormat] = &[ CardanoCVoteRegistrationFormat::CIP15, CardanoCVoteRegistrationFormat::CIP36, @@ -9793,6 +9883,16 @@ impl ::protobuf::Enum for CardanoTxSigningMode { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "ORDINARY_TRANSACTION" => ::std::option::Option::Some(CardanoTxSigningMode::ORDINARY_TRANSACTION), + "POOL_REGISTRATION_AS_OWNER" => ::std::option::Option::Some(CardanoTxSigningMode::POOL_REGISTRATION_AS_OWNER), + "MULTISIG_TRANSACTION" => ::std::option::Option::Some(CardanoTxSigningMode::MULTISIG_TRANSACTION), + "PLUTUS_TRANSACTION" => ::std::option::Option::Some(CardanoTxSigningMode::PLUTUS_TRANSACTION), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoTxSigningMode] = &[ CardanoTxSigningMode::ORDINARY_TRANSACTION, CardanoTxSigningMode::POOL_REGISTRATION_AS_OWNER, @@ -9849,6 +9949,14 @@ impl ::protobuf::Enum for CardanoTxWitnessType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "BYRON_WITNESS" => ::std::option::Option::Some(CardanoTxWitnessType::BYRON_WITNESS), + "SHELLEY_WITNESS" => ::std::option::Option::Some(CardanoTxWitnessType::SHELLEY_WITNESS), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [CardanoTxWitnessType] = &[ CardanoTxWitnessType::BYRON_WITNESS, CardanoTxWitnessType::SHELLEY_WITNESS, diff --git a/rust/trezor-client/src/protos/generated/messages_common.rs b/rust/trezor-client/src/protos/generated/messages_common.rs index d86019dd2..7688e2d41 100644 --- a/rust/trezor-client/src/protos/generated/messages_common.rs +++ b/rust/trezor-client/src/protos/generated/messages_common.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.Success) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Success { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.Success.message) @@ -183,8 +183,8 @@ impl ::protobuf::reflect::ProtobufValue for Success { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.Failure) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Failure { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.Failure.code) @@ -446,6 +446,27 @@ pub mod failure { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Failure_UnexpectedMessage" => ::std::option::Option::Some(FailureType::Failure_UnexpectedMessage), + "Failure_ButtonExpected" => ::std::option::Option::Some(FailureType::Failure_ButtonExpected), + "Failure_DataError" => ::std::option::Option::Some(FailureType::Failure_DataError), + "Failure_ActionCancelled" => ::std::option::Option::Some(FailureType::Failure_ActionCancelled), + "Failure_PinExpected" => ::std::option::Option::Some(FailureType::Failure_PinExpected), + "Failure_PinCancelled" => ::std::option::Option::Some(FailureType::Failure_PinCancelled), + "Failure_PinInvalid" => ::std::option::Option::Some(FailureType::Failure_PinInvalid), + "Failure_InvalidSignature" => ::std::option::Option::Some(FailureType::Failure_InvalidSignature), + "Failure_ProcessError" => ::std::option::Option::Some(FailureType::Failure_ProcessError), + "Failure_NotEnoughFunds" => ::std::option::Option::Some(FailureType::Failure_NotEnoughFunds), + "Failure_NotInitialized" => ::std::option::Option::Some(FailureType::Failure_NotInitialized), + "Failure_PinMismatch" => ::std::option::Option::Some(FailureType::Failure_PinMismatch), + "Failure_WipeCodeMismatch" => ::std::option::Option::Some(FailureType::Failure_WipeCodeMismatch), + "Failure_InvalidSession" => ::std::option::Option::Some(FailureType::Failure_InvalidSession), + "Failure_FirmwareError" => ::std::option::Option::Some(FailureType::Failure_FirmwareError), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [FailureType] = &[ FailureType::Failure_UnexpectedMessage, FailureType::Failure_ButtonExpected, @@ -507,8 +528,8 @@ pub mod failure { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.ButtonRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ButtonRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.ButtonRequest.code) @@ -768,6 +789,32 @@ pub mod button_request { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "ButtonRequest_Other" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_Other), + "ButtonRequest_FeeOverThreshold" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_FeeOverThreshold), + "ButtonRequest_ConfirmOutput" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_ConfirmOutput), + "ButtonRequest_ResetDevice" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_ResetDevice), + "ButtonRequest_ConfirmWord" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_ConfirmWord), + "ButtonRequest_WipeDevice" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_WipeDevice), + "ButtonRequest_ProtectCall" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_ProtectCall), + "ButtonRequest_SignTx" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_SignTx), + "ButtonRequest_FirmwareCheck" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_FirmwareCheck), + "ButtonRequest_Address" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_Address), + "ButtonRequest_PublicKey" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_PublicKey), + "ButtonRequest_MnemonicWordCount" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_MnemonicWordCount), + "ButtonRequest_MnemonicInput" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_MnemonicInput), + "_Deprecated_ButtonRequest_PassphraseType" => ::std::option::Option::Some(ButtonRequestType::_Deprecated_ButtonRequest_PassphraseType), + "ButtonRequest_UnknownDerivationPath" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_UnknownDerivationPath), + "ButtonRequest_RecoveryHomepage" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_RecoveryHomepage), + "ButtonRequest_Success" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_Success), + "ButtonRequest_Warning" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_Warning), + "ButtonRequest_PassphraseEntry" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_PassphraseEntry), + "ButtonRequest_PinEntry" => ::std::option::Option::Some(ButtonRequestType::ButtonRequest_PinEntry), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [ButtonRequestType] = &[ ButtonRequestType::ButtonRequest_Other, ButtonRequestType::ButtonRequest_FeeOverThreshold, @@ -839,8 +886,8 @@ pub mod button_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.ButtonAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ButtonAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.common.ButtonAck.special_fields) @@ -942,8 +989,8 @@ impl ::protobuf::reflect::ProtobufValue for ButtonAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.PinMatrixRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PinMatrixRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.PinMatrixRequest.type) @@ -1121,6 +1168,17 @@ pub mod pin_matrix_request { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "PinMatrixRequestType_Current" => ::std::option::Option::Some(PinMatrixRequestType::PinMatrixRequestType_Current), + "PinMatrixRequestType_NewFirst" => ::std::option::Option::Some(PinMatrixRequestType::PinMatrixRequestType_NewFirst), + "PinMatrixRequestType_NewSecond" => ::std::option::Option::Some(PinMatrixRequestType::PinMatrixRequestType_NewSecond), + "PinMatrixRequestType_WipeCodeFirst" => ::std::option::Option::Some(PinMatrixRequestType::PinMatrixRequestType_WipeCodeFirst), + "PinMatrixRequestType_WipeCodeSecond" => ::std::option::Option::Some(PinMatrixRequestType::PinMatrixRequestType_WipeCodeSecond), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [PinMatrixRequestType] = &[ PinMatrixRequestType::PinMatrixRequestType_Current, PinMatrixRequestType::PinMatrixRequestType_NewFirst, @@ -1162,8 +1220,8 @@ pub mod pin_matrix_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.PinMatrixAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PinMatrixAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.PinMatrixAck.pin) @@ -1323,8 +1381,8 @@ impl ::protobuf::reflect::ProtobufValue for PinMatrixAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.PassphraseRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PassphraseRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.PassphraseRequest._on_device) @@ -1464,8 +1522,8 @@ impl ::protobuf::reflect::ProtobufValue for PassphraseRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.PassphraseAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PassphraseAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.PassphraseAck.passphrase) @@ -1713,8 +1771,8 @@ impl ::protobuf::reflect::ProtobufValue for PassphraseAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.Deprecated_PassphraseStateRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Deprecated_PassphraseStateRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.Deprecated_PassphraseStateRequest.state) @@ -1871,8 +1929,8 @@ impl ::protobuf::reflect::ProtobufValue for Deprecated_PassphraseStateRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.Deprecated_PassphraseStateAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Deprecated_PassphraseStateAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.common.Deprecated_PassphraseStateAck.special_fields) @@ -1974,8 +2032,8 @@ impl ::protobuf::reflect::ProtobufValue for Deprecated_PassphraseStateAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.common.HDNodeType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct HDNodeType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.common.HDNodeType.depth) diff --git a/rust/trezor-client/src/protos/generated/messages_crypto.rs b/rust/trezor-client/src/protos/generated/messages_crypto.rs index 3f6b64436..4f4b248a1 100644 --- a/rust/trezor-client/src/protos/generated/messages_crypto.rs +++ b/rust/trezor-client/src/protos/generated/messages_crypto.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.CipherKeyValue) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CipherKeyValue { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.CipherKeyValue.address_n) @@ -429,8 +429,8 @@ impl ::protobuf::reflect::ProtobufValue for CipherKeyValue { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.CipheredKeyValue) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CipheredKeyValue { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.CipheredKeyValue.value) @@ -590,8 +590,8 @@ impl ::protobuf::reflect::ProtobufValue for CipheredKeyValue { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.IdentityType) +#[derive(PartialEq,Clone,Default,Debug)] pub struct IdentityType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.IdentityType.proto) @@ -1001,8 +1001,8 @@ impl ::protobuf::reflect::ProtobufValue for IdentityType { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.SignIdentity) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SignIdentity { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.SignIdentity.identity) @@ -1294,8 +1294,8 @@ impl ::protobuf::reflect::ProtobufValue for SignIdentity { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.SignedIdentity) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SignedIdentity { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.SignedIdentity.address) @@ -1566,8 +1566,8 @@ impl ::protobuf::reflect::ProtobufValue for SignedIdentity { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.GetECDHSessionKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetECDHSessionKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.GetECDHSessionKey.identity) @@ -1808,8 +1808,8 @@ impl ::protobuf::reflect::ProtobufValue for GetECDHSessionKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.ECDHSessionKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ECDHSessionKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.ECDHSessionKey.session_key) @@ -2023,8 +2023,8 @@ impl ::protobuf::reflect::ProtobufValue for ECDHSessionKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.CosiCommit) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CosiCommit { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.CosiCommit.address_n) @@ -2202,8 +2202,8 @@ impl ::protobuf::reflect::ProtobufValue for CosiCommit { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.CosiCommitment) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CosiCommitment { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.CosiCommitment.commitment) @@ -2420,8 +2420,8 @@ impl ::protobuf::reflect::ProtobufValue for CosiCommitment { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.CosiSign) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CosiSign { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.CosiSign.address_n) @@ -2716,8 +2716,8 @@ impl ::protobuf::reflect::ProtobufValue for CosiSign { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.crypto.CosiSignature) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CosiSignature { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.crypto.CosiSignature.signature) diff --git a/rust/trezor-client/src/protos/generated/messages_debug.rs b/rust/trezor-client/src/protos/generated/messages_debug.rs index 1052ca014..b787aeb03 100644 --- a/rust/trezor-client/src/protos/generated/messages_debug.rs +++ b/rust/trezor-client/src/protos/generated/messages_debug.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkDecision) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkDecision { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkDecision.button) @@ -483,6 +483,16 @@ pub mod debug_link_decision { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "UP" => ::std::option::Option::Some(DebugSwipeDirection::UP), + "DOWN" => ::std::option::Option::Some(DebugSwipeDirection::DOWN), + "LEFT" => ::std::option::Option::Some(DebugSwipeDirection::LEFT), + "RIGHT" => ::std::option::Option::Some(DebugSwipeDirection::RIGHT), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [DebugSwipeDirection] = &[ DebugSwipeDirection::UP, DebugSwipeDirection::DOWN, @@ -542,6 +552,15 @@ pub mod debug_link_decision { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "NO" => ::std::option::Option::Some(DebugButton::NO), + "YES" => ::std::option::Option::Some(DebugButton::YES), + "INFO" => ::std::option::Option::Some(DebugButton::INFO), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [DebugButton] = &[ DebugButton::NO, DebugButton::YES, @@ -600,6 +619,15 @@ pub mod debug_link_decision { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "LEFT_BTN" => ::std::option::Option::Some(DebugPhysicalButton::LEFT_BTN), + "MIDDLE_BTN" => ::std::option::Option::Some(DebugPhysicalButton::MIDDLE_BTN), + "RIGHT_BTN" => ::std::option::Option::Some(DebugPhysicalButton::RIGHT_BTN), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [DebugPhysicalButton] = &[ DebugPhysicalButton::LEFT_BTN, DebugPhysicalButton::MIDDLE_BTN, @@ -632,8 +660,8 @@ pub mod debug_link_decision { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkLayout) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkLayout { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkLayout.tokens) @@ -754,8 +782,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkLayout { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkReseedRandom) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkReseedRandom { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkReseedRandom.value) @@ -895,8 +923,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkReseedRandom { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkRecordScreen) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkRecordScreen { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkRecordScreen.target_directory) @@ -1090,8 +1118,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkRecordScreen { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkGetState) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkGetState { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkGetState.wait_word_list) @@ -1305,8 +1333,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkGetState { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkState) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkState { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkState.layout) @@ -1980,8 +2008,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkState { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkStop) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkStop { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.debug.DebugLinkStop.special_fields) @@ -2083,8 +2111,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkStop { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkLog) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkLog { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkLog.level) @@ -2332,8 +2360,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkLog { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkMemoryRead) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkMemoryRead { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkMemoryRead.address) @@ -2510,8 +2538,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkMemoryRead { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkMemory) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkMemory { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkMemory.memory) @@ -2668,8 +2696,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkMemory { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkMemoryWrite) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkMemoryWrite { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkMemoryWrite.address) @@ -2900,8 +2928,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkMemoryWrite { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkFlashErase) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkFlashErase { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkFlashErase.sector) @@ -3041,8 +3069,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkFlashErase { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkEraseSdCard) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkEraseSdCard { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkEraseSdCard.format) @@ -3182,8 +3210,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkEraseSdCard { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkWatchLayout) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkWatchLayout { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.debug.DebugLinkWatchLayout.watch) @@ -3323,8 +3351,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugLinkWatchLayout { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.debug.DebugLinkResetDebugEvents) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugLinkResetDebugEvents { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.debug.DebugLinkResetDebugEvents.special_fields) diff --git a/rust/trezor-client/src/protos/generated/messages_eos.rs b/rust/trezor-client/src/protos/generated/messages_eos.rs index be9a3c8d8..af40f217d 100644 --- a/rust/trezor-client/src/protos/generated/messages_eos.rs +++ b/rust/trezor-client/src/protos/generated/messages_eos.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosGetPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EosGetPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosGetPublicKey.address_n) @@ -224,8 +224,8 @@ impl ::protobuf::reflect::ProtobufValue for EosGetPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EosPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosPublicKey.wif_public_key) @@ -442,8 +442,8 @@ impl ::protobuf::reflect::ProtobufValue for EosPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EosSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosSignTx.address_n) @@ -730,8 +730,8 @@ impl ::protobuf::reflect::ProtobufValue for EosSignTx { /// Nested message and enums of message `EosSignTx` pub mod eos_sign_tx { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosSignTx.EosTxHeader) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosTxHeader { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosSignTx.EosTxHeader.expiration) @@ -1075,8 +1075,8 @@ pub mod eos_sign_tx { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EosTxActionRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionRequest.data_size) @@ -1216,8 +1216,8 @@ impl ::protobuf::reflect::ProtobufValue for EosTxActionRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EosTxActionAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.common) @@ -1685,8 +1685,8 @@ impl ::protobuf::reflect::ProtobufValue for EosTxActionAck { /// Nested message and enums of message `EosTxActionAck` pub mod eos_tx_action_ack { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosAsset) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosAsset { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosAsset.amount) @@ -1869,8 +1869,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosPermissionLevel) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosPermissionLevel { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosPermissionLevel.actor) @@ -2053,8 +2053,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosAuthorizationKey) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosAuthorizationKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosAuthorizationKey.type) @@ -2312,8 +2312,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosAuthorizationAccount) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosAuthorizationAccount { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosAuthorizationAccount.account) @@ -2483,8 +2483,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosAuthorizationWait) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosAuthorizationWait { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosAuthorizationWait.wait_sec) @@ -2667,8 +2667,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosAuthorization) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosAuthorization { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosAuthorization.threshold) @@ -2883,8 +2883,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionCommon) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionCommon { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionCommon.account) @@ -3091,8 +3091,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionTransfer) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionTransfer { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionTransfer.sender) @@ -3359,8 +3359,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionDelegate) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionDelegate { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionDelegate.sender) @@ -3637,8 +3637,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionUndelegate) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionUndelegate { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionUndelegate.sender) @@ -3875,8 +3875,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionRefund) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionRefund { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionRefund.owner) @@ -4019,8 +4019,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionBuyRam) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionBuyRam { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionBuyRam.payer) @@ -4230,8 +4230,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionBuyRamBytes) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionBuyRamBytes { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionBuyRamBytes.payer) @@ -4454,8 +4454,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionSellRam) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionSellRam { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionSellRam.account) @@ -4638,8 +4638,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionVoteProducer) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionVoteProducer { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionVoteProducer.voter) @@ -4843,8 +4843,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionUpdateAuth) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionUpdateAuth { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionUpdateAuth.account) @@ -5094,8 +5094,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionDeleteAuth) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionDeleteAuth { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionDeleteAuth.account) @@ -5278,8 +5278,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionLinkAuth) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionLinkAuth { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionLinkAuth.account) @@ -5542,8 +5542,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionUnlinkAuth) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionUnlinkAuth { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionUnlinkAuth.account) @@ -5766,8 +5766,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionNewAccount) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionNewAccount { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionNewAccount.creator) @@ -6004,8 +6004,8 @@ pub mod eos_tx_action_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosTxActionAck.EosActionUnknown) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EosActionUnknown { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosTxActionAck.EosActionUnknown.data_size) @@ -6206,8 +6206,8 @@ pub mod eos_tx_action_ack { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.eos.EosSignedTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EosSignedTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.eos.EosSignedTx.signature) diff --git a/rust/trezor-client/src/protos/generated/messages_ethereum.rs b/rust/trezor-client/src/protos/generated/messages_ethereum.rs index 52362cca1..98650c831 100644 --- a/rust/trezor-client/src/protos/generated/messages_ethereum.rs +++ b/rust/trezor-client/src/protos/generated/messages_ethereum.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumGetPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumGetPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumGetPublicKey.address_n) @@ -187,8 +187,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumGetPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumPublicKey.node) @@ -375,8 +375,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumGetAddress.address_n) @@ -628,8 +628,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumAddress._old_address) @@ -840,8 +840,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumSignTx.address_n) @@ -1470,8 +1470,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumSignTx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumSignTxEIP1559) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumSignTxEIP1559 { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumSignTxEIP1559.address_n) @@ -2155,8 +2155,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumSignTxEIP1559 { /// Nested message and enums of message `EthereumSignTxEIP1559` pub mod ethereum_sign_tx_eip1559 { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumSignTxEIP1559.EthereumAccessList) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumAccessList { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumSignTxEIP1559.EthereumAccessList.address) @@ -2335,8 +2335,8 @@ pub mod ethereum_sign_tx_eip1559 { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumTxRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTxRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumTxRequest.data_length) @@ -2621,8 +2621,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumTxRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumTxAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTxAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumTxAck.data_chunk) @@ -2782,8 +2782,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumTxAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumSignMessage) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumSignMessage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumSignMessage.address_n) @@ -3055,8 +3055,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumSignMessage { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumMessageSignature) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumMessageSignature { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumMessageSignature.signature) @@ -3273,8 +3273,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumMessageSignature { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumVerifyMessage) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumVerifyMessage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumVerifyMessage.signature) @@ -3585,8 +3585,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumVerifyMessage { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumSignTypedHash) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumSignTypedHash { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumSignTypedHash.address_n) @@ -3875,8 +3875,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumSignTypedHash { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum.EthereumTypedDataSignature) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTypedDataSignature { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum.EthereumTypedDataSignature.signature) diff --git a/rust/trezor-client/src/protos/generated/messages_ethereum_definitions.rs b/rust/trezor-client/src/protos/generated/messages_ethereum_definitions.rs index 187527249..f2ee22698 100644 --- a/rust/trezor-client/src/protos/generated/messages_ethereum_definitions.rs +++ b/rust/trezor-client/src/protos/generated/messages_ethereum_definitions.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_definitions.EthereumNetworkInfo) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumNetworkInfo { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_definitions.EthereumNetworkInfo.chain_id) @@ -323,8 +323,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumNetworkInfo { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_definitions.EthereumTokenInfo) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTokenInfo { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_definitions.EthereumTokenInfo.address) @@ -678,8 +678,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumTokenInfo { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_definitions.EthereumDefinitions) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumDefinitions { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_definitions.EthereumDefinitions.encoded_network) @@ -914,6 +914,14 @@ impl ::protobuf::Enum for EthereumDefinitionType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "NETWORK" => ::std::option::Option::Some(EthereumDefinitionType::NETWORK), + "TOKEN" => ::std::option::Option::Some(EthereumDefinitionType::TOKEN), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [EthereumDefinitionType] = &[ EthereumDefinitionType::NETWORK, EthereumDefinitionType::TOKEN, diff --git a/rust/trezor-client/src/protos/generated/messages_ethereum_eip712.rs b/rust/trezor-client/src/protos/generated/messages_ethereum_eip712.rs index 36fccfcad..84cde85c8 100644 --- a/rust/trezor-client/src/protos/generated/messages_ethereum_eip712.rs +++ b/rust/trezor-client/src/protos/generated/messages_ethereum_eip712.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumSignTypedData) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumSignTypedData { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumSignTypedData.address_n) @@ -268,8 +268,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumSignTypedData { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTypedDataStructRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructRequest.name) @@ -429,8 +429,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumTypedDataStructRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTypedDataStructAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructAck.members) @@ -559,8 +559,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumTypedDataStructAck { /// Nested message and enums of message `EthereumTypedDataStructAck` pub mod ethereum_typed_data_struct_ack { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructAck.EthereumStructMember) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumStructMember { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructAck.EthereumStructMember.type) @@ -747,8 +747,8 @@ pub mod ethereum_typed_data_struct_ack { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructAck.EthereumFieldType) + #[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumFieldType { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumTypedDataStructAck.EthereumFieldType.data_type) @@ -1051,6 +1051,20 @@ pub mod ethereum_typed_data_struct_ack { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "UINT" => ::std::option::Option::Some(EthereumDataType::UINT), + "INT" => ::std::option::Option::Some(EthereumDataType::INT), + "BYTES" => ::std::option::Option::Some(EthereumDataType::BYTES), + "STRING" => ::std::option::Option::Some(EthereumDataType::STRING), + "BOOL" => ::std::option::Option::Some(EthereumDataType::BOOL), + "ADDRESS" => ::std::option::Option::Some(EthereumDataType::ADDRESS), + "ARRAY" => ::std::option::Option::Some(EthereumDataType::ARRAY), + "STRUCT" => ::std::option::Option::Some(EthereumDataType::STRUCT), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [EthereumDataType] = &[ EthereumDataType::UINT, EthereumDataType::INT, @@ -1098,8 +1112,8 @@ pub mod ethereum_typed_data_struct_ack { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumTypedDataValueRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTypedDataValueRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumTypedDataValueRequest.member_path) @@ -1223,8 +1237,8 @@ impl ::protobuf::reflect::ProtobufValue for EthereumTypedDataValueRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ethereum_eip712.EthereumTypedDataValueAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EthereumTypedDataValueAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ethereum_eip712.EthereumTypedDataValueAck.value) diff --git a/rust/trezor-client/src/protos/generated/messages_management.rs b/rust/trezor-client/src/protos/generated/messages_management.rs index 0f57bfbb9..10bc8933a 100644 --- a/rust/trezor-client/src/protos/generated/messages_management.rs +++ b/rust/trezor-client/src/protos/generated/messages_management.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.Initialize) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Initialize { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.Initialize.session_id) @@ -257,8 +257,8 @@ impl ::protobuf::reflect::ProtobufValue for Initialize { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.GetFeatures) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetFeatures { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.GetFeatures.special_fields) @@ -360,8 +360,8 @@ impl ::protobuf::reflect::ProtobufValue for GetFeatures { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.Features) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Features { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.Features.vendor) @@ -2446,6 +2446,29 @@ pub mod features { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Capability_Bitcoin" => ::std::option::Option::Some(Capability::Capability_Bitcoin), + "Capability_Bitcoin_like" => ::std::option::Option::Some(Capability::Capability_Bitcoin_like), + "Capability_Binance" => ::std::option::Option::Some(Capability::Capability_Binance), + "Capability_Cardano" => ::std::option::Option::Some(Capability::Capability_Cardano), + "Capability_Crypto" => ::std::option::Option::Some(Capability::Capability_Crypto), + "Capability_EOS" => ::std::option::Option::Some(Capability::Capability_EOS), + "Capability_Ethereum" => ::std::option::Option::Some(Capability::Capability_Ethereum), + "Capability_Lisk" => ::std::option::Option::Some(Capability::Capability_Lisk), + "Capability_Monero" => ::std::option::Option::Some(Capability::Capability_Monero), + "Capability_NEM" => ::std::option::Option::Some(Capability::Capability_NEM), + "Capability_Ripple" => ::std::option::Option::Some(Capability::Capability_Ripple), + "Capability_Stellar" => ::std::option::Option::Some(Capability::Capability_Stellar), + "Capability_Tezos" => ::std::option::Option::Some(Capability::Capability_Tezos), + "Capability_U2F" => ::std::option::Option::Some(Capability::Capability_U2F), + "Capability_Shamir" => ::std::option::Option::Some(Capability::Capability_Shamir), + "Capability_ShamirGroups" => ::std::option::Option::Some(Capability::Capability_ShamirGroups), + "Capability_PassphraseEntry" => ::std::option::Option::Some(Capability::Capability_PassphraseEntry), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [Capability] = &[ Capability::Capability_Bitcoin, Capability::Capability_Bitcoin_like, @@ -2511,8 +2534,8 @@ pub mod features { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.LockDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct LockDevice { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.LockDevice.special_fields) @@ -2614,8 +2637,8 @@ impl ::protobuf::reflect::ProtobufValue for LockDevice { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.SetBusy) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SetBusy { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.SetBusy.expiry_ms) @@ -2755,8 +2778,8 @@ impl ::protobuf::reflect::ProtobufValue for SetBusy { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.EndSession) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EndSession { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.EndSession.special_fields) @@ -2858,8 +2881,8 @@ impl ::protobuf::reflect::ProtobufValue for EndSession { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.ApplySettings) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ApplySettings { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.ApplySettings.language) @@ -3423,8 +3446,8 @@ impl ::protobuf::reflect::ProtobufValue for ApplySettings { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.ApplyFlags) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ApplyFlags { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.ApplyFlags.flags) @@ -3567,8 +3590,8 @@ impl ::protobuf::reflect::ProtobufValue for ApplyFlags { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.ChangePin) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ChangePin { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.ChangePin.remove) @@ -3708,8 +3731,8 @@ impl ::protobuf::reflect::ProtobufValue for ChangePin { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.ChangeWipeCode) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ChangeWipeCode { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.ChangeWipeCode.remove) @@ -3849,8 +3872,8 @@ impl ::protobuf::reflect::ProtobufValue for ChangeWipeCode { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.SdProtect) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SdProtect { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.SdProtect.operation) @@ -4025,6 +4048,15 @@ pub mod sd_protect { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "DISABLE" => ::std::option::Option::Some(SdProtectOperationType::DISABLE), + "ENABLE" => ::std::option::Option::Some(SdProtectOperationType::ENABLE), + "REFRESH" => ::std::option::Option::Some(SdProtectOperationType::REFRESH), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [SdProtectOperationType] = &[ SdProtectOperationType::DISABLE, SdProtectOperationType::ENABLE, @@ -4057,8 +4089,8 @@ pub mod sd_protect { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.Ping) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Ping { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.Ping.message) @@ -4252,8 +4284,8 @@ impl ::protobuf::reflect::ProtobufValue for Ping { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.Cancel) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Cancel { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.Cancel.special_fields) @@ -4355,8 +4387,8 @@ impl ::protobuf::reflect::ProtobufValue for Cancel { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.GetEntropy) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetEntropy { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.GetEntropy.size) @@ -4499,8 +4531,8 @@ impl ::protobuf::reflect::ProtobufValue for GetEntropy { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.Entropy) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Entropy { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.Entropy.entropy) @@ -4660,8 +4692,8 @@ impl ::protobuf::reflect::ProtobufValue for Entropy { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.GetFirmwareHash) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetFirmwareHash { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.GetFirmwareHash.challenge) @@ -4818,8 +4850,8 @@ impl ::protobuf::reflect::ProtobufValue for GetFirmwareHash { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.FirmwareHash) +#[derive(PartialEq,Clone,Default,Debug)] pub struct FirmwareHash { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.FirmwareHash.hash) @@ -4979,8 +5011,8 @@ impl ::protobuf::reflect::ProtobufValue for FirmwareHash { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.AuthenticateDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct AuthenticateDevice { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.AuthenticateDevice.challenge) @@ -5140,8 +5172,8 @@ impl ::protobuf::reflect::ProtobufValue for AuthenticateDevice { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.AuthenticityProof) +#[derive(PartialEq,Clone,Default,Debug)] pub struct AuthenticityProof { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.AuthenticityProof.certificates) @@ -5319,8 +5351,8 @@ impl ::protobuf::reflect::ProtobufValue for AuthenticityProof { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.WipeDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WipeDevice { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.WipeDevice.special_fields) @@ -5422,8 +5454,8 @@ impl ::protobuf::reflect::ProtobufValue for WipeDevice { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.LoadDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct LoadDevice { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.LoadDevice.mnemonics) @@ -5891,8 +5923,8 @@ impl ::protobuf::reflect::ProtobufValue for LoadDevice { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.ResetDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ResetDevice { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.ResetDevice.display_random) @@ -6402,8 +6434,8 @@ impl ::protobuf::reflect::ProtobufValue for ResetDevice { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.BackupDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct BackupDevice { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.BackupDevice.special_fields) @@ -6505,8 +6537,8 @@ impl ::protobuf::reflect::ProtobufValue for BackupDevice { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.EntropyRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EntropyRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.EntropyRequest.special_fields) @@ -6608,8 +6640,8 @@ impl ::protobuf::reflect::ProtobufValue for EntropyRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.EntropyAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct EntropyAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.EntropyAck.entropy) @@ -6769,8 +6801,8 @@ impl ::protobuf::reflect::ProtobufValue for EntropyAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.RecoveryDevice) +#[derive(PartialEq,Clone,Default,Debug)] pub struct RecoveryDevice { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.RecoveryDevice.word_count) @@ -7269,6 +7301,14 @@ pub mod recovery_device { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "RecoveryDeviceType_ScrambledWords" => ::std::option::Option::Some(RecoveryDeviceType::RecoveryDeviceType_ScrambledWords), + "RecoveryDeviceType_Matrix" => ::std::option::Option::Some(RecoveryDeviceType::RecoveryDeviceType_Matrix), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [RecoveryDeviceType] = &[ RecoveryDeviceType::RecoveryDeviceType_ScrambledWords, RecoveryDeviceType::RecoveryDeviceType_Matrix, @@ -7300,8 +7340,8 @@ pub mod recovery_device { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.WordRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WordRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.WordRequest.type) @@ -7476,6 +7516,15 @@ pub mod word_request { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "WordRequestType_Plain" => ::std::option::Option::Some(WordRequestType::WordRequestType_Plain), + "WordRequestType_Matrix9" => ::std::option::Option::Some(WordRequestType::WordRequestType_Matrix9), + "WordRequestType_Matrix6" => ::std::option::Option::Some(WordRequestType::WordRequestType_Matrix6), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [WordRequestType] = &[ WordRequestType::WordRequestType_Plain, WordRequestType::WordRequestType_Matrix9, @@ -7508,8 +7557,8 @@ pub mod word_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.WordAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WordAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.WordAck.word) @@ -7669,8 +7718,8 @@ impl ::protobuf::reflect::ProtobufValue for WordAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.SetU2FCounter) +#[derive(PartialEq,Clone,Default,Debug)] pub struct SetU2FCounter { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.SetU2FCounter.u2f_counter) @@ -7813,8 +7862,8 @@ impl ::protobuf::reflect::ProtobufValue for SetU2FCounter { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.GetNextU2FCounter) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetNextU2FCounter { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.GetNextU2FCounter.special_fields) @@ -7916,8 +7965,8 @@ impl ::protobuf::reflect::ProtobufValue for GetNextU2FCounter { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.NextU2FCounter) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NextU2FCounter { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.NextU2FCounter.u2f_counter) @@ -8060,8 +8109,8 @@ impl ::protobuf::reflect::ProtobufValue for NextU2FCounter { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.DoPreauthorized) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DoPreauthorized { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.DoPreauthorized.special_fields) @@ -8163,8 +8212,8 @@ impl ::protobuf::reflect::ProtobufValue for DoPreauthorized { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.PreauthorizedRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct PreauthorizedRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.PreauthorizedRequest.special_fields) @@ -8266,8 +8315,8 @@ impl ::protobuf::reflect::ProtobufValue for PreauthorizedRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.CancelAuthorization) +#[derive(PartialEq,Clone,Default,Debug)] pub struct CancelAuthorization { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.CancelAuthorization.special_fields) @@ -8369,8 +8418,8 @@ impl ::protobuf::reflect::ProtobufValue for CancelAuthorization { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.RebootToBootloader) +#[derive(PartialEq,Clone,Default,Debug)] pub struct RebootToBootloader { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.RebootToBootloader.boot_command) @@ -8593,6 +8642,14 @@ pub mod reboot_to_bootloader { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "STOP_AND_WAIT" => ::std::option::Option::Some(BootCommand::STOP_AND_WAIT), + "INSTALL_UPGRADE" => ::std::option::Option::Some(BootCommand::INSTALL_UPGRADE), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [BootCommand] = &[ BootCommand::STOP_AND_WAIT, BootCommand::INSTALL_UPGRADE, @@ -8624,8 +8681,8 @@ pub mod reboot_to_bootloader { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.GetNonce) +#[derive(PartialEq,Clone,Default,Debug)] pub struct GetNonce { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.GetNonce.special_fields) @@ -8727,8 +8784,8 @@ impl ::protobuf::reflect::ProtobufValue for GetNonce { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.Nonce) +#[derive(PartialEq,Clone,Default,Debug)] pub struct Nonce { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.Nonce.nonce) @@ -8888,8 +8945,8 @@ impl ::protobuf::reflect::ProtobufValue for Nonce { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.UnlockPath) +#[derive(PartialEq,Clone,Default,Debug)] pub struct UnlockPath { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.UnlockPath.address_n) @@ -9067,8 +9124,8 @@ impl ::protobuf::reflect::ProtobufValue for UnlockPath { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.UnlockedPathRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct UnlockedPathRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.management.UnlockedPathRequest.mac) @@ -9225,8 +9282,8 @@ impl ::protobuf::reflect::ProtobufValue for UnlockedPathRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.ShowDeviceTutorial) +#[derive(PartialEq,Clone,Default,Debug)] pub struct ShowDeviceTutorial { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.ShowDeviceTutorial.special_fields) @@ -9328,8 +9385,8 @@ impl ::protobuf::reflect::ProtobufValue for ShowDeviceTutorial { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.management.UnlockBootloader) +#[derive(PartialEq,Clone,Default,Debug)] pub struct UnlockBootloader { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.management.UnlockBootloader.special_fields) @@ -9458,6 +9515,15 @@ impl ::protobuf::Enum for BackupType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Bip39" => ::std::option::Option::Some(BackupType::Bip39), + "Slip39_Basic" => ::std::option::Option::Some(BackupType::Slip39_Basic), + "Slip39_Advanced" => ::std::option::Option::Some(BackupType::Slip39_Advanced), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [BackupType] = &[ BackupType::Bip39, BackupType::Slip39_Basic, @@ -9516,6 +9582,15 @@ impl ::protobuf::Enum for SafetyCheckLevel { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Strict" => ::std::option::Option::Some(SafetyCheckLevel::Strict), + "PromptAlways" => ::std::option::Option::Some(SafetyCheckLevel::PromptAlways), + "PromptTemporarily" => ::std::option::Option::Some(SafetyCheckLevel::PromptTemporarily), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [SafetyCheckLevel] = &[ SafetyCheckLevel::Strict, SafetyCheckLevel::PromptAlways, @@ -9574,6 +9649,15 @@ impl ::protobuf::Enum for HomescreenFormat { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Toif" => ::std::option::Option::Some(HomescreenFormat::Toif), + "Jpeg" => ::std::option::Option::Some(HomescreenFormat::Jpeg), + "ToiG" => ::std::option::Option::Some(HomescreenFormat::ToiG), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [HomescreenFormat] = &[ HomescreenFormat::Toif, HomescreenFormat::Jpeg, diff --git a/rust/trezor-client/src/protos/generated/messages_monero.rs b/rust/trezor-client/src/protos/generated/messages_monero.rs index 9a658f73a..daf182a14 100644 --- a/rust/trezor-client/src/protos/generated/messages_monero.rs +++ b/rust/trezor-client/src/protos/generated/messages_monero.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSourceEntry) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSourceEntry { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSourceEntry.outputs) @@ -490,8 +490,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSourceEntry { /// Nested message and enums of message `MoneroTransactionSourceEntry` pub mod monero_transaction_source_entry { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSourceEntry.MoneroOutputEntry) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroOutputEntry { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSourceEntry.MoneroOutputEntry.idx) @@ -657,8 +657,8 @@ pub mod monero_transaction_source_entry { /// Nested message and enums of message `MoneroOutputEntry` pub mod monero_output_entry { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSourceEntry.MoneroOutputEntry.MoneroRctKeyPublic) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroRctKeyPublic { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSourceEntry.MoneroOutputEntry.MoneroRctKeyPublic.dest) @@ -876,8 +876,8 @@ pub mod monero_transaction_source_entry { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSourceEntry.MoneroMultisigKLRki) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroMultisigKLRki { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSourceEntry.MoneroMultisigKLRki.K) @@ -1197,8 +1197,8 @@ pub mod monero_transaction_source_entry { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionDestinationEntry) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionDestinationEntry { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionDestinationEntry.amount) @@ -1487,8 +1487,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionDestinationEntry { /// Nested message and enums of message `MoneroTransactionDestinationEntry` pub mod monero_transaction_destination_entry { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionDestinationEntry.MoneroAccountPublicAddress) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroAccountPublicAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionDestinationEntry.MoneroAccountPublicAddress.spend_public_key) @@ -1700,8 +1700,8 @@ pub mod monero_transaction_destination_entry { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionRsigData) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionRsigData { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionRsigData.rsig_type) @@ -2062,8 +2062,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionRsigData { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroGetAddress.address_n) @@ -2429,8 +2429,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroAddress.address) @@ -2587,8 +2587,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroGetWatchKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroGetWatchKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroGetWatchKey.address_n) @@ -2752,8 +2752,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroGetWatchKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroWatchKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroWatchKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroWatchKey.watch_key) @@ -2964,8 +2964,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroWatchKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionInitRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionInitRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionInitRequest.version) @@ -3187,8 +3187,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionInitRequest { /// Nested message and enums of message `MoneroTransactionInitRequest` pub mod monero_transaction_init_request { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionInitRequest.MoneroTransactionData) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionData { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionInitRequest.MoneroTransactionData.version) @@ -3832,8 +3832,8 @@ pub mod monero_transaction_init_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionInitAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionInitAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionInitAck.hmacs) @@ -3973,8 +3973,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionInitAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSetInputRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSetInputRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSetInputRequest.src_entr) @@ -4101,8 +4101,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSetInputRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSetInputAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSetInputAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSetInputAck.vini) @@ -4529,8 +4529,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSetInputAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionInputViniRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionInputViniRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionInputViniRequest.src_entr) @@ -4910,8 +4910,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionInputViniRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionInputViniAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionInputViniAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroTransactionInputViniAck.special_fields) @@ -5013,8 +5013,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionInputViniAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionAllInputsSetRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionAllInputsSetRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroTransactionAllInputsSetRequest.special_fields) @@ -5116,8 +5116,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionAllInputsSetRequest type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionAllInputsSetAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionAllInputsSetAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionAllInputsSetAck.rsig_data) @@ -5239,8 +5239,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionAllInputsSetAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSetOutputRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSetOutputRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSetOutputRequest.dst_entr) @@ -5472,8 +5472,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSetOutputRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSetOutputAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSetOutputAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSetOutputAck.tx_out) @@ -5811,8 +5811,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSetOutputAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionAllOutSetRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionAllOutSetRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionAllOutSetRequest.rsig_data) @@ -5934,8 +5934,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionAllOutSetRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionAllOutSetAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionAllOutSetAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionAllOutSetAck.extra) @@ -6221,8 +6221,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionAllOutSetAck { /// Nested message and enums of message `MoneroTransactionAllOutSetAck` pub mod monero_transaction_all_out_set_ack { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionAllOutSetAck.MoneroRingCtSig) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroRingCtSig { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionAllOutSetAck.MoneroRingCtSig.txn_fee) @@ -6454,8 +6454,8 @@ pub mod monero_transaction_all_out_set_ack { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSignInputRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSignInputRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSignInputRequest.src_entr) @@ -6943,8 +6943,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSignInputRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionSignInputAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionSignInputAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionSignInputAck.signature) @@ -7155,8 +7155,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionSignInputAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionFinalRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionFinalRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroTransactionFinalRequest.special_fields) @@ -7258,8 +7258,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionFinalRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroTransactionFinalAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransactionFinalAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroTransactionFinalAck.cout_key) @@ -7632,8 +7632,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroTransactionFinalAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageExportInitRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroKeyImageExportInitRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageExportInitRequest.num) @@ -7920,8 +7920,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroKeyImageExportInitRequest { /// Nested message and enums of message `MoneroKeyImageExportInitRequest` pub mod monero_key_image_export_init_request { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageExportInitRequest.MoneroSubAddressIndicesList) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroSubAddressIndicesList { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageExportInitRequest.MoneroSubAddressIndicesList.account) @@ -8086,8 +8086,8 @@ pub mod monero_key_image_export_init_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageExportInitAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroKeyImageExportInitAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroKeyImageExportInitAck.special_fields) @@ -8189,8 +8189,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroKeyImageExportInitAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageSyncStepRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroKeyImageSyncStepRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageSyncStepRequest.tdis) @@ -8319,8 +8319,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroKeyImageSyncStepRequest { /// Nested message and enums of message `MoneroKeyImageSyncStepRequest` pub mod monero_key_image_sync_step_request { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageSyncStepRequest.MoneroTransferDetails) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroTransferDetails { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageSyncStepRequest.MoneroTransferDetails.out_key) @@ -8670,8 +8670,8 @@ pub mod monero_key_image_sync_step_request { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageSyncStepAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroKeyImageSyncStepAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageSyncStepAck.kis) @@ -8795,8 +8795,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroKeyImageSyncStepAck { /// Nested message and enums of message `MoneroKeyImageSyncStepAck` pub mod monero_key_image_sync_step_ack { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageSyncStepAck.MoneroExportedKeyImage) + #[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroExportedKeyImage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageSyncStepAck.MoneroExportedKeyImage.iv) @@ -9008,8 +9008,8 @@ pub mod monero_key_image_sync_step_ack { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageSyncFinalRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroKeyImageSyncFinalRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroKeyImageSyncFinalRequest.special_fields) @@ -9111,8 +9111,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroKeyImageSyncFinalRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroKeyImageSyncFinalAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroKeyImageSyncFinalAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroKeyImageSyncFinalAck.enc_key) @@ -9269,8 +9269,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroKeyImageSyncFinalAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroGetTxKeyRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroGetTxKeyRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroGetTxKeyRequest.address_n) @@ -9753,8 +9753,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroGetTxKeyRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroGetTxKeyAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroGetTxKeyAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroGetTxKeyAck.salt) @@ -10019,8 +10019,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroGetTxKeyAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroLiveRefreshStartRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroLiveRefreshStartRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroLiveRefreshStartRequest.address_n) @@ -10184,8 +10184,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroLiveRefreshStartRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroLiveRefreshStartAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroLiveRefreshStartAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroLiveRefreshStartAck.special_fields) @@ -10287,8 +10287,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroLiveRefreshStartAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroLiveRefreshStepRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroLiveRefreshStepRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroLiveRefreshStepRequest.out_key) @@ -10625,8 +10625,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroLiveRefreshStepRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroLiveRefreshStepAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroLiveRefreshStepAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.MoneroLiveRefreshStepAck.salt) @@ -10837,8 +10837,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroLiveRefreshStepAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroLiveRefreshFinalRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroLiveRefreshFinalRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroLiveRefreshFinalRequest.special_fields) @@ -10940,8 +10940,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroLiveRefreshFinalRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.MoneroLiveRefreshFinalAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct MoneroLiveRefreshFinalAck { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.monero.MoneroLiveRefreshFinalAck.special_fields) @@ -11043,8 +11043,8 @@ impl ::protobuf::reflect::ProtobufValue for MoneroLiveRefreshFinalAck { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.DebugMoneroDiagRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugMoneroDiagRequest { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.DebugMoneroDiagRequest.ins) @@ -11387,8 +11387,8 @@ impl ::protobuf::reflect::ProtobufValue for DebugMoneroDiagRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.monero.DebugMoneroDiagAck) +#[derive(PartialEq,Clone,Default,Debug)] pub struct DebugMoneroDiagAck { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.monero.DebugMoneroDiagAck.ins) @@ -11761,6 +11761,16 @@ impl ::protobuf::Enum for MoneroNetworkType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "MAINNET" => ::std::option::Option::Some(MoneroNetworkType::MAINNET), + "TESTNET" => ::std::option::Option::Some(MoneroNetworkType::TESTNET), + "STAGENET" => ::std::option::Option::Some(MoneroNetworkType::STAGENET), + "FAKECHAIN" => ::std::option::Option::Some(MoneroNetworkType::FAKECHAIN), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [MoneroNetworkType] = &[ MoneroNetworkType::MAINNET, MoneroNetworkType::TESTNET, diff --git a/rust/trezor-client/src/protos/generated/messages_nem.rs b/rust/trezor-client/src/protos/generated/messages_nem.rs index 11ce87a5d..799e3468b 100644 --- a/rust/trezor-client/src/protos/generated/messages_nem.rs +++ b/rust/trezor-client/src/protos/generated/messages_nem.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NEMGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMGetAddress.address_n) @@ -261,8 +261,8 @@ impl ::protobuf::reflect::ProtobufValue for NEMGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NEMAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMAddress.address) @@ -422,8 +422,8 @@ impl ::protobuf::reflect::ProtobufValue for NEMAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NEMSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.transaction) @@ -797,8 +797,8 @@ impl ::protobuf::reflect::ProtobufValue for NEMSignTx { /// Nested message and enums of message `NEMSignTx` pub mod nemsign_tx { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMTransactionCommon) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMTransactionCommon { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMTransactionCommon.address_n) @@ -1133,8 +1133,8 @@ pub mod nemsign_tx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMTransfer) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMTransfer { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMTransfer.recipient) @@ -1468,8 +1468,8 @@ pub mod nemsign_tx { /// Nested message and enums of message `NEMTransfer` pub mod nemtransfer { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMTransfer.NEMMosaic) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMMosaic { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMTransfer.NEMMosaic.namespace) @@ -1727,8 +1727,8 @@ pub mod nemsign_tx { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMProvisionNamespace) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMProvisionNamespace { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMProvisionNamespace.namespace) @@ -2039,8 +2039,8 @@ pub mod nemsign_tx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMMosaicCreation) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMMosaicCreation { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMMosaicCreation.definition) @@ -2269,8 +2269,8 @@ pub mod nemsign_tx { /// Nested message and enums of message `NEMMosaicCreation` pub mod nemmosaic_creation { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMMosaicCreation.NEMMosaicDefinition) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMMosaicDefinition { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMMosaicCreation.NEMMosaicDefinition.name) @@ -3086,6 +3086,14 @@ pub mod nemsign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "MosaicLevy_Absolute" => ::std::option::Option::Some(NEMMosaicLevy::MosaicLevy_Absolute), + "MosaicLevy_Percentile" => ::std::option::Option::Some(NEMMosaicLevy::MosaicLevy_Percentile), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [NEMMosaicLevy] = &[ NEMMosaicLevy::MosaicLevy_Absolute, NEMMosaicLevy::MosaicLevy_Percentile, @@ -3122,8 +3130,8 @@ pub mod nemsign_tx { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMMosaicSupplyChange) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMMosaicSupplyChange { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMMosaicSupplyChange.namespace) @@ -3449,6 +3457,14 @@ pub mod nemsign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "SupplyChange_Increase" => ::std::option::Option::Some(NEMSupplyChangeType::SupplyChange_Increase), + "SupplyChange_Decrease" => ::std::option::Option::Some(NEMSupplyChangeType::SupplyChange_Decrease), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [NEMSupplyChangeType] = &[ NEMSupplyChangeType::SupplyChange_Increase, NEMSupplyChangeType::SupplyChange_Decrease, @@ -3484,8 +3500,8 @@ pub mod nemsign_tx { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMAggregateModification) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMAggregateModification { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMAggregateModification.modifications) @@ -3651,8 +3667,8 @@ pub mod nemsign_tx { /// Nested message and enums of message `NEMAggregateModification` pub mod nemaggregate_modification { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMAggregateModification.NEMCosignatoryModification) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMCosignatoryModification { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMAggregateModification.NEMCosignatoryModification.type) @@ -3881,6 +3897,14 @@ pub mod nemsign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "CosignatoryModification_Add" => ::std::option::Option::Some(NEMModificationType::CosignatoryModification_Add), + "CosignatoryModification_Delete" => ::std::option::Option::Some(NEMModificationType::CosignatoryModification_Delete), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [NEMModificationType] = &[ NEMModificationType::CosignatoryModification_Add, NEMModificationType::CosignatoryModification_Delete, @@ -3917,8 +3941,8 @@ pub mod nemsign_tx { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignTx.NEMImportanceTransfer) + #[derive(PartialEq,Clone,Default,Debug)] pub struct NEMImportanceTransfer { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignTx.NEMImportanceTransfer.mode) @@ -4147,6 +4171,14 @@ pub mod nemsign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "ImportanceTransfer_Activate" => ::std::option::Option::Some(NEMImportanceTransferMode::ImportanceTransfer_Activate), + "ImportanceTransfer_Deactivate" => ::std::option::Option::Some(NEMImportanceTransferMode::ImportanceTransfer_Deactivate), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [NEMImportanceTransferMode] = &[ NEMImportanceTransferMode::ImportanceTransfer_Activate, NEMImportanceTransferMode::ImportanceTransfer_Deactivate, @@ -4183,8 +4215,8 @@ pub mod nemsign_tx { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMSignedTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NEMSignedTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMSignedTx.data) @@ -4401,8 +4433,8 @@ impl ::protobuf::reflect::ProtobufValue for NEMSignedTx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMDecryptMessage) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NEMDecryptMessage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMDecryptMessage.address_n) @@ -4671,8 +4703,8 @@ impl ::protobuf::reflect::ProtobufValue for NEMDecryptMessage { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.nem.NEMDecryptedMessage) +#[derive(PartialEq,Clone,Default,Debug)] pub struct NEMDecryptedMessage { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.nem.NEMDecryptedMessage.payload) diff --git a/rust/trezor-client/src/protos/generated/messages_ripple.rs b/rust/trezor-client/src/protos/generated/messages_ripple.rs index 106510bee..94497219e 100644 --- a/rust/trezor-client/src/protos/generated/messages_ripple.rs +++ b/rust/trezor-client/src/protos/generated/messages_ripple.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ripple.RippleGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct RippleGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ripple.RippleGetAddress.address_n) @@ -224,8 +224,8 @@ impl ::protobuf::reflect::ProtobufValue for RippleGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ripple.RippleAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct RippleAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ripple.RippleAddress.address) @@ -385,8 +385,8 @@ impl ::protobuf::reflect::ProtobufValue for RippleAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ripple.RippleSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct RippleSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ripple.RippleSignTx.address_n) @@ -730,8 +730,8 @@ impl ::protobuf::reflect::ProtobufValue for RippleSignTx { /// Nested message and enums of message `RippleSignTx` pub mod ripple_sign_tx { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ripple.RippleSignTx.RipplePayment) + #[derive(PartialEq,Clone,Default,Debug)] pub struct RipplePayment { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ripple.RippleSignTx.RipplePayment.amount) @@ -969,8 +969,8 @@ pub mod ripple_sign_tx { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.ripple.RippleSignedTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct RippleSignedTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.ripple.RippleSignedTx.signature) diff --git a/rust/trezor-client/src/protos/generated/messages_stellar.rs b/rust/trezor-client/src/protos/generated/messages_stellar.rs index 2833ad143..d8823ed1a 100644 --- a/rust/trezor-client/src/protos/generated/messages_stellar.rs +++ b/rust/trezor-client/src/protos/generated/messages_stellar.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarAsset) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarAsset { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarAsset.type) @@ -280,8 +280,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarAsset { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarGetAddress.address_n) @@ -479,8 +479,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarAddress.address) @@ -640,8 +640,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarSignTx.address_n) @@ -1302,6 +1302,17 @@ pub mod stellar_sign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "NONE" => ::std::option::Option::Some(StellarMemoType::NONE), + "TEXT" => ::std::option::Option::Some(StellarMemoType::TEXT), + "ID" => ::std::option::Option::Some(StellarMemoType::ID), + "HASH" => ::std::option::Option::Some(StellarMemoType::HASH), + "RETURN" => ::std::option::Option::Some(StellarMemoType::RETURN), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [StellarMemoType] = &[ StellarMemoType::NONE, StellarMemoType::TEXT, @@ -1336,8 +1347,8 @@ pub mod stellar_sign_tx { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarTxOpRequest) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarTxOpRequest { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.stellar.StellarTxOpRequest.special_fields) @@ -1439,8 +1450,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarTxOpRequest { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarPaymentOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarPaymentOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarPaymentOp.source_account) @@ -1721,8 +1732,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarPaymentOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarCreateAccountOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarCreateAccountOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarCreateAccountOp.source_account) @@ -1976,8 +1987,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarCreateAccountOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarPathPaymentStrictReceiveOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarPathPaymentStrictReceiveOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarPathPaymentStrictReceiveOp.source_account) @@ -2349,8 +2360,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarPathPaymentStrictReceiveOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarPathPaymentStrictSendOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarPathPaymentStrictSendOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarPathPaymentStrictSendOp.source_account) @@ -2722,8 +2733,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarPathPaymentStrictSendOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarManageSellOfferOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarManageSellOfferOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarManageSellOfferOp.source_account) @@ -3094,8 +3105,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarManageSellOfferOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarManageBuyOfferOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarManageBuyOfferOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarManageBuyOfferOp.source_account) @@ -3466,8 +3477,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarManageBuyOfferOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarCreatePassiveSellOfferOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarCreatePassiveSellOfferOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarCreatePassiveSellOfferOp.source_account) @@ -3798,8 +3809,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarCreatePassiveSellOfferOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarSetOptionsOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarSetOptionsOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarSetOptionsOp.source_account) @@ -4446,6 +4457,15 @@ pub mod stellar_set_options_op { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "ACCOUNT" => ::std::option::Option::Some(StellarSignerType::ACCOUNT), + "PRE_AUTH" => ::std::option::Option::Some(StellarSignerType::PRE_AUTH), + "HASH" => ::std::option::Option::Some(StellarSignerType::HASH), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [StellarSignerType] = &[ StellarSignerType::ACCOUNT, StellarSignerType::PRE_AUTH, @@ -4478,8 +4498,8 @@ pub mod stellar_set_options_op { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarChangeTrustOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarChangeTrustOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarChangeTrustOp.source_account) @@ -4703,8 +4723,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarChangeTrustOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarAllowTrustOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarAllowTrustOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarAllowTrustOp.source_account) @@ -5055,8 +5075,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarAllowTrustOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarAccountMergeOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarAccountMergeOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarAccountMergeOp.source_account) @@ -5270,8 +5290,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarAccountMergeOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarManageDataOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarManageDataOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarManageDataOp.source_account) @@ -5539,8 +5559,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarManageDataOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarBumpSequenceOp) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarBumpSequenceOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarBumpSequenceOp.source_account) @@ -5737,8 +5757,8 @@ impl ::protobuf::reflect::ProtobufValue for StellarBumpSequenceOp { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.stellar.StellarSignedTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct StellarSignedTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.stellar.StellarSignedTx.public_key) @@ -5982,6 +6002,15 @@ impl ::protobuf::Enum for StellarAssetType { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "NATIVE" => ::std::option::Option::Some(StellarAssetType::NATIVE), + "ALPHANUM4" => ::std::option::Option::Some(StellarAssetType::ALPHANUM4), + "ALPHANUM12" => ::std::option::Option::Some(StellarAssetType::ALPHANUM12), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [StellarAssetType] = &[ StellarAssetType::NATIVE, StellarAssetType::ALPHANUM4, diff --git a/rust/trezor-client/src/protos/generated/messages_tezos.rs b/rust/trezor-client/src/protos/generated/messages_tezos.rs index 7de98de87..13e68d557 100644 --- a/rust/trezor-client/src/protos/generated/messages_tezos.rs +++ b/rust/trezor-client/src/protos/generated/messages_tezos.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosGetAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TezosGetAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosGetAddress.address_n) @@ -224,8 +224,8 @@ impl ::protobuf::reflect::ProtobufValue for TezosGetAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosAddress) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TezosAddress { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosAddress.address) @@ -385,8 +385,8 @@ impl ::protobuf::reflect::ProtobufValue for TezosAddress { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosGetPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TezosGetPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosGetPublicKey.address_n) @@ -584,8 +584,8 @@ impl ::protobuf::reflect::ProtobufValue for TezosGetPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosPublicKey) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TezosPublicKey { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosPublicKey.public_key) @@ -745,8 +745,8 @@ impl ::protobuf::reflect::ProtobufValue for TezosPublicKey { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TezosSignTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.address_n) @@ -1110,8 +1110,8 @@ impl ::protobuf::reflect::ProtobufValue for TezosSignTx { /// Nested message and enums of message `TezosSignTx` pub mod tezos_sign_tx { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosContractID) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosContractID { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosContractID.tag) @@ -1340,6 +1340,14 @@ pub mod tezos_sign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Implicit" => ::std::option::Option::Some(TezosContractType::Implicit), + "Originated" => ::std::option::Option::Some(TezosContractType::Originated), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [TezosContractType] = &[ TezosContractType::Implicit, TezosContractType::Originated, @@ -1371,8 +1379,8 @@ pub mod tezos_sign_tx { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosRevealOp) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosRevealOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosRevealOp.source) @@ -1749,8 +1757,8 @@ pub mod tezos_sign_tx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosTransactionOp) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosTransactionOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosTransactionOp.source) @@ -2217,8 +2225,8 @@ pub mod tezos_sign_tx { /// Nested message and enums of message `TezosTransactionOp` pub mod tezos_transaction_op { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosTransactionOp.TezosParametersManager) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosParametersManager { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosTransactionOp.TezosParametersManager.set_delegate) @@ -2438,8 +2446,8 @@ pub mod tezos_sign_tx { /// Nested message and enums of message `TezosParametersManager` pub mod tezos_parameters_manager { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosTransactionOp.TezosParametersManager.TezosManagerTransfer) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosManagerTransfer { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosTransactionOp.TezosParametersManager.TezosManagerTransfer.destination) @@ -2611,8 +2619,8 @@ pub mod tezos_sign_tx { } } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosOriginationOp) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosOriginationOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosOriginationOp.source) @@ -3211,8 +3219,8 @@ pub mod tezos_sign_tx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosDelegationOp) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosDelegationOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosDelegationOp.source) @@ -3589,8 +3597,8 @@ pub mod tezos_sign_tx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosProposalOp) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosProposalOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosProposalOp.source) @@ -3808,8 +3816,8 @@ pub mod tezos_sign_tx { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignTx.TezosBallotOp) + #[derive(PartialEq,Clone,Default,Debug)] pub struct TezosBallotOp { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignTx.TezosBallotOp.source) @@ -4138,6 +4146,15 @@ pub mod tezos_sign_tx { } } + fn from_str(str: &str) -> ::std::option::Option { + match str { + "Yay" => ::std::option::Option::Some(TezosBallotType::Yay), + "Nay" => ::std::option::Option::Some(TezosBallotType::Nay), + "Pass" => ::std::option::Option::Some(TezosBallotType::Pass), + _ => ::std::option::Option::None + } + } + const VALUES: &'static [TezosBallotType] = &[ TezosBallotType::Yay, TezosBallotType::Nay, @@ -4171,8 +4188,8 @@ pub mod tezos_sign_tx { } } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.tezos.TezosSignedTx) +#[derive(PartialEq,Clone,Default,Debug)] pub struct TezosSignedTx { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.tezos.TezosSignedTx.signature) diff --git a/rust/trezor-client/src/protos/generated/messages_webauthn.rs b/rust/trezor-client/src/protos/generated/messages_webauthn.rs index 8a13fe406..7de0714c1 100644 --- a/rust/trezor-client/src/protos/generated/messages_webauthn.rs +++ b/rust/trezor-client/src/protos/generated/messages_webauthn.rs @@ -1,4 +1,4 @@ -// This file is generated by rust-protobuf 3.2.0. Do not edit +// This file is generated by rust-protobuf 3.3.0. Do not edit // .proto file is parsed by protoc 3.19.6 // @generated @@ -23,10 +23,10 @@ /// Generated files are compatible only with the same version /// of protobuf runtime. -const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_2_0; +const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_3_3_0; -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.webauthn.WebAuthnListResidentCredentials) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WebAuthnListResidentCredentials { // special fields // @@protoc_insertion_point(special_field:hw.trezor.messages.webauthn.WebAuthnListResidentCredentials.special_fields) @@ -128,8 +128,8 @@ impl ::protobuf::reflect::ProtobufValue for WebAuthnListResidentCredentials { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.webauthn.WebAuthnAddResidentCredential) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WebAuthnAddResidentCredential { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.webauthn.WebAuthnAddResidentCredential.credential_id) @@ -286,8 +286,8 @@ impl ::protobuf::reflect::ProtobufValue for WebAuthnAddResidentCredential { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.webauthn.WebAuthnRemoveResidentCredential) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WebAuthnRemoveResidentCredential { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.webauthn.WebAuthnRemoveResidentCredential.index) @@ -427,8 +427,8 @@ impl ::protobuf::reflect::ProtobufValue for WebAuthnRemoveResidentCredential { type RuntimeType = ::protobuf::reflect::rt::RuntimeTypeMessage; } -#[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.webauthn.WebAuthnCredentials) +#[derive(PartialEq,Clone,Default,Debug)] pub struct WebAuthnCredentials { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.webauthn.WebAuthnCredentials.credentials) @@ -552,8 +552,8 @@ impl ::protobuf::reflect::ProtobufValue for WebAuthnCredentials { /// Nested message and enums of message `WebAuthnCredentials` pub mod web_authn_credentials { - #[derive(PartialEq,Clone,Default,Debug)] // @@protoc_insertion_point(message:hw.trezor.messages.webauthn.WebAuthnCredentials.WebAuthnCredential) + #[derive(PartialEq,Clone,Default,Debug)] pub struct WebAuthnCredential { // message fields // @@protoc_insertion_point(field:hw.trezor.messages.webauthn.WebAuthnCredentials.WebAuthnCredential.index)