Fixed AR identities in mutual TNC measurements case
This commit is contained in:
@@ -335,6 +335,10 @@ static eap_tnc_t *eap_tnc_create(identification_t *server,
|
|||||||
free(this);
|
free(this);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
if (!is_server)
|
||||||
|
{
|
||||||
|
tnccs->set_auth_type(tnccs, TNC_AUTH_X509_CERT);
|
||||||
|
}
|
||||||
this->tnccs = tnccs->get_ref(tnccs);
|
this->tnccs = tnccs->get_ref(tnccs);
|
||||||
this->tls_eap = tls_eap_create(type, &tnccs->tls,
|
this->tls_eap = tls_eap_create(type, &tnccs->tls,
|
||||||
EAP_TNC_MAX_MESSAGE_LEN,
|
EAP_TNC_MAX_MESSAGE_LEN,
|
||||||
|
|||||||
@@ -450,6 +450,7 @@ METHOD(pt_tls_client_t, run_assessment, status_t,
|
|||||||
{
|
{
|
||||||
return FAILED;
|
return FAILED;
|
||||||
}
|
}
|
||||||
|
tnccs->set_auth_type(tnccs, TNC_AUTH_X509_CERT);
|
||||||
|
|
||||||
DBG1(DBG_TNC, "entering PT-TLS data transport phase");
|
DBG1(DBG_TNC, "entering PT-TLS data transport phase");
|
||||||
if (!assess(this, (tls_t*)tnccs))
|
if (!assess(this, (tls_t*)tnccs))
|
||||||
|
|||||||
@@ -729,7 +729,9 @@ METHOD(tnccs_manager_t, get_attribute, TNC_Result,
|
|||||||
list = linked_list_create();
|
list = linked_list_create();
|
||||||
tnccs = entry->tnccs;
|
tnccs = entry->tnccs;
|
||||||
|
|
||||||
peer_id = tnccs->tls.get_peer_id(&tnccs->tls);
|
peer_id = tnccs->tls.is_server(&tnccs->tls) ?
|
||||||
|
tnccs->tls.get_peer_id(&tnccs->tls) :
|
||||||
|
tnccs->tls.get_server_id(&tnccs->tls);
|
||||||
if (peer_id)
|
if (peer_id)
|
||||||
{
|
{
|
||||||
switch (peer_id->get_type(peer_id))
|
switch (peer_id->get_type(peer_id))
|
||||||
@@ -771,7 +773,9 @@ METHOD(tnccs_manager_t, get_attribute, TNC_Result,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
peer_ip = tnccs->get_peer_ip(tnccs);
|
peer_ip = tnccs->tls.is_server(&tnccs->tls) ?
|
||||||
|
tnccs->get_peer_ip(tnccs) :
|
||||||
|
tnccs->get_server_ip(tnccs);
|
||||||
if (peer_ip)
|
if (peer_ip)
|
||||||
{
|
{
|
||||||
switch (peer_ip->get_family(peer_ip))
|
switch (peer_ip->get_family(peer_ip))
|
||||||
|
|||||||
Reference in New Issue
Block a user