Home
last modified time | relevance | path

Searched refs:cert (Results 1 – 25 of 469) sorted by relevance

12345678910>>...19

/freebsd/crypto/openssl/test/certs/
H A Dsetup.sh4 ./mkcert.sh genroot "Root CA" root-key root-cert
12 ./mkcert.sh genca "Root CA" root-key root-cross-cert cross-key cross-root
14 openssl x509 -in root-cert.pem -trustout \
16 openssl x509 -in root-cert.pem -trustout \
18 openssl x509 -in root-cert.pem -trustout \
20 openssl x509 -in root-cert.pem -trustout \
23 openssl x509 -in root-cert.pem -trustout \
25 openssl x509 -in root-cert.pem -trustout \
43 ./mkcert.sh genroot "Root CA" root-key root-cert-md5
46 ./mkcert.sh genroot "Root CA" root-key-768 root-cert-768
[all …]
H A Dmkcert.sh90 cert() { function
91 local cert=$1; shift
95 openssl x509 -req -"${OPENSSL_SIGALG}" -out "${cert}.pem" \
102 local cert=$1; shift
115 cert "$cert" "$exts" -signkey "${key}.pem" -set_serial 1 -days "${DAYS}"
135 local cert=$1; shift
156 cert "$cert" "$exts" -CA "${cacert}.pem" -CAkey "${cakey}.pem" \
163 local cert=$1; shift
177 cert "$cert" "$exts" -CA "${cacert}.pem" -CAkey "${cakey}.pem" \
188 local cert=$1; shift
[all …]
/freebsd/crypto/openssl/test/recipes/
H A D25-test_req.t390 my $cert = shift @_;
391 my $ss = $cert =~ m/self-signed/;
392 my $is_ca = $cert =~ m/CA/;
397 "-subj", "/CN=$cn", @_, "-out", $cert);
400 ok(run(app([@cmd])), "generate $cert");
403 my $cert = shift @_;
405 cert_contains($cert, "Subject Key Identifier", $expect);
408 my $cert = shift @_;
410 cert_contains($cert, "Authority Key Identifier", $expect);
413 my $cert
[all...]
/freebsd/crypto/heimdal/lib/hx509/
H A Dtest_ca.in66 cert:FILE:cert-ee.pem \
76 cert:FILE:cert-ee.pem \
84 FILE:cert-ee.pem || exit 1
88 cert:FILE:cert-ee.pem \
97 FILE:cert-ee.pem || exit 1
101 cert:FILE:cert-ee.pem \
153 cert:FILE:cert-ee.pem \
159 cert:FILE:cert-ee.pem \
165 cert:FILE:cert-ee.pem \
179 cert:FILE:cert-ee.pem \
[all …]
H A Dtest_chain.in52 cert:FILE:$srcdir/data/test.crt \
59 cert:FILE:$srcdir/data/test.crt \
65 cert:FILE:$srcdir/data/test.crt \
70 cert:FILE:$srcdir/data/sub-cert.crt \
76 cert:FILE:$srcdir/data/sub-cert.crt \
83 cert:FILE:$srcdir/data/sub-cert.crt \
88 cert:FILE:$srcdir/data/sub-cert.crt \
95 cert:FILE:$srcdir/data/sub-cert.crt \
102 cert:FILE:$srcdir/data/sub-cert.crt \
109 cert:FILE:$srcdir/data/sub-cert.crt \
[all …]
H A Dcert.c191 _hx509_get_cert(hx509_cert cert) in _hx509_get_cert() argument
193 return cert->data; in _hx509_get_cert()
220 hx509_cert_init(hx509_context context, const Certificate *c, hx509_cert *cert) in hx509_cert_init() argument
224 *cert = malloc(sizeof(**cert)); in hx509_cert_init()
225 if (*cert == NULL) in hx509_cert_init()
227 (*cert)->ref = 1; in hx509_cert_init()
228 (*cert)->friendlyname = NULL; in hx509_cert_init()
229 (*cert)->attrs.len = 0; in hx509_cert_init()
230 (*cert)->attrs.val = NULL; in hx509_cert_init()
231 (*cert)->private_key = NULL; in hx509_cert_init()
[all …]
H A Dtest_cert.in61 FILE:${srcdir}/data/test.crt PEM-FILE:cert-pem.tmp || exit 1
63 ${hxtool} certificate-copy PEM-FILE:cert-pem.tmp DER-FILE:cert-der.tmp || exit 1
64 ${hxtool} certificate-copy DER-FILE:cert-der.tmp PEM-FILE:cert-pem2.tmp || exit 1
66 cmp cert-pem.tmp cert-pem2.tmp || exit 1
71 cert:FILE:$srcdir/data/n0ll.pem \
76 cert:FILE:$srcdir/data/n0ll.pem \
81 cert:FILE:$srcdir/data/win-u16-in-printablestring.der \
/freebsd/contrib/wpa/src/tls/
H A Dx509v3.c45 void x509_certificate_free(struct x509_certificate *cert) in x509_certificate_free() argument
47 if (cert == NULL) in x509_certificate_free()
49 if (cert->next) { in x509_certificate_free()
52 cert, cert->next); in x509_certificate_free()
54 x509_free_name(&cert->issuer); in x509_certificate_free()
55 x509_free_name(&cert->subject); in x509_certificate_free()
56 os_free(cert->public_key); in x509_certificate_free()
57 os_free(cert->sign_value); in x509_certificate_free()
58 os_free(cert->subject_dn); in x509_certificate_free()
59 os_free(cert); in x509_certificate_free()
[all …]
/freebsd/crypto/openssh/regress/
H A Dcert-hostkey.sh6 rm -f $OBJ/known_hosts-cert* $OBJ/host_ca_key* $OBJ/host_revoked_*
19 *rsa*cert*)
26 *cert*) types="$i,$types";;
64 kh_ca host_ca_key.pub host_ca_key2.pub > $OBJ/known_hosts-cert.orig
65 cp $OBJ/known_hosts-cert.orig $OBJ/known_hosts-cert
106 $OBJ/cert_host_key_${ktype}-cert.pub || \
108 cat $OBJ/cert_host_key_${ktype}-cert.pub >> $OBJ/host_revoked_cert
117 cp $OBJ/known_hosts-cert.orig $OBJ/known_hosts-cert
118 ${SSH} -oUserKnownHostsFile=$OBJ/known_hosts-cert \
119 -oGlobalKnownHostsFile=$OBJ/known_hosts-cert \
[all …]
H A Dagent-pkcs11-cert.sh46 ${SSH_SOFTHSM_DIR}/EC-cert.pub \
48 ${SSH_SOFTHSM_DIR}/RSA-cert.pub ||
54 ${SSH_SOFTHSM_DIR}/EC-cert.pub \
55 ${SSH_SOFTHSM_DIR}/RSA-cert.pub | sort > $OBJ/expect_list
61 ${SSH_SOFTHSM_DIR}/EC-cert.pub ${SSH_SOFTHSM_DIR}/RSA-cert.pub ; do
68 for x in ${SSH_SOFTHSM_DIR}/EC-cert.pub ${SSH_SOFTHSM_DIR}/RSA-cert.pub ; do
78 ${SSH_SOFTHSM_DIR}/EC-cert.pub \
80 ${SSH_SOFTHSM_DIR}/RSA-cert.pub ||
84 ${SSH_SOFTHSM_DIR}/EC-cert.pub \
85 ${SSH_SOFTHSM_DIR}/RSA-cert.pub | sort > $OBJ/expect_list
[all …]
/freebsd/crypto/openssl/test/recipes/80-test_cmp_http_data/
H A Dtest_credentials.csv1 expected,description, -section,val, -ref,val, -secret,val, -cert,val, -key,val, -keypass,val, -extr…
3 1,valid secret - wrong cert/key ignored, -section,, -ref,_PBM_REF, -secret,_PBM_SECRET, -cert,root.…
6 0,wrong secret - correct cert, -section,,BLANK,, -secret,pass:wrong, -cert,signer.crt, -key,signer.…
9 1,empty ref but correct cert, -section,, -ref,"""",BLANK,, -cert,signer.crt, -key,signer.p12, -keyp…
10 1,wrong ref but correct cert, -section,, -ref,wrong,BLANK,, -cert,signer.crt, -key,signer.p12, -key…
12 1,valid cert and key and keypass, -section,,BLANK,,-secret,"""", -cert,signer.crt, -key,signer.p12,…
13 0,cert missing arg, -section,,BLANK,,BLANK,, -cert,, -key,signer.p12, -keypass,pass:12345,BLANK,,BL…
14 0,key missing arg, -section,,BLANK,,BLANK,, -cert,signer.crt, -key,, -keypass,pass:12345,BLANK,,BLA…
15 0,keypass missing arg, -section,,BLANK,,BLANK,, -cert,signer.crt, -key,signer.p12, -keypass,,BLANK,…
16 0,keypass empty string, -section,,BLANK,,BLANK,, -cert,signer.crt, -key,signer.p12, -keypass,pass:,…
[all …]
H A Dtest_commands.csv16 1,revreason unspecified, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem, -…
18 1,revreason keyCompromise, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem,…
20 1,revreason CACompromise, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem, …
22 1,revreason affiliationChanged, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert
24 1,revreason superseded, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem, -r…
26 …nOfOperation, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem, -revreason,5
28 1,revreason certificateHold, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pe…
29 1,revreason removeFromCRL, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem,…
30 0,revreason 7 (invalid), -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert.pem, -…
32 1,revreason priviligeWithdrawn, -section,, -cmd,rr,,BLANK,,,BLANK,,, -oldcert,_RESULT_DIR/test.cert
[all …]
/freebsd/crypto/openssh/regress/unittests/authopt/testdata/
H A Dmktestdata.sh7 rm -f *.cert
18 mv user_key-cert.pub "$output"
21 sign all_permit.cert -Opermit-agent-forwarding -Opermit-port-forwarding \
23 sign no_permit.cert -Oclear
25 sign no_agentfwd.cert -Ono-agent-forwarding
26 sign no_portfwd.cert -Ono-port-forwarding
27 sign no_pty.cert -Ono-pty
28 sign no_user_rc.cert -Ono-user-rc
29 sign no_x11fwd.cert -Ono-X11-forwarding
31 sign only_agentfwd.cert -Oclear -Opermit-agent-forwarding
[all …]
/freebsd/contrib/ldns/
H A Ddane.c134 ldns_dane_cert2rdf(ldns_rdf** rdf, X509* cert, in ldns_dane_cert2rdf() argument
147 assert(cert != NULL); in ldns_dane_cert2rdf()
152 len = (size_t)i2d_X509(cert, &buf); in ldns_dane_cert2rdf()
158 xpubkey = X509_get_X509_PUBKEY(cert); in ldns_dane_cert2rdf()
223 ldns_dane_pkix_validate(X509* cert, STACK_OF(X509)* extra_certs, in ldns_dane_pkix_validate() argument
238 cert, extra_certs) != 1) { in ldns_dane_pkix_validate()
257 ldns_dane_pkix_validate_and_get_chain(STACK_OF(X509)** chain, X509* cert, in ldns_dane_pkix_validate_and_get_chain() argument
276 cert, extra_certs) != 1) { in ldns_dane_pkix_validate_and_get_chain()
306 X509* cert, STACK_OF(X509)* extra_certs) in ldns_dane_pkix_get_chain() argument
322 cert, extra_certs) != 1) { in ldns_dane_pkix_get_chain()
[all …]
/freebsd/crypto/openssl/ssl/
H A Dssl_cert.c85 CERT *ssl_cert_dup(CERT *cert) in ssl_cert_dup() argument
96 ret->key = &ret->pkeys[cert->key - cert->pkeys]; in ssl_cert_dup()
104 if (cert->dh_tmp != NULL) { in ssl_cert_dup()
105 ret->dh_tmp = cert->dh_tmp; in ssl_cert_dup()
109 ret->dh_tmp_cb = cert->dh_tmp_cb; in ssl_cert_dup()
110 ret->dh_tmp_auto = cert->dh_tmp_auto; in ssl_cert_dup()
113 CERT_PKEY *cpk = cert->pkeys + i; in ssl_cert_dup()
132 if (cert->pkeys[i].serverinfo != NULL) { in ssl_cert_dup()
135 OPENSSL_malloc(cert->pkeys[i].serverinfo_length); in ssl_cert_dup()
140 ret->pkeys[i].serverinfo_length = cert->pkeys[i].serverinfo_length; in ssl_cert_dup()
[all …]
/freebsd/crypto/openssl/crypto/ess/
H A Dess_lib.c18 static ESS_CERT_ID *ESS_CERT_ID_new_init(const X509 *cert,
21 const X509 *cert,
42 X509 *cert = sk_X509_value(certs, i); in OSSL_ESS_signing_cert_new_init() local
44 if ((cid = ESS_CERT_ID_new_init(cert, 1)) == NULL in OSSL_ESS_signing_cert_new_init()
57 static ESS_CERT_ID *ESS_CERT_ID_new_init(const X509 *cert, in ESS_CERT_ID_new_init() argument
66 if (!X509_digest(cert, EVP_sha1(), cert_sha1, NULL)) in ESS_CERT_ID_new_init()
81 if ((name->d.dirn = X509_NAME_dup(X509_get_issuer_name(cert))) == NULL) in ESS_CERT_ID_new_init()
88 ASN1_INTEGER_dup(X509_get0_serialNumber(cert))) == NULL) in ESS_CERT_ID_new_init()
119 X509 *cert = sk_X509_value(certs, i); in OSSL_ESS_signing_cert_v2_new_init() local
121 if ((cid = ESS_CERT_ID_V2_new_init(hash_alg, cert, in OSSL_ESS_signing_cert_v2_new_init()
137 ESS_CERT_ID_V2_new_init(const EVP_MD * hash_alg,const X509 * cert,int set_issuer_serial) ESS_CERT_ID_V2_new_init() argument
197 ess_issuer_serial_cmp(const ESS_ISSUER_SERIAL * is,const X509 * cert) ess_issuer_serial_cmp() argument
220 const X509 *cert; find() local
[all...]
/freebsd/crypto/openssl/crypto/cmp/
H A Dcmp_vfy.c26 const OSSL_CMP_MSG *msg, X509 *cert) in verify_signature() argument
33 if (!ossl_assert(cmp_ctx != NULL && msg != NULL && cert != NULL)) in verify_signature()
40 && (X509_get_key_usage(cert) & X509v3_KU_DIGITAL_SIGNATURE) == 0) { in verify_signature()
45 pubkey = X509_get_pubkey(cert); in verify_signature()
63 res = ossl_x509_print_ex_brief(bio, cert, X509_FLAG_NO_EXTENSIONS); in verify_signature()
106 X509_STORE *trusted_store, X509 *cert) in OSSL_CMP_validate_cert_path() argument
112 if (ctx == NULL || cert == NULL) { in OSSL_CMP_validate_cert_path()
124 cert, ctx->untrusted)) in OSSL_CMP_validate_cert_path()
206 static int already_checked(const X509 *cert, in already_checked() argument
212 if (X509_cmp(sk_X509_value(already_checked, i - 1), cert) == 0) in already_checked()
[all …]
/freebsd/crypto/openssl/crypto/ocsp/
H A Docsp_srv.c157 int OCSP_basic_add1_cert(OCSP_BASICRESP *resp, X509 *cert) in OCSP_basic_add1_cert() argument
159 return ossl_x509_add_cert_new(&resp->certs, cert, X509_ADD_FLAG_UP_REF); in OCSP_basic_add1_cert()
236 int OCSP_RESPID_set_by_name(OCSP_RESPID *respid, X509 *cert) in OCSP_RESPID_set_by_name() argument
238 if (!X509_NAME_set(&respid->value.byName, X509_get_subject_name(cert))) in OCSP_RESPID_set_by_name()
246 int OCSP_RESPID_set_by_key_ex(OCSP_RESPID *respid, X509 *cert, in OCSP_RESPID_set_by_key_ex() argument
258 if (!X509_pubkey_digest(cert, sha1, md, NULL)) in OCSP_RESPID_set_by_key_ex()
279 int OCSP_RESPID_set_by_key(OCSP_RESPID *respid, X509 *cert) in OCSP_RESPID_set_by_key() argument
281 if (cert == NULL) in OCSP_RESPID_set_by_key()
283 return OCSP_RESPID_set_by_key_ex(respid, cert, cert->libctx, cert->propq); in OCSP_RESPID_set_by_key()
286 int OCSP_RESPID_match_ex(OCSP_RESPID *respid, X509 *cert, OSSL_LIB_CTX *libctx, in OCSP_RESPID_match_ex() argument
[all …]
/freebsd/crypto/openssl/test/ssl-tests/
H A D20-cert-select.cnf.in16 "ECDSA.Certificate" => test_pem("server-ecdsa-cert.pem"),
18 "Ed25519.Certificate" => test_pem("server-ed25519-cert.pem"),
20 "Ed448.Certificate" => test_pem("server-ed448-cert.pem"),
26 "PSS.Certificate" => test_pem("server-pss-cert.pem"),
28 "ECDSA.Certificate" => test_pem("server-ecdsa-cert.pem"),
30 "Ed25519.Certificate" => test_pem("server-ed25519-cert.pem"),
32 "Ed448.Certificate" => test_pem("server-ed448-cert.pem"),
38 "Certificate" => test_pem("server-pss-cert.pem"),
43 "Certificate" => test_pem("server-pss-restrict-cert.pem"),
56 "PSS.Certificate" => test_pem("server-pss-cert
[all...]
/freebsd/crypto/openssh/regress/unittests/sshkey/
H A Dtest_sshkey.c419 ASSERT_PTR_NE(k1->cert, NULL); in sshkey_tests()
420 k1->cert->type = SSH2_CERT_TYPE_USER; in sshkey_tests()
421 k1->cert->serial = 1234; in sshkey_tests()
422 k1->cert->key_id = strdup("estragon"); in sshkey_tests()
423 ASSERT_PTR_NE(k1->cert->key_id, NULL); in sshkey_tests()
424 k1->cert->principals = calloc(4, sizeof(*k1->cert->principals)); in sshkey_tests()
425 ASSERT_PTR_NE(k1->cert->principals, NULL); in sshkey_tests()
426 k1->cert->principals[0] = strdup("estragon"); in sshkey_tests()
427 k1->cert->principals[1] = strdup("vladimir"); in sshkey_tests()
428 k1->cert->principals[2] = strdup("pozzo"); in sshkey_tests()
[all …]
/freebsd/crypto/openssl/fuzz/
H A Dserver.c527 X509 *cert; in FuzzerTestOneInput() local
562 cert = d2i_X509(NULL, &bufp, sizeof(kCertificateDER)); in FuzzerTestOneInput()
563 OPENSSL_assert(cert != NULL); in FuzzerTestOneInput()
564 ret = SSL_CTX_use_certificate(ctx, cert); in FuzzerTestOneInput()
566 X509_free(cert); in FuzzerTestOneInput()
585 cert = PEM_read_bio_X509(bio_buf, NULL, NULL, NULL); in FuzzerTestOneInput()
586 OPENSSL_assert(cert != NULL); in FuzzerTestOneInput()
588 ret = SSL_CTX_use_certificate(ctx, cert); in FuzzerTestOneInput()
590 X509_free(cert); in FuzzerTestOneInput()
609 cert = PEM_read_bio_X509(bio_buf, NULL, NULL, NULL); in FuzzerTestOneInput()
[all …]
/freebsd/crypto/openssl/test/
H A Dlocaletest.c97 X509 *cert = NULL; in setup_tests() local
110 cert = d2i_X509(NULL, &p, sizeof(der_bytes)); in setup_tests()
111 if (!TEST_ptr(cert)) in setup_tests()
114 cert_pubkey = X509_get_X509_PUBKEY(cert); in setup_tests()
116 X509_free(cert); in setup_tests()
121 X509_free(cert); in setup_tests()
125 X509_free(cert); in setup_tests()
/freebsd/crypto/openssh/
H A Dsshkey.c235 return impl->cert; in sshkey_type_is_cert()
261 (!impl->cert && strcasecmp(impl->shortname, name) == 0)) in sshkey_type_from_name()
331 if ((certs_only && !impl->cert) || (plain_only && impl->cert)) in sshkey_alg_list()
410 return !impl->cert; in sshkey_type_is_valid_ca()
570 cert_free(struct sshkey_cert *cert) in cert_free() argument
574 if (cert == NULL) in cert_free()
576 sshbuf_free(cert->certblob); in cert_free()
577 sshbuf_free(cert->critical); in cert_free()
578 sshbuf_free(cert->extensions); in cert_free()
579 free(cert->key_id); in cert_free()
[all …]
/freebsd/crypto/openssl/crypto/pkcs12/
H A Dp12_crt.c18 X509 *cert,
38 X509 *cert, STACK_OF(X509) *ca, int nid_key, int nid_cert, in PKCS12_create_ex() argument
63 if (pkey == NULL && cert == NULL && ca == NULL) { in PKCS12_create_ex()
68 if (pkey && cert) { in PKCS12_create_ex()
69 if (!X509_check_private_key(cert, pkey)) in PKCS12_create_ex()
71 if (!X509_digest(cert, EVP_sha1(), keyid, &keyidlen)) in PKCS12_create_ex()
75 if (cert) { in PKCS12_create_ex()
77 name = (char *)X509_alias_get0(cert, &namelen); in PKCS12_create_ex()
82 pkeyid = X509_keyid_get0(cert, &pkeyidlen); in PKCS12_create_ex()
85 bag = pkcs12_add_cert_bag(&bags, cert, name, namelen, pkeyid, pkeyidlen); in PKCS12_create_ex()
[all …]
/freebsd/crypto/openssl/crypto/ct/
H A Dct_sct_ctx.c63 static int ct_x509_get_ext(X509 *cert, int nid, int *is_duplicated) in ct_x509_get_ext() argument
65 int ret = X509_get_ext_by_NID(cert, nid, -1); in ct_x509_get_ext()
68 *is_duplicated = ret >= 0 && X509_get_ext_by_NID(cert, nid, ret) >= 0; in ct_x509_get_ext()
78 __owur static int ct_x509_cert_fixup(X509 *cert, X509 *presigner) in ct_x509_cert_fixup() argument
88 certidx = ct_x509_get_ext(cert, NID_authority_key_identifier, in ct_x509_cert_fixup()
103 if (!X509_set_issuer_name(cert, X509_get_issuer_name(presigner))) in ct_x509_cert_fixup()
108 X509_EXTENSION *certext = X509_get_ext(cert, certidx); in ct_x509_cert_fixup()
122 int SCT_CTX_set1_cert(SCT_CTX *sctx, X509 *cert, X509 *presigner) in SCT_CTX_set1_cert() argument
129 int poison_idx = ct_x509_get_ext(cert, NID_ct_precert_poison, &poison_ext_is_dup); in SCT_CTX_set1_cert()
141 certderlen = i2d_X509(cert, &certder); in SCT_CTX_set1_cert()
[all …]

12345678910>>...19