summaryrefslogtreecommitdiff
path: root/src/libtnccs
diff options
context:
space:
mode:
Diffstat (limited to 'src/libtnccs')
-rw-r--r--src/libtnccs/Makefile.in14
-rw-r--r--src/libtnccs/tnc/imv/imv_recommendations.h10
-rw-r--r--src/libtnccs/tnc/tnc.c14
-rw-r--r--src/libtnccs/tnc/tnccs/tnccs_manager.h2
4 files changed, 24 insertions, 16 deletions
diff --git a/src/libtnccs/Makefile.in b/src/libtnccs/Makefile.in
index 61a51fb4c..5eac73ab0 100644
--- a/src/libtnccs/Makefile.in
+++ b/src/libtnccs/Makefile.in
@@ -49,6 +49,7 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/config/libtool.m4 \
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
@@ -78,7 +79,7 @@ libtnccs_la_DEPENDENCIES = $(top_builddir)/src/libtncif/libtncif.la
am_libtnccs_la_OBJECTS = tnc.lo imv_recommendations.lo tnccs.lo \
tnccs_manager.lo
libtnccs_la_OBJECTS = $(am_libtnccs_la_OBJECTS)
-DEFAULT_INCLUDES = -I.@am__isrc@
+DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
am__mv = mv -f
@@ -104,6 +105,7 @@ AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
+BFDLIB = @BFDLIB@
BTLIB = @BTLIB@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
@@ -198,11 +200,14 @@ build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
c_plugins = @c_plugins@
+charon_natt_port = @charon_natt_port@
+charon_plugins = @charon_plugins@
+charon_udp_port = @charon_udp_port@
clearsilver_LIBS = @clearsilver_LIBS@
datadir = @datadir@
datarootdir = @datarootdir@
dbusservicedir = @dbusservicedir@
-default_pkcs11 = @default_pkcs11@
+dev_headers = @dev_headers@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
@@ -219,11 +224,12 @@ imcvdir = @imcvdir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
+ipsec_script = @ipsec_script@
+ipsec_script_upper = @ipsec_script_upper@
ipsecdir = @ipsecdir@
ipsecgroup = @ipsecgroup@
ipseclibdir = @ipseclibdir@
ipsecuser = @ipsecuser@
-libcharon_plugins = @libcharon_plugins@
libdir = @libdir@
libexecdir = @libexecdir@
linux_headers = @linux_headers@
@@ -239,6 +245,7 @@ mkdir_p = @mkdir_p@
nm_CFLAGS = @nm_CFLAGS@
nm_LIBS = @nm_LIBS@
nm_ca_dir = @nm_ca_dir@
+nm_plugins = @nm_plugins@
oldincludedir = @oldincludedir@
openac_plugins = @openac_plugins@
p_plugins = @p_plugins@
@@ -248,7 +255,6 @@ pdfdir = @pdfdir@
piddir = @piddir@
pki_plugins = @pki_plugins@
plugindir = @plugindir@
-pluto_plugins = @pluto_plugins@
pool_plugins = @pool_plugins@
prefix = @prefix@
program_transform_name = @program_transform_name@
diff --git a/src/libtnccs/tnc/imv/imv_recommendations.h b/src/libtnccs/tnc/imv/imv_recommendations.h
index d694e16ae..e7fe355f7 100644
--- a/src/libtnccs/tnc/imv/imv_recommendations.h
+++ b/src/libtnccs/tnc/imv/imv_recommendations.h
@@ -68,6 +68,11 @@ struct recommendations_t {
TNC_IMV_Evaluation_Result *eval);
/**
+ * Clear all recommendation information
+ */
+ void (*clear_recommendation)(recommendations_t *this);
+
+ /**
* Get the preferred language for remediation messages
*
* @return preferred language
@@ -110,11 +115,6 @@ struct recommendations_t {
enumerator_t* (*create_reason_enumerator)(recommendations_t *this);
/**
- * Clears all reason entries
- */
- void (*clear_reasons)(recommendations_t *this);
-
- /**
* Destroys an imv_t object.
*/
void (*destroy)(recommendations_t *this);
diff --git a/src/libtnccs/tnc/tnc.c b/src/libtnccs/tnc/tnc.c
index 652afc291..7c0ee4132 100644
--- a/src/libtnccs/tnc/tnc.c
+++ b/src/libtnccs/tnc/tnc.c
@@ -57,7 +57,7 @@ void libtnccs_init(void)
INIT(this,
.public = {
},
- );
+ );
tnc = &this->public;
}
@@ -75,6 +75,7 @@ void libtnccs_deinit(void)
static bool load_imcvs_from_config(char *filename, bool is_imc)
{
+ bool success = FALSE;
int fd, line_nr = 0;
chunk_t src, line;
struct stat sb;
@@ -110,7 +111,6 @@ static bool load_imcvs_from_config(char *filename, bool is_imc)
while (fetchline(&src, &line))
{
char *name, *path;
- bool success;
chunk_t token;
line_nr++;
@@ -126,7 +126,7 @@ static bool load_imcvs_from_config(char *filename, bool is_imc)
{
DBG1(DBG_TNC, "line %d: keyword must be followed by a space",
line_nr);
- return FALSE;
+ break;
}
/* only interested in IMCs or IMVs depending on label */
@@ -141,7 +141,7 @@ static bool load_imcvs_from_config(char *filename, bool is_imc)
{
DBG1(DBG_TNC, "line %d: %s name must be set in double quotes",
line_nr, label);
- return FALSE;
+ break;
}
/* copy the IMC/IMV name */
@@ -154,7 +154,7 @@ static bool load_imcvs_from_config(char *filename, bool is_imc)
{
DBG1(DBG_TNC, "line %d: %s path is missing", line_nr, label);
free(name);
- return FALSE;
+ break;
}
if (!extract_token(&token, ' ', &line))
{
@@ -177,12 +177,12 @@ static bool load_imcvs_from_config(char *filename, bool is_imc)
}
if (!success)
{
- return FALSE;
+ break;
}
}
munmap(addr, sb.st_size);
close(fd);
- return TRUE;
+ return success;
}
/**
diff --git a/src/libtnccs/tnc/tnccs/tnccs_manager.h b/src/libtnccs/tnc/tnccs/tnccs_manager.h
index 9ca450468..cbf2dc0e9 100644
--- a/src/libtnccs/tnc/tnccs/tnccs_manager.h
+++ b/src/libtnccs/tnc/tnccs/tnccs_manager.h
@@ -70,6 +70,7 @@ struct tnccs_manager_t {
* @param tnccs TNCCS connection instance
* @param send_message TNCCS callback function
* @param request_handshake_retry pointer to boolean variable
+ * @param max_msg_len maximum PA-TNC message size
* @param recs pointer to IMV recommendation set
* @return assigned connection ID
*/
@@ -77,6 +78,7 @@ struct tnccs_manager_t {
tnccs_type_t type, tnccs_t *tnccs,
tnccs_send_message_t send_message,
bool *request_handshake_retry,
+ u_int32_t max_msg_len,
recommendations_t **recs);
/**