added support of INVALID_PARAMETER PA-Error
[strongswan.git] / src / libimcv / plugins / imc_attestation / imc_attestation.c
index 743ba3c..22fd4f0 100644 (file)
@@ -173,6 +173,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);
@@ -182,6 +183,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);