[pisa-src] r1151 - in trunk/pisacd: cdconf.c cdconf.h cdconmgr.c cdconmgr.h cdctx.c cdctx.h cdmain.c cdmsg.c cdmsg.h

  • From: Thomas Jansen <mithi@xxxxxxxxx>
  • To: pisa-src@xxxxxxxxxxxxx
  • Date: Wed, 14 Oct 2009 17:12:26 +0200

Author: tjansen
Date: Wed Oct 14 17:12:26 2009
New Revision: 1151

Log:
Deprecated much of the preauth code in pisacd.

Modified:
   trunk/pisacd/cdconf.c
   trunk/pisacd/cdconf.h
   trunk/pisacd/cdconmgr.c
   trunk/pisacd/cdconmgr.h
   trunk/pisacd/cdctx.c
   trunk/pisacd/cdctx.h
   trunk/pisacd/cdmain.c
   trunk/pisacd/cdmsg.c
   trunk/pisacd/cdmsg.h

Modified: trunk/pisacd/cdconf.c
==============================================================================
--- trunk/pisacd/cdconf.c       Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdconf.c       Wed Oct 14 17:12:26 2009        (r1151)
@@ -29,15 +29,21 @@
 /* prototypes of static functions */
 static void cdconf_read_debuglevel(cd_conf *cdconf);
 static void cdconf_read_debugtypemask(cd_conf *cdconf);
+#ifdef REMOVE_PREAUTH_CODE
 static void cdconf_read_ifname_wlan(cd_conf *cdconf);
+#endif /* REMOVE_PREAUTH_CODE */
 static void cdconf_read_port_control(cd_conf *cdconf);
 static void cdconf_read_port_data(cd_conf *cdconf);
+#ifdef REMOVE_PREAUTH_CODE
 static void cdconf_read_port_pasrv(cd_conf *cdconf);
+#endif /* REMOVE_PREAUTH_CODE */
 static void cdconf_read_make_tunnel(cd_conf *cdconf);
+#ifdef REMOVE_PREAUTH_CODE
 static void cdconf_read_pareq_interval(cd_conf *cdconf);
 static void cdconf_read_pareq_maxretry(cd_conf *cdconf);
 static void cdconf_read_bureq_timeout(cd_conf *cdconf);
 static void cdconf_read_bureq_maxretry(cd_conf *cdconf);
+#endif /* REMOVE_PREAUTH_CODE */
 static void cdconf_read_idle_disconnect_delay(cd_conf *cdconf);
 static void cdconf_read_local_ipv4(cd_conf *cdconf);
 static void cdconf_read_local_netmask(cd_conf *cdconf);
@@ -52,20 +58,26 @@
 {
        memset(cdconf->conffile, 0, sizeof(cdconf->conffile));
        memset(cdconf->debuglevel, 0, sizeof(cdconf->debuglevel));
+#ifdef REMOVE_PREAUTH_CODE
        memset(cdconf->ifname_wlan, 0, sizeof(cdconf->ifname_wlan));
+#endif /* REMOVE_PREAUTH_CODE */
        memset(&cdconf->ipaddr, 0, sizeof(cdconf->ipaddr));
        memset(&cdconf->local_ipv4, 0, sizeof(cdconf->local_ipv4));
        memset(&cdconf->local_netmask, 0, sizeof(cdconf->local_netmask));
        cdconf->port_control = 0;
        cdconf->port_data = 0;
+#ifdef REMOVE_PREAUTH_CODE
        cdconf->port_pasrv = 0;
+#endif /* REMOVE_PREAUTH_CODE */
        cdconf->make_tunnel = UNDEFINED;
+#ifdef REMOVE_PREAUTH_CODE
        cdconf->heartbeat_timeout = PISACD_DEFAULT_HEARTBEAT_TIMEOUT;
        cdconf->heartbeat_maxretry = PISACD_DEFAULT_HEARTBEAT_MAXRETRY;
        cdconf->pareq_interval = PISACD_DEFAULT_PAREQ_INTERVAL;
        cdconf->pareq_maxretry = PISACD_DEFAULT_PAREQ_MAXRETRY;
        cdconf->bureq_timeout = PISACD_DEFAULT_BUREQ_TIMEOUT;
        cdconf->bureq_maxretry = PISACD_DEFAULT_BUREQ_MAXRETRY;
+#endif /* REMOVE_PREAUTH_CODE */
        cdconf->idle_disconnect_delay = PISACD_DEFAULT_IDLE_DISCONNECT_DELAY;
 }
 
