diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-03-30 13:28:34 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-03-30 13:28:34 -0500 |
commit | 6790562907c0ec32ea66e082ec901b5e35da5e2b (patch) | |
tree | eb8b2c8b4fb157367f047ae0db3a517c4f38311b /crypto/asymmetric_keys | |
parent | f349a25c7c6b753176540d10e6c243047faefa3a (diff) | |
parent | 98c3e8a2a8098c06ef97f033ee0e59638282e49d (diff) | |
download | linux-crypto-6790562907c0ec32ea66e082ec901b5e35da5e2b.tar.gz linux-crypto-6790562907c0ec32ea66e082ec901b5e35da5e2b.zip |
Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto fix from Herbert Xu:
"This fixes a bug in pkcs7_validate_trust and its users where the
output value may in fact be taken from uninitialised memory"
* 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
PKCS#7: pkcs7_validate_trust(): initialize the _trusted output argument
Diffstat (limited to '')
-rw-r--r-- | crypto/asymmetric_keys/pkcs7_trust.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/asymmetric_keys/pkcs7_trust.c b/crypto/asymmetric_keys/pkcs7_trust.c index 3bbdcc79..7d7a39b4 100644 --- a/crypto/asymmetric_keys/pkcs7_trust.c +++ b/crypto/asymmetric_keys/pkcs7_trust.c @@ -178,6 +178,8 @@ int pkcs7_validate_trust(struct pkcs7_message *pkcs7, int cached_ret = -ENOKEY; int ret; + *_trusted = false; + for (p = pkcs7->certs; p; p = p->next) p->seen = false; |