From 25a713873c8f8d37f7ebbadfbf1ebfaf4bac106b Mon Sep 17 00:00:00 2001 From: Paul Crowley Date: Mon, 25 Jul 2016 15:55:36 -0700 Subject: [PATCH] Don't try to fixate CE keys for ephemeral users Ephemeral users don't have keys stored on disk at all, so it's neither necessary nor possible to manipulate the disk keys here. Bug: 30038313 Change-Id: Idc7ec1bfe1e8a6ffa6cee2f284dbe378097b08da --- Ext4Crypt.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Ext4Crypt.cpp b/Ext4Crypt.cpp index 7d65364..cb41295 100644 --- a/Ext4Crypt.cpp +++ b/Ext4Crypt.cpp @@ -614,6 +614,7 @@ bool e4crypt_add_user_key_auth(userid_t user_id, int serial, const char* token_h bool e4crypt_fixate_newest_user_key_auth(userid_t user_id) { LOG(DEBUG) << "e4crypt_fixate_newest_user_key_auth " << user_id; if (!e4crypt_is_native()) return true; + if (s_ephemeral_users.count(user_id) != 0) return true; auto const directory_path = get_ce_key_directory_path(user_id); auto const paths = get_ce_key_paths(directory_path); if (paths.empty()) {