source:
trunk/server/common/patches/gnutls-2.12.x-cve-2014-0092.patch
@
2507
Last change on this file since 2507 was 2507, checked in by achernya, 11 years ago | |
---|---|
File size: 2.1 KB |
-
lib/x509/verify.c
diff --git a/lib/x509/verify.c b/lib/x509/verify.c index 2efcebf..e9c704d 100644
a b check_if_ca (gnutls_x509_crt_t cert, gnutls_x509_crt_t issuer, 141 141 if (result < 0) 142 142 { 143 143 gnutls_assert (); 144 goto cleanup;144 goto fail; 145 145 } 146 146 147 147 result = … … check_if_ca (gnutls_x509_crt_t cert, gnutls_x509_crt_t issuer, 150 150 if (result < 0) 151 151 { 152 152 gnutls_assert (); 153 goto cleanup;153 goto fail; 154 154 } 155 155 156 156 result = … … check_if_ca (gnutls_x509_crt_t cert, gnutls_x509_crt_t issuer, 158 158 if (result < 0) 159 159 { 160 160 gnutls_assert (); 161 goto cleanup;161 goto fail; 162 162 } 163 163 164 164 result = … … check_if_ca (gnutls_x509_crt_t cert, gnutls_x509_crt_t issuer, 166 166 if (result < 0) 167 167 { 168 168 gnutls_assert (); 169 goto cleanup;169 goto fail; 170 170 } 171 171 172 172 /* If the subject certificate is the same as the issuer … … check_if_ca (gnutls_x509_crt_t cert, gnutls_x509_crt_t issuer, 206 206 else 207 207 gnutls_assert (); 208 208 209 fail: 209 210 result = 0; 210 211 211 212 cleanup: … … _gnutls_verify_certificate2 (gnutls_x509_crt_t cert, 330 331 gnutls_datum_t cert_signed_data = { NULL, 0 }; 331 332 gnutls_datum_t cert_signature = { NULL, 0 }; 332 333 gnutls_x509_crt_t issuer = NULL; 333 int issuer_version, result ;334 int issuer_version, result = 0; 334 335 335 336 if (output) 336 337 *output = 0; … … _gnutls_verify_certificate2 (gnutls_x509_crt_t cert, 363 364 if (issuer_version < 0) 364 365 { 365 366 gnutls_assert (); 366 return issuer_version;367 return 0; 367 368 } 368 369 369 370 if (!(flags & GNUTLS_VERIFY_DISABLE_CA_SIGN) && … … _gnutls_verify_certificate2 (gnutls_x509_crt_t cert, 385 386 if (result < 0) 386 387 { 387 388 gnutls_assert (); 389 result = 0; 388 390 goto cleanup; 389 391 } 390 392 … … _gnutls_verify_certificate2 (gnutls_x509_crt_t cert, 393 395 if (result < 0) 394 396 { 395 397 gnutls_assert (); 398 result = 0; 396 399 goto cleanup; 397 400 } 398 401 … … _gnutls_verify_certificate2 (gnutls_x509_crt_t cert, 410 413 else if (result < 0) 411 414 { 412 415 gnutls_assert(); 416 result = 0; 413 417 goto cleanup; 414 418 } 415 419
Note: See TracBrowser
for help on using the repository browser.