mirror of
https://github.com/polhenarejos/pico-hsm.git
synced 2026-01-17 01:18:06 +00:00
Use BOOTKEY instead of reading json.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
parent
1933498a33
commit
68360978d6
1 changed files with 3 additions and 3 deletions
|
|
@ -57,6 +57,8 @@ from argparse import RawTextHelpFormatter
|
|||
|
||||
pin = None
|
||||
|
||||
BOOTKEY = [225, 209, 107, 167, 100, 171, 215, 18, 212, 239, 110, 62, 221, 116, 78, 213, 99, 140, 38, 11, 119, 28, 249, 129, 81, 17, 11, 175, 172, 155, 200, 113]
|
||||
|
||||
def hexy(a):
|
||||
return [hex(i) for i in a]
|
||||
|
||||
|
|
@ -498,9 +500,7 @@ def otp(picohsm, args):
|
|||
picohsm.otp(row=row, data=data)
|
||||
print(f'OTP row {args.row} written successfully.')
|
||||
elif (args.subcommand == 'secure_boot'):
|
||||
script_path = os.path.dirname(os.path.abspath(__file__))
|
||||
boot_json = json.load(open(f'{script_path}/../pico-keys-sdk/config/rp2350/secure_boot.json'))
|
||||
picohsm.secure_boot(boot_json['bootkey0'], bootkey_index=args.index, lock=args.lock)
|
||||
picohsm.secure_boot(BOOTKEY, bootkey_index=args.index, lock=args.lock)
|
||||
|
||||
def main(args):
|
||||
sys.stderr.buffer.write(b'Pico HSM Tool v1.18\n')
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue