summaryrefslogtreecommitdiff
path: root/crypto/asymmetric_keys/signature.c
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2016-04-06 16:13:33 +0100
committerDavid Howells <dhowells@redhat.com>2016-04-06 16:13:33 +0100
commiteb4c866ec4450cf652162de8274563c87bf4e154 (patch)
treef60f40fff7f042ae0f3e281062f3f1fab53f8812 /crypto/asymmetric_keys/signature.c
parent18f467573e22d9bb30ac7413d49a2c0390ab98bf (diff)
downloadlinux-crypto-eb4c866ec4450cf652162de8274563c87bf4e154.tar.gz
linux-crypto-eb4c866ec4450cf652162de8274563c87bf4e154.zip
KEYS: Add identifier pointers to public_key_signature struct
Add key identifier pointers to public_key_signature struct so that they can be used to retain the identifier of the key to be used to verify the signature in both PKCS#7 and X.509. Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to '')
-rw-r--r--crypto/asymmetric_keys/signature.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/crypto/asymmetric_keys/signature.c b/crypto/asymmetric_keys/signature.c
index 3beee397..11b7ba17 100644
--- a/crypto/asymmetric_keys/signature.c
+++ b/crypto/asymmetric_keys/signature.c
@@ -24,7 +24,11 @@
*/
void public_key_signature_free(struct public_key_signature *sig)
{
+ int i;
+
if (sig) {
+ for (i = 0; i < ARRAY_SIZE(sig->auth_ids); i++)
+ kfree(sig->auth_ids[i]);
kfree(sig->s);
kfree(sig->digest);
kfree(sig);