-
-
Notifications
You must be signed in to change notification settings - Fork 655
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
Unable to sign custom firmware #976
Comments
There is something seriously wrong with your checkout. It looks like you are using an old version of binctl/keyctl (which doesn't exist in the repository anymore) together with a relatively new trezorlib -- which should not exist at the same time as the above tools, unless you just picked a commit at random in the middle of the conversion. |
I created my branch from |
try the following - which brings the master branch to the latest commit:
|
Okay awesome it worked! Thank you. I actually checked the online diff from my master against yours and they both seemed to be on the same commit. Anyways it worked. I have fixed some issues related to the rebase and could verify everthing on the emulator. Updating the firmware works now. But the trezor gets stuck in the starting up view. Everything loads, it says |
Ok, the original issue is fixed. For the other problem, please open a new issue. |
Hey @Dimfred have you resolved your issue when Trezor T stucks in the starting up view? I've built firmware and getting the same problem as well. I tried to search for another tracked issue that would be a proper place to discuss this, but found only this one lol. |
Hey @xlab, I think I solved it, but I can't recall how^^ It was just too long ago. |
Hi @Dimfred, I've built firmware with legacy folder and now How can I sign my custom firmware? |
Hello, I am currently trying to build my custom firmware, but the
build_firmware
target fails on signing the firmware.I run:
BUILD_VERBOSE=1 PRODUCTION=0 BITCOIN_ONLY=0 PYOPT=0 make vendor build_firmware
Initial build output before signing
cat build/firmware/firmware.bin.p1 build/firmware/firmware.bin.p2 > build/firmware/firmware.bin
tools/binctl build/firmware/firmware.bin -h
Trezor Vendor Header
No firmware signature
Trezor Firmware Image
Signing process
tools/binctl build/firmware/firmware.bin -s 1:2 tools/keyctl sign firmware build/firmware/firmware.bin 4747474747474747474747474747474747474747474747474747474747474747 4848484848484848484848484848484848484848484848484848484848484848`
Traceback (most recent call last):
File "tools/keyctl", line 73, in
cli()
File "/home/dimfred/01_data/02_programs/pyenv/versions/3.7.3/lib/python3.7/site-packages/click/core.py", line 829, in call
return self.main(*args, **kwargs)
File "/home/dimfred/01_data/02_programs/pyenv/versions/3.7.3/lib/python3.7/site-packages/click/core.py", line 782, in main
rv = self.invoke(ctx)
File "/home/dimfred/01_data/02_programs/pyenv/versions/3.7.3/lib/python3.7/site-packages/click/core.py", line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/home/dimfred/01_data/02_programs/pyenv/versions/3.7.3/lib/python3.7/site-packages/click/core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/dimfred/01_data/02_programs/pyenv/versions/3.7.3/lib/python3.7/site-packages/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "tools/keyctl", line 68, in sign
cosi.verify(sig, digest, global_pk)
TypeError: verify() missing 2 required positional arguments: 'keys' and 'mask'
Trezor Vendor Header
No firmware signature
Traceback (most recent call last):
File "tools/binctl", line 359, in
main()
File "tools/binctl", line 349, in main
signature = binascii.unhexlify(sys.argv[4])
IndexError: list index out of range
scons: *** [build/firmware/firmware.bin] Error 1
make: *** [Makefile:124: build_firmware] Error 2
I am running with
The
build_unix
target works perfectly and I could verify that everything works as expected with the emulator.how I build with docker
The docker build skips my probuf messages. (probably because, they aren't present in the official messages repo?)
PRODUCTION=0 BITCOIN_ONLY=0 REPOSITORY=local TAG=<my_branch> ./build-docker.sh
Any help appreciated, thanks in advance.
The text was updated successfully, but these errors were encountered: