pub mod ins {
pub const GET_ETH_PUBLIC_ADDRESS: u8 = 0x02;
pub const SIGN_ETH_TRANSACTION: u8 = 0x04;
pub const GET_APP_CONFIGURATION: u8 = 0x06;
pub const SIGN_ETH_PERSONAL_MESSAGE: u8 = 0x08;
pub const PROVIDE_ERC20_TOKEN_INFO: u8 = 0x0A;
pub const SIGN_ETH_EIP712: u8 = 0x0C;
pub const GET_ETH2_PUBLIC_KEY: u8 = 0x0E;
pub const SET_ETH2_WITHDRAWAL_INDEX: u8 = 0x10;
pub const SET_EXTERNAL_PLUGIN: u8 = 0x12;
pub const PROVIDE_NFT_INFORMATION: u8 = 0x14;
pub const SET_PLUGIN: u8 = 0x16;
pub const PERFORM_PRIVACY_OPERATION: u8 = 0x18;
pub const EIP712_SEND_STRUCT_DEFINITION: u8 = 0x1A;
pub const EIP712_SEND_STRUCT_IMPLEMENTATION: u8 = 0x1C;
pub const EIP712_FILTERING: u8 = 0x1E;
pub const GET_CHALLENGE: u8 = 0x20;
pub const PROVIDE_DOMAIN_NAME: u8 = 0x22;
pub const PROVIDE_NETWORK_INFORMATION: u8 = 0x30;
pub const PROVIDE_TX_SIMULATION: u8 = 0x32;
pub const SIGN_EIP7702_AUTHORIZATION: u8 = 0x34;
pub const PROVIDE_SAFE_ACCOUNT: u8 = 0x36;
}
pub mod p1_get_address {
pub const RETURN_ADDRESS: u8 = 0x00;
pub const DISPLAY_AND_CONFIRM: u8 = 0x01;
}
pub mod p2_get_address {
pub const NO_CHAIN_CODE: u8 = 0x00;
pub const RETURN_CHAIN_CODE: u8 = 0x01;
}
pub mod p1_sign_transaction {
pub const FIRST_DATA_BLOCK: u8 = 0x00;
pub const SUBSEQUENT_DATA_BLOCK: u8 = 0x80;
}
pub mod p2_sign_transaction {
pub const PROCESS_AND_START: u8 = 0x00;
pub const STORE_ONLY: u8 = 0x01;
pub const START_FLOW: u8 = 0x02;
}
pub mod p1_sign_message {
pub const FIRST_DATA_BLOCK: u8 = 0x00;
pub const SUBSEQUENT_DATA_BLOCK: u8 = 0x80;
}
pub mod p1_privacy_operation {
pub const RETURN_DATA: u8 = 0x00;
pub const DISPLAY_AND_CONFIRM: u8 = 0x01;
}
pub mod p2_privacy_operation {
pub const RETURN_PUBLIC_KEY: u8 = 0x00;
pub const RETURN_SHARED_SECRET: u8 = 0x01;
}
pub mod p1_get_eth2_key {
pub const RETURN_KEY: u8 = 0x00;
pub const DISPLAY_AND_CONFIRM: u8 = 0x01;
}
pub mod p1_sign_eip712 {
pub const FIRST_CHUNK: u8 = 0x00;
pub const FOLLOWING_CHUNK: u8 = 0x01;
}
pub mod p2_sign_eip712 {
pub const V0_IMPLEMENTATION: u8 = 0x00;
pub const FULL_IMPLEMENTATION: u8 = 0x01;
}
pub mod p2_eip712_struct_def {
pub const STRUCT_NAME: u8 = 0x00;
pub const STRUCT_FIELD: u8 = 0xFF;
}
pub mod p1_eip712_struct_impl {
pub const COMPLETE_SEND: u8 = 0x00;
pub const PARTIAL_SEND: u8 = 0x01;
}
pub mod p2_eip712_struct_impl {
pub const ROOT_STRUCT: u8 = 0x00;
pub const ARRAY: u8 = 0x0F;
pub const STRUCT_FIELD: u8 = 0xFF;
}
pub mod p1_eip712_filtering {
pub const STANDARD: u8 = 0x00;
pub const DISCARDED: u8 = 0x01;
}
pub mod p2_eip712_filtering {
pub const ACTIVATION: u8 = 0x00;
pub const DISCARDED_FILTER_PATH: u8 = 0x01;
pub const MESSAGE_INFO: u8 = 0x0F;
pub const TRUSTED_NAME: u8 = 0xFB;
pub const DATE_TIME: u8 = 0xFC;
pub const AMOUNT_JOIN_TOKEN: u8 = 0xFD;
pub const AMOUNT_JOIN_VALUE: u8 = 0xFE;
pub const RAW_FIELD: u8 = 0xFF;
}
pub mod length {
pub const MAX_BIP32_PATH_DEPTH: usize = 10;
pub const BIP32_INDEX_SIZE: usize = 4;
pub const CHAIN_ID_SIZE: usize = 8;
pub const ETH_ADDRESS_SIZE: usize = 20;
pub const CHAIN_CODE_SIZE: usize = 32;
pub const SIGNATURE_COMPONENT_SIZE: usize = 32;
pub const SIGNATURE_V_SIZE: usize = 1;
pub const MAX_MESSAGE_CHUNK_SIZE: usize = 255;
pub const EIP712_DOMAIN_HASH_SIZE: usize = 32;
pub const EIP712_MESSAGE_HASH_SIZE: usize = 32;
}
pub mod config_flags {
pub const ARBITRARY_DATA_SIGNATURE: u8 = 0x01;
pub const ERC20_EXTERNAL_INFO: u8 = 0x02;
pub const TRANSACTION_CHECK_ENABLED: u8 = 0x10;
pub const TRANSACTION_CHECK_OPT_IN: u8 = 0x20;
}