Files
m241Neelima/components/ip_net2-6.9/ip8021x/config/ip8021x_config.h
T
2026-07-30 11:19:44 +05:30

153 lines
4.9 KiB
C

/*
******************************************************************************
* INTERPEAK CONFIGURATION HEADER FILE
*
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ip8021x_config.h,v $ $Revision: 1.13 $
* $Source: /home/interpeak/CVSRoot/ip8021x/config/ip8021x_config.h,v $
* $Author: krosenfe $ $Date: 2010-04-05 20:52:27 $
* $State: Exp $ $Locker: $
*
* INTERPEAK_COPYRIGHT_STRING
* Design and implementation by Roger Boden <roger@interpeak.se>
******************************************************************************
*/
#ifndef IP8021X_CONFIG_H
#define IP8021X_CONFIG_H
/*
****************************************************************************
* 1 DESCRIPTION
****************************************************************************
*/
/*
****************************************************************************
* 2 INCLUDE FILES
****************************************************************************
*/
#define IPCOM_USE_CLIB_PROTO
#include <ipcom_type.h>
#include <ipcom_cstyle.h>
#include <ipcom_err.h>
#include <ipcom_syslog.h>
#include <vsbConfig.h>
#ifdef __cplusplus
extern "C" {
#endif
/*
****************************************************************************
* 3 DEFINES
****************************************************************************
*/
#ifdef _WRS_CONFIG_IP8021X_DEBUG
#ifndef IPSUPP_DEBUG
#define IPSUPP_DEBUG
#endif
#endif
#ifdef IPCOM_SYSLOG_PRIORITY
#undef IPCOM_SYSLOG_PRIORITY
#endif
#if defined(_WRS_CONFIG_IP8021X_SYSLOG_PRIORITY)
#define IPCOM_SYSLOG_PRIORITY _WRS_CONFIG_IP8021X_SYSLOG_PRIORITY
#else
#define IPCOM_SYSLOG_PRIORITY IPCOM_LOG_ERR
#endif
#ifdef IPCOM_SYSLOG_FACILITY
#undef IPCOM_SYSLOG_FACILITY
#endif
#define IPCOM_SYSLOG_FACILITY IPCOM_LOG_IP8021X
/*
*===========================================================================
* IP8021X_RSN_CAP
*===========================================================================
* EAPOL key msg 2 contains an information element, that must match the
* information element in the association request. When using WPA2, the
* information element contains an RSN capabilities field.
*
*/
#define IP8021X_RSN_CAP_PRE_AUTH 0x01
#define IP8021X_RSN_CAP_NO_PAIRWISE 0x02
#define IP8021X_RSN_CAP_PTK_SA_REPLAY_COUNTER_2 0x04
#define IP8021X_RSN_CAP_PTK_SA_REPLAY_COUNTER_4 0x08
#define IP8021X_RSN_CAP_PTK_SA_REPLAY_COUNTER_16 0x0B
#define IP8021X_RSN_CAP_GTK_SA_REPLAY_COUNTER_2 0x10
#define IP8021X_RSN_CAP_GTK_SA_REPLAY_COUNTER_4 0x20
#define IP8021X_RSN_CAP_GTK_SA_REPLAY_COUNTER_16 0x30
#define IP8021X_RSN_CAP (IP8021X_RSN_CAP_PTK_SA_REPLAY_COUNTER_2 | IP8021X_RSN_CAP_GTK_SA_REPLAY_COUNTER_2)
/*
*===========================================================================
* IP8021X_USE_STATS
*===========================================================================
* Set this define to enable supplicant statistics counters as defined in
* IEEE 802.1x.
*/
#ifdef _WRS_CONFIG_IP8021X_USE_STATS
#define IP8021X_USE_STATS
#endif
/*
*===========================================================================
* IP8021X_SIM_SUPPORT
*===========================================================================
* Set this define to enable 802.1x simulation support.
*/
#if 0
#define IP8021X_SIM_SUPPORT
#endif
/*
****************************************************************************
* 4 TYPES
****************************************************************************
*/
/* Forward declarations */
struct Ip8021x_pkt_st;
struct Ip8021x_ctx_st;
typedef Ip_err (*Ip8021x_output)(struct Ip8021x_ctx_st* ctx, struct Ip8021x_pkt_st* pkt);
typedef int (*Ip8021x_input)(struct Ip8021x_ctx_st* ctx, struct Ip8021x_pkt_st* pkt, int len);
typedef Ip_err (*Ip8021x_ioctl)(struct Ip8021x_ctx_st* ctx, unsigned long request, void* data);
typedef Ip_err (*Ip8021x_get_supp_addr)(struct Ip8021x_ctx_st* ctx, Ip_u8* spa);
typedef Ip_fd (*Ip8021x_get_fd)(struct Ip8021x_ctx_st* ctx);
typedef struct Ip8021x_funcs_st
{
Ip8021x_output output;
Ip8021x_input input;
Ip8021x_ioctl ioctl;
Ip8021x_get_supp_addr get_spa;
Ip8021x_get_fd get_fd;
} Ip8021x_funcs;
/*
****************************************************************************
* 5 FUNCTIONS
****************************************************************************
*/
IP_PUBLIC Ip8021x_funcs* ip8021x_get_callbacks(struct Ip8021x_ctx_st *ctx);
#ifdef __cplusplus
}
#endif
#endif
/*
****************************************************************************
* END OF FILE
****************************************************************************
*/