24 |
24 |
25 |
25 |
26 #include "eap_am_assert.h" |
26 #include "eap_am_assert.h" |
27 #include "eap_am_tools.h" |
27 #include "eap_am_tools.h" |
28 #include "eap_tools.h" |
28 #include "eap_tools.h" |
|
29 #include "eap_am_export.h" |
|
30 // Start: added by script change_export_macros.sh. |
|
31 #if defined(EAP_NO_EXPORT_EAP_DIAMETER_AVP_CODE_H) |
|
32 #define EAP_CLASS_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_NONSHARABLE |
|
33 #define EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H |
|
34 #define EAP_C_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H |
|
35 #define EAP_FUNC_EXPORT_EAP_DIAMETER_AVP_CODE_H |
|
36 #define EAP_C_FUNC_EXPORT_EAP_DIAMETER_AVP_CODE_H |
|
37 #elif defined(EAP_EXPORT_EAP_DIAMETER_AVP_CODE_H) |
|
38 #define EAP_CLASS_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_EXPORT |
|
39 #define EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_FUNC_EXPORT |
|
40 #define EAP_C_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_C_FUNC_EXPORT |
|
41 #define EAP_FUNC_EXPORT_EAP_DIAMETER_AVP_CODE_H EAP_FUNC_EXPORT |
|
42 #define EAP_C_FUNC_EXPORT_EAP_DIAMETER_AVP_CODE_H EAP_C_FUNC_EXPORT |
|
43 #else |
|
44 #define EAP_CLASS_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_IMPORT |
|
45 #define EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_FUNC_IMPORT |
|
46 #define EAP_C_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H EAP_C_FUNC_IMPORT |
|
47 #define EAP_FUNC_EXPORT_EAP_DIAMETER_AVP_CODE_H |
|
48 #define EAP_C_FUNC_EXPORT_EAP_DIAMETER_AVP_CODE_H |
|
49 #endif |
|
50 // End: added by script change_export_macros.sh. |
|
51 |
29 |
52 |
30 |
53 |
31 /** @file */ |
54 /** @file */ |
32 |
55 |
33 /** |
56 /** |
111 |
134 |
112 //----------------------------------------------------------------------------------------- |
135 //----------------------------------------------------------------------------------------- |
113 //----------------------------------------------------------------------------------------- |
136 //----------------------------------------------------------------------------------------- |
114 //----------------------------------------------------------------------------------------- |
137 //----------------------------------------------------------------------------------------- |
115 |
138 |
116 class EAP_EXPORT eap_diameter_avp_code_c |
139 class EAP_CLASS_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c |
117 { |
140 { |
118 |
141 |
119 public: |
142 public: |
120 |
143 |
121 EAP_FUNC_IMPORT ~eap_diameter_avp_code_c(); |
144 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H ~eap_diameter_avp_code_c(); |
122 |
145 |
123 EAP_FUNC_IMPORT eap_diameter_avp_code_c(); |
146 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c(); |
124 |
147 |
125 EAP_FUNC_IMPORT eap_diameter_avp_code_c( |
148 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c( |
126 const eap_diameter_vendor_id_e vendor_id, |
149 const eap_diameter_vendor_id_e vendor_id, |
127 const u32_t vendor_code); |
150 const u32_t vendor_code); |
128 |
151 |
129 EAP_FUNC_IMPORT eap_diameter_avp_code_c( |
152 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c( |
130 const eap_diameter_avp_code_of_ietf_e ietf_code); |
153 const eap_diameter_avp_code_of_ietf_e ietf_code); |
131 |
154 |
132 |
155 |
133 EAP_FUNC_IMPORT static bool is_ietf_code(const eap_diameter_avp_code_c code); |
156 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H static bool is_ietf_code(const eap_diameter_avp_code_c code); |
134 |
157 |
135 |
158 |
136 EAP_FUNC_IMPORT eap_status_e get_code_data( |
159 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_status_e get_code_data( |
137 abs_eap_am_tools_c * const am_tools, |
160 abs_eap_am_tools_c * const am_tools, |
138 eap_diameter_avp_code_of_ietf_e * const code); |
161 eap_diameter_avp_code_of_ietf_e * const code); |
139 |
162 |
140 EAP_FUNC_IMPORT eap_status_e get_code_data( |
163 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_status_e get_code_data( |
141 abs_eap_am_tools_c * const am_tools, |
164 abs_eap_am_tools_c * const am_tools, |
142 eap_diameter_avp_code_c * const code); |
165 eap_diameter_avp_code_c * const code); |
143 |
166 |
144 |
167 |
145 EAP_FUNC_IMPORT void set_code_values( |
168 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H void set_code_values( |
146 const eap_diameter_vendor_id_e vendor_id, |
169 const eap_diameter_vendor_id_e vendor_id, |
147 const u32_t vendor_code); |
170 const u32_t vendor_code); |
148 |
171 |
149 EAP_FUNC_IMPORT eap_diameter_vendor_id_e get_vendor_id() const; |
172 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_vendor_id_e get_vendor_id() const; |
150 |
173 |
151 EAP_FUNC_IMPORT u32_t get_vendor_code() const; |
174 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H u32_t get_vendor_code() const; |
152 |
175 |
153 |
176 |
154 EAP_FUNC_IMPORT bool operator == (const eap_diameter_avp_code_of_ietf_e right_type_value) const; |
177 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H bool operator == (const eap_diameter_avp_code_of_ietf_e right_type_value) const; |
155 |
178 |
156 EAP_FUNC_IMPORT bool operator != (const eap_diameter_avp_code_of_ietf_e right_type_value) const; |
179 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H bool operator != (const eap_diameter_avp_code_of_ietf_e right_type_value) const; |
157 |
180 |
158 EAP_FUNC_IMPORT bool operator == (const eap_diameter_avp_code_c &right_type_value) const; |
181 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H bool operator == (const eap_diameter_avp_code_c &right_type_value) const; |
159 |
182 |
160 EAP_FUNC_IMPORT bool operator != (const eap_diameter_avp_code_c &right_type_value) const; |
183 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H bool operator != (const eap_diameter_avp_code_c &right_type_value) const; |
161 |
184 |
162 |
185 |
163 EAP_FUNC_IMPORT eap_diameter_avp_code_c &operator = (const eap_diameter_avp_code_of_ietf_e right_type_value); |
186 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c &operator = (const eap_diameter_avp_code_of_ietf_e right_type_value); |
164 |
187 |
165 EAP_FUNC_IMPORT eap_diameter_avp_code_c &operator = (const eap_diameter_avp_code_c &right_type_value); |
188 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c &operator = (const eap_diameter_avp_code_c &right_type_value); |
166 |
189 |
167 EAP_FUNC_IMPORT eap_diameter_avp_code_c *operator & (); |
190 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H eap_diameter_avp_code_c *operator & (); |
168 |
191 |
169 |
192 |
170 EAP_FUNC_IMPORT const eap_diameter_avp_code_c *operator & () const; |
193 EAP_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H const eap_diameter_avp_code_c *operator & () const; |
171 |
194 |
172 |
195 |
173 private: |
196 private: |
174 |
197 |
175 eap_diameter_vendor_id_e m_vendor_id; |
198 eap_diameter_vendor_id_e m_vendor_id; |
197 |
220 |
198 //----------------------------------------------------------------------------------------- |
221 //----------------------------------------------------------------------------------------- |
199 //----------------------------------------------------------------------------------------- |
222 //----------------------------------------------------------------------------------------- |
200 //----------------------------------------------------------------------------------------- |
223 //----------------------------------------------------------------------------------------- |
201 |
224 |
202 EAP_C_FUNC_IMPORT u32_t convert_eap_diameter_avp_code_to_u32_t(eap_diameter_avp_code_c code); |
225 EAP_C_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H u32_t convert_eap_diameter_avp_code_to_u32_t(eap_diameter_avp_code_c code); |
203 |
226 |
204 EAP_C_FUNC_IMPORT u64_t convert_eap_diameter_avp_code_to_u64_t(eap_diameter_avp_code_c code); |
227 EAP_C_FUNC_VISIBILITY_EAP_DIAMETER_AVP_CODE_H u64_t convert_eap_diameter_avp_code_to_u64_t(eap_diameter_avp_code_c code); |
205 |
228 |
206 //----------------------------------------------------------------------------------------- |
229 //----------------------------------------------------------------------------------------- |
207 |
230 |
208 #if defined(EAP_USE_TTLS_PLAIN_MS_CHAP_V2_HACK) |
231 #if defined(EAP_USE_TTLS_PLAIN_MS_CHAP_V2_HACK) |
209 |
232 |