mirror of
https://github.com/markqvist/OpenModem.git
synced 2025-06-19 03:49:26 -04:00
EEPROM configuration
This commit is contained in:
parent
b3b1a9b253
commit
474f3ad4d2
13 changed files with 429 additions and 131 deletions
|
@ -13,6 +13,7 @@
|
|||
#define PATH_ENTROPY_INDEX "OpenModem/entropy.index"
|
||||
#define PATH_ENTROPY_SOURCE "OpenModem/entropy.source"
|
||||
#define PATH_AES_128_KEY "OpenModem/aes128.key"
|
||||
#define PATH_CRYPTO_DISABLE "OpenModem/aes128.disable"
|
||||
|
||||
#define CRYPTO_KEY_SIZE_BITS 128
|
||||
#define CRYPTO_KEY_SIZE (CRYPTO_KEY_SIZE_BITS/8)
|
||||
|
@ -20,9 +21,13 @@
|
|||
#define CRYPTO_HMAC_SIZE (CRYPTO_HMAC_SIZE_BITS/8)
|
||||
#define MAX_IVS_PER_ENTROPY_BLOCK 128
|
||||
|
||||
#define CRYPTO_WAIT_TIMEOUT_MS 2000
|
||||
|
||||
uint8_t crypto_work_block[CRYPTO_KEY_SIZE];
|
||||
|
||||
void crypto_init(void);
|
||||
bool crypto_wait(void);
|
||||
|
||||
bool crypto_enabled(void);
|
||||
bool crypto_generate_iv(void);
|
||||
uint8_t* crypto_get_iv(void);
|
||||
|
@ -35,6 +40,7 @@ void crypto_decrypt_block(uint8_t block[CRYPTO_KEY_SIZE]);
|
|||
|
||||
void crypto_test(void);
|
||||
|
||||
bool should_disable_enryption(void);
|
||||
bool load_key(void);
|
||||
bool load_entropy(void);
|
||||
bool load_entropy_index(void);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue