summaryrefslogtreecommitdiff
path: root/src/conftest
diff options
context:
space:
mode:
authorRené Mayrhofer <rene@mayrhofer.eu.org>2011-05-19 13:37:29 +0200
committerRené Mayrhofer <rene@mayrhofer.eu.org>2011-05-19 13:37:29 +0200
commit0a9d51a49042a68daa15b0c74a2b7f152f52606b (patch)
tree451888dcb17d00e52114f734e846821373fbbd44 /src/conftest
parent568905f488e63e28778f87ac0e38d845f45bae79 (diff)
downloadvyos-strongswan-0a9d51a49042a68daa15b0c74a2b7f152f52606b.tar.gz
vyos-strongswan-0a9d51a49042a68daa15b0c74a2b7f152f52606b.zip
Imported Upstream version 4.5.2
Diffstat (limited to 'src/conftest')
-rw-r--r--src/conftest/Makefile.in3
-rw-r--r--src/conftest/conftest.c2
-rw-r--r--src/conftest/hooks/log_ts.c24
3 files changed, 25 insertions, 4 deletions
diff --git a/src/conftest/Makefile.in b/src/conftest/Makefile.in
index 1c07710e0..a89df8f27 100644
--- a/src/conftest/Makefile.in
+++ b/src/conftest/Makefile.in
@@ -231,6 +231,8 @@ nm_ca_dir = @nm_ca_dir@
oldincludedir = @oldincludedir@
openac_plugins = @openac_plugins@
p_plugins = @p_plugins@
+pcsclite_CFLAGS = @pcsclite_CFLAGS@
+pcsclite_LIBS = @pcsclite_LIBS@
pdfdir = @pdfdir@
piddir = @piddir@
pki_plugins = @pki_plugins@
@@ -254,6 +256,7 @@ soup_LIBS = @soup_LIBS@
srcdir = @srcdir@
strongswan_conf = @strongswan_conf@
sysconfdir = @sysconfdir@
+systemdsystemunitdir = @systemdsystemunitdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
diff --git a/src/conftest/conftest.c b/src/conftest/conftest.c
index fea88818e..48bf9681f 100644
--- a/src/conftest/conftest.c
+++ b/src/conftest/conftest.c
@@ -79,7 +79,7 @@ static bool load_configs(char *suite_file, char *test_file)
return FALSE;
}
conftest->test = settings_create(suite_file);
- conftest->test->load_files(conftest->test, test_file);
+ conftest->test->load_files(conftest->test, test_file, TRUE);
conftest->suite_dir = strdup(dirname(suite_file));
return TRUE;
}
diff --git a/src/conftest/hooks/log_ts.c b/src/conftest/hooks/log_ts.c
index dacc7a58c..fb7c89a0a 100644
--- a/src/conftest/hooks/log_ts.c
+++ b/src/conftest/hooks/log_ts.c
@@ -38,7 +38,6 @@ METHOD(listener_t, message, bool,
{
enumerator_t *enumerator;
payload_t *payload;
- linked_list_t *list;
ts_payload_t *ts;
enumerator = message->create_payload_enumerator(message);
@@ -48,10 +47,29 @@ METHOD(listener_t, message, bool,
payload->get_type(payload) == TRAFFIC_SELECTOR_RESPONDER)
{
ts = (ts_payload_t*)payload;
+ host_t *from, *to;
+ linked_list_t *list;
+ enumerator_t *tsenum;
+ traffic_selector_t *selector;
+
list = ts->get_traffic_selectors(ts);
+ tsenum = list->create_enumerator(list);
+ while (tsenum->enumerate(tsenum, &selector))
+ {
+ from = host_create_from_chunk(AF_UNSPEC,
+ selector->get_from_address(selector), 0);
+ to = host_create_from_chunk(AF_UNSPEC,
+ selector->get_to_address(selector), 0);
+
+ DBG1(DBG_CFG, "received %N: %N %H-%H proto %u port %u-%u",
+ payload_type_short_names, payload->get_type(payload),
+ ts_type_name, selector->get_type(selector),
+ from, to, selector->get_protocol(selector),
+ selector->get_from_port(selector),
+ selector->get_to_port(selector));
+ }
+ tsenum->destroy(tsenum);
- DBG1(DBG_CFG, "received %N: %#R",
- payload_type_short_names, payload->get_type(payload), list);
list->destroy_offset(list, offsetof(traffic_selector_t, destroy));
}
}