From c62ce78b8ae6961c9d1dda092781b6988488a135 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Fri, 8 Aug 2014 08:47:54 +0200 Subject: trust: Don't use invalid public keys for looking up stapled extensions https://bugs.freedesktop.org/show_bug.cgi?id=82328 --- trust/builder.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'trust') diff --git a/trust/builder.c b/trust/builder.c index f7ea86a..fd7a662 100644 --- a/trust/builder.c +++ b/trust/builder.c @@ -125,7 +125,7 @@ lookup_extension (p11_builder *builder, { CKA_INVALID }, }; - if (public_key == NULL) + if (public_key == NULL || public_key->type == CKA_INVALID) public_key = p11_attrs_find_valid (cert, CKA_X_PUBLIC_KEY_INFO); /* Look for a stapled certificate extension */ -- cgit v1.1