diff options
author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2020-08-08 18:46:43 +0200 |
---|---|---|
committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2020-10-18 19:08:32 +0200 |
commit | 2037b837f81485770fcb066adea70b1d22e9b727 (patch) | |
tree | 41d15b95f38843dfe5fb45327c25d3a116731b05 /utils/imxtools/sbtools/crypto.h | |
parent | 815b289cb3438ed566b3e9dc5074fe12e4b98f46 (diff) | |
download | rockbox-2037b837f81485770fcb066adea70b1d22e9b727.tar.gz rockbox-2037b837f81485770fcb066adea70b1d22e9b727.zip |
sbtools: convert crypto to libtomcrypt.
Replace the use of crypto++ with tomcrypt, which is much smaller and C.
This gets rid of various build issues for systems that don't ship
crypo++ (i.e. everything except Linux.)
Change-Id: Ic0799e17b94935c71b14765cf9a2a7ea2b0adc7a
Diffstat (limited to 'utils/imxtools/sbtools/crypto.h')
-rw-r--r-- | utils/imxtools/sbtools/crypto.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/utils/imxtools/sbtools/crypto.h b/utils/imxtools/sbtools/crypto.h index bdb94bb881..446891b7f2 100644 --- a/utils/imxtools/sbtools/crypto.h +++ b/utils/imxtools/sbtools/crypto.h | |||
@@ -77,11 +77,12 @@ int crypto_apply( | |||
77 | uint32_t crc(uint8_t *data, int size); | 77 | uint32_t crc(uint8_t *data, int size); |
78 | uint32_t crc_continue(uint32_t previous_crc, uint8_t *data, int size); | 78 | uint32_t crc_continue(uint32_t previous_crc, uint8_t *data, int size); |
79 | 79 | ||
80 | #include "tomcrypt.h" | ||
80 | /* sha1.c */ | 81 | /* sha1.c */ |
81 | struct sha_1_params_t | 82 | struct sha_1_params_t |
82 | { | 83 | { |
83 | uint8_t hash[20]; /* final hash */ | 84 | uint8_t hash[20]; /* final hash */ |
84 | void *object; /* pointer to CryptoPP::SHA1 object */ | 85 | hash_state state; /* libtomcrypt state */ |
85 | }; | 86 | }; |
86 | 87 | ||
87 | void sha_1_init(struct sha_1_params_t *params); | 88 | void sha_1_init(struct sha_1_params_t *params); |