If you want to use simontool to encrypt a file, you should first look at my post of encrypting files with the simon cipher because of the quirks with the keys. The default behavior is ECB, but the -m flag now allows CBC behavior. The CBC mode is included in the file header. An example of the encryption is:
Encrypt the file, testfile.txt:
simontool -e -m cbc -b 128 -k 128 -s 0f0e0d0c0b0a09080706050403020100 -i testfile.txt -o testfile.simon
Decrypt the file testfile.simon, use the expanded key:
simontool.elf -d -b 128 -k 128 -s 6413494fda72360d1cb8547cd58c4df9 -i testfile.simon -o testfile.txt
No comments:
Post a Comment