@@ -108,17 +120,23 @@
        /* Read several configuration from pisacd.conf. */
        cdconf_read_debuglevel(cdconf);
        cdconf_read_debugtypemask(cdconf);
+#ifdef REMOVE_PREAUTH_CODE
        cdconf_read_ifname_wlan(cdconf);
+#endif /* REMOVE_PREAUTH_CODE */
        cdconf_read_port_control(cdconf);
        cdconf_read_port_data(cdconf);
+#ifdef REMOVE_PREAUTH_CODE
        cdconf_read_port_pasrv(cdconf);
+#endif /* REMOVE_PREAUTH_CODE */
        cdconf_read_make_tunnel(cdconf);
 /*        cdconf_read_heartbeat_timeout(cdconf);*/
 /*        cdconf_read_heartbeat_maxretry(cdconf);*/
+#ifdef REMOVE_PREAUTH_CODE
        cdconf_read_pareq_interval(cdconf);
        cdconf_read_pareq_maxretry(cdconf);
        cdconf_read_bureq_timeout(cdconf);
        cdconf_read_bureq_maxretry(cdconf);
+#endif /* REMOVE_PREAUTH_CODE */
        cdconf_read_idle_disconnect_delay(cdconf);
        cdconf_read_local_ipv4(cdconf);
        cdconf_read_local_netmask(cdconf);
@@ -153,6 +171,7 @@
        pisa_debug_set_type_mask((unsigned long)mask);
 }
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * Read the wireless interface name from the configuration file.
  *
@@ -168,6 +187,7 @@
                }
        }
 }
+#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Read the listening control port number from the configuration file.
@@ -211,6 +231,7 @@
        }
 }
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * Read the listening port number pasrv from the configuration file.
  *
@@ -231,6 +252,7 @@
                }
        }
 }
+#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Read the listening data port number from the configuration file.
@@ -258,6 +280,7 @@
        }
 }
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * Read the pre-authentication request interval from the configuration file.
  *
@@ -319,6 +342,7 @@
                cdconf->bureq_maxretry = PISACD_DEFAULT_BUREQ_MAXRETRY;
        }
 }
+#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Read the delay before idle connections are deregistered from the
@@ -373,6 +397,7 @@
        }
 }
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * Set several wlan info based on the interface name in the configuration file.
  *
@@ -421,6 +446,7 @@
        myaddr.s_addr = pisa_get_ifaddr(cdconf->ifname_wlan);
        pisa_ipv4_copy(&cdconf->ipaddr, &myaddr);
 }
+#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Set the global debug level variable
@@ -447,6 +473,7 @@
        }
 }
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * Get the configuration of bootstrap neighbor list from pisacd.conf
  *
@@ -672,3 +699,4 @@
 
        return len;
 }
+#endif /* REMOVE_PREAUTH_CODE */

