This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

add magic number to bin file in keil uvision

Hi,

could someone of you tell me if it is possible to add a specific magic number to a bin file created by keil uvision?

Under "target for options" -> User-tab I added the following line to the (Run user programs after build /rebuild.

fromelf --bin ".\test.axf" --output ".\test.bin"

best regards
Jens

Parents
  • Then you need to sign it. Compute a cryptographically strong hash based on the contents of the binary file and some secret you know about.

    The loader computes the same and compares the result. Obviously, the big problem is if someone tries to extract that common secret from the boot loader.

    Are you afraid that someone will buy your hardware and write own software - to use the hardware for a different task?

    Or are you afraid that someone will host a fake web site and fool your customers to download fake binaries?

    Or exactly why do you worry that someone have manipulated the binary? Most companies just settle for a CRC-32, Adler-32, MD5 or similar to check that the file haven't been damanged when copied.

Reply
  • Then you need to sign it. Compute a cryptographically strong hash based on the contents of the binary file and some secret you know about.

    The loader computes the same and compares the result. Obviously, the big problem is if someone tries to extract that common secret from the boot loader.

    Are you afraid that someone will buy your hardware and write own software - to use the hardware for a different task?

    Or are you afraid that someone will host a fake web site and fool your customers to download fake binaries?

    Or exactly why do you worry that someone have manipulated the binary? Most companies just settle for a CRC-32, Adler-32, MD5 or similar to check that the file haven't been damanged when copied.

Children