]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
integrity: Allow sigv3 verification on EVM_XATTR_PORTABLE_DIGSIG
authorStefan Berger <stefanb@linux.ibm.com>
Wed, 25 Mar 2026 00:10:51 +0000 (20:10 -0400)
committerMimi Zohar <zohar@linux.ibm.com>
Wed, 1 Apr 2026 14:16:53 +0000 (10:16 -0400)
Allow sigv3 verification on EVM_XATTR_PORTABLE_DIGSIG on RSA, ECDSA,
ECRDSA, and SM2 signatures.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
security/integrity/digsig_asymmetric.c

index 6b21b9bf829e1048f5f7579e8c60332c3fc0edfc..6e68ec3becbd1eed42505515816aff0d243e8cbf 100644 (file)
@@ -154,7 +154,8 @@ static int calc_file_id_hash(enum evm_ima_xattr_type type,
        size_t file_id_size;
        int rc;
 
-       if (type != IMA_VERITY_DIGSIG && type != EVM_IMA_XATTR_DIGSIG)
+       if (type != IMA_VERITY_DIGSIG && type != EVM_IMA_XATTR_DIGSIG &&
+           type != EVM_XATTR_PORTABLE_DIGSIG)
                return -EINVAL;
 
        tfm = crypto_alloc_shash(hash_algo_name[algo], 0, 0);