Modified: trunk/pisacd/cdconf.h
==============================================================================
--- trunk/pisacd/cdconf.h       Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdconf.h       Wed Oct 14 17:12:26 2009        (r1151)
@@ -22,18 +22,24 @@
 typedef struct {
        char conffile[MAX_PATH+1]; /**< configuration file */
        char debuglevel[MAX_DEBUGLEVEL_STR+1];  /**< debug level */
+#ifdef REMOVE_PREAUTH_CODE
        char ifname_wlan[MAX_IFNAME+1]; /**< main wireless interface name of 
this client. */
+#endif /* REMOVE_PREAUTH_CODE */
        struct in_addr ipaddr; /**< IPv4 address of this client */
        int port_control;       /**< control port number to listen to */
        int port_data;          /**< data port number to listen to */
+#ifdef REMOVE_PREAUTH_CODE
        int port_pasrv;         /**< port to listen to pre-auth responses */
+#endif /* REMOVE_PREAUTH_CODE */
        int make_tunnel;        /**< whether to establish the tunnel */ /* TODO 
Why is this here WOLF */
+#ifdef REMOVE_PREAUTH_CODE
        int heartbeat_timeout;  /**< timeout when sending heartbeat packets */
        int heartbeat_maxretry; /**< max retry time when sending heartbeat 
packets */
        int pareq_interval;     /**< interval when sending pareq packets */
        int pareq_maxretry;     /**< max retry time when sending pareq packets 
*/
        int bureq_timeout;      /**< timeout when sending bureq packets */
        int bureq_maxretry;     /**< max retry time when sending bureq packets 
*/
+#endif /* REMOVE_PREAUTH_CODE */
        int idle_disconnect_delay; /**< number of seconds to wait before idle 
connections are deregistered */
        struct in_addr local_ipv4;
        struct in_addr local_netmask;
@@ -54,6 +60,7 @@
 
 void cdconf_read_basic_confs(cd_conf *cdconf);
 void cdconf_setup_conffile(cd_conf *cdconf);
+#ifdef REMOVE_PREAUTH_CODE
 void cdconf_set_wlaninfos(cd_conf *cdconf);
 
 /**
@@ -88,5 +95,6 @@
 
 int cd_config_get_bootstrap_neighbors(extractCDCnbCallback cb_bcn, 
extractCDRnbCallback cb_brn);
 int cd_config_get_default_ap(extractCDDAPCallback cb_dap);
+#endif /* REMOVE_PREAUTH_CODE */
 
 #endif /* PISA_CDCONF_H */

Modified: trunk/pisacd/cdconmgr.c
==============================================================================
--- trunk/pisacd/cdconmgr.c     Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdconmgr.c     Wed Oct 14 17:12:26 2009        (r1151)
@@ -19,6 +19,7 @@
 #include "socket.h"
 #include "util.h"
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * holds the biggest file descriptor (needed by select(2) calls)
  * for all associated file descriptors
@@ -197,3 +198,4 @@
 {
        return maxFD;
 }
+#endif /* REMOVE_PREAUTH_CODE */

Modified: trunk/pisacd/cdconmgr.h
==============================================================================
--- trunk/pisacd/cdconmgr.h     Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdconmgr.h     Wed Oct 14 17:12:26 2009        (r1151)
@@ -14,6 +14,7 @@
 #ifndef PISA_CDCONMGR_H
 #define PISA_CDCONMGR_H
 
+#ifdef REMOVE_PREAUTH_CODE
 #include <netinet/in.h>
 #include <net/if.h>
 
@@ -78,5 +79,6 @@
 void cdConMgrRemove(cdConMgrEntry* entry);
 void cdConMgrIterateOverEntries(fdCallback cb,void* data);
 int cdConMgrGetMaxFD(void);
+#endif /* REMOVE_PREAUTH_CODE */
 
 #endif /* PISA_CDCONMGR_H */

Modified: trunk/pisacd/cdctx.c
==============================================================================
--- trunk/pisacd/cdctx.c        Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdctx.c        Wed Oct 14 17:12:26 2009        (r1151)
@@ -21,6 +21,7 @@
  */
 cd_context cd_ctx;
 
+#ifdef REMOVE_PREAUTH_CODE
 static void add_conf_to_cnblist(const char* ssid, const char *macaddr, const 
int channel, const uint8_t quality);
 static void add_conf_to_rnblist(const char* ssid, const char *macaddr, const 
char *ipaddr, const char *token);
 static void add_conf_to_dapinfo(const char* ssid, const char *macaddr, const 
char *ipaddr, const uint16_t ndport);
@@ -36,6 +37,7 @@
        "eduroam-WPAonly",
        "mops"
 };
