Skip to content

Commit

Permalink
Merge pull request #8 from Zondax/main (B2CA-1850)
Browse files Browse the repository at this point in the history
Fix IBC Issue
  • Loading branch information
tdejoigny-ledger authored Nov 6, 2024
2 parents fef23b9 + 3417211 commit 853d9ca
Show file tree
Hide file tree
Showing 212 changed files with 21 additions and 10 deletions.
2 changes: 1 addition & 1 deletion app/Makefile.version
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ APPVERSION_M=1
# This is the `spec_version` field of `Runtime`
APPVERSION_N=0
# This is the patch version of this release
APPVERSION_P=3
APPVERSION_P=4
2 changes: 1 addition & 1 deletion app/src/parser_impl.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ parser_error_t _read(parser_context_t *ctx, parser_tx_t *v) {

CHECK_ERROR(validateTransactionParams(v))

if(ctx->tx_obj->transaction.isMasp || ctx->tx_obj->ibc.is_ibc) {
if(ctx->tx_obj->transaction.isMasp) {
CHECK_ERROR(verifyShieldedHash(ctx))
}

Expand Down
2 changes: 1 addition & 1 deletion deps/ledger-zxlib
14 changes: 7 additions & 7 deletions tests_zemu/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,19 @@
},
"dependencies": {
"@zondax/ledger-namada": "../js",
"@zondax/zemu": "^0.50.3"
"@zondax/zemu": "^0.51.0"
},
"devDependencies": {
"@types/jest": "^29.5.12",
"@types/jest": "^29.5.14",
"@types/ledgerhq__hw-transport": "^4.21.6",
"@typescript-eslint/eslint-plugin": "^8.5.0",
"@typescript-eslint/parser": "^8.5.0",
"@typescript-eslint/eslint-plugin": "^8.12.2",
"@typescript-eslint/parser": "^8.12.2",
"blakejs": "^1.1.1",
"crypto-js": "4.2.0",
"ed25519-supercop": "^2.0.1",
"eslint": "^9.10.0",
"eslint": "^9.13.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.30.0",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-jest": "^28.8.3",
"eslint-plugin-prettier": "^5.2.1",
"jest": "29.7.0",
Expand All @@ -42,6 +42,6 @@
"prettier": "^3.3.3",
"ts-jest": "^29.2.5",
"ts-node": "^10.9.2",
"typescript": "^5.6.2"
"typescript": "^5.6.3"
}
}
Binary file modified tests_zemu/snapshots/fl-mainmenu/00004.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified tests_zemu/snapshots/s-mainmenu/00004.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified tests_zemu/snapshots/s-mainmenu/00010.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified tests_zemu/snapshots/sp-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/sp-mainmenu/00010.png
Binary file modified tests_zemu/snapshots/st-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/x-mainmenu/00004.png
Binary file modified tests_zemu/snapshots/x-mainmenu/00010.png
11 changes: 11 additions & 0 deletions tests_zemu/tests/transactions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,17 @@ const TEST_DATA = [
0xff: Buffer.from('b38a61dd0f1ea2430905e13e3287353cede3bd3c2f37b5d40dd16ca1019cf650', 'hex'),
} as { [index: number]: Buffer },
},
{
name: 'ibc_transfer_non_masp',
blob: Buffer.from('110000004468786371395f6c6f476745354b3758790123000000353436392d30392d30385431373a31353a35322e3136353535333230342b30303a303023000000323234382d31312d31375431393a31353a35352e3939313238333533372b30303a30300100000032f6aecad9d0e72f80c4a6afa9420ca73f70f9438113f3d9461d9f4ddf6d50d02213b9aa6de354a9809f399afa1f985c33b4a90c9c0dc5cb4b21e4f1731bc474983682f22b93735f5fadfe945f8b1e63c907787c05a86410016733a7a438a5e6010105990a0892b67eb00000000000000000000000000000000000000000000000005c00a7adc3fb6ece562a2816e2c54625e1df278129f8007e6345a44dde356835420e6bc1d03504d08685bee49649861426245bf12971afdf178b8bfbd24bfb0300000000f8cea44b542df3de8b030000860300000a35394623632b683c47235d477a4b3c42235f316e3e307a772b2d533c2e2d5d322b7a3c2d6d4d232e4d653c742d482d614f5d633e2b2b121b6368616e6e656c2d343430373038333934343336393833323033361af1050a9f05234f5f3c356c5f3c344b3e2323393e2323422d31553e3e2b592e74326c6d3c3e392e2e3e665d3c5d5f734f2b5d6f2b3e41743671336d2b3c37472b365f5b3e4d42654d362b31373c2b2d2b5f2b232b3e5d6a5d5954353c2b6a5d3e745d2b2f6368616e6e656c2d31373733393434383031363033323331353632362f44693c2e493c5d77564a23325d2e5d5f353e5f5d325f42462b5d2e2d485d366d72373c23353c7923485f2b5f3c23485a2d562b3e323e5f455823232b7067772d645f2e5b4d5d395f2f6368616e6e656c2d363130323534313433373732373737383533392f3e5d323e313e772355563455362b2b656748435023315f565d2d2e66523c4e2d5f4823645f5d363423333c7535735f3e7775652b3c5f236634582b42716a3e2e58232b742f6368616e6e656c2d343434393332353836343838313334323032322f23533c4a2b3e415f235d78745f5d5d5a615d39444b5d234f2e563c23485d5d2e305d2b34415d3e345f235d3c52373e2e5f313c2e5d3e4c5f393c232b632e713e3c3c5f652b234223794b2d2d5d2e5f65623c423536683876583e3c713e535f5f2e755d6c3e6e5d234c235d622d5f74723c3c776b2b5a353e3e2e4f67413e3e792f6368616e6e656c2d3837323139343833333936393734343632362f635f23453551237a322f6368616e6e656c2d31303933383036353833313533303232393439352f5f2b475d2e523e7123562e5d2b3e5f5d313c3e65622b3e6351237644595d71655f555d562b535f5f4c3568673e2e642b3c235a4d2b3c492b6569332e5d7870753e493c6d2b2341235d3c3c5d2e4e4f2d2367725f5d5d673323512e234b465f375a5d632b622b314876562b5f2b572f6368616e6e656c2d383831353630383636383231313531363937302f303133375a647676454437764c6c6b124d373034353033393934333536393331313831343635363038323039333531393230363637333536393537343336343731333132353533353838383335323330393134383736393632323732333222097475665f4f41546d6d2a0c5f6b63475f30485f5f5f5f48321408b5c8d79587a7b9ff7510b295d4c1b5a4f6b81638fbbadebeaedcd3b28901420273320002fcb6a376964b8faa0057aca0722616650f0b7f665aa072a297aab5a517cc68374fc4ca438a1498572e010b00000074785f6962632e7761736d012a5871596852219b01d8030000676563365f34395f31763349393755356a53415f657a3234325f5f735f4e3337325f324c505f5f49724d38664d5845585f5f75363258736b36464433645833345f4f68386a544a395f395f7a36465f4b5f447a36665f5f687a37304550505f784734435f755f493474476875395f5538696d695f5f5f5f5f4e365278495f575f5f5f695036386d7175565f475f5f313332585370356839515f5a5f5f6235736f336d6752384b30497262546753736750625f7a5737796635645f715f5a705f5f665063644a5f3979355f304553774e5f5f73776171485f38626b5879345f6b5f5f5f6f323359556f33634878735f355268444f385f305f6571664b5f5159725f7436384c62345f33385f4e48397874375f737771484337466a72445f5f3556385f6652525f6d49475578565f446a4f513738343369374e677652694f517975676e5a32573557753833313673695679746a4f4c6e5f41396b625f715a68436a59545f534c5638347163324c505f33544d5f4934423432554f4e637332584e5f6d6b4f44594c5f655f31335138525f754739434e3838364c43355f5356714c6c72487a5f4d7836365f30504d43545f32395f5633455f45505f4144306f346d646d476a616f395f3851355f4b6d5f395f355f5f43323955416b7173374d354e427438365f434f6c5f5f465861685f365f6a516e6d31724d5f46385f435f4f356441307931455f775f3155455f3633713561375f5f5743595f435f5a6f69595f70554668545f724963545f5f335f5f5f5f3235767439357173583166315f4e3239384858355838664970666d4d565438776f65785f573570397942355f3747385f4337336a6c476c326c5447745f61673830347837304779345f486e5f7859417549333339356748595f396d31473346555f48435f5f4637766f69645f575f57335a715662635f5f724f5178704d613634655f435438595a306a5f5f386b494d7144663745475f63654f336843345232465f455535495f70665f51356754635f725f725f5f6e51626330384e6a5f41486f43315f5132453631455f5f5f514274474e39363933365f72744b6437715f7a365f4257535f325f5f6878634d5747674443356e3242357469334b5f314142785f4d5565365f5f5443397071417238435f3269385f6d304e386652313830374d38397450303968315a5f6d6e465f31785f5f4b385f386e6d635a6f4f6a4368505f30485f33465f4136625a5f5f384a3735376f706a574f335f41415f485f743073595f5a38395f6a455f6e6c437a5f4e334d35687143394d766a4f735f5a48797a575f4566685f664b5f365f5a51306b5f336350325f773059433674385f52366165535f4c6b30795a7601b900000039434d4469344c5f5f394d5f5f735f735449745f4f563774795f3753775f7358793469564a3554335f5f3237395f6853676f4d33584f69453332513530443565715f594f3839635f486c374543555f32374c3446374e305f6a5f5f6e6a6958747479455f71436c375f35315f5f483862366f5474314557745f6c5f575f5f3638415f627249725f5f6d3231397a756f795164315f65755f5f707a485f4f3078736e5f51556c6656637538613732525f5f33355f5f5f325f5f6b', 'hex'),
sectionHashes: {
0: Buffer.from('44056c9fdaef14880bdbebd5c87daf4ce947f6fc8924276efc0ebd1fc260d180', 'hex'),
1: Buffer.from('2213b9aa6de354a9809f399afa1f985c33b4a90c9c0dc5cb4b21e4f1731bc474', 'hex'),
2: Buffer.from('32f6aecad9d0e72f80c4a6afa9420ca73f70f9438113f3d9461d9f4ddf6d50d0', 'hex'),
3: Buffer.from('983682f22b93735f5fadfe945f8b1e63c907787c05a86410016733a7a438a5e6', 'hex'),
0xff: Buffer.from('860d76fc05b2c26599d490205736112e0e1c7e69348797177b3d953eb174b56d', 'hex'),
} as { [index: number]: Buffer },
},
]

jest.setTimeout(120000)
Expand Down

0 comments on commit 853d9ca

Please sign in to comment.