From 5dc1ab61e4cce9f4194f2f124ef9e43146d3c072 Mon Sep 17 00:00:00 2001 From: "7u83@mail.ru" <7u83@mail.ru@noemail.net> Date: Fri, 24 Apr 2015 16:30:26 +0000 Subject: [PATCH] New ... FossilOrigin-Name: 21e83eda3d1e98dfb6f1db715efe0df69364a95f6cb1bdd1e9e844a9a60439f7 --- src/capwap/cw_in_check_cfg_upate_req.c | 30 +++++++++++++++++++ src/capwap/cw_in_radio_administrative_state.c | 19 ++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 src/capwap/cw_in_check_cfg_upate_req.c create mode 100644 src/capwap/cw_in_radio_administrative_state.c diff --git a/src/capwap/cw_in_check_cfg_upate_req.c b/src/capwap/cw_in_check_cfg_upate_req.c new file mode 100644 index 00000000..dee0089f --- /dev/null +++ b/src/capwap/cw_in_check_cfg_upate_req.c @@ -0,0 +1,30 @@ + +#include "capwap.h" +#include "intavltree.h" +#include "dbg.h" +#include "log.h" +#include "capwap_items.h" + +int cw_in_check_cfg_update_req(struct conn *conn, struct cw_action_in *a, uint8_t * data, + int len,struct sockaddr *from) +{ + + cw_action_in_t * mlist[60]; + + /* Check for mandatory elements */ + int n = cw_check_missing_mand(mlist,conn,a); + if (n) { + if ( conn->strict_capwap ){ + cw_dbg_missing_mand(DBG_MSG_ERR,conn,mlist,n,a); + conn->capwap_state=CW_STATE_JOIN; + return CW_RESULT_MISSING_MAND_ELEM; + } + cw_dbg_missing_mand(DBG_RFC,conn,mlist,n,a); + } + + + /* set result code to ok and change to configure state */ + mbag_set_dword(conn->outgoing,CW_ITEM_RESULT_CODE,0); + + return 0; +} diff --git a/src/capwap/cw_in_radio_administrative_state.c b/src/capwap/cw_in_radio_administrative_state.c new file mode 100644 index 00000000..b563526f --- /dev/null +++ b/src/capwap/cw_in_radio_administrative_state.c @@ -0,0 +1,19 @@ + +#include "action.h" +#include "dbg.h" +#include "log.h" +#include "mbag.h" +#include "capwap.h" + + + +int cw_in_radio_administrative_state(struct conn *conn, struct cw_action_in *a, uint8_t * data, int len, + struct sockaddr *from) +{ + int rid = cw_get_byte(data); + + mbag_get_mbag(conn->radios,rid,NULL); + + + return 1; +}