Skip to content

Commit

Permalink
Update zxlib
Browse files Browse the repository at this point in the history
  • Loading branch information
neithanmo committed Dec 9, 2024
1 parent 32fa2b7 commit c233a9f
Show file tree
Hide file tree
Showing 106 changed files with 87 additions and 100 deletions.
10 changes: 1 addition & 9 deletions app/rust/src/parser/coreth/native/sign_msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ use core::{mem::MaybeUninit, ptr::addr_of_mut};
use crate::{
checked_add,
handlers::handle_ui_message,
parser::{DisplayableItem, FromBytes, Message, MSG_MAX_CHUNK_LEN},
parser::{DisplayableItem, FromBytes, Message},
zlog,
};
use bolos::{pic_str, PIC};
Expand Down Expand Up @@ -65,14 +65,6 @@ impl<'b> DisplayableItem for PersonalMsg<'b> {
message: &mut [u8],
page: u8,
) -> Result<u8, ViewError> {
match item_n {
0 => zlog("render_title"),
1 => zlog("msg_1_chunk"),
2 => zlog("msg_2_chunk"),
3 => zlog("msg_3_chunk"),
_ => zlog("unexpected chunk???"),
}

if item_n == 0 {
let label = pic_str!(b"Sign");
title[..label.len()].copy_from_slice(label);
Expand Down
3 changes: 0 additions & 3 deletions app/src/apdu_handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,6 @@ __Z_INLINE void handleNftInfo(volatile uint32_t *flags, volatile uint32_t *tx, u
THROW(APDU_CODE_DATA_INVALID);
}

zemu_log("processed_nft_info ok\n");
set_code(G_io_apdu_buffer, 0, APDU_CODE_OK);
io_exchange(CHANNEL_APDU | IO_RETURN_AFTER_TX, 2);
*flags |= IO_ASYNCH_REPLY;
Expand All @@ -407,7 +406,6 @@ __Z_INLINE void handleProvideErc20(volatile uint32_t *flags, volatile uint32_t *
// ontinue with signing contract calls
*tx = 0;

zemu_log("provide_erc20_info\n");
set_code(G_io_apdu_buffer, 0, APDU_CODE_OK);
io_exchange(CHANNEL_APDU | IO_RETURN_AFTER_TX, 2);
*flags |= IO_ASYNCH_REPLY;
Expand Down Expand Up @@ -451,7 +449,6 @@ __Z_INLINE void handleSignEthMsg(volatile uint32_t *flags, volatile uint32_t *tx
THROW(APDU_CODE_DATA_INVALID);
}

// view_review_init(tx_getItem, tx_getNumItems, app_sign_eth);
view_review_init_progressive(tx_getItem, tx_getNumItems, app_sign_eth);
view_review_show(REVIEW_TXN);

Expand Down
2 changes: 1 addition & 1 deletion deps/ledger-zxlib
Submodule ledger-zxlib updated 59 files
+34 −39 app/common/app_main.c
+31 −30 app/common/app_main.h
+37 −26 app/ui/view.c
+9 −2 app/ui/view.h
+35 −37 app/ui/view_inspect_s.c
+22 −0 app/ui/view_internal.h
+4 −4 app/ui/view_nano.c
+1 −1 app/ui/view_nano.h
+15 −14 app/ui/view_nano_inspect.h
+12 −12 app/ui/view_nbgl.c
+108 −7 app/ui/view_s.c
+100 −2 app/ui/view_x.c
+1 −1 dockerized_build.mk
+32 −33 include/apdu_codes.h
+19 −16 include/app_mode.h
+19 −21 include/base58.h
+1 −1 include/base64.h
+1 −1 include/bech32.h
+1 −1 include/bignum.h
+1 −6 include/bittools.h
+17 −20 include/buffering.h
+15 −15 include/hexutils.h
+8 −35 include/segwit_addr.h
+15 −18 include/sigutils.h
+17 −16 include/timeutils.h
+318 −415 include/utf8.h
+145 −149 include/view_templates.h
+14 −14 include/zxcanary.h
+51 −49 include/zxerror.h
+74 −79 include/zxformat.h
+14 −14 include/zxtypes.h
+2 −3 include/zxutils_ledger.h
+4 −4 include/zxversion.h
+1 −1 scripts/install_deps.sh
+1 −1 scripts/template.sh
+27 −3 src/app_mode.c
+40 −48 src/base58.c
+20 −20 src/base64.c
+20 −23 src/bech32.c
+24 −27 src/bignum.c
+20 −26 src/buffering.c
+24 −25 src/hexutils.c
+14 −22 src/segwit_addr.c
+17 −21 src/sigutils.c
+76 −686 src/timeutils.c
+19 −17 src/zxcanary.c
+30 −30 src/zxformat.c
+133 −134 src/zxutils_ledger.c
+1 −1 templates/Makefile.root
+1 −1 tests/asciify.cpp
+1 −1 tests/base64.cpp
+1 −1 tests/bech32.cpp
+1 −1 tests/bip44path.cpp
+1 −1 tests/buffering_tests.cpp
+1 −1 tests/doubledabble.cpp
+1 −1 tests/hexutils.cpp
+1 −1 tests/macros.cpp
+1 −1 tests/sigutils.cpp
+1 −1 tests/zxformat.cpp
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/fl-eth-sign-message/00002.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/fl-eth-sign-message/00003.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-eth-sign-message/00001.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-eth-sign-message/00002.png
Binary file modified tests_zemu/snapshots/s-eth-sign-message/00003.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00004.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00005.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00006.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00007.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00008.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00009.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00010.png
Binary file added tests_zemu/snapshots/s-eth-sign-message/00011.png
Binary file modified tests_zemu/snapshots/sp-eth-sign-message/00002.png
Binary file modified tests_zemu/snapshots/sp-eth-sign-message/00003.png
Binary file modified tests_zemu/snapshots/sp-eth-sign-message/00004.png
Binary file added tests_zemu/snapshots/sp-eth-sign-message/00005.png
Binary file added tests_zemu/snapshots/sp-eth-sign-message/00006.png
Binary file added tests_zemu/snapshots/sp-eth-sign-message/00007.png
Binary file added tests_zemu/snapshots/sp-eth-sign-message/00008.png
Binary file added tests_zemu/snapshots/sp-eth-sign-message/00009.png
Binary file added tests_zemu/snapshots/sp-eth-sign-message/00010.png
Binary file modified tests_zemu/snapshots/st-eth-sign-message/00000.png
Binary file modified tests_zemu/snapshots/st-eth-sign-message/00001.png
Binary file modified tests_zemu/snapshots/st-eth-sign-message/00002.png
Binary file modified tests_zemu/snapshots/st-eth-sign-message/00003.png
Binary file modified tests_zemu/snapshots/x-eth-sign-message/00002.png
Binary file modified tests_zemu/snapshots/x-eth-sign-message/00003.png
Binary file modified tests_zemu/snapshots/x-eth-sign-message/00004.png
Binary file added tests_zemu/snapshots/x-eth-sign-message/00005.png
Binary file added tests_zemu/snapshots/x-eth-sign-message/00006.png
Binary file added tests_zemu/snapshots/x-eth-sign-message/00007.png
Binary file added tests_zemu/snapshots/x-eth-sign-message/00008.png
Binary file added tests_zemu/snapshots/x-eth-sign-message/00009.png
Binary file added tests_zemu/snapshots/x-eth-sign-message/00010.png
144 changes: 57 additions & 87 deletions tests_zemu/tests/eth.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,42 @@ const SIGN_TEST_DATA: TestData[] = [
},
]

const ETH_MSG_RAW: number[] = [
...Buffer.from('Hello, ', 'utf8'),
0x80,
...Buffer.from('World! ', 'utf8'),
0x81,
...Buffer.from('This is a ', 'utf8'),
0x82,
...Buffer.from('complex ', 'utf8'),
0x83,
...Buffer.from('test ', 'utf8'),
0x84,
...Buffer.from('vector with ', 'utf8'),
0x85,
0x86,
0x87,
...Buffer.from(' multiple non-ASCII ', 'utf8'),
0x88,
0x89,
...Buffer.from(' characters ', 'utf8'),
0x8a,
...Buffer.from('scattered ', 'utf8'),
0x8b,
...Buffer.from('throughout. ', 'utf8'),
0x8c,
0x8d,
0x8e,
0x8f,
...Buffer.from('It should ', 'utf8'),
0x90,
...Buffer.from('properly ', 'utf8'),
0x91,
...Buffer.from('chunk ', 'utf8'),
0x92,
...Buffer.from('and format.', 'utf8'),
]

jest.setTimeout(60000)

// Nanos does not support erc721
Expand Down Expand Up @@ -196,22 +232,26 @@ describe.each(models)('EthereumOthers [%s] - misc', function (m) {
await sim.close()
}
})
})

