Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(179)

Side by Side Diff: openssl/crypto/x509/x509_trs.c

Issue 9254031: Upgrade chrome's OpenSSL to same version Android ships with. (Closed) Base URL: http://src.chromium.org/svn/trunk/deps/third_party/openssl/
Patch Set: '' Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « openssl/crypto/x509/x509_set.c ('k') | openssl/crypto/x509/x509_txt.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* x509_trs.c */ 1 /* x509_trs.c */
2 /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 2 /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
3 * project 1999. 3 * project 1999.
4 */ 4 */
5 /* ==================================================================== 5 /* ====================================================================
6 * Copyright (c) 1999 The OpenSSL Project. All rights reserved. 6 * Copyright (c) 1999 The OpenSSL Project. All rights reserved.
7 * 7 *
8 * Redistribution and use in source and binary forms, with or without 8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions 9 * modification, are permitted provided that the following conditions
10 * are met: 10 * are met:
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 * value to get an index into the table 77 * value to get an index into the table
78 */ 78 */
79 79
80 static X509_TRUST trstandard[] = { 80 static X509_TRUST trstandard[] = {
81 {X509_TRUST_COMPAT, 0, trust_compat, "compatible", 0, NULL}, 81 {X509_TRUST_COMPAT, 0, trust_compat, "compatible", 0, NULL},
82 {X509_TRUST_SSL_CLIENT, 0, trust_1oidany, "SSL Client", NID_client_auth, NULL}, 82 {X509_TRUST_SSL_CLIENT, 0, trust_1oidany, "SSL Client", NID_client_auth, NULL},
83 {X509_TRUST_SSL_SERVER, 0, trust_1oidany, "SSL Server", NID_server_auth, NULL}, 83 {X509_TRUST_SSL_SERVER, 0, trust_1oidany, "SSL Server", NID_server_auth, NULL},
84 {X509_TRUST_EMAIL, 0, trust_1oidany, "S/MIME email", NID_email_protect, NULL}, 84 {X509_TRUST_EMAIL, 0, trust_1oidany, "S/MIME email", NID_email_protect, NULL},
85 {X509_TRUST_OBJECT_SIGN, 0, trust_1oidany, "Object Signer", NID_code_sign, NULL} , 85 {X509_TRUST_OBJECT_SIGN, 0, trust_1oidany, "Object Signer", NID_code_sign, NULL} ,
86 {X509_TRUST_OCSP_SIGN, 0, trust_1oid, "OCSP responder", NID_OCSP_sign, NULL}, 86 {X509_TRUST_OCSP_SIGN, 0, trust_1oid, "OCSP responder", NID_OCSP_sign, NULL},
87 {X509_TRUST_OCSP_REQUEST, 0, trust_1oid, "OCSP request", NID_ad_OCSP, NULL} 87 {X509_TRUST_OCSP_REQUEST, 0, trust_1oid, "OCSP request", NID_ad_OCSP, NULL},
88 {X509_TRUST_TSA, 0, trust_1oidany, "TSA server", NID_time_stamp, NULL}
88 }; 89 };
89 90
90 #define X509_TRUST_COUNT (sizeof(trstandard)/sizeof(X509_TRUST)) 91 #define X509_TRUST_COUNT (sizeof(trstandard)/sizeof(X509_TRUST))
91 92
92 IMPLEMENT_STACK_OF(X509_TRUST) 93 IMPLEMENT_STACK_OF(X509_TRUST)
93 94
94 static STACK_OF(X509_TRUST) *trtable = NULL; 95 static STACK_OF(X509_TRUST) *trtable = NULL;
95 96
96 static int tr_cmp(const X509_TRUST * const *a, 97 static int tr_cmp(const X509_TRUST * const *a,
97 const X509_TRUST * const *b) 98 const X509_TRUST * const *b)
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
278 } 279 }
279 if(ax->trust) { 280 if(ax->trust) {
280 for(i = 0; i < sk_ASN1_OBJECT_num(ax->trust); i++) { 281 for(i = 0; i < sk_ASN1_OBJECT_num(ax->trust); i++) {
281 obj = sk_ASN1_OBJECT_value(ax->trust, i); 282 obj = sk_ASN1_OBJECT_value(ax->trust, i);
282 if(OBJ_obj2nid(obj) == id) return X509_TRUST_TRUSTED; 283 if(OBJ_obj2nid(obj) == id) return X509_TRUST_TRUSTED;
283 } 284 }
284 } 285 }
285 return X509_TRUST_UNTRUSTED; 286 return X509_TRUST_UNTRUSTED;
286 } 287 }
287 288
OLDNEW
« no previous file with comments | « openssl/crypto/x509/x509_set.c ('k') | openssl/crypto/x509/x509_txt.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698