utils: Use chunk_equals_const() for all cryptographic purposes
This commit is contained in:
@@ -425,7 +425,7 @@ static status_t process_challenge(private_eap_aka_server_t *this,
|
||||
enumerator->destroy(enumerator);
|
||||
|
||||
/* compare received RES against stored XRES */
|
||||
if (!chunk_equals(res, this->xres))
|
||||
if (!chunk_equals_const(res, this->xres))
|
||||
{
|
||||
DBG1(DBG_IKE, "received RES does not match XRES");
|
||||
return FAILED;
|
||||
@@ -486,7 +486,7 @@ static status_t process_reauthentication(private_eap_aka_server_t *this,
|
||||
this->crypto->clear_keys(this->crypto);
|
||||
return challenge(this, out);
|
||||
}
|
||||
if (!chunk_equals(counter, this->counter))
|
||||
if (!chunk_equals_const(counter, this->counter))
|
||||
{
|
||||
DBG1(DBG_IKE, "received counter does not match");
|
||||
return FAILED;
|
||||
@@ -730,4 +730,3 @@ eap_aka_server_t *eap_aka_server_create(identification_t *server,
|
||||
|
||||
return &this->public;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user