]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KEYS: trusted: Add generic trusted keys framework
authorSumit Garg <sumit.garg@linaro.org>
Mon, 1 Mar 2021 13:11:24 +0000 (18:41 +0530)
committerJarkko Sakkinen <jarkko@kernel.org>
Fri, 9 Apr 2021 05:58:31 +0000 (08:58 +0300)
commit830027e2cb55ac7e0a6d718cf7686b3e6056c41c
tree9a57c86612b9aad4f948a87419a417624adca480
parent5d93625a76dabdab156a1331d50db61fb67220d2
KEYS: trusted: Add generic trusted keys framework

Current trusted keys framework is tightly coupled to use TPM device as
an underlying implementation which makes it difficult for implementations
like Trusted Execution Environment (TEE) etc. to provide trusted keys
support in case platform doesn't posses a TPM device.

Add a generic trusted keys framework where underlying implementations
can be easily plugged in. Create struct trusted_key_ops to achieve this,
which contains necessary functions of a backend.

Also, define a module parameter in order to select a particular trust
source in case a platform support multiple trust sources. In case its
not specified then implementation itetrates through trust sources list
starting with TPM and assign the first trust source as a backend which
has initiazed successfully during iteration.

Note that current implementation only supports a single trust source at
runtime which is either selectable at compile time or during boot via
aforementioned module parameter.

Suggested-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: Sumit Garg <sumit.garg@linaro.org>
Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org>
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
Documentation/admin-guide/kernel-parameters.txt
include/keys/trusted-type.h
include/keys/trusted_tpm.h
security/keys/trusted-keys/Makefile
security/keys/trusted-keys/trusted_core.c [new file with mode: 0644]
security/keys/trusted-keys/trusted_tpm1.c