mirror of
https://github.com/espressif/openthread.git
synced 2026-06-05 21:14:49 +00:00
[mac] clear mode2 key only on mac destruction
This commit is contained in:
@@ -134,6 +134,11 @@ public:
|
||||
*/
|
||||
explicit Mac(Instance &aInstance);
|
||||
|
||||
/**
|
||||
* Clears the Mode2Key on destruction.
|
||||
*/
|
||||
~Mac(void) { ClearMode2Key(); }
|
||||
|
||||
/**
|
||||
* Starts an IEEE 802.15.4 Active Scan.
|
||||
*
|
||||
|
||||
@@ -691,7 +691,6 @@ void KeyManager::DestroyTemporaryKeys(void)
|
||||
mMleKey.Clear();
|
||||
mKek.Clear();
|
||||
Get<Mac::SubMac>().ClearMacKeys();
|
||||
Get<Mac::Mac>().ClearMode2Key();
|
||||
}
|
||||
|
||||
void KeyManager::DestroyPersistentKeys(void) { Get<Crypto::Storage::KeyRefManager>().DestroyPersistentKeys(); }
|
||||
|
||||
Reference in New Issue
Block a user