mirror-linux/include/keys
Srish Srinivasan c99fcb0d73 keys/trusted_keys: establish PKWM as a trusted source
The wrapping key does not exist by default and is generated by the
hypervisor as a part of PKWM initialization. This key is then persisted by
the hypervisor and is used to wrap trusted keys. These are variable length
symmetric keys, which in the case of PowerVM Key Wrapping Module (PKWM) are
generated using the kernel RNG. PKWM can be used as a trust source through
the following example keyctl commands:

keyctl add trusted my_trusted_key "new 32" @u

Use the wrap_flags command option to set the secure boot requirement for
the wrapping request through the following keyctl commands

case1: no secure boot requirement. (default)
keyctl usage: keyctl add trusted my_trusted_key "new 32" @u
	      OR
	      keyctl add trusted my_trusted_key "new 32 wrap_flags=0x00" @u

case2: secure boot required to in either audit or enforce mode. set bit 0
keyctl usage: keyctl add trusted my_trusted_key "new 32 wrap_flags=0x01" @u

case3: secure boot required to be in enforce mode. set bit 1
keyctl usage: keyctl add trusted my_trusted_key "new 32 wrap_flags=0x02" @u

NOTE:
-> Setting the secure boot requirement is NOT a must.
-> Only either of the secure boot requirement options should be set. Not
both.
-> All the other bits are required to be not set.
-> Set the kernel parameter trusted.source=pkwm to choose PKWM as the
backend for trusted keys implementation.
-> CONFIG_PSERIES_PLPKS must be enabled to build PKWM.

Add PKWM, which is a combination of IBM PowerVM and Power LPAR Platform
KeyStore, as a new trust source for trusted keys.

Signed-off-by: Srish Srinivasan <ssrish@linux.ibm.com>
Tested-by: Nayna Jain <nayna@linux.ibm.com>
Reviewed-by: Mimi Zohar <zohar@linux.ibm.com>
Reviewed-by: Nayna Jain <nayna@linux.ibm.com>
Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org>
Signed-off-by: Madhavan Srinivasan <maddy@linux.ibm.com>
Link: https://patch.msgid.link/20260127145228.48320-6-ssrish@linux.ibm.com
2026-01-30 09:27:26 +05:30
..
asymmetric-parser.h KEYS: Add forward declaration in asymmetric-parser.h 2023-06-23 16:15:37 +08:00
asymmetric-subtype.h docs: crypto: convert asymmetric-keys.txt to ReST 2020-06-19 14:03:46 -06:00
asymmetric-type.h keys: Annotate struct asymmetric_key_id with __counted_by 2025-10-31 17:43:56 +08:00
big_key-type.h keys: Implement update for the big_key type 2020-06-02 17:22:31 +01:00
ceph-type.h
dns_resolver-type.h KEYS: Remove unused declarations 2024-09-20 18:28:26 +03:00
encrypted-type.h encrypted-keys: Replace HTTP links with HTTPS ones 2021-01-21 16:16:09 +00:00
keyring-type.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
request_key_auth-type.h request_key improvements 2019-07-08 19:19:37 -07:00
rxrpc-type.h rxrpc: Add YFS RxGK (GSSAPI) security class 2025-04-14 17:36:41 -07:00
system_keyring.h keys: drop shadowing dead prototype 2025-01-21 11:25:23 +02:00
trusted-type.h keys/trusted_keys: establish PKWM as a trusted source 2026-01-30 09:27:26 +05:30
trusted_caam.h KEYS: trusted: Introduce support for NXP CAAM-based trusted keys 2022-05-23 18:47:50 +03:00
trusted_dcp.h KEYS: trusted: Introduce NXP DCP-backed trusted keys 2024-05-09 18:29:03 +03:00
trusted_pkwm.h keys/trusted_keys: establish PKWM as a trusted source 2026-01-30 09:27:26 +05:30
trusted_tee.h KEYS: trusted: Introduce TEE based Trusted Keys 2021-04-14 16:30:30 +03:00
trusted_tpm.h KEYS: trusted_tpm1: Move private functionality out of public header 2025-09-27 21:05:06 +03:00
user-type.h KEYS: Replace zero-length array with flexible-array 2020-06-02 17:22:31 +01:00