diff options
Diffstat (limited to 'security/keys/key.c')
-rw-r--r-- | security/keys/key.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/security/keys/key.c b/security/keys/key.c index ab7997ded725..07a87311055c 100644 --- a/security/keys/key.c +++ b/security/keys/key.c @@ -429,8 +429,11 @@ static int __key_instantiate_and_link(struct key *key, awaken = 1; /* and link it into the destination keyring */ - if (keyring) + if (keyring) { + set_bit(KEY_FLAG_KEEP, &key->flags); + __key_link(key, _edit); + } /* disable the authorisation key */ if (authkey) |