diff options
author | Paul Moore <pmoore@redhat.com> | 2014-08-05 15:44:22 -0400 |
---|---|---|
committer | Paul Moore <pmoore@redhat.com> | 2014-08-05 15:44:22 -0400 |
commit | aa9e0de81b5b257f6dae48efe2ed5f255f066497 (patch) | |
tree | 9b0b791d5912368006115427e74105cfe26750bd /security/keys/keyring.c | |
parent | 4fbe63d1c773cceef3fe1f6ed0c9c268f4f24760 (diff) | |
parent | 19583ca584d6f574384e17fe7613dfaeadcdc4a6 (diff) | |
download | linux-aa9e0de81b5b257f6dae48efe2ed5f255f066497.tar.gz linux-aa9e0de81b5b257f6dae48efe2ed5f255f066497.tar.bz2 linux-aa9e0de81b5b257f6dae48efe2ed5f255f066497.zip |
Merge tag 'v3.16' into next
Linux 3.16
Diffstat (limited to 'security/keys/keyring.c')
-rw-r--r-- | security/keys/keyring.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/security/keys/keyring.c b/security/keys/keyring.c index 2fb2576dc644..9cf2575f0d97 100644 --- a/security/keys/keyring.c +++ b/security/keys/keyring.c @@ -541,7 +541,7 @@ static int keyring_search_iterator(const void *object, void *iterator_data) /* key must have search permissions */ if (!(ctx->flags & KEYRING_SEARCH_NO_CHECK_PERM) && key_task_permission(make_key_ref(key, ctx->possessed), - ctx->cred, KEY_SEARCH) < 0) { + ctx->cred, KEY_NEED_SEARCH) < 0) { ctx->result = ERR_PTR(-EACCES); kleave(" = %d [!perm]", ctx->skipped_ret); goto skipped; @@ -721,7 +721,7 @@ ascend_to_node: /* Search a nested keyring */ if (!(ctx->flags & KEYRING_SEARCH_NO_CHECK_PERM) && key_task_permission(make_key_ref(key, ctx->possessed), - ctx->cred, KEY_SEARCH) < 0) + ctx->cred, KEY_NEED_SEARCH) < 0) continue; /* stack the current position */ @@ -843,7 +843,7 @@ key_ref_t keyring_search_aux(key_ref_t keyring_ref, return ERR_PTR(-ENOTDIR); if (!(ctx->flags & KEYRING_SEARCH_NO_CHECK_PERM)) { - err = key_task_permission(keyring_ref, ctx->cred, KEY_SEARCH); + err = key_task_permission(keyring_ref, ctx->cred, KEY_NEED_SEARCH); if (err < 0) return ERR_PTR(err); } @@ -973,7 +973,7 @@ struct key *find_keyring_by_name(const char *name, bool skip_perm_check) if (!skip_perm_check && key_permission(make_key_ref(keyring, 0), - KEY_SEARCH) < 0) + KEY_NEED_SEARCH) < 0) continue; /* we've got a match but we might end up racing with |