2 * EAP-TNC - TNCS (IF-IMV, IF-TNCCS, and IF-TNCCS-SOH)
3 * Copyright (c) 2007-2008, Jouni Malinen <j@w1.fi>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 2 as
7 * published by the Free Software Foundation.
9 * Alternatively, this software may be distributed under the terms of BSD
12 * See README and COPYING for more details.
20 struct tncs_data
* tncs_init(void);
21 void tncs_deinit(struct tncs_data
*tncs
);
22 void tncs_init_connection(struct tncs_data
*tncs
);
23 size_t tncs_total_send_len(struct tncs_data
*tncs
);
24 u8
* tncs_copy_send_buf(struct tncs_data
*tncs
, u8
*pos
);
25 char * tncs_if_tnccs_start(struct tncs_data
*tncs
);
26 char * tncs_if_tnccs_end(void);
28 enum tncs_process_res
{
29 TNCCS_PROCESS_ERROR
= -1,
30 TNCCS_PROCESS_OK_NO_RECOMMENDATION
= 0,
31 TNCCS_RECOMMENDATION_ERROR
,
32 TNCCS_RECOMMENDATION_ALLOW
,
33 TNCCS_RECOMMENDATION_NONE
,
34 TNCCS_RECOMMENDATION_ISOLATE
,
35 TNCCS_RECOMMENDATION_NO_ACCESS
,
36 TNCCS_RECOMMENDATION_NO_RECOMMENDATION
39 enum tncs_process_res
tncs_process_if_tnccs(struct tncs_data
*tncs
,
40 const u8
*msg
, size_t len
);
42 int tncs_global_init(void);
43 void tncs_global_deinit(void);
45 struct wpabuf
* tncs_build_soh_request(void);
46 struct wpabuf
* tncs_process_soh(const u8
*soh_tlv
, size_t soh_tlv_len
,