Revamp the simple password flag and rPi fixes (#1056)
MY_SIGNING_SIMPLE_PASSWD is now called MY_SECURITY_SIMPLE_PASSWD. MY_SIGNING_SIMPLE_PASSWD only affects signing, and a new flag, MY_ENCRYPTION_SIMPLE_PASSWD only affects encryption. MY_SECURITY_SIMPLE_PASSWD enable both these flags. The rPi port has been improved to support more security settings and it is now also possible to enable encryption for RFM69 transport. Documentation has been improved to provide a "Security" section under "Library customisation" which has a table that summarize all security related configuration flags, and the corresponding rPi configuration flags. The signing personalization documentation has been updated to include the procedure for rPi. Fixes #1055
This commit is contained in:
@@ -68,9 +68,9 @@ uint8_t _psk[16];
|
||||
bool transportInit(void)
|
||||
{
|
||||
#if defined(MY_RF24_ENABLE_ENCRYPTION)
|
||||
#ifdef MY_SIGNING_SIMPLE_PASSWD
|
||||
#ifdef MY_ENCRYPTION_SIMPLE_PASSWD
|
||||
memset(_psk, 0, 16);
|
||||
memcpy(_psk, MY_SIGNING_SIMPLE_PASSWD, strnlen(MY_SIGNING_SIMPLE_PASSWD, 16));
|
||||
memcpy(_psk, MY_ENCRYPTION_SIMPLE_PASSWD, strnlen(MY_ENCRYPTION_SIMPLE_PASSWD, 16));
|
||||
#else
|
||||
hwReadConfigBlock((void*)_psk, (void*)EEPROM_RF_ENCRYPTION_AES_KEY_ADDRESS, 16);
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user