cx = HMAC_Create(hashObj, init_hash->data, init_hash->len);
cx = HMAC_Create(hashObj, init_hash->data, init_hash->len, PR_TRUE);
nsspkcs5_PFXPBE(const SECHashObject *hashObj, NSSPKCS5PBEParameter *pbe_param,				SECItem *init_hash, unsigned int bytes_needed){    SECItem *ret_bits = NULL;    int hash_size = 0;    unsigned int i;    unsigned int hash_iter;    unsigned int dig_len;    SECStatus rv = SECFailure;    unsigned char *state = NULL;    unsigned int state_len;    HMACContext *cx = NULL;    hash_size = hashObj->length;    hash_iter = (bytes_needed + (unsigned int)hash_size - 1) / hash_size;    /* allocate return buffer */    ret_bits = (SECItem  *)PORT_ZAlloc(sizeof(SECItem));    if(ret_bits == NULL)	return NULL;    ret_bits->data = (unsigned char *)PORT_ZAlloc((hash_iter * hash_size) + 1);    ret_bits->len = (hash_iter * hash_size);    if(ret_bits->data == NULL) {	PORT_Free(ret_bits);	return NULL;    }    /* allocate intermediate hash buffer.  8 is for the 8 bytes of     * data which are added based on iteration number      */    if ((unsigned int)hash_size > pbe_param->salt.len) {	state_len = hash_size;    } else {	state_len = pbe_param->salt.len;    }    state = (unsigned char *)PORT_ZAlloc(state_len);    if(state == NULL) {	rv = SECFailure;	goto loser;    }    if(pbe_param->salt.len > 0) {	PORT_Memcpy(state, pbe_param->salt.data, pbe_param->salt.len);    }    cx = HMAC_Create(hashObj, init_hash->data, init_hash->len);    if (cx == NULL) {	rv = SECFailure;	goto loser;    }    for(i = 0; i < hash_iter; i++) { 	/* generate output bits */	HMAC_Begin(cx);	HMAC_Update(cx, state, state_len);	HMAC_Update(cx, pbe_param->salt.data, pbe_param->salt.len);	rv = HMAC_Finish(cx, ret_bits->data + (i * hash_size),			 &dig_len, hash_size);	if (rv != SECSuccess)	    goto loser;	PORT_Assert((unsigned int)hash_size == dig_len);	/* generate new state */	HMAC_Begin(cx);	HMAC_Update(cx, state, state_len);	rv = HMAC_Finish(cx, state, &state_len, state_len);	if (rv != SECSuccess)	    goto loser;	PORT_Assert(state_len == dig_len);    }loser:    if (state != NULL)	PORT_ZFree(state, state_len);    HMAC_Destroy(cx);    if(rv != SECSuccess) {	SECITEM_ZfreeItem(ret_bits, PR_TRUE);	ret_bits = NULL;    }    return ret_bits;}