Home
last modified time | relevance | path

Searched refs:cert (Results 1 - 25 of 87) sorted by relevance

1234

/kernel/linux/linux-5.10/crypto/asymmetric_keys/
H A Dx509_public_key.c23 int x509_get_sig_params(struct x509_certificate *cert) in x509_get_sig_params() argument
25 struct public_key_signature *sig = cert->sig; in x509_get_sig_params()
33 sig->data = cert->tbs; in x509_get_sig_params()
34 sig->data_size = cert->tbs_size; in x509_get_sig_params()
36 if (!cert->pub->pkey_algo) in x509_get_sig_params()
37 cert->unsupported_key = true; in x509_get_sig_params()
40 cert->unsupported_sig = true; in x509_get_sig_params()
44 cert->unsupported_sig = true; in x509_get_sig_params()
48 sig->s = kmemdup(cert->raw_sig, cert in x509_get_sig_params()
104 x509_check_for_self_signed(struct x509_certificate *cert) x509_check_for_self_signed() argument
163 struct x509_certificate *cert; x509_key_preparse() local
[all...]
H A Dx509_cert_parser.c20 struct x509_certificate *cert; /* Certificate being constructed */ member
22 const void *cert_start; /* Start of cert content */
46 void x509_free_certificate(struct x509_certificate *cert) in x509_free_certificate() argument
48 if (cert) { in x509_free_certificate()
49 public_key_free(cert->pub); in x509_free_certificate()
50 public_key_signature_free(cert->sig); in x509_free_certificate()
51 kfree(cert->issuer); in x509_free_certificate()
52 kfree(cert->subject); in x509_free_certificate()
53 kfree(cert->id); in x509_free_certificate()
54 kfree(cert in x509_free_certificate()
65 struct x509_certificate *cert; x509_cert_parse() local
[all...]
H A Dx509_parser.h47 extern void x509_free_certificate(struct x509_certificate *cert);
56 extern int x509_get_sig_params(struct x509_certificate *cert);
57 extern int x509_check_for_self_signed(struct x509_certificate *cert);
/kernel/linux/linux-6.6/crypto/asymmetric_keys/
H A Dx509_public_key.c25 int x509_get_sig_params(struct x509_certificate *cert) in x509_get_sig_params() argument
27 struct public_key_signature *sig = cert->sig; in x509_get_sig_params()
35 sig->s = kmemdup(cert->raw_sig, cert->raw_sig_size, GFP_KERNEL); in x509_get_sig_params()
39 sig->s_size = cert->raw_sig_size; in x509_get_sig_params()
47 cert->unsupported_sig = true; in x509_get_sig_params()
67 if (strcmp(cert->pub->pkey_algo, "sm2") == 0) { in x509_get_sig_params()
70 sm2_compute_z_digest(desc, cert->pub->key, in x509_get_sig_params()
71 cert->pub->keylen, sig->digest) ?: in x509_get_sig_params()
75 crypto_shash_finup(desc, cert in x509_get_sig_params()
106 x509_check_for_self_signed(struct x509_certificate *cert) x509_check_for_self_signed() argument
165 struct x509_certificate *cert; x509_key_preparse() local
[all...]
H A Dx509_cert_parser.c20 struct x509_certificate *cert; /* Certificate being constructed */ member
26 enum OID key_algo; /* Algorithm used by the cert's key */
28 enum OID sig_algo; /* Algorithm used to sign the cert */
44 void x509_free_certificate(struct x509_certificate *cert) in x509_free_certificate() argument
46 if (cert) { in x509_free_certificate()
47 public_key_free(cert->pub); in x509_free_certificate()
48 public_key_signature_free(cert->sig); in x509_free_certificate()
49 kfree(cert->issuer); in x509_free_certificate()
50 kfree(cert->subject); in x509_free_certificate()
51 kfree(cert in x509_free_certificate()
63 struct x509_certificate *cert; x509_cert_parse() local
[all...]
H A Dx509_parser.h46 extern void x509_free_certificate(struct x509_certificate *cert);
55 extern int x509_get_sig_params(struct x509_certificate *cert);
56 extern int x509_check_for_self_signed(struct x509_certificate *cert);
/kernel/linux/common_modules/code_sign/
H A Dverify_cert_chain.c31 struct x509_certificate *cert; in pkcs7_find_key() local
37 cert = pkcs7->certs; in pkcs7_find_key()
38 while (cert) { in pkcs7_find_key()
39 if (asymmetric_key_id_same(cert->id, sinfo->sig->auth_ids[0])) { in pkcs7_find_key()
40 if (strcmp(cert->pub->pkey_algo, sinfo->sig->pkey_algo) != 0 in pkcs7_find_key()
41 && (strncmp(cert->pub->pkey_algo, "ecdsa-", 6) != 0 in pkcs7_find_key()
42 || strcmp(cert->sig->pkey_algo, "ecdsa") != 0)) { in pkcs7_find_key()
44 cert = cert->next; in pkcs7_find_key()
50 sinfo->index, cert in pkcs7_find_key()
189 struct x509_certificate* cert = pkcs7->certs; code_sign_verify_certchain() local
[all...]
H A Dcode_sign_ioctl.c41 code_sign_log_info("cert found"); in matched_cert_search()
46 code_sign_log_error("cert not found"); in matched_cert_search()
90 int cert_chain_insert(struct rb_root *root, struct cert_source *cert) in cert_chain_insert() argument
98 if (!(cert->path_type == RELEASE_DEVELOPER_CODE in cert_chain_insert()
99 || cert->path_type == DEBUG_DEVELOPER_CODE)) { in cert_chain_insert()
100 code_sign_log_error("no permission to insert code %d", cert->path_type); in cert_chain_insert()
110 int result = strcmp(cert->subject, this->subject); in cert_chain_insert()
118 result = strcmp(cert->issuer, this->issuer); in cert_chain_insert()
125 code_sign_log_info("cert already exist in trust sources"); in cert_chain_insert()
132 cert in cert_chain_insert()
143 cert_chain_remove(struct rb_root *root, struct cert_source *cert) cert_chain_remove() argument
[all...]
/kernel/linux/linux-6.6/arch/s390/boot/
H A Dipl_report.c31 struct ipl_rb_certificate_entry *cert; in get_cert_comp_list_size() local
42 for_each_rb_entry(cert, certs) in get_cert_comp_list_size()
43 ipl_cert_list_size += sizeof(unsigned int) + cert->len; in get_cert_comp_list_size()
50 struct ipl_rb_certificate_entry *cert; in ipl_report_certs_intersects() local
55 for_each_rb_entry(cert, certs) { in ipl_report_certs_intersects()
56 if (intersects(addr, size, cert->addr, cert->len)) { in ipl_report_certs_intersects()
57 *intersection_start = cert->addr; in ipl_report_certs_intersects()
75 struct ipl_rb_certificate_entry *cert; in copy_certificates_bootdata() local
79 for_each_rb_entry(cert, cert in copy_certificates_bootdata()
[all...]
/kernel/linux/linux-5.10/arch/s390/boot/
H A Dipl_report.c34 struct ipl_rb_certificate_entry *cert; in find_bootdata_space() local
45 for_each_rb_entry(cert, certs) in find_bootdata_space()
46 ipl_cert_list_size += sizeof(unsigned int) + cert->len; in find_bootdata_space()
73 for_each_rb_entry(cert, certs) in find_bootdata_space()
74 if (intersects(safe_addr, size, cert->addr, cert->len)) { in find_bootdata_space()
75 safe_addr = cert->addr + cert->len; in find_bootdata_space()
95 struct ipl_rb_certificate_entry *cert; in copy_certificates_bootdata() local
99 for_each_rb_entry(cert, cert in copy_certificates_bootdata()
[all...]
/foundation/communication/netstack/frameworks/native/net_ssl/
H A Dnet_ssl.cpp25 uint32_t NetStackVerifyCertification(const CertBlob *cert) in NetStackVerifyCertification() argument
27 if (cert == nullptr) { in NetStackVerifyCertification()
31 return VerifyCert(cert); in NetStackVerifyCertification()
34 uint32_t NetStackVerifyCertification(const CertBlob *cert, const CertBlob *caCert) in NetStackVerifyCertification() argument
36 if (cert == nullptr || caCert == nullptr) { in NetStackVerifyCertification()
40 return VerifyCert(cert, caCert); in NetStackVerifyCertification()
H A Dnet_ssl_verify_cert.cpp83 X509 *CertBlobToX509(const CertBlob *cert) in CertBlobToX509() argument
87 if (cert == nullptr) { in CertBlobToX509()
90 switch (cert->type) { in CertBlobToX509()
92 x509 = PemToX509(cert->data, cert->size); in CertBlobToX509()
94 NETSTACK_LOGE("x509 of PEM cert is nullptr\n"); in CertBlobToX509()
98 x509 = DerToX509(cert->data, cert->size); in CertBlobToX509()
100 NETSTACK_LOGE("x509 of DER cert is nullptr\n"); in CertBlobToX509()
110 uint32_t VerifyCert(const CertBlob *cert) in VerifyCert() argument
153 VerifyCert(const CertBlob *cert, const CertBlob *caCert) VerifyCert() argument
[all...]
/kernel/linux/linux-6.6/certs/
H A DMakefile26 cmd_extract_certs = $(obj)/extract-cert "$(extract-cert-in)" $@
27 extract-cert-in = $(filter-out $(obj)/extract-cert, $(real-prereqs))
31 $(obj)/x509_certificate_list: $(CONFIG_SYSTEM_TRUSTED_KEYS) $(obj)/extract-cert FORCE
70 $(obj)/signing_key.x509: extract-cert-in := $(PKCS11_URI)
73 $(obj)/signing_key.x509: $(filter-out $(PKCS11_URI),$(CONFIG_MODULE_SIG_KEY)) $(obj)/extract-cert FORCE
80 $(obj)/x509_revocation_list: $(CONFIG_SYSTEM_REVOCATION_KEYS) $(obj)/extract-cert FORCE
85 hostprogs := extract-cert
87 HOSTCFLAGS_extract-cert
[all...]
/foundation/communication/netmanager_base/test/netsysbpfstats/unittest/bpf_core_test/
H A DBpfSSLTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netmanager_base/test/netmanagernative/unittest/netsys_core_test/
H A DNetSysSSLTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netmanager_ext/test/vpnmanager/unittest/vpn_core_test/
H A DVpnSSLTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netstack/test/unittest/http_test/
H A DNetsslTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netstack/test/unittest/netssl/
H A DNetsslTest.cpp55 CertBlob *cert = nullptr; in HWTEST_F() local
58 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
61 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
67 CertBlob cert; in HWTEST_F() local
70 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
73 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netstack/test/unittest/tcp_core_test/
H A DTcpSocketSSLTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netmanager_ext/test/networksharemanager/unittest/netshare_core_test/
H A DNetShareSSLTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netstack/test/unittest/websocket_core_test/
H A DWebSocketSSLTest.cpp54 CertBlob *cert = nullptr; in HWTEST_F() local
57 uint32_t ret = NetStackVerifyCertification(cert); in HWTEST_F()
60 ret = NetStackVerifyCertification(cert, caCert); in HWTEST_F()
66 CertBlob cert; in HWTEST_F() local
69 uint32_t ret = NetStackVerifyCertification(&cert); in HWTEST_F()
72 ret = NetStackVerifyCertification(&cert, &caCert); in HWTEST_F()
/foundation/communication/netstack/interfaces/kits/c/net_ssl/src/
H A Dnet_ssl_c.cpp32 struct OHOS::NetStack::Ssl::CertBlob SwitchToCertBlob(const struct NetStack_CertBlob cert) in SwitchToCertBlob() argument
35 switch (cert.type) { in SwitchToCertBlob()
48 cb.size = cert.size; in SwitchToCertBlob()
49 cb.data = cert.data; in SwitchToCertBlob()
53 uint32_t VerifyCert_With_RootCa(const struct NetStack_CertBlob *cert) in VerifyCert_With_RootCa() argument
56 OHOS::NetStack::Ssl::CertBlob cb = SwitchToCertBlob(*cert); in VerifyCert_With_RootCa()
61 uint32_t VerifyCert_With_DesignatedCa(const struct NetStack_CertBlob *cert, const struct NetStack_CertBlob *caCert) in VerifyCert_With_DesignatedCa() argument
64 OHOS::NetStack::Ssl::CertBlob cb = SwitchToCertBlob(*cert); in VerifyCert_With_DesignatedCa()
70 uint32_t OH_NetStack_CertVerification(const struct NetStack_CertBlob *cert, const struct NetStack_CertBlob *caCert) in OH_NetStack_CertVerification() argument
72 if (cert in OH_NetStack_CertVerification()
[all...]
/kernel/linux/linux-5.10/scripts/
H A DMakefile15 hostprogs-always-$(CONFIG_SYSTEM_TRUSTED_KEYRING) += extract-cert
16 hostprogs-always-$(CONFIG_SYSTEM_EXTRA_CERTIFICATE) += insert-sys-cert
17 hostprogs-always-$(CONFIG_SYSTEM_REVOCATION_LIST) += extract-cert
23 HOSTCFLAGS_extract-cert.o = $(CRYPTO_CFLAGS)
24 HOSTLDLIBS_extract-cert = $(CRYPTO_LIBS)
/foundation/communication/netstack/interfaces/innerkits/rust/ylong_http_client/src/reqwest_impl/async_impl/
H A Dmod.rs301 /// # fn set_cert(cert: Certificate) {
302 /// let builder = ClientBuilder::new().add_root_certificate(cert);
305 pub fn add_root_certificate(mut self, cert: Certificate) -> Self { in add_root_certificate()
306 for cert in cert.into_inner() { in add_root_certificate()
307 self = Self(self.0.add_root_certificate(cert)); in add_root_certificate()
/kernel/linux/linux-5.10/certs/
H A DMakefile26 cmd_extract_certs = scripts/extract-cert $(2) $@
29 $(obj)/x509_certificate_list: scripts/extract-cert $(SYSTEM_TRUSTED_KEYS_SRCPREFIX)$(SYSTEM_TRUSTED_KEYS_FILENAME) FORCE
126 $(obj)/signing_key.x509: scripts/extract-cert $(X509_DEP) FORCE
137 cmd_extract_certs = scripts/extract-cert $(2) $@
140 $(obj)/x509_revocation_list: scripts/extract-cert $(SYSTEM_REVOCATION_KEYS_SRCPREFIX)$(SYSTEM_REVOCATION_KEYS_FILENAME) FORCE

Completed in 7 milliseconds

1234