66
66
#include "internal.h"
67
67
68
68
69
- static int trust_1oidany (const X509_TRUST * trust , X509 * x , int flags );
70
- static int trust_compat (const X509_TRUST * trust , X509 * x , int flags );
69
+ static int trust_1oidany (const X509_TRUST * trust , X509 * x );
70
+ static int trust_compat (const X509_TRUST * trust , X509 * x );
71
71
72
- static int obj_trust (int id , X509 * x , int flags );
72
+ static int obj_trust (int id , X509 * x );
73
73
74
74
static const X509_TRUST trstandard [] = {
75
75
{X509_TRUST_COMPAT , 0 , trust_compat , (char * )"compatible" , 0 , NULL },
@@ -90,18 +90,18 @@ int X509_check_trust(X509 *x, int id, int flags) {
90
90
}
91
91
// We get this as a default value
92
92
if (id == 0 ) {
93
- int rv = obj_trust (NID_anyExtendedKeyUsage , x , 0 );
93
+ int rv = obj_trust (NID_anyExtendedKeyUsage , x );
94
94
if (rv != X509_TRUST_UNTRUSTED ) {
95
95
return rv ;
96
96
}
97
- return trust_compat (NULL , x , 0 );
97
+ return trust_compat (NULL , x );
98
98
}
99
99
int idx = X509_TRUST_get_by_id (id );
100
100
if (idx == -1 ) {
101
- return obj_trust (id , x , flags );
101
+ return obj_trust (id , x );
102
102
}
103
103
const X509_TRUST * pt = X509_TRUST_get0 (idx );
104
- return pt -> check_trust (pt , x , flags );
104
+ return pt -> check_trust (pt , x );
105
105
}
106
106
107
107
int X509_TRUST_get_count (void ) { return OPENSSL_ARRAY_SIZE (trstandard ); }
@@ -139,16 +139,16 @@ char *X509_TRUST_get0_name(const X509_TRUST *xp) { return xp->name; }
139
139
140
140
int X509_TRUST_get_trust (const X509_TRUST * xp ) { return xp -> trust ; }
141
141
142
- static int trust_1oidany (const X509_TRUST * trust , X509 * x , int flags ) {
142
+ static int trust_1oidany (const X509_TRUST * trust , X509 * x ) {
143
143
if (x -> aux && (x -> aux -> trust || x -> aux -> reject )) {
144
- return obj_trust (trust -> arg1 , x , flags );
144
+ return obj_trust (trust -> arg1 , x );
145
145
}
146
146
// we don't have any trust settings: for compatibility we return trusted
147
147
// if it is self signed
148
- return trust_compat (trust , x , flags );
148
+ return trust_compat (trust , x );
149
149
}
150
150
151
- static int trust_compat (const X509_TRUST * trust , X509 * x , int flags ) {
151
+ static int trust_compat (const X509_TRUST * trust , X509 * x ) {
152
152
if (!x509v3_cache_extensions (x )) {
153
153
return X509_TRUST_UNTRUSTED ;
154
154
}
@@ -159,7 +159,7 @@ static int trust_compat(const X509_TRUST *trust, X509 *x, int flags) {
159
159
}
160
160
}
161
161
162
- static int obj_trust (int id , X509 * x , int flags ) {
162
+ static int obj_trust (int id , X509 * x ) {
163
163
ASN1_OBJECT * obj ;
164
164
size_t i ;
165
165
X509_CERT_AUX * ax ;
0 commit comments