tools: add getkey command to keyctl to retrieve the public key

pull/25/head
Pavol Rusnak 6 years ago
parent b77a1eb12f
commit 5e164ebaf1
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D

@ -29,6 +29,16 @@ def cli():
pass
@cli.command(help='')
@click.argument('index', type=click.Choice(indexmap.keys()))
def getkey(index):
index = indexmap[index]
t = get_trezor()
path = "10018'/%d'" % index
node = t.get_public_node(t.expand_path(path), ecdsa_curve_name='ed25519').node
print('%s' % (binascii.hexlify(node.public_key[1:]).decode()))
@cli.command(help='')
@click.argument('index', type=click.Choice(indexmap.keys()))
@click.argument('filename')

Loading…
Cancel
Save