-
Notifications
You must be signed in to change notification settings - Fork 956
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use a tag/discriminant to distinguish between IBC NFT transfers and fungible token transfers #3501
Comments
Another separate issue on the topic of IBC (N)FT Transfer (de)serialization: While most of the |
why is this breaking the tx format? I think this is only breaking the |
My mistake here. You are correct. I've removed the |
As you mentioned, currently, an IBC transaction can have a message for all IBC operations not only for IBC transfers. |
@murisi Is this still required, or did ZondaX find a workaround? |
Zondax found a workaround. There's a certain byte they check in the Protobuf encoding. See: https://github.com/Zondax/ledger-namada/blob/6e0ac0f674ee3f9429244c7089fa31335e5f80af/app/src/parser_impl_txn.c#L853 . |
Thanks - closing for now then. |
Parsing IBC transfers is a task that was completed in the context of #3494. Right now it seems that the best way for a hardware wallet to parse a
TX_IBC_WASM
transaction is to attempt to parse it as aMsgTransfer
, and if that fails then to attempt to parse it as aMsgNftTransfer
. Is this the case? If so, then I guess the assumption here is that there is no byte sequence that can be successfully interpreted as both aMsgTransfer
and aMsgNftTransfer
? If so, then it might be simpler/more robust to just use two separate WASMs for these two transaction types, or use the same WASM and embed in the Data section a tagged enumeration instance that can either be inhabited by aMsgTransfer
orMsgNftTransfer
. In this way, the errors reported by a parser could also be more precise.The text was updated successfully, but these errors were encountered: