mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 17:47:41 +02:00
A: request_key() B: KEYCTL_INSTANTIATE_IOV
================ =========================
create auth key
store rka in auth key
wait for helper
get auth key
load rka from auth key
copy user payload
sleep on #PF
helper completed
detach and free rka
destroy auth key
wake up
use rka->target_key
**USE-AFTER-FREE**
Give request_key_auth payloads a refcount. Take a payload reference while
authkey->sem stabilizes the payload and revocation state. Hold that
reference across the instantiate and reject paths. Drop the auth key
owning reference from revoke and destroy.
[jarkko: Replaced the first two paragraphs of text with an actual
concurrency scenario.]
Cc: stable@vger.kernel.org # v5.10+
Fixes:
|
||
|---|---|---|
| .. | ||
| asymmetric-parser.h | ||
| asymmetric-subtype.h | ||
| asymmetric-type.h | ||
| big_key-type.h | ||
| ceph-type.h | ||
| dns_resolver-type.h | ||
| encrypted-type.h | ||
| keyring-type.h | ||
| request_key_auth-type.h | ||
| rxrpc-type.h | ||
| system_keyring.h | ||
| trusted_caam.h | ||
| trusted_dcp.h | ||
| trusted_pkwm.h | ||
| trusted_tee.h | ||
| trusted_tpm.h | ||
| trusted-type.h | ||
| user-type.h | ||