diff options
Diffstat (limited to 'src/lib/libcrypto/x509/x509_vfy.c')
-rw-r--r-- | src/lib/libcrypto/x509/x509_vfy.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/src/lib/libcrypto/x509/x509_vfy.c b/src/lib/libcrypto/x509/x509_vfy.c index 701ec565e9..b0779db023 100644 --- a/src/lib/libcrypto/x509/x509_vfy.c +++ b/src/lib/libcrypto/x509/x509_vfy.c | |||
@@ -153,7 +153,6 @@ static int x509_subject_cmp(X509 **a, X509 **b) | |||
153 | int X509_verify_cert(X509_STORE_CTX *ctx) | 153 | int X509_verify_cert(X509_STORE_CTX *ctx) |
154 | { | 154 | { |
155 | X509 *x,*xtmp,*chain_ss=NULL; | 155 | X509 *x,*xtmp,*chain_ss=NULL; |
156 | X509_NAME *xn; | ||
157 | int bad_chain = 0; | 156 | int bad_chain = 0; |
158 | X509_VERIFY_PARAM *param = ctx->param; | 157 | X509_VERIFY_PARAM *param = ctx->param; |
159 | int depth,i,ok=0; | 158 | int depth,i,ok=0; |
@@ -205,7 +204,6 @@ int X509_verify_cert(X509_STORE_CTX *ctx) | |||
205 | */ | 204 | */ |
206 | 205 | ||
207 | /* If we are self signed, we break */ | 206 | /* If we are self signed, we break */ |
208 | xn=X509_get_issuer_name(x); | ||
209 | if (ctx->check_issued(ctx, x,x)) break; | 207 | if (ctx->check_issued(ctx, x,x)) break; |
210 | 208 | ||
211 | /* If we were passed a cert chain, use it first */ | 209 | /* If we were passed a cert chain, use it first */ |
@@ -242,7 +240,6 @@ int X509_verify_cert(X509_STORE_CTX *ctx) | |||
242 | 240 | ||
243 | i=sk_X509_num(ctx->chain); | 241 | i=sk_X509_num(ctx->chain); |
244 | x=sk_X509_value(ctx->chain,i-1); | 242 | x=sk_X509_value(ctx->chain,i-1); |
245 | xn = X509_get_subject_name(x); | ||
246 | if (ctx->check_issued(ctx, x, x)) | 243 | if (ctx->check_issued(ctx, x, x)) |
247 | { | 244 | { |
248 | /* we have a self signed certificate */ | 245 | /* we have a self signed certificate */ |
@@ -291,7 +288,6 @@ int X509_verify_cert(X509_STORE_CTX *ctx) | |||
291 | if (depth < num) break; | 288 | if (depth < num) break; |
292 | 289 | ||
293 | /* If we are self signed, we break */ | 290 | /* If we are self signed, we break */ |
294 | xn=X509_get_issuer_name(x); | ||
295 | if (ctx->check_issued(ctx,x,x)) break; | 291 | if (ctx->check_issued(ctx,x,x)) break; |
296 | 292 | ||
297 | ok = ctx->get_issuer(&xtmp, ctx, x); | 293 | ok = ctx->get_issuer(&xtmp, ctx, x); |
@@ -310,7 +306,6 @@ int X509_verify_cert(X509_STORE_CTX *ctx) | |||
310 | } | 306 | } |
311 | 307 | ||
312 | /* we now have our chain, lets check it... */ | 308 | /* we now have our chain, lets check it... */ |
313 | xn=X509_get_issuer_name(x); | ||
314 | 309 | ||
315 | /* Is last certificate looked up self signed? */ | 310 | /* Is last certificate looked up self signed? */ |
316 | if (!ctx->check_issued(ctx,x,x)) | 311 | if (!ctx->check_issued(ctx,x,x)) |