+#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Initialize general context of client daemon.
@@ -45,6 +47,7 @@
  */
 void cdctx_init(cd_context *cdctx)
 {
+#ifdef REMOVE_PREAUTH_CODE
        pisa_ll_init(&cdctx->cands_queue);
        pisa_ll_init(&cdctx->ready_queue);
        pisa_ll_init(&cdctx->bulist);
@@ -53,20 +56,25 @@
 
        cdctx->cq_offset = 0;
        cdctx->rq_offset = 0;
+#endif /* REMOVE_PREAUTH_CODE */
 
        cdctx->is_cd_running = FALSE;
        cdctx->is_bgrun = FALSE;
+#ifdef REMOVE_PREAUTH_CODE
        cdctx->is_scanning = FALSE;
        cdctx->is_sending_pareq = FALSE;
        cdctx->is_sending_bureq = FALSE;
+#endif /* REMOVE_PREAUTH_CODE */
        cdctx->tunnel = -1;
        cdctx->tunc = -1;
        cdctx->tund = -1;
+#ifdef REMOVE_PREAUTH_CODE
        cdctx->fd_pacli = -1;
        cdctx->fd_pasrv = -1;
 
        cdctx->pareq_tries_count = 0;
        cdctx->bureq_tries_count = 0;
+#endif /* REMOVE_PREAUTH_CODE */
 
        cdctx->ctrlhandlers = NULL;
        cdctx->natlist = NULL;
@@ -83,11 +91,14 @@
  */
 void cdctx_destroy(cd_context *cdctx)
 {
+#ifdef REMOVE_PREAUTH_CODE
        pisa_ll_uninit(&cdctx->cands_queue, pisa_free);
        pisa_ll_uninit(&cdctx->ready_queue, pisa_free);
        pisa_ll_uninit(&cdctx->bulist, pisa_free);
+#endif /* REMOVE_PREAUTH_CODE */
 }
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * Get a list of clients.
  *
@@ -640,3 +651,4 @@
 
        return FALSE;
 }
+#endif /* REMOVE_PREAUTH_CODE */

Modified: trunk/pisacd/cdctx.h
==============================================================================
--- trunk/pisacd/cdctx.h        Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdctx.h        Wed Oct 14 17:12:26 2009        (r1151)
@@ -25,6 +25,7 @@
  * current client daemon.
  */
 typedef struct {
+#ifdef REMOVE_PREAUTH_CODE
        pisa_ll cands_queue;    /* a queue of candidate client routers */
        pisa_ll ready_queue;    /* a priority queue of handover-ready routers */
        pisa_ll bulist; /* a priority queue of handover-ready routers */
@@ -48,6 +49,7 @@
         * the current index where the next handover-ready router is to be 
accessed
         */
        int rq_offset;
+#endif /* REMOVE_PREAUTH_CODE */
 
        /**
         * Flag for the internal packet processing loop.
@@ -61,6 +63,7 @@
         */
        int is_bgrun;
 
+#ifdef REMOVE_PREAUTH_CODE
        /**
         * Flag if scanning candidate neighbor access points
         */
@@ -75,6 +78,7 @@
         * Flag if sending binding update request packet to my AP
         */
        int is_sending_bureq;
+#endif /* REMOVE_PREAUTH_CODE */
 
        /**
         * Sockets for the tunnel device, the tunc and tund sockets
@@ -89,6 +93,7 @@
         */
        int fd_pisaconf;
 
+#ifdef REMOVE_PREAUTH_CODE
        /**
         * The file descriptor of the pre-authentication client socket,
         * on which outgoing packet is sent to the access router.
@@ -110,6 +115,7 @@
         * The current count value of binding update tries.
         */
        int bureq_tries_count;
+#endif /* REMOVE_PREAUTH_CODE */
 
        /**
         * Tunnel interface name.
@@ -139,6 +145,7 @@
 
 extern cd_context cd_ctx;
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * data structure defining a pair of core information about candidate routers
  */
@@ -169,6 +176,7 @@
        char macaddr[MAX_MACADDR+1];    /**< MAC address of access point */
        pisa_common_addr ipaddr;        /**< IP address obtained from peer 
neighbor */
 } pisacd_bulist_entry;
+#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Function prototypes
@@ -179,6 +187,7 @@
  */
 void cdctx_init(cd_context *cdctx);
 void cdctx_destroy(cd_context *cdctx);
+#ifdef REMOVE_PREAUTH_CODE
 int cdctx_get_neighbors(void);
 void cdctx_get_default_ap(void);
 
