Lines Matching refs:hashparams
51 Curl_HMAC_init(const HMAC_params * hashparams, in Curl_HMAC_init() argument
61 i = sizeof(*ctxt) + 2 * hashparams->hmac_ctxtsize + in Curl_HMAC_init()
62 hashparams->hmac_resultlen; in Curl_HMAC_init()
68 ctxt->hmac_hash = hashparams; in Curl_HMAC_init()
71 hashparams->hmac_ctxtsize); in Curl_HMAC_init()
74 if(keylen > hashparams->hmac_maxkeylen) { in Curl_HMAC_init()
75 (*hashparams->hmac_hinit)(ctxt->hmac_hashctxt1); in Curl_HMAC_init()
76 (*hashparams->hmac_hupdate)(ctxt->hmac_hashctxt1, key, keylen); in Curl_HMAC_init()
77 hkey = (unsigned char *) ctxt->hmac_hashctxt2 + hashparams->hmac_ctxtsize; in Curl_HMAC_init()
78 (*hashparams->hmac_hfinal)(hkey, ctxt->hmac_hashctxt1); in Curl_HMAC_init()
80 keylen = hashparams->hmac_resultlen; in Curl_HMAC_init()
84 (*hashparams->hmac_hinit)(ctxt->hmac_hashctxt1); in Curl_HMAC_init()
85 (*hashparams->hmac_hinit)(ctxt->hmac_hashctxt2); in Curl_HMAC_init()
89 (*hashparams->hmac_hupdate)(ctxt->hmac_hashctxt1, &b, 1); in Curl_HMAC_init()
91 (*hashparams->hmac_hupdate)(ctxt->hmac_hashctxt2, &b, 1); in Curl_HMAC_init()
94 for(; i < hashparams->hmac_maxkeylen; i++) { in Curl_HMAC_init()
95 (*hashparams->hmac_hupdate)(ctxt->hmac_hashctxt1, &hmac_ipad, 1); in Curl_HMAC_init()
96 (*hashparams->hmac_hupdate)(ctxt->hmac_hashctxt2, &hmac_opad, 1); in Curl_HMAC_init()
115 const HMAC_params * hashparams = ctxt->hmac_hash; in Curl_HMAC_final() local
124 (*hashparams->hmac_hfinal)(result, ctxt->hmac_hashctxt1); in Curl_HMAC_final()
125 (*hashparams->hmac_hupdate)(ctxt->hmac_hashctxt2, in Curl_HMAC_final()
126 result, hashparams->hmac_resultlen); in Curl_HMAC_final()
127 (*hashparams->hmac_hfinal)(result, ctxt->hmac_hashctxt2); in Curl_HMAC_final()