Lines Matching refs:pkcs7
31 static int pkcs7_to_cert(struct hs20_osu_client *ctx, const u8 *pkcs7, in pkcs7_to_cert() argument
38 const unsigned char *p = pkcs7; in pkcs7_to_cert()
48 CBS_init(&pkcs7_cbs, pkcs7, len); in pkcs7_to_cert()
125 unsigned char *pkcs7; in est_load_cacerts() local
161 pkcs7 = base64_decode((unsigned char *) resp, resp_len, &pkcs7_len); in est_load_cacerts()
162 if (pkcs7 && pkcs7_len < resp_len / 2) { in est_load_cacerts()
165 os_free(pkcs7); in est_load_cacerts()
166 pkcs7 = NULL; in est_load_cacerts()
168 if (pkcs7 == NULL) { in est_load_cacerts()
170 pkcs7 = os_malloc(resp_len); in est_load_cacerts()
171 if (pkcs7) { in est_load_cacerts()
172 os_memcpy(pkcs7, resp, resp_len); in est_load_cacerts()
178 if (pkcs7 == NULL) { in est_load_cacerts()
184 res = pkcs7_to_cert(ctx, pkcs7, pkcs7_len, "Cert/est-cacerts.pem", in est_load_cacerts()
186 os_free(pkcs7); in est_load_cacerts()
681 unsigned char *pkcs7; in est_simple_enroll() local
737 pkcs7 = base64_decode((unsigned char *) resp, resp_len, &pkcs7_len); in est_simple_enroll()
738 if (pkcs7 == NULL) { in est_simple_enroll()
740 pkcs7 = os_malloc(resp_len); in est_simple_enroll()
741 if (pkcs7) { in est_simple_enroll()
742 os_memcpy(pkcs7, resp, resp_len); in est_simple_enroll()
748 if (pkcs7 == NULL) { in est_simple_enroll()
754 res = pkcs7_to_cert(ctx, pkcs7, pkcs7_len, "Cert/est_cert.pem", in est_simple_enroll()
756 os_free(pkcs7); in est_simple_enroll()