2014-07-11 22:12:11 +02:00
|
|
|
#include <stdlib.h>
|
|
|
|
#include <string.h>
|
|
|
|
|
|
|
|
#include <sys/types.h>
|
|
|
|
#include <sys/socket.h>
|
|
|
|
|
2016-03-03 20:46:20 +01:00
|
|
|
#include "cw/sock.h"
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
#include "socklist.h"
|
|
|
|
#include "conf.h"
|
|
|
|
|
2016-03-03 20:46:20 +01:00
|
|
|
#include "cw/capwap.h"
|
2016-03-08 20:06:42 +01:00
|
|
|
//#include "cw/capwap_80211.h"
|
2016-03-03 20:46:20 +01:00
|
|
|
#include "cw/aciplist.h"
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
|
2015-04-26 14:17:40 +02:00
|
|
|
/*
|
2014-07-28 07:06:59 +02:00
|
|
|
int pr(void *x,void *y){
|
|
|
|
}
|
2015-04-26 14:17:40 +02:00
|
|
|
*/
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-04-26 14:17:40 +02:00
|
|
|
/*
|
2014-07-28 07:06:59 +02:00
|
|
|
struct radioinfo * get_radioinfo()
|
|
|
|
{
|
|
|
|
|
|
|
|
}
|
2015-04-26 14:17:40 +02:00
|
|
|
*/
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-04-12 10:19:02 +02:00
|
|
|
/*
|
2014-07-11 22:12:11 +02:00
|
|
|
struct ac_info * get_acinfo()
|
|
|
|
{
|
|
|
|
|
|
|
|
struct ac_info * acinfo;
|
|
|
|
acinfo = malloc(sizeof(struct ac_info));
|
|
|
|
if(!acinfo)
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
memset(acinfo,0,sizeof(struct ac_info));
|
|
|
|
acinfo->ac_name=conf_acname;
|
|
|
|
|
|
|
|
acinfo->stations=10;
|
|
|
|
acinfo->limit=10000;
|
|
|
|
acinfo->active_wtps=10;
|
|
|
|
acinfo->max_wtps=conf_max_wtps;
|
2015-04-12 10:19:02 +02:00
|
|
|
acinfo->rmac=1;
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
acinfo->vendor_id=conf_vendor_id;
|
2014-08-23 22:18:25 +02:00
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
acinfo->hardware_version=(uint8_t*)conf_hardware_version;
|
|
|
|
acinfo->software_version=(uint8_t*)conf_software_version;
|
2015-03-15 20:53:21 +01:00
|
|
|
acinfo->cisco_hardware_version=(uint8_t*)conf_cisco_hardware_version;
|
|
|
|
acinfo->cisco_software_version=(uint8_t*)conf_cisco_software_version;
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
if (conf_dtls_psk)
|
|
|
|
acinfo->security|=AC_SECURITY_S;
|
2014-08-02 14:24:01 +02:00
|
|
|
if (conf_sslkeyfilename && conf_sslcertfilename)
|
|
|
|
acinfo->security|=AC_SECURITY_X;
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2014-07-28 07:06:59 +02:00
|
|
|
|
2015-04-05 02:07:59 +02:00
|
|
|
// acinfo->dtls_policy = AC_DTLS_POLICY_C | AC_DTLS_POLICY_D ;
|
2014-07-11 22:12:11 +02:00
|
|
|
// acinfo->ac_ips = conf_ac_ips;
|
|
|
|
// acinfo->ac_ips_len=conf_ac_ips_len;
|
|
|
|
|
|
|
|
// acinfo->salist=conf_salist;
|
|
|
|
// acinfo->salist_len=conf_salist_len;
|
|
|
|
|
|
|
|
// acinfo->salist = conf_ac_ips;
|
|
|
|
// acinfo->salist_len = conf_ac_ips_len;
|
|
|
|
|
2015-04-05 02:07:59 +02:00
|
|
|
//acinfo->aciplist=get_aciplist();
|
2014-07-28 07:06:59 +02:00
|
|
|
|
2015-04-12 10:19:02 +02:00
|
|
|
|
2014-07-28 07:06:59 +02:00
|
|
|
aciplist_foreach(acinfo->aciplist,pr,NULL);
|
2015-04-05 02:07:59 +02:00
|
|
|
*/
|
2015-04-12 10:19:02 +02:00
|
|
|
|
|
|
|
/*
|
2014-07-28 07:06:59 +02:00
|
|
|
int i;
|
2014-08-02 14:24:01 +02:00
|
|
|
for (i=1; i<=4; i++){
|
2014-07-28 07:06:59 +02:00
|
|
|
acinfo->radioinfos[i].type=
|
2015-03-19 21:51:28 +01:00
|
|
|
CW_80211_RADIO_TYPE_B |
|
|
|
|
CW_80211_RADIO_TYPE_A |
|
|
|
|
CW_80211_RADIO_TYPE_G |
|
|
|
|
CW_80211_RADIO_TYPE_N;
|
2014-08-02 14:24:01 +02:00
|
|
|
// acinfo->radioinfos[i].type=0xffffffff;
|
2014-07-28 07:06:59 +02:00
|
|
|
acinfo->radioinfos[i].rid=i;
|
|
|
|
}
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
return acinfo;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2015-04-12 10:19:02 +02:00
|
|
|
*/
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-04-26 14:17:40 +02:00
|
|
|
/*
|
2014-07-11 22:12:11 +02:00
|
|
|
get_join_result()
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
2015-04-26 14:17:40 +02:00
|
|
|
*/
|
2014-07-11 22:12:11 +02:00
|
|
|
|