Changed definition of get_my_pub_val function a little
This commit is contained in:
committed by
Andreas Steffen
parent
4002b41b92
commit
4b3d992d08
@@ -161,14 +161,11 @@ METHOD(pts_t, create_dh, bool,
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
METHOD(pts_t, get_my_pub_val, chunk_t,
|
METHOD(pts_t, get_my_pub_val, void,
|
||||||
private_pts_t *this)
|
private_pts_t *this, chunk_t *pub_value)
|
||||||
{
|
{
|
||||||
chunk_t public_value;
|
this->dh->get_my_public_value(this->dh, pub_value);
|
||||||
|
DBG3(DBG_PTS, "My Public value:%B", pub_value);
|
||||||
this->dh->get_my_public_value(this->dh, &public_value);
|
|
||||||
DBG3(DBG_PTS, "My Public value:%B", &public_value);
|
|
||||||
return public_value;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
METHOD(pts_t, set_other_pub_val, void,
|
METHOD(pts_t, set_other_pub_val, void,
|
||||||
@@ -215,6 +212,7 @@ METHOD(pts_t, calculate_secret, bool,
|
|||||||
this->secret = chunk_create(output, HASH_SIZE_SHA1);
|
this->secret = chunk_create(output, HASH_SIZE_SHA1);
|
||||||
DBG3(DBG_PTS, "Secret assessment value: %B", &this->secret);
|
DBG3(DBG_PTS, "Secret assessment value: %B", &this->secret);
|
||||||
|
|
||||||
|
chunk_free(&shared_secret);
|
||||||
hasher->destroy(hasher);
|
hasher->destroy(hasher);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -101,9 +101,9 @@ struct pts_t {
|
|||||||
/**
|
/**
|
||||||
* Gets Own Diffie Hellman Public Value
|
* Gets Own Diffie Hellman Public Value
|
||||||
*
|
*
|
||||||
* @return D-H Public Value
|
* @param info chunk to keep own public value
|
||||||
*/
|
*/
|
||||||
chunk_t (*get_my_pub_val)(pts_t *this);
|
void (*get_my_pub_val)(pts_t *this, chunk_t *pub_value);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the public value of partner.
|
* Sets the public value of partner.
|
||||||
|
|||||||
Reference in New Issue
Block a user