aboutsummaryrefslogtreecommitdiffstats
path: root/src/libimcv/plugins/imc_test/imc_test.c
diff options
context:
space:
mode:
authorAndreas Steffen <andreas.steffen@strongswan.org>2011-07-13 22:18:32 +0200
committerAndreas Steffen <andreas.steffen@strongswan.org>2011-07-13 22:18:32 +0200
commit47f2da4ef9f1a7fa0a34f00efdd9885f622867b9 (patch)
treec7fba750937325c9c4fe7b3e5565e93b6d535d91 /src/libimcv/plugins/imc_test/imc_test.c
parenta96d9abf3eb4f9a251cda59e0abe1ffca1fe5303 (diff)
downloadstrongswan-47f2da4ef9f1a7fa0a34f00efdd9885f622867b9.tar.bz2
strongswan-47f2da4ef9f1a7fa0a34f00efdd9885f622867b9.tar.xz
support of error_offset in PA-TNC INVALID PARAMETER error messages
Diffstat (limited to 'src/libimcv/plugins/imc_test/imc_test.c')
-rw-r--r--src/libimcv/plugins/imc_test/imc_test.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/libimcv/plugins/imc_test/imc_test.c b/src/libimcv/plugins/imc_test/imc_test.c
index 8cbfa900b..06cc076db 100644
--- a/src/libimcv/plugins/imc_test/imc_test.c
+++ b/src/libimcv/plugins/imc_test/imc_test.c
@@ -219,6 +219,7 @@ TNC_Result TNC_IMC_ReceiveMessage(TNC_IMCID imc_id,
ietf_attr_pa_tnc_error_t *error_attr;
pa_tnc_error_code_t error_code;
chunk_t msg_info, attr_info;
+ u_int32_t offset;
error_attr = (ietf_attr_pa_tnc_error_t*)attr;
error_code = error_attr->get_error_code(error_attr);
@@ -228,6 +229,10 @@ TNC_Result TNC_IMC_ReceiveMessage(TNC_IMCID imc_id,
pa_tnc_error_code_names, error_code, &msg_info);
switch (error_code)
{
+ case PA_ERROR_INVALID_PARAMETER:
+ offset = error_attr->get_offset(error_attr);
+ DBG1(DBG_IMC, " occurred at offset of %u bytes", offset);
+ break;
case PA_ERROR_ATTR_TYPE_NOT_SUPPORTED:
attr_info = error_attr->get_attr_info(error_attr);
DBG1(DBG_IMC, " unsupported attribute %#B", &attr_info);