| 35 | } |
| 36 | |
| 37 | void StreamCipherKey::allocGlobalCipherKey() { |
| 38 | if (StreamCipherKey::isGlobalKeyPresent()) { |
| 39 | return; |
| 40 | } |
| 41 | StreamCipherKey::globalKeyId = deterministicRandom()->randomUniqueID(); |
| 42 | StreamCipherKey::globalKey = std::make_unique<StreamCipherKey>(AES_256_KEY_LENGTH); |
| 43 | StreamCipherKey::cipherKeys[StreamCipherKey::globalKeyId] = StreamCipherKey::globalKey.get(); |
| 44 | } |
| 45 | |
| 46 | void StreamCipherKey::initializeGlobalRandomTestKey() { |
| 47 | if (!StreamCipherKey::isGlobalKeyPresent()) { |
nothing calls this directly
no test coverage detected