Searched refs:GCM_NONCE_BYTES (Results 1 – 1 of 1) sorted by relevance
60 static constexpr size_t GCM_NONCE_BYTES = 12; variable255 if (!checkSize("nonce", nonce.size(), GCM_NONCE_BYTES)) return false; in encryptWithKeymasterKey()271 auto nonce = ciphertext.substr(0, GCM_NONCE_BYTES); in decryptWithKeymasterKey()272 auto bodyAndMac = ciphertext.substr(GCM_NONCE_BYTES); in decryptWithKeymasterKey()351 if (!readRandomBytesOrLog(GCM_NONCE_BYTES, ciphertext)) return false; in encryptWithoutKeymaster()364 ciphertext->resize(GCM_NONCE_BYTES + plaintext.size() + GCM_MAC_BYTES); in encryptWithoutKeymaster()367 ctx.get(), reinterpret_cast<uint8_t*>(&(*ciphertext)[0] + GCM_NONCE_BYTES), in encryptWithoutKeymaster()378 reinterpret_cast<uint8_t*>(&(*ciphertext)[0] + GCM_NONCE_BYTES + plaintext.size()), in encryptWithoutKeymaster()388 reinterpret_cast<uint8_t*>(&(*ciphertext)[0] + GCM_NONCE_BYTES + in encryptWithoutKeymaster()398 if (ciphertext.size() < GCM_NONCE_BYTES + GCM_MAC_BYTES) { in decryptWithoutKeymaster()[all …]