Home
last modified time | relevance | path

Searched refs:ext4_key (Results 1 – 1 of 1) sorted by relevance

/system/vold/
DExt4Crypt.cpp124 static bool fill_key(const std::string& key, ext4_encryption_key* ext4_key) { in fill_key() argument
129 static_assert(EXT4_AES_256_XTS_KEY_SIZE <= sizeof(ext4_key->raw), "Key too long!"); in fill_key()
130 ext4_key->mode = EXT4_ENCRYPTION_MODE_AES_256_XTS; in fill_key()
131 ext4_key->size = key.size(); in fill_key()
132 memset(ext4_key->raw, 0, sizeof(ext4_key->raw)); in fill_key()
133 memcpy(ext4_key->raw, key.data(), key.size()); in fill_key()
159 ext4_encryption_key ext4_key; in install_key() local
160 if (!fill_key(key, &ext4_key)) return false; in install_key()
161 *raw_ref = generate_key_ref(ext4_key.raw, ext4_key.size); in install_key()
166 add_key("logon", ref.c_str(), (void*)&ext4_key, sizeof(ext4_key), device_keyring); in install_key()