Lines Matching refs:alg
32 *none_jose = "{\"alg\":\"none\"}",
66 &temp_len) < 0 || !jose.alg) {
71 /* confirm we used the "none" alg as expected from JOSE hdr */
72 if (strcmp(jose.alg->alg, "none")) {
73 lwsl_err("%s: JOSE header has wrong alg\n", __func__);
102 *test1 = "{\"typ\":\"JWT\",\r\n \"alg\":\"HS256\"}",
135 &temp_len) < 0 || !jose.alg) {
140 /* confirm we used the "none" alg as expected from JOSE hdr */
141 if (strcmp(jose.alg->alg, "HS256")) {
142 lwsl_err("%s: JOSE header has wrong alg\n", __func__);
179 if (lws_genhmac_init(&ctx, jose.alg->hmac_type,
290 if (lws_gencrypto_jws_alg_to_definition("RS256", &jose.alg)) {
374 *es256_jose = "{\"alg\":\"ES256\"}",
456 /* confirm we used "ES256" alg we expect from the JOSE hdr */
457 if (strcmp(jose.alg->alg, "ES256")) {
458 lwsl_err("%s: JOSE header has wrong alg\n", __func__);
497 if (lws_genhash_init(&hash_ctx, jose.alg->hash_type) ||
547 *es512_jose = "{\"alg\":\"ES512\"}",
618 /* confirm we used "es512" alg we expect from the JOSE hdr */
619 if (strcmp(jose.alg->alg, "ES512")) {
620 lwsl_err("%s: JOSE header has wrong alg\n", __func__);
659 if (lws_genhash_init(&hash_ctx, jose.alg->hash_type) ||
894 const char hdr_fmt[] = "{\"alg\":\"RS256\", \"typ\":\"JWT\", \"x5t\":\"%s\"}";
898 .alg = NULL,