Changeset 438:e7814e24e57b in freeDiameter for extensions/app_diameap/diameap_server.h
- Timestamp:
- Jul 28, 2010, 3:59:39 PM (14 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/app_diameap/diameap_server.h
r425 r438 40 40 #define DIAMEAP_SERVER_H_ 41 41 42 /* handler for DiamEAP server callback */43 static struct disp_hdl * handle;44 45 /* session handler for DiamEAP sessions state machine */46 static struct session_handler * diameap_server_reg = NULL;47 42 48 43 /* session data structure to store */ … … 120 115 int diameap_stop_server(void); 121 116 122 /* Initialize DiamEAP state machine variables */117 /* Initialize DiamEAP state machine variables 123 118 static int diameap_initialize_diameap_sm( 124 119 struct diameap_state_machine * diameap_sm, 125 120 struct diameap_sess_data_sm * diameap_sess_data); 126 121 127 /* Initialize interface between the diameap and the eap states machines */ 122 Initialize interface between the diameap and the eap states machines 128 123 static int diameap_initialize_diameap_eap_interface( 129 124 struct diameap_eap_interface * eap_i); 130 125 131 /* Parse received message */ 126 Parse received message 132 127 static int diameap_parse_avps(struct diameap_state_machine * diameap_sm, 133 128 struct msg * req, struct diameap_eap_interface * eap_i); 134 129 135 /* Add an avp to Failed_AVP AVP for answer message */ 130 Add an avp to Failed_AVP AVP for answer message 136 131 static int diameap_failed_avp(struct diameap_state_machine * diameap_sm, 137 132 struct avp * invalidavp); 138 133 139 /* Parse EAP Response */ 134 Parse EAP Response 140 135 static int diameap_parse_eap_resp(struct eap_state_machine * eap_sm, 141 136 struct eap_packet eappacket); 142 137 143 /* */ 138 144 139 static int diameap_eappacket_new(struct eap_packet * eapPacket, 145 140 struct avp_hdr * avpdata); 146 141 147 /* */ 142 148 143 static int diameap_sess_data_new( 149 144 struct diameap_sess_data_sm *diameap_sess_data, 150 145 struct diameap_state_machine *diameap_sm); 151 146 152 /* */ 147 153 148 static int diameap_unlink_attributes_lists( 154 149 struct diameap_state_machine * diameap_sm); 155 150 156 /**/ 151 157 152 static int diameap_answer_avp_attributes( 158 153 struct diameap_state_machine * diameap_sm); 159 154 160 /**/ 155 161 156 static int diameap_answer_authorization_attributes( 162 157 struct diameap_state_machine * diameap_sm); … … 166 161 static void free_ans_attrib(struct avp_attribute * ans_attrib); 167 162 168 /* */ 163 169 164 static int diameap_get_avp_attribute(struct fd_list * avp_attributes, 170 165 char * attribute, struct avp_attribute ** avp_attrib, int unlink, 171 166 int *ret); 172 167 173 /* */ 168 174 169 static int diameap_get_auth_attribute(struct fd_list * auth_attributes, 175 170 char * attribute, struct auth_attribute ** auth_attrib, int unlink, 176 171 int *ret); 177 172 178 /**/ 173 179 174 static int diameap_get_ans_attribute(struct fd_list * ans_attributes, 180 175 char * attribute, struct avp_attribute ** ans_attrib, int unlink, 181 176 int *ret); 182 177 183 /* */ 178 184 179 static int diameap_policy_decision(struct diameap_state_machine * diameap_sm, 185 180 struct diameap_eap_interface eap_i); 186 181 187 /* */ 182 188 183 static int diameap_add_avps(struct diameap_state_machine * diameap_sm, 189 184 struct msg * ans, struct msg * req); 190 185 191 /* */ 186 192 187 static int diameap_add_user_sessions_avps( 193 188 struct diameap_state_machine * diameap_sm, struct msg * ans); 194 189 195 /* */ 190 196 191 static int diameap_add_result_code(struct diameap_state_machine * diameap_sm, 197 192 struct msg * ans, struct session * sess); 198 193 199 /* */ 194 200 195 static int diameap_add_eap_payload(struct diameap_state_machine * diameap_sm, 201 196 struct msg * ans, struct diameap_eap_interface eap_i); 202 197 203 /* */ 198 204 199 static int diameap_add_authorization_avps(struct diameap_state_machine * diameap_sm, 205 200 struct msg * ans); 206 201 207 /* */ 202 208 203 static int diameap_send(struct msg ** rmsg); 209 204 210 /* */ 205 211 206 static int diameap_add_eap_success_avps( 212 207 struct diameap_state_machine * diameap_sm, struct msg * ans, 213 208 struct diameap_eap_interface eap_i); 214 209 215 /* */ 210 216 211 void diameap_cli_sess_cleanup(void * arg, char * sid); 217 212 218 /* */ 213 219 214 static void diameap_free(struct diameap_state_machine * diameap_sm); 220 215 221 /* */ 216 222 217 static void diameap_sess_data_free( 223 218 struct diameap_sess_data_sm * diameap_sess_data); 224 219 225 /* */ 220 226 221 static int diameap_add_accounting_eap_auth_method( 227 222 struct diameap_state_machine * diameap_sm, struct msg * ans); 228 223 229 /* */ 230 static int diameap_add_eap_reissued_payload(struct msg * ans,struct msg * req); 224 225 static int diameap_add_eap_reissued_payload(struct msg * ans,struct msg * req);*/ 231 226 #endif /* DIAMEAP_SERVER_H_ */
Note: See TracChangeset
for help on using the changeset viewer.