• Home
  • Raw
  • Download

Lines Matching refs:crt

136 static int set_cn(X509 *crt, ...)  in set_cn()  argument
141 va_start(ap, crt); in set_cn()
156 if (!X509_set_subject_name(crt, n)) in set_cn()
172 static int set_altname(X509 *crt, ...) in set_altname() argument
179 va_start(ap, crt); in set_altname()
211 if (!X509_add1_ext_i2d(crt, NID_subject_alt_name, gens, 0, 0)) in set_altname()
222 static int set_cn1(X509 *crt, const char *name) in set_cn1() argument
224 return set_cn(crt, NID_commonName, name, 0); in set_cn1()
227 static int set_cn_and_email(X509 *crt, const char *name) in set_cn_and_email() argument
229 return set_cn(crt, NID_commonName, name, in set_cn_and_email()
233 static int set_cn2(X509 *crt, const char *name) in set_cn2() argument
235 return set_cn(crt, NID_commonName, "dummy value", in set_cn2()
239 static int set_cn3(X509 *crt, const char *name) in set_cn3() argument
241 return set_cn(crt, NID_commonName, name, in set_cn3()
245 static int set_email1(X509 *crt, const char *name) in set_email1() argument
247 return set_cn(crt, NID_pkcs9_emailAddress, name, 0); in set_email1()
250 static int set_email2(X509 *crt, const char *name) in set_email2() argument
252 return set_cn(crt, NID_pkcs9_emailAddress, "dummy@example.com", in set_email2()
256 static int set_email3(X509 *crt, const char *name) in set_email3() argument
258 return set_cn(crt, NID_pkcs9_emailAddress, name, in set_email3()
262 static int set_email_and_cn(X509 *crt, const char *name) in set_email_and_cn() argument
264 return set_cn(crt, NID_pkcs9_emailAddress, name, in set_email_and_cn()
268 static int set_altname_dns(X509 *crt, const char *name) in set_altname_dns() argument
270 return set_altname(crt, GEN_DNS, name, 0); in set_altname_dns()
273 static int set_altname_email(X509 *crt, const char *name) in set_altname_email() argument
275 return set_altname(crt, GEN_EMAIL, name, 0); in set_altname_email()
302 X509 *crt = NULL; in make_cert() local
304 crt = X509_new(); in make_cert()
305 if (crt == NULL) in make_cert()
307 if (!X509_set_version(crt, 3)) in make_cert()
309 ret = crt; in make_cert()
310 crt = NULL; in make_cert()
333 static void run_cert(X509 *crt, const char *nameincert, in run_cert() argument
344 ret = X509_check_host(crt, name, namelen, 0, NULL); in run_cert()
358 ret = X509_check_host(crt, name, namelen, in run_cert()
373 ret = X509_check_email(crt, name, namelen, 0); in run_cert()
394 bssl::UniquePtr<X509> crt(make_cert()); in TEST() local
395 ASSERT_TRUE(crt); in TEST()
396 ASSERT_TRUE(pfn->fn(crt.get(), *pname)); in TEST()
397 run_cert(crt.get(), *pname, pfn); in TEST()