Create negotiated hasher earlier during Main Mode so it is available for building NAT-D payloads.

This commit is contained in:
Tobias Brunner
2012-03-20 17:31:10 +01:00
parent 4ace4daf0c
commit 61e2a1ad8a
+8
View File
@@ -376,6 +376,10 @@ METHOD(task_t, build_i, status_t,
{
u_int16_t group;
if (!this->keymat->create_hasher(this->keymat, this->proposal))
{
return FAILED;
}
if (!this->proposal->get_algorithm(this->proposal,
DIFFIE_HELLMAN_GROUP, &group, NULL))
{
@@ -470,6 +474,10 @@ METHOD(task_t, process_r, status_t,
{
u_int16_t group;
if (!this->keymat->create_hasher(this->keymat, this->proposal))
{
return FAILED;
}
if (!this->proposal->get_algorithm(this->proposal,
DIFFIE_HELLMAN_GROUP, &group, NULL))
{