Skip to content

Commit fd35f19

Browse files
mimizoharJames Morris
authored and
James Morris
committed
integrity: support new struct public_key_signature encoding field
On systems with IMA-appraisal enabled with a policy requiring file signatures, the "good" signature values are stored on the filesystem as extended attributes (security.ima). Signature verification failure would normally be limited to just a particular file (eg. executable), but during boot signature verification failure could result in a system hang. Defining and requiring a new public_key_signature field requires all callers of asymmetric signature verification to be updated to reflect the change. This patch updates the integrity asymmetric_verify() caller. Fixes: 82f94f2 ("KEYS: Provide software public key query function [ver #2]") Signed-off-by: Mimi Zohar <[email protected]> Cc: David Howells <[email protected]> Acked-by: Denis Kenzior <[email protected]> Signed-off-by: James Morris <[email protected]>
1 parent ccda4af commit fd35f19

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

security/integrity/digsig_asymmetric.c

+1
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ int asymmetric_verify(struct key *keyring, const char *sig,
106106

107107
pks.pkey_algo = "rsa";
108108
pks.hash_algo = hash_algo_name[hdr->hash_algo];
109+
pks.encoding = "pkcs1";
109110
pks.digest = (u8 *)data;
110111
pks.digest_size = datalen;
111112
pks.s = hdr->sig;

0 commit comments

Comments
 (0)