hmac_ctx
ret = hmac_init(&hmac_ctx, K, hsize, hash_type); EG(ret, err);
ret = hmac_update(&hmac_ctx, V, hsize); EG(ret, err);
ret = hmac_update(&hmac_ctx, &tmp, 1); EG(ret, err);
ret = hmac_update(&hmac_ctx, priv_key_buff, q_len); EG(ret, err);
ret = hmac_update(&hmac_ctx, T, q_len); EG(ret, err);
ret = hmac_finalize(&hmac_ctx, K, &hmac_size); EG(ret, err);
ret = hmac_init(&hmac_ctx, K, hsize, hash_type); EG(ret, err);
ret = hmac_update(&hmac_ctx, V, hsize); EG(ret, err);
ret = hmac_update(&hmac_ctx, &tmp, 1); EG(ret, err);
ret = hmac_finalize(&hmac_ctx, K, &hmac_size); EG(ret, err);
hmac_context hmac_ctx;
ret = hmac_init(&hmac_ctx, K, hsize, hash_type); EG(ret, err);
ret = hmac_update(&hmac_ctx, V, hsize); EG(ret, err);
ret = hmac_update(&hmac_ctx, &tmp, 1); EG(ret, err);
ret = hmac_update(&hmac_ctx, priv_key_buff, q_len); EG(ret, err);
ret = hmac_update(&hmac_ctx, T, q_len); EG(ret, err);
ret = hmac_finalize(&hmac_ctx, K, &hmac_size); EG(ret, err);
if ((mac->hmac_ctx = ssh_hmac_start(macalg->alg)) == NULL)
if (mac->hmac_ctx == NULL ||
ssh_hmac_init(mac->hmac_ctx, mac->key, mac->key_len) < 0)
if (ssh_hmac_init(mac->hmac_ctx, NULL, 0) < 0 ||
ssh_hmac_update(mac->hmac_ctx, b, sizeof(b)) < 0 ||
ssh_hmac_update(mac->hmac_ctx, data, datalen) < 0 ||
ssh_hmac_final(mac->hmac_ctx, u.m, sizeof(u.m)) < 0)
} else if (mac->hmac_ctx != NULL)
ssh_hmac_free(mac->hmac_ctx);
mac->hmac_ctx = NULL;
struct ssh_hmac_ctx *hmac_ctx;
EVP_MAC_CTX_free(ctx->hmac_ctx);
ret->hmac_ctx = EVP_MAC_CTX_new(key->hmac);
if (ret->hmac_ctx == NULL)
if (src->hmac_ctx != NULL
&& (ret->hmac_ctx = EVP_MAC_CTX_dup(src->hmac_ctx)) == NULL)
EVP_MAC_CTX *hmac_ctx; /* required by SHA algorithms for PRFmsg() */
EVP_MAC_CTX *mctx = hctx->hmac_ctx;
struct hmac_ctx ctxtemplate;
struct hmac_ctx *ctxp, char *passbuf, size_t passbufsize)
struct hmac_ctx *ctxp)
eli_init_key_hmac_ctx(struct gctl_req *req, struct hmac_ctx *ctx, bool new)
eli_genkey(struct gctl_req *req, const struct hmac_ctx *ctxtemplate,
struct hmac_ctx ctx;
struct hmac_ctx ctx;
struct hmac_ctx ctxtemplate;
struct hmac_ctx ctx;
g_eli_keyfiles_load(struct hmac_ctx *ctx, const char *provider)
struct hmac_ctx ctx;
void g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const char *hkey,
void g_eli_crypto_hmac_update(struct hmac_ctx *ctx, const uint8_t *data,
void g_eli_crypto_hmac_final(struct hmac_ctx *ctx, uint8_t *md, size_t mdsize);
struct hmac_ctx ctx;
g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const char *hkey,
g_eli_crypto_hmac_update(struct hmac_ctx *ctx, const uint8_t *data,
g_eli_crypto_hmac_final(struct hmac_ctx *ctx, uint8_t *md, size_t mdsize)
struct hmac_ctx startpoint, ctx;