Skip to content

Commit 62f444e

Browse files
committed
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
2 parents 07c0db7 + e543589 commit 62f444e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

crypto/asymmetric_keys/pkcs7_trust.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,8 @@ int pkcs7_validate_trust(struct pkcs7_message *pkcs7,
178178
int cached_ret = -ENOKEY;
179179
int ret;
180180

181+
*_trusted = false;
182+
181183
for (p = pkcs7->certs; p; p = p->next)
182184
p->seen = false;
183185

0 commit comments

Comments
 (0)