@@ -227,5 +236,6 @@
 pisacd_rlist_entry *pisacd_rlist_update_priority(pisa_ll *llist, const char 
*keyssid, const int priority);
 
 pisacd_bulist_entry *pisacd_bulist_lookup_ssid(pisa_ll *llist, const char 
*keyssid);
+#endif /* REMOVE_PREAUTH_CODE */
 
 #endif /* PISA_CDCTX_H */

Modified: trunk/pisacd/cdmain.c
==============================================================================
--- trunk/pisacd/cdmain.c       Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdmain.c       Wed Oct 14 17:12:26 2009        (r1151)
@@ -65,7 +65,9 @@
  */
 static const struct option cd_longopts[] = {
        {"config",      required_argument,      NULL,   'f'},
+#ifdef REMOVE_PREAUTH_CODE
        {"interface",   required_argument,      NULL,   'i'},
+#endif /* REMOVE_PREAUTH_CODE */
        {"port_control",        required_argument,      NULL,   'p'},
        {"port_data",   required_argument,      NULL,   'q'},
        {"skip_tunnel", no_argument,            NULL,   't'},
@@ -76,6 +78,7 @@
        {NULL,          0,                      NULL,   '\0'}
 };
 
+#ifdef REMOVE_PREAUTH_CODE
 /**
  * A set of pointers to packet handling functions
  */
@@ -84,7 +87,6 @@
 /**
  * Timeout management variables
  */
-#ifdef REMOVE_PREAUTH_CODE
 static time_t init_pareq_period;
 static time_t currentTime;
 #endif /* REMOVE_PREAUTH_CODE */
@@ -207,8 +209,10 @@
 
        /* Make default sockets */
        cd_ctx.tunnel = pisa_tunnel_open_tundev(cd_ctx.ifname_tunnel, IFNAMSIZ);
+#ifdef REMOVE_PREAUTH_CODE
        cd_ctx.fd_pacli = setup_sock_udp(AF_INET);
        cd_ctx.fd_pasrv = setup_listen_sock_udp(AF_INET, cd_cfg.port_pasrv);
+#endif /* REMOVE_PREAUTH_CODE */
        cd_ctx.fd_pisaconf = pisa_conf_open_server_socket(PISA_CONF_PORT_CD);
 
        /* open peer sockets targeting the pisa server daemon,
@@ -216,6 +220,7 @@
        cd_ctx.tunc = pisa_tunnel_open_socket(cd_cfg.port_control);
        cd_ctx.tund = pisa_tunnel_open_socket(cd_cfg.port_data);
 
+#ifdef REMOVE_PREAUTH_CODE
        /* Get neighbor routers, at the moment just reading them from conf file.
         * TODO: make some fancy way to determine neighbors... */
        cdctx_get_neighbors();
@@ -236,6 +241,7 @@
        pisacd_packet_handle_func_set.handle_vrfyres1 = pisacd_handle_vrfyres1;
        pisacd_packet_handle_func_set.handle_vrfyreq2 = pisacd_handle_vrfyreq2;
        pisacd_packet_handle_func_set.handle_vrfyres2 = pisacd_handle_vrfyres2;
+#endif /* REMOVE_PREAUTH_CODE */
 
        /* set handlers for tunnel control packet types */
        pisa_ctrlhandler_set(&cd_ctx.ctrlhandlers, 
PISA_PKTTYPE_TUN_REGISTER_ACK, pisa_recv_register_ack);
@@ -256,10 +262,10 @@
 #ifdef REMOVE_PREAUTH_CODE
        /* set the default alarm */
        cd_start_alarm();
-#endif /* REMOVE_PREAUTH_CODE */
 
        /* We should start sending pareq packets in the beginning. */
        cd_ctx.is_sending_pareq = TRUE;
+#endif /* REMOVE_PREAUTH_CODE */
 
        /* initialize the connection list */
        cd_ctx.conlist = 
pisa_conmgr_init(pisacd_cleanup_after_removed_connection);
@@ -286,8 +292,10 @@
        pisa_arp_cleanup();
        pisa_sched_cleanup();
 
+#ifdef REMOVE_PREAUTH_CODE
        close(cd_ctx.fd_pacli);
        close(cd_ctx.fd_pasrv);
