goto failure;
}
- if (memcmp(vp->vp_octets, eap_aka_sim_session->keys.umts.vector.xres, vp->vp_length)) {
+ if (fr_digest_cmp(vp->vp_octets, eap_aka_sim_session->keys.umts.vector.xres, vp->vp_length)) {
REDEBUG("Received RES does not match calculated XRES");
RHEXDUMP_INLINE2(vp->vp_octets, vp->vp_length, "RES :");
RHEXDUMP_INLINE2(eap_aka_sim_session->keys.umts.vector.xres,
/*
* And finally, compare the digest in the packet with KD.
*/
- if (memcmp(&kd[0], &hash[0], 16) == 0) RETURN_UNLANG_OK;
+ if (fr_digest_cmp(&kd[0], &hash[0], 16) == 0) RETURN_UNLANG_OK;
REDEBUG("FAILED authentication");
RETURN_UNLANG_REJECT;
*/
smbhash(old_nt_hash_expected, auth_ctx->nt_password->vp_octets, q);
smbhash(old_nt_hash_expected + 8, auth_ctx->nt_password->vp_octets + 8, q + 7);
- if (memcmp(old_nt_hash_expected, auth_ctx->cpw_ctx->old_nt_hash, NT_DIGEST_LENGTH)!=0) {
+ if (fr_digest_cmp(old_nt_hash_expected, auth_ctx->cpw_ctx->old_nt_hash, NT_DIGEST_LENGTH)!=0) {
REDEBUG("Old NT hash value from client does not match our value");
RHEXDUMP1(old_nt_hash_expected, NT_DIGEST_LENGTH, "expected");
RHEXDUMP1(auth_ctx->cpw_ctx->old_nt_hash, NT_DIGEST_LENGTH, "got");