test.concurrent('EthPersonalMsg%s', async function () {
describe.each(models)('Ethereum Personal Message [%s] - misc', function (m) {
test.concurrent('eth_msg sign%s', async function () {
const sim = new Zemu(m.path)
try {
await sim.start(defaultOptions(m))
const app = new Eth(sim.getTransport())
// Put the app in expert mode
await sim.toggleExpertMode()

let msgData = Buffer.from('Hello World', 'utf8')
// Initialize array to hold the message content
let msgData = Buffer.from(ETH_MSG_RAW)

const testcase = `${m.prefix.toLowerCase()}-eth-sign-message`

const currentScreen = await sim.snapshot()

const respReq = app.signPersonalMessage(ETH_DERIVATION, msgData.toString('hex'))

await sim.waitUntilScreenIsNot(currentScreen, 20000)
await sim.compareSnapshotsAndApprove('.', testcase)

Expand All @@ -222,36 +262,12 @@ describe.each(models)('EthereumOthers [%s] - misc', function (m) {
expect(resp).toHaveProperty('s')
expect(resp).toHaveProperty('r')
expect(resp).toHaveProperty('v')

//Verify signature
const resp_addr = await app.getAddress(ETH_DERIVATION, false)
console.log(resp_addr, m.name)

const header = Buffer.from('\x19Ethereum Signed Message:\n', 'utf8')
const msgLengthString = String(msgData.length)
const msg = Buffer.concat([header, Buffer.from(msgLengthString, 'utf8'), msgData])

const sha3 = require('js-sha3')
const msgHash = sha3.keccak256(msg)

console.log('***msgHash:', msgHash.toString('hex'))

const pubKey = Buffer.from(resp_addr.publicKey, 'hex')
const signature_obj = {
r: Buffer.from(resp.r, 'hex'),
s: Buffer.from(resp.s, 'hex'),
}

const EC = new ec('secp256k1')
const ok = EC.verify(msgHash, signature_obj, pubKey, 'hex')

expect(ok).toEqual(true)
} finally {
await sim.close()
}
})

test.concurrent('EthMsgWithBytes%s', async function () {
test.concurrent('eth_msg sign complex nav approve%s', async function () {
const sim = new Zemu(m.path)
try {
await sim.start(defaultOptions(m))
Expand All @@ -260,46 +276,24 @@ describe.each(models)('EthereumOthers [%s] - misc', function (m) {
await sim.toggleExpertMode()

// Initialize array to hold the message content
const msgRaw: number[] = []

// Add content following the same pattern as the Rust test
msgRaw.push(...Buffer.from('Hello, ', 'utf8'))
msgRaw.push(0x80)
msgRaw.push(...Buffer.from('World! ', 'utf8'))
msgRaw.push(0x81)
msgRaw.push(...Buffer.from('This is a ', 'utf8'))
msgRaw.push(0x82)
msgRaw.push(...Buffer.from('complex ', 'utf8'))
msgRaw.push(0x83)
msgRaw.push(...Buffer.from('test ', 'utf8'))
msgRaw.push(0x84)
msgRaw.push(...Buffer.from('vector with ', 'utf8'))
msgRaw.push(0x85, 0x86, 0x87)
msgRaw.push(...Buffer.from(' multiple non-ASCII ', 'utf8'))
msgRaw.push(0x88, 0x89)
msgRaw.push(...Buffer.from(' characters ', 'utf8'))
msgRaw.push(0x8a)
msgRaw.push(...Buffer.from('scattered ', 'utf8'))
msgRaw.push(0x8b)
msgRaw.push(...Buffer.from('throughout. ', 'utf8'))
msgRaw.push(0x8c, 0x8d, 0x8e, 0x8f)
msgRaw.push(...Buffer.from('It should ', 'utf8'))
msgRaw.push(0x90)
msgRaw.push(...Buffer.from('properly ', 'utf8'))
msgRaw.push(0x91)
msgRaw.push(...Buffer.from('chunk ', 'utf8'))
msgRaw.push(0x92)
msgRaw.push(...Buffer.from('and format.', 'utf8'))

let msgData = Buffer.from(msgRaw)

const testcase = `${m.prefix.toLowerCase()}-eth-sign-message-with-bytes`
let msgData = Buffer.from(ETH_MSG_RAW)

const testcase = `${m.prefix.toLowerCase()}-eth-sign-message-complex_nav`

const currentScreen = await sim.snapshot()

const respReq = app.signPersonalMessage(ETH_DERIVATION, msgData.toString('hex'))
await sim.waitUntilScreenIsNot(currentScreen, 20000)
await sim.compareSnapshotsAndApprove('.', testcase)

if (m.name === 'nanos') {
await sim.navigateAndCompareSnapshots('.', testcase, [5, -4, 3, 0, 0])
} else if (m.name === 'nanox' || m.name === 'nanosp') {
await sim.navigateAndCompareSnapshots('.', testcase, [9, -4, 3, 0, 0])
} else {
// skip menu is not available for larger devices
// like stax and flex
await sim.waitUntilScreenIsNot(currentScreen, 20000)
await sim.compareSnapshotsAndApprove('.', testcase)
}

const resp = await respReq

Expand All @@ -308,30 +302,6 @@ describe.each(models)('EthereumOthers [%s] - misc', function (m) {
expect(resp).toHaveProperty('s')
expect(resp).toHaveProperty('r')
expect(resp).toHaveProperty('v')

//Verify signature
const resp_addr = await app.getAddress(ETH_DERIVATION, false)
console.log(resp_addr, m.name)

const header = Buffer.from('\x19Ethereum Signed Message:\n', 'utf8')
const msgLengthString = String(msgData.length)
const msg = Buffer.concat([header, Buffer.from(msgLengthString, 'utf8'), msgData])

const sha3 = require('js-sha3')
const msgHash = sha3.keccak256(msg)

console.log('***msgHash:', msgHash.toString('hex'))

const pubKey = Buffer.from(resp_addr.publicKey, 'hex')
const signature_obj = {
r: Buffer.from(resp.r, 'hex'),
s: Buffer.from(resp.s, 'hex'),
}

const EC = new ec('secp256k1')
const ok = EC.verify(msgHash, signature_obj, pubKey, 'hex')

expect(ok).toEqual(true)
} finally {
await sim.close()
}
Expand Down
28 changes: 28 additions & 0 deletions tests_zemu/try.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,32 @@ import AvalancheApp from '@zondax/ledger-avalanche-app'
const APP_DERIVATION = "m/44'/9000'/0'/0/0"
const ETH_DERIVATION = "m/44'/60'/0'/0'"

const ADD_DELEGATOR_DATA = Buffer.from([
0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x30, 0x39, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01,
0xdb, 0xcf, 0x89, 0x0f, 0x77, 0xf4, 0x9b, 0x96, 0x85, 0x76, 0x48, 0xb7, 0x2b, 0x77, 0xf9, 0xf8, 0x29, 0x37, 0xf2, 0x8a, 0x68, 0x70, 0x4a,
0xf0, 0x5d, 0xa0, 0xdc, 0x12, 0xba, 0x53, 0xf2, 0xdb, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0xee, 0x5b, 0xe5, 0xc0, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0xda, 0x2b, 0xee, 0x01, 0xbe, 0x82, 0xec, 0xc0, 0x0c,
0x34, 0xf3, 0x61, 0xed, 0xa8, 0xeb, 0x30, 0xfb, 0x5a, 0x71, 0x5c, 0x00, 0x00, 0x00, 0x01, 0xdf, 0xaf, 0xbd, 0xf5, 0xc8, 0x1f, 0x63, 0x5c,
0x92, 0x57, 0x82, 0x4f, 0xf2, 0x1c, 0x8e, 0x3e, 0x6f, 0x7b, 0x63, 0x2a, 0xc3, 0x06, 0xe1, 0x14, 0x46, 0xee, 0x54, 0x0d, 0x34, 0x71, 0x1a,
0x15, 0x00, 0x00, 0x00, 0x01, 0xdb, 0xcf, 0x89, 0x0f, 0x77, 0xf4, 0x9b, 0x96, 0x85, 0x76, 0x48, 0xb7, 0x2b, 0x77, 0xf9, 0xf8, 0x29, 0x37,
0xf2, 0x8a, 0x68, 0x70, 0x4a, 0xf0, 0x5d, 0xa0, 0xdc, 0x12, 0xba, 0x53, 0xf2, 0xdb, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x01, 0xd2, 0x97,
0xb5, 0x48, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe9, 0x09, 0x4f, 0x73, 0x69, 0x80, 0x02, 0xfd,
0x52, 0xc9, 0x08, 0x19, 0xb4, 0x57, 0xb9, 0xfb, 0xc8, 0x66, 0xab, 0x80, 0x00, 0x00, 0x00, 0x00, 0x5f, 0x21, 0xf3, 0x1d, 0x00, 0x00, 0x00,
0x00, 0x5f, 0x49, 0x7d, 0xc6, 0x00, 0x00, 0x01, 0xd1, 0xa9, 0x4a, 0x20, 0x00, 0x00, 0x00, 0x00, 0x01, 0xdb, 0xcf, 0x89, 0x0f, 0x77, 0xf4,
0x9b, 0x96, 0x85, 0x76, 0x48, 0xb7, 0x2b, 0x77, 0xf9, 0xf8, 0x29, 0x37, 0xf2, 0x8a, 0x68, 0x70, 0x4a, 0xf0, 0x5d, 0xa0, 0xdc, 0x12, 0xba,
0x53, 0xf2, 0xdb, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x01, 0xd1, 0xa9, 0x4a, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x3c, 0xb7, 0xd3, 0x84, 0x2e, 0x8c, 0xee, 0x6a, 0x0e, 0xbd, 0x09, 0xf1, 0xfe, 0x88, 0x4f,
0x68, 0x61, 0xe1, 0xb2, 0x9c, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
0x00, 0x01, 0xda, 0x2b, 0xee, 0x01, 0xbe, 0x82, 0xec, 0xc0, 0x0c, 0x34, 0xf3, 0x61, 0xed, 0xa8, 0xeb, 0x30, 0xfb, 0x5a, 0x71, 0x5c,
])

async function signAvax(app: AvalancheApp) {
const signers = ['0/0', '0/1', '1/100']
const resp = await app.sign("m/44'/9000'/0'", signers, ADD_DELEGATOR_DATA)
console.log(resp)
}

async function get_avax_address(app: AvalancheApp) {
const resp = await app.getAddressAndPubKey(APP_DERIVATION, true)
console.log(resp)
Expand Down Expand Up @@ -55,7 +81,9 @@ async function main() {
log('trying to connect to device')

const app = new Eth(transport)
// await get_avax_address(new AvalancheApp(transport))
await sign_191_message(app)
// await signAvax(new AvalancheApp(transport))
}

;(async () => {
Expand Down

0 comments on commit c233a9f

Please sign in to comment.