Moved debug.[ch] to utils folder
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
#include <tncif_pa_subtypes.h>
|
||||
|
||||
#include <pen/pen.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
/* IMC definitions */
|
||||
|
||||
@@ -329,7 +329,7 @@ static TNC_Result receive_message(imc_msg_t *in_msg)
|
||||
break;
|
||||
}
|
||||
}
|
||||
e->destroy(e);
|
||||
e->destroy(e);
|
||||
}
|
||||
else if (attr_type.type == IETF_ATTR_REMEDIATION_INSTRUCTIONS)
|
||||
{
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
#include <tncif_names.h>
|
||||
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
typedef struct private_imc_os_state_t private_imc_os_state_t;
|
||||
|
||||
@@ -155,7 +155,7 @@ imc_state_t *imc_os_state_create(TNC_ConnectionID connection_id)
|
||||
.result = TNC_IMV_EVALUATION_RESULT_DONT_KNOW,
|
||||
.connection_id = connection_id,
|
||||
);
|
||||
|
||||
|
||||
return &this->public.interface;
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
#include <pen/pen.h>
|
||||
#include <utils/lexparser.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
#include <tncif_names.h>
|
||||
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
typedef struct private_imc_scanner_state_t private_imc_scanner_state_t;
|
||||
|
||||
@@ -155,7 +155,7 @@ imc_state_t *imc_scanner_state_create(TNC_ConnectionID connection_id)
|
||||
.result = TNC_IMV_EVALUATION_RESULT_DONT_KNOW,
|
||||
.connection_id = connection_id,
|
||||
);
|
||||
|
||||
|
||||
return &this->public.interface;
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
#include <tncif_pa_subtypes.h>
|
||||
|
||||
#include <pen/pen.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
/* IMC definitions */
|
||||
|
||||
@@ -36,7 +36,7 @@ static pen_type_t msg_types[] = {
|
||||
};
|
||||
|
||||
static imc_agent_t *imc_test;
|
||||
|
||||
|
||||
/**
|
||||
* see section 3.8.1 of TCG TNC IF-IMC Specification 1.3
|
||||
*/
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
#include <tncif_names.h>
|
||||
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
#include <collections/linked_list.h>
|
||||
|
||||
typedef struct private_imc_test_state_t private_imc_test_state_t;
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
|
||||
#include <pen/pen.h>
|
||||
#include <collections/linked_list.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
/* IMV definitions */
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
#include "imv_os_state.h"
|
||||
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
typedef struct private_imv_os_state_t private_imv_os_state_t;
|
||||
|
||||
@@ -81,7 +81,7 @@ struct entry_t {
|
||||
};
|
||||
|
||||
/**
|
||||
* Table of multi-lingual reason string entries
|
||||
* Table of multi-lingual reason string entries
|
||||
*/
|
||||
static entry_t reasons[] = {
|
||||
{ "en", "" },
|
||||
@@ -211,7 +211,7 @@ imv_state_t *imv_os_state_create(TNC_ConnectionID connection_id)
|
||||
.eval = TNC_IMV_EVALUATION_RESULT_DONT_KNOW,
|
||||
.connection_id = connection_id,
|
||||
);
|
||||
|
||||
|
||||
return &this->public.interface;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
#include <pen/pen.h>
|
||||
#include <collections/linked_list.h>
|
||||
#include <utils/lexparser.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
/* IMV definitions */
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
#include "imv_scanner_state.h"
|
||||
|
||||
#include <utils/lexparser.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
typedef struct private_imv_scanner_state_t private_imv_scanner_state_t;
|
||||
|
||||
@@ -87,7 +87,7 @@ struct entry_t {
|
||||
};
|
||||
|
||||
/**
|
||||
* Table of multi-lingual reason string entries
|
||||
* Table of multi-lingual reason string entries
|
||||
*/
|
||||
static entry_t reasons[] = {
|
||||
{ "en", "The following ports are open:" },
|
||||
@@ -189,7 +189,7 @@ METHOD(imv_state_t, get_reason_string, bool,
|
||||
if (chunk_equals(lang, pref_lang))
|
||||
{
|
||||
this->reason_string = chunk_cat("cc",
|
||||
chunk_create(reasons[i].string,
|
||||
chunk_create(reasons[i].string,
|
||||
strlen(reasons[i].string)),
|
||||
chunk_create(this->violating_ports,
|
||||
strlen(this->violating_ports)));
|
||||
@@ -208,7 +208,7 @@ METHOD(imv_state_t, get_reason_string, bool,
|
||||
chunk_create(this->violating_ports,
|
||||
strlen(this->violating_ports)));
|
||||
*reason_string = this->reason_string;
|
||||
*reason_language = chunk_create(reasons[0].lang,
|
||||
*reason_language = chunk_create(reasons[0].lang,
|
||||
strlen(reasons[0].lang));
|
||||
return TRUE;
|
||||
}
|
||||
@@ -256,7 +256,7 @@ imv_state_t *imv_scanner_state_create(TNC_ConnectionID connection_id)
|
||||
.eval = TNC_IMV_EVALUATION_RESULT_DONT_KNOW,
|
||||
.connection_id = connection_id,
|
||||
);
|
||||
|
||||
|
||||
return &this->public.interface;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
#include <tncif_pa_subtypes.h>
|
||||
|
||||
#include <pen/pen.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
/* IMV definitions */
|
||||
|
||||
@@ -130,7 +130,7 @@ static TNC_Result receive_message(imv_state_t *state, imv_msg_t *in_msg)
|
||||
{
|
||||
ita_attr_command_t *ita_attr;
|
||||
char *command;
|
||||
|
||||
|
||||
received_command = TRUE;
|
||||
ita_attr = (ita_attr_command_t*)attr;
|
||||
command = ita_attr->get_command(ita_attr);
|
||||
@@ -139,19 +139,19 @@ static TNC_Result receive_message(imv_state_t *state, imv_msg_t *in_msg)
|
||||
{
|
||||
state->set_recommendation(state,
|
||||
TNC_IMV_ACTION_RECOMMENDATION_ALLOW,
|
||||
TNC_IMV_EVALUATION_RESULT_COMPLIANT);
|
||||
TNC_IMV_EVALUATION_RESULT_COMPLIANT);
|
||||
}
|
||||
else if (streq(command, "isolate"))
|
||||
{
|
||||
state->set_recommendation(state,
|
||||
TNC_IMV_ACTION_RECOMMENDATION_ISOLATE,
|
||||
TNC_IMV_EVALUATION_RESULT_NONCOMPLIANT_MINOR);
|
||||
TNC_IMV_EVALUATION_RESULT_NONCOMPLIANT_MINOR);
|
||||
}
|
||||
else if (streq(command, "block") || streq(command, "none"))
|
||||
{
|
||||
state->set_recommendation(state,
|
||||
TNC_IMV_ACTION_RECOMMENDATION_NO_ACCESS,
|
||||
TNC_IMV_EVALUATION_RESULT_NONCOMPLIANT_MAJOR);
|
||||
TNC_IMV_EVALUATION_RESULT_NONCOMPLIANT_MAJOR);
|
||||
}
|
||||
else if (streq(command, "retry"))
|
||||
{
|
||||
@@ -162,7 +162,7 @@ static TNC_Result receive_message(imv_state_t *state, imv_msg_t *in_msg)
|
||||
DBG1(DBG_IMV, "unsupported ITA Command '%s'", command);
|
||||
state->set_recommendation(state,
|
||||
TNC_IMV_ACTION_RECOMMENDATION_NO_RECOMMENDATION,
|
||||
TNC_IMV_EVALUATION_RESULT_ERROR);
|
||||
TNC_IMV_EVALUATION_RESULT_ERROR);
|
||||
}
|
||||
}
|
||||
else if (attr_type.type == ITA_ATTR_DUMMY)
|
||||
@@ -199,7 +199,7 @@ static TNC_Result receive_message(imv_state_t *state, imv_msg_t *in_msg)
|
||||
state->get_connection_id(state),
|
||||
TNC_RETRY_REASON_IMV_SERIOUS_EVENT);
|
||||
}
|
||||
|
||||
|
||||
/* repeat the measurement ? */
|
||||
if (test_state->another_round(test_state, in_msg->get_src_id(in_msg)))
|
||||
{
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
#include <utils/lexparser.h>
|
||||
#include <collections/linked_list.h>
|
||||
#include <debug.h>
|
||||
#include <utils/debug.h>
|
||||
|
||||
typedef struct private_imv_test_state_t private_imv_test_state_t;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user