f45246541e903322cbc33ebb74c8e011d7845b56
[strongswan.git] / src / libcharon / plugins / tnccs_20 / tnccs_20_types.h
1 /*
2 * Copyright (C) 2010 Sansar Choinynambuu
3 * HSR Hochschule fuer Technik Rapperswil
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * for more details.
14 */
15
16 /**
17 * @defgroup tnccs_20_types_h tnccs_20
18 * @{ @ingroup tnccs_20
19 */
20
21 #ifndef TNCCS_20_TYPES_H_
22 #define TNCCS_20_TYPES_H_
23
24 #include <library.h>
25
26 typedef enum pb_tnc_batch_type_t pb_tnc_batch_type_t;
27 typedef enum pb_tnc_msg_type_t pb_tnc_msg_type_t;
28 typedef enum pb_tnc_remed_param_type_t pb_tnc_remed_param_type_t;
29 typedef enum pb_tnc_error_code_t pb_tnc_error_code_t;
30 typedef enum pa_tnc_subtype_t pa_tnc_subtype_t;
31
32 /**
33 * PB-TNC Batch Types as defined in section 4.1 of RFC 5793
34 */
35 enum pb_tnc_batch_type_t {
36 PB_BATCH_CDATA = 1,
37 PB_BATCH_SDATA = 2,
38 PB_BATCH_RESULT = 3,
39 PB_BATCH_CRETRY = 4,
40 PB_BATCH_SRETRY = 5,
41 PB_BATCH_CLOSE = 6
42 };
43
44 /**
45 * enum name for pb_tnc_batch_type_t.
46 */
47 extern enum_name_t *pb_tnc_batch_type_names;
48
49 /**
50 * PB-TNC Message Types as defined in section 4.3 of RFC 5793
51 */
52 enum pb_tnc_msg_type_t {
53 PB_MSG_EXPERIMENTAL = 0,
54 PB_MSG_PA = 1,
55 PB_MSG_ASSESSMENT_RESULT = 2,
56 PB_MSG_ACCESS_RECOMMENDATION = 3,
57 PB_MSG_REMEDIATION_PARAMETERS = 4,
58 PB_MSG_ERROR = 5,
59 PB_MSG_LANGUAGE_PREFERENCE = 6,
60 PB_MSG_REASON_STRING = 7,
61 PB_MSG_ROOF = 7
62 };
63
64 /**
65 * enum name for pb_tnc_msg_type_t.
66 */
67 extern enum_name_t *pb_tnc_msg_type_names;
68
69 /**
70 * PB-TNC Remediation Parameter Types as defined in section 4.8.1 of RFC 5793
71 */
72 enum pb_tnc_remed_param_type_t {
73 PB_REMEDIATION_URI = 1,
74 PB_REMEDIATION_STRING = 2,
75 };
76
77 /**
78 * enum name for pb_tnc_remed_param_type_t.
79 */
80 extern enum_name_t *pb_tnc_remed_param_type_names;
81
82 /**
83 * PB-TNC Error Codes as defined in section 4.9.1 of RFC 5793
84 */
85 enum pb_tnc_error_code_t {
86 PB_ERROR_UNEXPECTED_BATCH_TYPE = 0,
87 PB_ERROR_INVALID_PARAMETER = 1,
88 PB_ERROR_LOCAL_ERROR = 2,
89 PB_ERROR_UNSUPPORTED_MANDATORY_MESSAGE = 3,
90 PB_ERROR_VERSION_NOT_SUPPORTED = 4
91 };
92
93 /**
94 * enum name for pb_tnc_error_code_t.
95 */
96 extern enum_name_t *pb_tnc_error_code_names;
97
98 /**
99 * PA-TNC Subtypes as defined in section 3.5 of RFC 5792
100 */
101 enum pa_tnc_subtype_t {
102 PA_SUBTYPE_TESTING = 0,
103 PA_SUBTYPE_OPERATING_SYSTEM = 1,
104 PA_SUBTYPE_ANTI_VIRUS = 2,
105 PA_SUBTYPE_ANTI_SPYWARE = 3,
106 PA_SUBTYPE_ANTI_MALWARE = 4,
107 PA_SUBTYPE_FIREWALL = 5,
108 PA_SUBTYPE_IDPS = 6,
109 PA_SUBTYPE_VPN = 7,
110 PA_SUBTYPE_NEA_CLIENT = 8
111 };
112
113 /**
114 * enum name for pa_tnc_subtype_t.
115 */
116 extern enum_name_t *pa_tnc_subtype_names;
117
118 #endif /** TNCCS_20_TYPES_H_ @}*/