wolfssl-examples/crypto/aes
Eric Blankenhorn 6df432eaac Clarify aesgcm-file-encrypt demo 2025-05-13 17:00:40 -05:00
..
Makefile AES-GCM one shot example 2024-08-08 12:23:06 +10:00
README.md Phase 1 updates to wolfSSL examples based on testing with wolfSSL 2023-03-25 09:15:11 -05:00
aes-file-encrypt.c Add missing wc_AesInit calls. 2023-11-30 15:14:05 -06:00
aescfb-file-encrypt.c Add missing wc_AesInit calls. 2023-11-30 15:14:05 -06:00
aesctr-file-encrypt.c Add missing wc_AesInit calls. 2023-11-30 15:14:05 -06:00
aesgcm-file-encrypt.c Clarify aesgcm-file-encrypt demo 2025-05-13 17:00:40 -05:00
aesgcm-file-encrypt.sh Add Benchmark scripts 2023-03-20 09:03:55 -07:00
aesgcm-oneshot.c AES-GCM one shot example 2024-08-08 12:23:06 +10:00
plot_data.gp Add Benchmark scripts 2023-03-20 09:03:55 -07:00

README.md

How to use aes-file-encrypt.c

  1. a. Compile wolfSSL with ./configure --enable-pwdbased, run 'make', and then install by typing 'sudo make install'. b. In the crypto/aes directory run the Makefile by typing 'make'.

  2. Make a file to encode. Can be any file (ex. .txt .in .out .file etc.)

  3. run the executable, for help run with -h flag. Basic command is as follows:

    ./aes-file-encrypt <-option> <KeySize> -i <input.file> -o <output.file>
    
    KeySize (in bits) allowed values: 128, 192, 256
    

    typing -e for option will encrypt the input.file onto the output.file. typing -d for option will decrypt the input.file onto the output.file. NOTE: When decrypting make sure the key is the same used for the encryption, otherwise it won't decode correctly. Which is the idea. Only those with the key will be able to decode the message. If no key is entered into the command line, it will use "0123456789abcdef" by default.

  4. Running 'make clean' will delete the executable as well as any created files. Making sure that the only files left are 'aes-file-encrypt.c', 'Makefile', and 'README'.