+#endif /* REMOVE_PREAUTH_CODE */
        close(cd_ctx.fd_pisaconf);
        close(cd_ctx.tunc);
        close(cd_ctx.tund);
@@ -321,7 +329,9 @@
 
        memset(&from_addr, 0, sizeof(struct sockaddr_in));
 
+#ifdef REMOVE_PREAUTH_CODE
        cd_ctx.is_scanning = TRUE;
+#endif /* REMOVE_PREAUTH_CODE */
        cd_ctx.is_cd_running = TRUE;
 
        pisa_servers_add_all();
@@ -455,7 +465,6 @@
        fd_set *set = (fd_set *)data;
        FD_SET(entry->fd, set);
 }
-#endif /* REMOVE_PREAUTH_CODE */
 
 /**
  * Send pre-authentication request packet to my current access point.
@@ -517,7 +526,6 @@
        }
 }
 
-#ifdef REMOVE_PREAUTH_CODE
 /**
  * Read function for inbound messages.
  *
@@ -728,9 +736,11 @@
                case 'f':
                        PISA_STRNCPY(cd_cfg.conffile, optarg, 
sizeof(cd_cfg.conffile));
                        break;
+#ifdef REMOVE_PREAUTH_CODE
                case 'i':
                        PISA_STRNCPY(cd_cfg.ifname_wlan, optarg, 
sizeof(cd_cfg.ifname_wlan));
                        break;
+#endif /* REMOVE_PREAUTH_CODE */
                case 'p':
                        cd_cfg.port_control = atoi(optarg);
                        break;
@@ -915,9 +925,14 @@
        tmfd = pisa_maxInt(tmfd, cd_ctx.tund);
        maxfd = tmfd + 1;
 #else
+#ifdef REMOVE_PREAUTH_CODE
        maxfd = pisa_maxof(6, cd_ctx.tunnel, cd_ctx.fd_pisaconf,
                cd_ctx.fd_pacli, cd_ctx.fd_pasrv,
                cd_ctx.tunc, cd_ctx.tund) + 1;
+#else 
+       maxfd = pisa_maxof(4, cd_ctx.tunnel, cd_ctx.fd_pisaconf,
+               cd_ctx.tunc, cd_ctx.tund) + 1;
+#endif /* REMOVE_PREAUTH_CODE */
 #endif
 
        return maxfd;

Modified: trunk/pisacd/cdmsg.c
==============================================================================
--- trunk/pisacd/cdmsg.c        Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdmsg.c        Wed Oct 14 17:12:26 2009        (r1151)
@@ -20,6 +20,7 @@
 # include "pisaperf.h"
 #endif
 
+#ifdef REMOVE_PREAUTH_CODE /* apparently the entire file can be removed -- 
Thomas */
 static int pisacd_conf_wlan_network(pisa_dhcp_info *dhcp_info, 
pisa_common_addr *ext_raddr);
 
 /**
@@ -744,3 +745,4 @@
 
        return 0;
 }
+#endif /* REMOVE_PREAUTH_CODE */

Modified: trunk/pisacd/cdmsg.h
==============================================================================
--- trunk/pisacd/cdmsg.h        Wed Oct 14 16:45:15 2009        (r1150)
+++ trunk/pisacd/cdmsg.h        Wed Oct 14 17:12:26 2009        (r1151)
@@ -18,6 +18,8 @@
 #include "packet.h"
 #include "cdctx.h"
 
+#ifdef REMOVE_PREAUTH_CODE
+
 /* 32(SSID) + 46(IPv6 address) + 32(token) + 2(delimiters) = 112 */
 #define SIZE_PAREQ_ENTRY       112
 
@@ -55,4 +57,6 @@
 
 int pisacd_perform_handover(void);
 
+#endif /* REMOVE_PREAUTH_CODE */
+
 #endif /* PISA_CDMSG_H */

Other related posts:

  • » [pisa-src] r1151 - in trunk/pisacd: cdconf.c cdconf.h cdconmgr.c cdconmgr.h cdctx.c cdctx.h cdmain.c cdmsg.c cdmsg.h - Thomas Jansen