aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndreas Steffen <andreas.steffen@strongswan.org>2010-11-10 22:42:36 +0100
committerAndreas Steffen <andreas.steffen@strongswan.org>2010-11-10 22:42:36 +0100
commitc2835ef29f451226155b2ad413c98ead13a23ff0 (patch)
tree1db76bad81e7fe6d1ced997784ea41af6f0616c6 /src
parent3db904641ebb5dfbd72b8baa9f4df0287326ae80 (diff)
downloadstrongswan-c2835ef29f451226155b2ad413c98ead13a23ff0.tar.bz2
strongswan-c2835ef29f451226155b2ad413c98ead13a23ff0.tar.xz
created dummy have_recommendation() function
Diffstat (limited to 'src')
-rw-r--r--src/libcharon/plugins/tnccs_20/tnccs_20.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/src/libcharon/plugins/tnccs_20/tnccs_20.c b/src/libcharon/plugins/tnccs_20/tnccs_20.c
index 10365d6b0..156b6ef7b 100644
--- a/src/libcharon/plugins/tnccs_20/tnccs_20.c
+++ b/src/libcharon/plugins/tnccs_20/tnccs_20.c
@@ -87,6 +87,16 @@ struct private_tnccs_20_t {
mutex_t *recommendation_mutex;
};
+static bool have_recommendation(private_tnccs_20_t *this,
+ TNC_IMV_Action_Recommendation *rec,
+ TNC_IMV_Evaluation_Result *eval)
+{
+ /* TODO */
+ *rec = TNC_IMV_ACTION_RECOMMENDATION_ALLOW;
+ *eval = TNC_IMV_EVALUATION_RESULT_COMPLIANT;
+ return TRUE;
+}
+
METHOD(tnccs_t, send_message, void,
private_tnccs_20_t* this, TNC_BufferReference message,
TNC_UInt32 message_len,
@@ -232,7 +242,17 @@ METHOD(tls_t, get_purpose, tls_purpose_t,
METHOD(tls_t, is_complete, bool,
private_tnccs_20_t *this)
{
- return FALSE;
+ TNC_IMV_Action_Recommendation rec;
+ TNC_IMV_Evaluation_Result eval;
+
+ if (this->is_server && have_recommendation(this, &rec, &eval))
+ {
+ return charon->imvs->enforce_recommendation(charon->imvs, rec);
+ }
+ else
+ {
+ return FALSE;
+ }
}
METHOD(tls_t, get_eap_msk, chunk_t,