original files of m241
This commit is contained in:
@@ -0,0 +1,557 @@
|
||||
/* 00comp_ipnet_mobility.cdf - IPNet Mobility configuration file */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2006-2007 Wind River Systems, Inc.
|
||||
*
|
||||
* The right to copy, distribute or otherwise make use of this software
|
||||
* may be licensed only pursuant to the terms of an applicable Wind River
|
||||
* license agreement. No license to Wind River intellectual property rights
|
||||
* is granted herein. All rights not licensed by Wind River are reserved
|
||||
* by Wind River.
|
||||
*/
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01i,11oct07,jho Fixed defect 106455; confusing naming and synopsis updated.
|
||||
01h,19sep07,rme Added missing backslash (line:137, 304)
|
||||
01f,27feb07,kch Added MIPMN_IPSEC_PROTECTED configuration parameter for
|
||||
mobile node. Also renamed MIPMN_IFNAME_LIST to MIPMN_IFNAME
|
||||
since only one interface can be configured at any time in
|
||||
the mobile node (WIND00089286).
|
||||
01e,23jan06,tlu Fix MIP CDF defects (85299, 85297, 85290)
|
||||
01d,25nov06,kch Added MIPHA_IF_NAT_T_KEEPALIVE_LIST configuration parameter.
|
||||
01c,23sep06,kch Fixed IPCOM shell commands description.
|
||||
01b,26aug06,kch Added support for configuration parameters.
|
||||
01a,22may06,kch created.
|
||||
*/
|
||||
|
||||
#ifdef _WRS_CONFIG_COMPONENT_IPMIPMN
|
||||
|
||||
Component INCLUDE_IPMIPMN {
|
||||
NAME IPv4 Mobile Node
|
||||
SYNOPSIS IPv4 Mobile Node
|
||||
MODULES ipmipmn.o
|
||||
REQUIRES INCLUDE_IPCOM INCLUDE_IPNET INCLUDE_IPMIP4
|
||||
_CHILDREN FOLDER_MOBILITY_MN
|
||||
CONFIGLETTES ipmipmn_config.c
|
||||
CFG_PARAMS MIPMN_IFNAME \
|
||||
MIPMN_HOME_AGENT \
|
||||
MIPMN_MTU_REDUCTION \
|
||||
MIPMN_HOME_ADDRESS \
|
||||
MIPMN_HOME_MASK \
|
||||
MIPMN_HOME_GATEWAY \
|
||||
MIPMN_SOL_ADDRESS \
|
||||
MIPMN_HA_AUTH_SECRET \
|
||||
MIPMN_HA_AUTH_SPI \
|
||||
MIPMN_HA_AUTH_METHOD \
|
||||
MIPMN_RUN_MODE \
|
||||
MIPMN_FA_AUTH_SECRET \
|
||||
MIPMN_FA_AUTH_SPI \
|
||||
MIPMN_FA_AUTH_METHOD \
|
||||
MIPMN_REG_LIFETIME \
|
||||
MIPMN_RECV_BROADCASTS \
|
||||
MIPMN_TUNNEL_TYPE \
|
||||
MIPMN_REVERSE_TUNNELING \
|
||||
MIPMN_NAI \
|
||||
MIPMN_DYNAMIC_HOME_AGENT_ASSIGNMENT \
|
||||
MIPMN_SOLICIT \
|
||||
MIPMN_IPSEC_PROTECTED \
|
||||
MIPMN_IPIKE_RECONFIGURE \
|
||||
MIPMN_IPIKE_SECURE \
|
||||
MIPMN_NAT_T_ENABLED \
|
||||
MIPMN_NAT_T_FORCED \
|
||||
MIPMN_NAT_T_KEEPALIVE \
|
||||
MIPMN_NAT_T_TUNNEL_TYPE \
|
||||
MIPMN_FA_SPI_SECRET_LIST \
|
||||
MIPMN_FA_SPI_METHOD_LIST \
|
||||
MIPMN_HA_SPI_SECRET_LIST \
|
||||
MIPMN_HA_SPI_METHOD_LIST \
|
||||
MIPMN_FA_SA_ADDRESS_LIST \
|
||||
MIPMN_HA_SA_ADDRESS_LIST \
|
||||
MIPMN_AAA_SECRET \
|
||||
MIPMN_AAA_SPI \
|
||||
MIPMN_AAA_METHOD \
|
||||
MIPMN_SIMBIND \
|
||||
MIPMN_TUNNEL_REORDERING \
|
||||
MIPMN_REVOCATION \
|
||||
MIPMN_IPIKE_MOBIKE
|
||||
}
|
||||
|
||||
Component INCLUDE_IPMIPMN_FEATURE_EXTENSION {
|
||||
NAME IPv4 Mobile Node Feature Extension Registration Hook
|
||||
SYNOPSIS IPv4 Mobile Node Feature Extension allows you provide \
|
||||
an additional registration hook for registration of \
|
||||
external functions.
|
||||
REQUIRES INCLUDE_IPMIPMN
|
||||
_CHILDREN FOLDER_MOBILITY_HA
|
||||
CFG_PARAMS MIPMN_FEATURE_INITIALIZATION_HOOK
|
||||
}
|
||||
|
||||
|
||||
Parameter MIPMN_FEATURE_INITIALIZATION_HOOK {
|
||||
NAME Mobile Node Feature Initialization Hook
|
||||
SYNOPSIS This is the function hook that you may define in order to \
|
||||
register extra functional extensions to the Mobile Node
|
||||
TYPE FUNCPTR
|
||||
DEFAULT your_function_here
|
||||
}
|
||||
|
||||
/* INCLUDE_IPMIPMN configuration parameters */
|
||||
Parameter MIPMN_IFNAME {
|
||||
NAME Mobile Node Interface
|
||||
SYNOPSIS Specifies network interface that should be managed by the \
|
||||
mobile IP node implementation, e.g. "eth0".
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_HOME_AGENT {
|
||||
NAME Home Agent IPv4 Address
|
||||
SYNOPSIS The IPv4 address of the mobile node home agent, \
|
||||
e.g. "10.1.2.42".
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_MTU_REDUCTION {
|
||||
NAME Mtu Reduction
|
||||
SYNOPSIS Set to "1" to reserve MTU for headers beyond the mobile \
|
||||
nodes control, such as IPSEC or other security releated \
|
||||
protocols. This is useful to avoid needless fragmentation.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_HOME_ADDRESS {
|
||||
NAME Home Address
|
||||
SYNOPSIS The mobile node IPv4 address on the home network. By \
|
||||
choosing the IP address any (i.e. "0.0.0.0"), the mobile \
|
||||
node will read the IP address and netmask from the \
|
||||
configured interface (set by MIPMN_IFNAME) at start and \
|
||||
use as mobile node home address and netmask.
|
||||
TYPE char *
|
||||
DEFAULT "0.0.0.0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_HOME_MASK {
|
||||
NAME Home Netmask
|
||||
SYNOPSIS The mobile node home network (sub)netmask in "a.b.c.d" \
|
||||
format, e.g."255.255.0.0".
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_DYNAMIC_HOME_AGENT_ASSIGNMENT {
|
||||
NAME Dynamic Home Agent Assignment
|
||||
SYNOPSIS Enables Dynamic Home Agent Assignment (DHAA) as per RFC4433. \
|
||||
When DHAA is used, if an address is specified in the \
|
||||
MIPMN_HOME_AGENT configuration parameter, it will be used \
|
||||
as a 'initial' home agent to query. If the mobile node is \
|
||||
run in co-located mode, the MIPMN_HOME_AGENT must still \
|
||||
be specified, since there's no way for the mobile node to \
|
||||
resolve the home agent. If foreign agent's are being used, \
|
||||
depending on the configuration of the foreign agent, the \
|
||||
mobile node may actually not specify a home agent at all, \
|
||||
since the foreign agent may resolve the proper one, or assign \
|
||||
one depending on the type home agent assignment. Values for \
|
||||
this configuration item are: 'disabled', 'enabled' or 'home'. \
|
||||
When 'enabled', the mobile node may be assigned a home agent \
|
||||
either in its home domain, or in the foreign domain depending \
|
||||
on the policy of the foreign agent. When 'home' the mobile \
|
||||
node requires a home agent in its own domain.
|
||||
TYPE char *
|
||||
DEFAULT "disabled"
|
||||
}
|
||||
|
||||
Parameter MIPMN_HOME_GATEWAY {
|
||||
NAME Home Gateway
|
||||
SYNOPSIS If set, the mobile node will update the default gateway upon \
|
||||
reaching the home network. If not set, it is outside the \
|
||||
scope of IPMIPMN how to update the default gateway upon \
|
||||
returning home with a possibly unreachable default gateway. \
|
||||
E.g. "10.1.1.1".
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_SOL_ADDRESS {
|
||||
NAME Router Solicitation Address
|
||||
SYNOPSIS Configures the destination address of outgoing router \
|
||||
solicitation messages from the mobile node. If not set, \
|
||||
set to invalid IP address or 0.0.0.0 IP address, the mobile \
|
||||
node will not send ICMP router solicitations. \
|
||||
E.g. "224.0.0.11".
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_HA_AUTH_SECRET {
|
||||
NAME Default Home Agent Shared Secret
|
||||
SYNOPSIS This parameter specifies the default secret to be used when \
|
||||
authenticating towards home agents. If you need to configure \
|
||||
secrets on a per home agent basis, you must use the \
|
||||
MIPMN_HA_SPI_METHOD_LIST, MIPMN_HA_SPI_SECRET_LIST and \
|
||||
MIPMN_HA_SA_ADDRESS_LIST parameters. An example configuration \
|
||||
is "test0"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_HA_AUTH_SPI {
|
||||
NAME Default Home Agent SPI
|
||||
SYNOPSIS This is the default home agent SPI parameter when \
|
||||
authenticating towards home agents. If you need to configure \
|
||||
SPI's on a per home agent basis, you must use the \
|
||||
MIPMN_HA_SPI_METHOD_LIST, MIPMN_HA_SPI_SECRET_LIST and \
|
||||
MIPMN_HA_SA_ADDRESS_LIST parameters. An example configuration \
|
||||
is "1000"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_HA_AUTH_METHOD {
|
||||
NAME Default Home Agent Security Method
|
||||
SYNOPSIS The default home agent authentication method, which specifies \
|
||||
what type of security verification mechanism should be used. \
|
||||
There are two different values available, md5-hmac and keygen, \
|
||||
where md5-hmac is the default MIPv4 authentication method, \
|
||||
and keygen will tell the mobile node to generate keys using \
|
||||
RFC3957. Note that you MUST configure MIPMN_AAA_SPI, \
|
||||
MIPMN_AAA_SECRET and MIPMN_AAA_METHOD when using keygen. If \
|
||||
you need to configure auth methods on a per home agent basis, \
|
||||
you must use the MIPMN_HA_SPI_METHOD_LIST, \
|
||||
MIPMN_HA_SPI_SECRET_LIST and MIPMN_HA_SA_ADDRESS_LIST
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_RUN_MODE {
|
||||
NAME Mobile Node Run Mode
|
||||
SYNOPSIS Whether to use a foreign agent ("fa") or a co-located \
|
||||
("co") address.
|
||||
TYPE char *
|
||||
DEFAULT "fa"
|
||||
}
|
||||
|
||||
Parameter MIPMN_FA_AUTH_SECRET {
|
||||
NAME Default Foreign Agent Shared Secret
|
||||
SYNOPSIS This parameter specifies the default secret to be used when \
|
||||
authenticating towards foreign agents. If you need to configure \
|
||||
secrets on a per foreign agent basis, you must use the \
|
||||
MIPMN_FA_SPI_METHOD_LIST, MIPMN_FA_SPI_SECRET_LIST and \
|
||||
MIPMN_FA_SA_ADDRESS_LIST parameters. An example configuration \
|
||||
is "test1"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_FA_AUTH_SPI {
|
||||
NAME Default Foreign Agent SPI
|
||||
SYNOPSIS This is the default foreign agent SPI parameter when \
|
||||
authenticating towards foreign agents. If you need to configure \
|
||||
SPI's on a per foreign agent basis, you must use the \
|
||||
MIPMN_FA_SPI_METHOD_LIST, MIPMN_FA_SPI_SECRET_LIST and \
|
||||
MIPMN_FA_SA_ADDRESS_LIST parameters. An example configuration \
|
||||
is "1001"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_FA_AUTH_METHOD {
|
||||
NAME Default Foreign Agent Security Method
|
||||
SYNOPSIS The default foreign agent authentication method, which \
|
||||
specifies what type of security verification mechanism should \
|
||||
be used. There are two different values available, md5-hmac \
|
||||
and keygen, where md5-hmac is the default MIPv4 authentication \
|
||||
method, and keygen will tell the mobile node to generate keys \
|
||||
using RFC3957. Note that you MUST configure MIPMN_AAA_SPI, \
|
||||
MIPMN_AAA_SECRET and MIPMN_AAA_METHOD when using keygen. If \
|
||||
you need to configure auth methods on a per foreign agent basis, \
|
||||
you must use the MIPMN_FA_SPI_METHOD_LIST, \
|
||||
MIPMN_FA_SPI_SECRET_LIST and MIPMN_FA_SA_ADDRESS_LIST
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
|
||||
Parameter MIPMN_REG_LIFETIME {
|
||||
NAME Registration Lifetime
|
||||
SYNOPSIS Registration lifetime in seconds where 0 means infinite \
|
||||
lifetime. When on foreign networks, the mobile node will \
|
||||
attempt to reregister after half the lifetime.
|
||||
TYPE char *
|
||||
DEFAULT "30"
|
||||
}
|
||||
|
||||
Parameter MIPMN_RECV_BROADCASTS {
|
||||
NAME Receive Broadcasts
|
||||
SYNOPSIS Setting this configuration option to "1" enables the \
|
||||
reception of broadcast packets from the home network \
|
||||
(assuming the home agent supports forwarding of such \
|
||||
packets). "0" means disable.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_TUNNEL_TYPE {
|
||||
NAME Tunnel Type
|
||||
SYNOPSIS The type of tunnel negotiated between the mobile node and \
|
||||
foreign agent is chosen by setting this configuration \
|
||||
option to "ipip", "gre" or "min" for IPIP, GRE or Minimal \
|
||||
Encapsulation respectively. If the home agent does not \
|
||||
support GRE or MIN, IPIP will be tried. If IPIP is not \
|
||||
supported as well, the registration operation will fail and \
|
||||
the mobile node must be reconfigured.
|
||||
TYPE char *
|
||||
DEFAULT "ipip"
|
||||
}
|
||||
|
||||
Parameter MIPMN_REVERSE_TUNNELING {
|
||||
NAME Reverse Tunneling
|
||||
SYNOPSIS By setting this configuration option to "required" the mobile node \
|
||||
will require the use of reverse tunneling. "optional" will enable \
|
||||
the node to try to negotiate the use of reverse tunnelling, i.e. \
|
||||
the mobile node will tunnel all outgoing packets to the \
|
||||
home agent. If the home agent does not support reverse \
|
||||
tunnelling, the mobile node will automatically retry the \
|
||||
registration request without the use of reverse tunnelling \
|
||||
(i.e. use normal triangular routing).
|
||||
TYPE char *
|
||||
DEFAULT "optional"
|
||||
}
|
||||
|
||||
Parameter MIPMN_NAI {
|
||||
NAME Network Access Identifier
|
||||
SYNOPSIS Specify the network access identity as according to RFC 2794.
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_SOLICIT {
|
||||
NAME Solicitations
|
||||
SYNOPSIS Set to "required" to force the mobile node to always solicit \
|
||||
routers on L2-LU. This is the default behaviour but it may \
|
||||
be unset in order to allow transparent POST Low Latency \
|
||||
Handovers without the mobile node re-registering until the \
|
||||
registration time out occurs, or the FA forces the \
|
||||
re-registration. Other values are "optional", which \
|
||||
will try to keep solicitations to a minimum, and "disabled" \
|
||||
which do not solicit at all.
|
||||
TYPE char *
|
||||
DEFAULT "required"
|
||||
}
|
||||
|
||||
Parameter MIPMN_IPSEC_PROTECTED {
|
||||
NAME IPSEC Protected CoA Only
|
||||
SYNOPSIS This configuration parameter defines whether or not the \
|
||||
mobile node should only use addresses which has SPD's \
|
||||
specified which covers them. It requires that IPIPSEC or \
|
||||
IPIKE has set up the required security policies and \
|
||||
associations prior to any mobile IP registration. If \
|
||||
MIPMN_IPIKE_SECURE is set, it takes precedense, and this \
|
||||
configuration variable will be ignored.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_IPIKE_RECONFIGURE {
|
||||
NAME IPIKE Reconfiguration On Movement
|
||||
SYNOPSIS Specifies whether or not the mobile node should send a \
|
||||
reconfiguration request to the IPIKE process when it moves. \
|
||||
This is so that the IPIKE daemon may re-read its \
|
||||
configuration file, re-acquire any primary addresses on the \
|
||||
selected interface and renegotiate security associations.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_IPIKE_SECURE {
|
||||
NAME IPIKE Secure Address Only
|
||||
SYNOPSIS Specifies whether or not the mobile node should only use \
|
||||
addresses allocated by IPIKE during its negotiation process. \
|
||||
If set, the mobile node will scan its configured interface \
|
||||
for addresses which IPIKE has reported are secure, and use \
|
||||
them.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_IPIKE_MOBIKE {
|
||||
NAME IPIKE Mobike On Movement
|
||||
SYNOPSIS Specifies whether or not the mobile node should use \
|
||||
mobike when roaming, in order to re-establish the encrypted \
|
||||
channel previously created by IPIKE. Only addresses allocated \
|
||||
by IPIKE are subjected to mobike, and therefore \
|
||||
MIPMN_IPIKE_SECURE should usually also be enabled when this \
|
||||
option is used.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_NAT_T_ENABLED {
|
||||
NAME NAT Traversal
|
||||
SYNOPSIS Enables or disables NAT Traversal according to RFC 3519.
|
||||
TYPE char *
|
||||
DEFAULT "1"
|
||||
}
|
||||
|
||||
Parameter MIPMN_NAT_T_FORCED {
|
||||
NAME Forced NAT Traversal
|
||||
SYNOPSIS Enables forcing of NAT traversal (RFC 3519), regardless \
|
||||
what the home agent NAT detection decides.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_NAT_T_KEEPALIVE {
|
||||
NAME NAT Traversal Keepalive
|
||||
SYNOPSIS Decides the keepalive timeout to use for NAT Traversal \
|
||||
ICMP keepalive messages in order to maintain a NAT device \
|
||||
UDP port mapping.
|
||||
TYPE char *
|
||||
DEFAULT "120"
|
||||
}
|
||||
|
||||
Parameter MIPMN_NAT_T_TUNNEL_TYPE {
|
||||
NAME NAT Traversal Tunnel Type
|
||||
SYNOPSIS Allows for specifying a different tunnel type if NAT \
|
||||
traversal is used. Ordinarily, the tunnel type specified \
|
||||
by the mobile node base configuration is used, it may be \
|
||||
overriden for NAT Traversal tunneling, if for example only \
|
||||
IPIP is specified to work. Allowed values are "min", "gre" \
|
||||
and "ipip". If not specified or empty, the mobile node \
|
||||
base configuration will take precedence.
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
|
||||
Parameter MIPMN_HA_SPI_SECRET_LIST {
|
||||
NAME Home Agent Security Association Secrets
|
||||
SYNOPSIS These keys specify the secrets associated with specific SPI's \
|
||||
for use when communicating with home agents. The syntax is \
|
||||
"<spi value>=<secret>" and multiple entries are separated \
|
||||
by a semicolon. E.g. "1003=firstsecret;1004=secondsecret"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_HA_SPI_METHOD_LIST {
|
||||
NAME Home Agent Security Association Methods
|
||||
SYNOPSIS These keys specify the security method associated with specific \
|
||||
SPI's for use when communicating with home agents. The syntax \
|
||||
is "<spi value>=<method>" and multiple entries are separated \
|
||||
by a semicolon. Valid methods are: \
|
||||
md5-hmac - The default MIPv4 hash mechanism. \
|
||||
keygen - AAA key generation. If this method has been \
|
||||
specified, keys will be generated according to \
|
||||
RFC3957. You must configure MIPMN_AAA_SPI, \
|
||||
MIPMN_AAA_SECRET and MIPMN_AAA_METHOD as well.
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_FA_SPI_SECRET_LIST {
|
||||
NAME Foreign Agent Security Association Secrets
|
||||
SYNOPSIS These keys specify the secrets associated with specific SPI's \
|
||||
for use when communicating with foreign agents. The syntax is \
|
||||
"<spi value>=<secret>" and multiple entries are separated\
|
||||
by a semicolon. E.g. "1003=firstsecret;1004=secondsecret"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_FA_SPI_METHOD_LIST {
|
||||
NAME Foreign Agent Security Association Methods
|
||||
SYNOPSIS These keys specify the security method associated with specific \
|
||||
SPI's for use when communicating with foreign agents. The syntax \
|
||||
is "<spi value>=<method>" and multiple entries are separated\
|
||||
by a semicolon. Valid methods are: \
|
||||
md5-hmac - The default MIPv4 hash mechanism. \
|
||||
keygen - AAA key generation. If this method has been\
|
||||
specified, keys will be generated according to\
|
||||
RFC3957. You must configure MIPMN_AAA_SPI,\
|
||||
MIPMN_AAA_SECRET and MIPMN_AAA_METHOD as well.
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
|
||||
Parameter MIPMN_FA_SA_ADDRESS_LIST {
|
||||
NAME Foreign Agent Security Association Selection
|
||||
SYNOPSIS These keys specify what security association should be used \
|
||||
when communicating with foreign agents. There may be multiple \
|
||||
selection directives specified, each separated by a semicolon. \
|
||||
The syntax for the directives is "<network[/prefix]>=<spi>".\
|
||||
E.g. "10.1.2.3=1004;10.2.0.0/16=1005"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
|
||||
Parameter MIPMN_HA_SA_ADDRESS_LIST {
|
||||
NAME Home Agent Security Association Selection
|
||||
SYNOPSIS These keys specify what security association should be used \
|
||||
when communicating with home agents. There may be multiple \
|
||||
selection directives specified, each separated by a semicolon. \
|
||||
The syntax for the directives is "<network[/prefix]>=<spi>". \
|
||||
E.g. "10.1.2.3=1004;10.2.0.0/16=1005"
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
|
||||
Parameter MIPMN_AAA_SECRET {
|
||||
NAME AAA Shared Secret
|
||||
SYNOPSIS The shared secret used when authenticating towards a AAA \
|
||||
infrastructure. E.g. "myaaasecret".
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_AAA_SPI {
|
||||
NAME AAA SPI
|
||||
SYNOPSIS The Security Parameter Index (SPI) used when authenticating \
|
||||
towards a AAA infrastructure. If set to the pre-defined \
|
||||
value of "2", will indicate that RADIUS CHAP authentication \
|
||||
should be used.
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_AAA_METHOD {
|
||||
NAME AAA Security Association Method
|
||||
SYNOPSIS Indicates what kind of HASH or authentication method should \
|
||||
be used when calculating the authentication extensions. May \
|
||||
be set to either md5-hmac or chap.
|
||||
TYPE char *
|
||||
DEFAULT ""
|
||||
}
|
||||
|
||||
Parameter MIPMN_SIMBIND {
|
||||
NAME Simultaneous Bindings
|
||||
SYNOPSIS Enables or disables simultaneous bindings.
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_TUNNEL_REORDERING {
|
||||
NAME Tunnel Reordering
|
||||
SYNOPSIS Disabled(0)/Enabled(1) tunnel reordering. When enabled, any \
|
||||
tunneltype such as GRE that supports it will guarantee in-order \
|
||||
packet delivery
|
||||
TYPE char *
|
||||
DEFAULT "0"
|
||||
}
|
||||
|
||||
Parameter MIPMN_REVOCATION {
|
||||
NAME Registration Revocation
|
||||
SYNOPSIS Disabled(0)/Enabled(1) registration revocation. When enabled \
|
||||
the mobile node will indicate to the home agent that it \
|
||||
supports the usage of registration revocation.
|
||||
TYPE char *
|
||||
DEFAULT "1"
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,11 @@
|
||||
# Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: common.vxconfig,v $ $Revision: 1.9 $
|
||||
# $Source: /home/interpeak/CVSRoot/ipmipmn/config/common.vxconfig,v $
|
||||
# $Author: myakan $
|
||||
# $State: Exp $ $Locker: $
|
||||
#
|
||||
# INTERPEAK_COPYRIGHT_STRING
|
||||
|
||||
#hidden option that enables IPMIPMN
|
||||
config SUPPORTS_MIPMN
|
||||
bool
|
||||
default y
|
||||
@@ -0,0 +1,323 @@
|
||||
/*
|
||||
******************************************************************************
|
||||
* INTERPEAK CONFIGURATION SOURCE FILE
|
||||
*
|
||||
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ipmipmn_config.c,v $ $Revision: 1.27 $
|
||||
* $Source: /home/interpeak/CVSRoot/ipmipmn/config/ipmipmn_config.c,v $
|
||||
* $Author: jhorteli $
|
||||
* $State: Exp $ $Locker: $
|
||||
*
|
||||
* INTERPEAK_COPYRIGHT_STRING
|
||||
* Design and implementation by Lennart Bang <lob@interpeak.se>
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 1 DESCRIPTION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 2 CONFIGURATION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 3 INCLUDE FILES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#include <ipcom_cstyle.h>
|
||||
#include <ipcom_err.h>
|
||||
#include <ipcom_sysvar.h>
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 4 DEFINES
|
||||
****************************************************************************
|
||||
*/
|
||||
#define INCLUDE_IPMIPMN_CMD 1
|
||||
/*
|
||||
****************************************************************************
|
||||
* 5 TYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 6 EXTERN PROTOTYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
IP_PUBLIC int ipmipmn_cmd_mn(int argc, char **argv);
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 7 LOCAL PROTOTYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
IP_PUBLIC Ip_err ipmipmn_configure(void);
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 8 DATA
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* Mobile Node sysvar Configuration
|
||||
*===========================================================================
|
||||
*/
|
||||
|
||||
#if defined(INCLUDE_IPMIPMN)
|
||||
|
||||
IP_STATIC IP_CONST Ipcom_sysvar ipmipmn_conf_sysvar[] =
|
||||
{
|
||||
/*
|
||||
* Active MIP interface. There's only one interface configured at
|
||||
* any time in the mobile node.
|
||||
*/
|
||||
{ "ipmipmn.interface", MIPMN_IFNAME},
|
||||
|
||||
/* Home agent IP address */
|
||||
{ "ipmipmn.homeagent", MIPMN_HOME_AGENT},
|
||||
|
||||
/* Reduce the MTU of tunneled routes; incase of VPN tunneling to
|
||||
* reduce fragmentation
|
||||
*/
|
||||
{ "ipmipmn.mtu_reduction", MIPMN_MTU_REDUCTION },
|
||||
|
||||
/* Home address and netmask. 0.0.0.0 -> read IP address/netmask at start. */
|
||||
{ "ipmipmn.homeaddress", MIPMN_HOME_ADDRESS},
|
||||
{ "ipmipmn.homenetmask", MIPMN_HOME_MASK},
|
||||
|
||||
/* Set default gateway on home network if this sysvar is set. */
|
||||
{ "ipmipmn.homegateway", MIPMN_HOME_GATEWAY},
|
||||
|
||||
/* Destination address for outgoing router solicitation messages. Set to 0 to disable. */
|
||||
{ "ipmipmn.sol_address", MIPMN_SOL_ADDRESS},
|
||||
|
||||
/* Home agent shared secret and Security Parameter Index (SPI). */
|
||||
{ "ipmipmn.haauthsecret", MIPMN_HA_AUTH_SECRET},
|
||||
{ "ipmipmn.haauthspi", MIPMN_HA_AUTH_SPI},
|
||||
{ "ipmipmn.haauthmethod", MIPMN_HA_AUTH_METHOD},
|
||||
|
||||
/* Whether to use a foreign agent ("fa") or a co-located ("co") address. */
|
||||
{ "ipmipmn.runmode", MIPMN_RUN_MODE},
|
||||
|
||||
/* Foreign agent shared secret and Security Parameter Index (SPI).
|
||||
* This is only needed if ipmipmn.runmode is set to "fa".
|
||||
* Note: not setting "ipmipmn.faauthsecret" means mobile-foreign
|
||||
* authentication is disabled.
|
||||
*/
|
||||
{ "ipmipmn.faauthsecret", MIPMN_FA_AUTH_SECRET},
|
||||
{ "ipmipmn.faauthspi", MIPMN_FA_AUTH_SPI},
|
||||
{ "ipmipmn.faauthmethod", MIPMN_FA_AUTH_METHOD},
|
||||
|
||||
/* AAA */
|
||||
{ "ipmipmn.aaa.secret", MIPMN_AAA_SECRET},
|
||||
{ "ipmipmn.aaa.spi", MIPMN_AAA_SPI},
|
||||
{ "ipmipmn.aaa.method", MIPMN_AAA_METHOD},
|
||||
|
||||
/* Registration lifetime in seconds. 0 = infinite. */
|
||||
{ "ipmipmn.reg_lifetime", MIPMN_REG_LIFETIME},
|
||||
|
||||
/* Receive broadcast packets from home network. */
|
||||
{ "ipmipmn.receivebroadcasts",MIPMN_RECV_BROADCASTS},
|
||||
|
||||
/* "ipip" = IP over IP (gif), "gre" = GRE, "min" = minimal encapsulation. */
|
||||
{ "ipmipmn.simbind", MIPMN_SIMBIND},
|
||||
|
||||
/* Tunnel reordering */
|
||||
{ "ipmipmn.reordering", MIPMN_TUNNEL_REORDERING},
|
||||
|
||||
/* Revocation support */
|
||||
{ "ipmipmn.revocation", MIPMN_REVOCATION},
|
||||
|
||||
/* "ipip" = IP over IP (gif), "gre" = GRE, "min" = minimal encapsulation. */
|
||||
{ "ipmipmn.tunneltype", MIPMN_TUNNEL_TYPE},
|
||||
|
||||
/* Enable(1)/disable(0) reverse tunneling. */
|
||||
{ "ipmipmn.reversetunneling", MIPMN_REVERSE_TUNNELING},
|
||||
|
||||
/* NAI. Network Access identifiers */
|
||||
{ "ipmipmn.nai.mn", MIPMN_NAI},
|
||||
|
||||
/* DHAA */
|
||||
{ "ipmipmn.dhaa", MIPMN_DYNAMIC_HOME_AGENT_ASSIGNMENT },
|
||||
|
||||
/*
|
||||
* Movement and solicitations; Always solicit on L2-LU (wont work
|
||||
* well with POST LLH)
|
||||
*/
|
||||
{ "ipmipmn.solicit", MIPMN_SOLICIT},
|
||||
|
||||
/* ipsec protected CoA's only */
|
||||
{ "ipmipmn.ipipsec.protected", MIPMN_IPSEC_PROTECTED},
|
||||
|
||||
/* Force reconfiguration on move */
|
||||
{ "ipmipmn.ipike.reconfigure", MIPMN_IPIKE_RECONFIGURE },
|
||||
|
||||
/* only use secure addresses (IKE allocated) */
|
||||
{ "ipmipmn.ipike.secure", MIPMN_IPIKE_SECURE},
|
||||
|
||||
/* enable mobike on movement (IKE allocated) */
|
||||
{ "ipmipmn.ipike.mobike", MIPMN_IPIKE_MOBIKE },
|
||||
|
||||
/* NAT-T enabled on this interface */
|
||||
{ "ipmipmn.nat_t.enabled", MIPMN_NAT_T_ENABLED},
|
||||
|
||||
/* NAT-T enabled on this interface */
|
||||
{ "ipmipmn.nat_t.forced", MIPMN_NAT_T_FORCED},
|
||||
|
||||
/* NAT-T keepalive; In seconds */
|
||||
{ "ipmipmn.nat_t.keepalive", MIPMN_NAT_T_KEEPALIVE},
|
||||
|
||||
/* NAT-T forced tunnel type; ipip, gre, min or empty (use ordinary spec) */
|
||||
{ "ipmipmn.nat_t.tunneltype", MIPMN_NAT_T_TUNNEL_TYPE},
|
||||
|
||||
/* Configuration delimiter - DO NOT EDIT! */
|
||||
{ IP_NULL, IP_NULL }
|
||||
};
|
||||
|
||||
IP_STATIC IP_CONST Ipcom_sysvar_ext ipmipmn_conf_sysvar_ext[] =
|
||||
{
|
||||
/* Extended security association selection and creation */
|
||||
{ "ipmipmn.fa.spi", "secret", MIPMN_FA_SPI_SECRET_LIST},
|
||||
{ "ipmipmn.fa.spi", "method", MIPMN_FA_SPI_METHOD_LIST},
|
||||
{ "ipmipmn.ha.spi", "secret", MIPMN_HA_SPI_SECRET_LIST },
|
||||
{ "ipmipmn.ha.spi", "method", MIPMN_HA_SPI_METHOD_LIST},
|
||||
|
||||
{ "ipmipmn.ha.sa.address", IP_NULL, MIPMN_HA_SA_ADDRESS_LIST},
|
||||
{ "ipmipmn.fa.sa.address", IP_NULL, MIPMN_FA_SA_ADDRESS_LIST},
|
||||
|
||||
/* Configuration delimiter - DO NOT EDIT! */
|
||||
{ IP_NULL, IP_NULL, IP_NULL }
|
||||
};
|
||||
|
||||
#else /* WRS_IPNET */
|
||||
|
||||
|
||||
IP_STATIC IP_CONST Ipcom_sysvar ipmipmn_conf_sysvar[] =
|
||||
{
|
||||
/* Configuration delimiter - DO NOT EDIT! */
|
||||
{ IP_NULL, IP_NULL }
|
||||
};
|
||||
|
||||
#if defined(IPTESTENGINE)
|
||||
# define INCLUDE_IPMIPMN_FEATURE_EXTENSION 1
|
||||
# define MIPMN_FEATURE_INITIALIZATION_HOOK ipmipmn_regext_test_install
|
||||
#endif
|
||||
|
||||
#endif /* WRS_IPNET */
|
||||
|
||||
|
||||
#if defined(INCLUDE_IPMIPMN_FEATURE_EXTENSION)
|
||||
extern void MIPMN_FEATURE_INITIALIZATION_HOOK(void);
|
||||
#endif
|
||||
|
||||
IP_GLOBAL void ipmipmn_regext_mobnet_install(void);
|
||||
|
||||
typedef void (*Ipmipmn_config_func_t) (void);
|
||||
Ipmipmn_config_func_t ipmipmn_function_registrations[] =
|
||||
{
|
||||
#if defined(INCLUDE_IPMIPMN_FEATURE_EXTENSION)
|
||||
MIPMN_FEATURE_INITIALIZATION_HOOK,
|
||||
#endif
|
||||
|
||||
#ifdef IPMIPMN_NOT_YET
|
||||
ipmipmn_regext_mobnet_install,
|
||||
#endif
|
||||
|
||||
IP_NULL
|
||||
};
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 9 PUBLIC FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipmn_configure
|
||||
*===========================================================================
|
||||
* Description:
|
||||
* Parameters:
|
||||
* Returns:
|
||||
*
|
||||
*/
|
||||
IP_PUBLIC Ip_err
|
||||
ipmipmn_configure(void)
|
||||
{
|
||||
Ip_err err;
|
||||
/* Initialize IPMIPMN system variables. */
|
||||
if ((err = ipcom_sysvar_setv(ipmipmn_conf_sysvar, 0)) != IPCOM_SUCCESS)
|
||||
return err;
|
||||
|
||||
#if defined(INCLUDE_IPMIPMN)
|
||||
if ((err = ipcom_sysvar_ext_setv(ipmipmn_conf_sysvar_ext, 0)) != IPCOM_SUCCESS)
|
||||
return err;
|
||||
#endif
|
||||
|
||||
return IPCOM_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipha_init
|
||||
*===========================================================================
|
||||
* Description:
|
||||
* Parameters:
|
||||
* Returns:
|
||||
*
|
||||
*/
|
||||
IP_PUBLIC Ip_err ipmipmn_init(void);
|
||||
IP_PUBLIC Ip_err
|
||||
ipmipmn_init(void)
|
||||
{
|
||||
#if defined(INCLUDE_IPMIPMN_CMD) && !defined(IP_PORT_LAS)
|
||||
(void)ipcom_shell_add_cmd("mn",
|
||||
"mn <command> [modifiers]", "Mobile IP Mobile Node",
|
||||
ipmipmn_cmd_mn,
|
||||
IPCOM_PRIORITY_DEFAULT, IPCOM_PROC_STACK_SMALL);
|
||||
#endif
|
||||
|
||||
return IPCOM_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipha_exit
|
||||
*===========================================================================
|
||||
* Description:
|
||||
* Parameters:
|
||||
* Returns:
|
||||
*
|
||||
*/
|
||||
IP_PUBLIC Ip_err ipmipmn_exit(void);
|
||||
IP_PUBLIC Ip_err
|
||||
ipmipmn_exit(void)
|
||||
{
|
||||
#if defined(INCLUDE_IPMIPMN_CMD) && !defined(IP_PORT_LAS)
|
||||
(void)ipcom_shell_remove_cmd("mn", ipmipmn_cmd_mn);
|
||||
#endif
|
||||
return IPCOM_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* END OF FILE
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
@@ -0,0 +1,82 @@
|
||||
/*
|
||||
******************************************************************************
|
||||
* INTERPEAK CONFIGURATION HEADER FILE
|
||||
*
|
||||
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ipmipmn_config.h,v $ $Revision: 1.14 $
|
||||
* $Source: /home/interpeak/CVSRoot/ipmipmn/config/ipmipmn_config.h,v $
|
||||
* $Author: jhorteli $ $Date: 2009-03-31 14:57:47 $
|
||||
* $State: Exp $ $Locker: $
|
||||
*
|
||||
* INTERPEAK_COPYRIGHT_STRING
|
||||
* Design and implementation by Lennart Bang <lob@interpeak.se>
|
||||
******************************************************************************
|
||||
*/
|
||||
#ifndef IPMIPMN_CONFIG_H
|
||||
#define IPMIPMN_CONFIG_H
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 1 DESCRIPTION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 2 INCLUDE FILES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#include <ipmip4_config.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 3 DEFINES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#ifdef IP_DEBUG
|
||||
#define IPMIPMN_EVENT_BACKLOG 300
|
||||
#else
|
||||
#define IPMIPMN_EVENT_BACKLOG 100
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* IPMIPMN_MAX_CHALLENGE_SIZE
|
||||
*===========================================================================
|
||||
* Maximum size of rfc3012 FA Challenge.
|
||||
*/
|
||||
#define IPMIPMN_MAX_CHALLENGE_SIZE 16
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 4 TYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 5 FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
extern Ipmip_init_func_t ipmipmn_function_registrations[];
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* END OF FILE
|
||||
****************************************************************************
|
||||
*/
|
||||
@@ -0,0 +1,171 @@
|
||||
|
||||
/*
|
||||
******************************************************************************
|
||||
* INTERPEAK SOURCE FILE
|
||||
*
|
||||
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ipmipmn_pktbuf.c,v $ $Revision: 1.8 $
|
||||
* $Source: /home/interpeak/CVSRoot/ipmipmn/config/ipmipmn_pktbuf.c,v $
|
||||
* $Author: jhorteli $
|
||||
* $State: Exp $ $Locker: $
|
||||
*
|
||||
* INTERPEAK_COPYRIGHT_STRING
|
||||
* Design and implementation by Joel Hortelius <joel.hortelis@interpeak.se>
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 1 DESCRIPTION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 2 CONFIGURATION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#include "ipmipmn_config.h"
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 3 INCLUDE FILES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#define IPCOM_USE_CLIB_PROTO
|
||||
#include <ipcom_clib.h>
|
||||
#include <ipcom_err.h>
|
||||
#include <ipcom_hash.h>
|
||||
#include <ipcom_inet.h>
|
||||
#include <ipcom_ipd.h>
|
||||
#include <ipcom_list.h>
|
||||
#include <ipcom_os.h>
|
||||
#include <ipcom_sock.h>
|
||||
#include <ipcom_sock2.h>
|
||||
#include <ipcom_syslog.h>
|
||||
#include <ipcom_sysvar.h>
|
||||
|
||||
#include <ipmip.h>
|
||||
#include <private/ipmip_sysvar.h>
|
||||
|
||||
#include <ipmip4.h>
|
||||
#include <private/ipmip4_if.h>
|
||||
#include <private/ipmip4_sysext.h>
|
||||
#include <private/ipmip4_util.h>
|
||||
#include <private/ipmip4_pktbuf.h>
|
||||
#include <private/ipmip4_context.h>
|
||||
#include <private/ipmip4_auth.h>
|
||||
|
||||
#include "ipmipmn_h.h"
|
||||
#include "ipmipmn_pktbuf.h"
|
||||
#include "ipmipmn_if.h"
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 4 DEFINES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 5 TYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 6 EXTERN PROTOTYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 7 LOCAL PROTOTYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 8 DATA
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 9 STATIC FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 10 GLOBAL FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipmn_pktbuf_alloc
|
||||
*===========================================================================
|
||||
* Description: Allocate a packet buffer
|
||||
* Parameters:
|
||||
* Returns: A newly allocated packet buffer
|
||||
*
|
||||
*/
|
||||
IP_GLOBAL Ipmip_pktbuf_t *
|
||||
ipmipmn_pktbuf_alloc(Ipmipmn_context_t *ctx,
|
||||
Ipmip_proc_t *proc,
|
||||
Ip_size_t extra)
|
||||
{
|
||||
Ipmipmn_pktbuf_t *pbuf = ipcom_calloc(1, sizeof(Ipmipmn_pktbuf_t) + extra);
|
||||
IPMIP_UNUSED_PARAMETER(ctx);
|
||||
IPMIP_UNUSED_PARAMETER(proc);
|
||||
|
||||
if (pbuf)
|
||||
{
|
||||
pbuf->api.ipmip4.ipmip.pktend = (void *) (pbuf + 1);
|
||||
return &pbuf->api.ipmip4.ipmip;
|
||||
}
|
||||
|
||||
/* Return a Ipmipha_pktbuf_t */
|
||||
return IP_NULL;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipmn_pktbuf_free
|
||||
*===========================================================================
|
||||
* Description: Free a packet buffer
|
||||
* Parameters: pbuf - The packet buffer
|
||||
* Returns:
|
||||
*
|
||||
*/
|
||||
IP_GLOBAL void
|
||||
ipmipmn_pktbuf_free(Ipmipmn_context_t *ctx,
|
||||
Ipmip_proc_t *proc,
|
||||
Ipmipmn_pktbuf_t *pbuf)
|
||||
{
|
||||
ipmipmn_api_pktbuf_free(&ctx->api, proc, &pbuf->api);
|
||||
|
||||
if (pbuf->api.iff.priv != IP_NULL)
|
||||
ipmipmn_if_release(ctx, proc, pbuf->api.iff.priv, IP_NULL);
|
||||
|
||||
/* Free the data */
|
||||
ipcom_free(pbuf);
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 11 PUBLIC FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* END OF FILE
|
||||
****************************************************************************
|
||||
*/
|
||||
@@ -0,0 +1,109 @@
|
||||
|
||||
/*
|
||||
******************************************************************************
|
||||
* HEADER FILE
|
||||
*
|
||||
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ipmipmn_pktbuf.h,v $ $Revision: 1.7 $
|
||||
* $Source: /home/interpeak/CVSRoot/ipmipmn/config/ipmipmn_pktbuf.h,v $
|
||||
* $Author: jhorteli $ $Date: 2009-04-01 18:34:38 $
|
||||
* $State: Exp $ $Locker: $
|
||||
*
|
||||
* INTERPEAK_COPYRIGHT_STRING
|
||||
* Design and implementation by Joel Hortelius <joel.hortelius@interpeak.se>
|
||||
******************************************************************************
|
||||
*/
|
||||
#ifndef IPMIPMN_PKTBUF_H
|
||||
#define IPMIPMN_PKTBUF_H
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 1 DESCRIPTION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 2 CONFIGURATION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 3 INCLUDE FILES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#include <private/ipmipmn_api_pktbuf.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 4 DEFINES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 5 TYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
struct Ipmipmn_context;
|
||||
typedef struct Ipmipmn_pktbuf
|
||||
{
|
||||
Ipmipmn_api_pktbuf_t api;
|
||||
} Ipmipmn_pktbuf_t;
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 6 FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipmn_pktbuf_alloc
|
||||
*===========================================================================
|
||||
* Description: Allocate a packet buffer
|
||||
* Parameters: ctx - Context
|
||||
* proc - Process
|
||||
* Returns: A newly allocated packet buffer
|
||||
*
|
||||
*/
|
||||
IP_GLOBAL Ipmip_pktbuf_t *ipmipmn_pktbuf_alloc(struct Ipmipmn_context *ctx,
|
||||
struct Ipmip_proc *proc,
|
||||
Ip_size_t extra);
|
||||
|
||||
|
||||
/*
|
||||
*===========================================================================
|
||||
* ipmipmn_pktbuf_free
|
||||
*===========================================================================
|
||||
* Description: Free a packet buffer
|
||||
* Parameters: ctx - Context
|
||||
* proc - Process
|
||||
* pbuf - The packet buffer
|
||||
* Returns:
|
||||
*
|
||||
*/
|
||||
IP_GLOBAL void ipmipmn_pktbuf_free(struct Ipmipmn_context *ctx,
|
||||
struct Ipmip_proc *proc,
|
||||
Ipmipmn_pktbuf_t *pbuf);
|
||||
|
||||
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* END OF FILE
|
||||
****************************************************************************
|
||||
*/
|
||||
@@ -0,0 +1,404 @@
|
||||
|
||||
/*
|
||||
******************************************************************************
|
||||
* INTERPEAK SOURCE FILE
|
||||
*
|
||||
* Document no: @(#) $Name: VXWORKS_ITER40_2019102207 $ $RCSfile: ipmipmn_regext_test.c,v $ $Revision: 1.4.16.1 $
|
||||
* $Source: /home/interpeak/CVSRoot/ipmipmn/config/ipmipmn_regext_test.c,v $
|
||||
* $Author: svc-cmnet $
|
||||
* $State: Exp $ $Locker: $
|
||||
*
|
||||
* INTERPEAK_COPYRIGHT_STRING
|
||||
* Design and implementation by Joel Hortelius <joel.hortelis@interpeak.se>
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 1 DESCRIPTION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 2 CONFIGURATION
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
#include "ipmipmn_config.h"
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 3 INCLUDE FILES
|
||||
****************************************************************************
|
||||
*/
|
||||
#ifdef IPTESTENGINE
|
||||
|
||||
#define IPCOM_USE_CLIB_PROTO
|
||||
#include <ipcom_clib.h>
|
||||
#include <ipcom_os.h>
|
||||
#include <ipcom_sock.h>
|
||||
#include <ipcom_sock6.h>
|
||||
#include <ipcom_inet.h>
|
||||
#include <ipcom_list.h>
|
||||
#include <ipcom_hash.h>
|
||||
#include <ipcom_err.h>
|
||||
#include <ipcom_sysvar.h>
|
||||
#include <ipcom_syslog.h>
|
||||
#include <ipcom_shell.h>
|
||||
#include <ipcom_route.h>
|
||||
|
||||
#include <ipnet.h>
|
||||
#include <ipnet_radvd.h>
|
||||
|
||||
#include <ipmip.h>
|
||||
#include <private/ipmip_util.h>
|
||||
#include <private/ipmip_sysvar.h>
|
||||
|
||||
#include <ipmip4.h>
|
||||
#include <private/ipmip4_context.h>
|
||||
#include <private/ipmip4_util.h>
|
||||
#include <private/ipmip4_sysext.h>
|
||||
|
||||
#include "ipmipmn.h"
|
||||
#include "ipmipmn_h.h"
|
||||
#include "ipmipmn_attr_h.h"
|
||||
#include "ipmipmn_pktbuf.h"
|
||||
#include "ipmipmn_if.h"
|
||||
#include "ipmipmn_node.h"
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 4 DEFINES
|
||||
****************************************************************************
|
||||
*/
|
||||
#define IPMIPMN_REGEXT_TEST_VENDOR_WR "VENDOR-WR"
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 5 TYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
typedef struct Ipmipmn_regext_test_vendor_ext_wr_config_instance
|
||||
{
|
||||
union Ipmip4_msgext_uhdr *nvse_noop_mn;
|
||||
union Ipmip4_msgext_uhdr *nvse_noop_fa;
|
||||
union Ipmip4_msgext_uhdr *nvse_noop_ha;
|
||||
union Ipmip4_msgext_uhdr *nvse_noop_all;
|
||||
union Ipmip4_msgext_uhdr *cvse_noop_mn;
|
||||
union Ipmip4_msgext_uhdr *cvse_noop_fa;
|
||||
union Ipmip4_msgext_uhdr *cvse_noop_ha;
|
||||
union Ipmip4_msgext_uhdr *cvse_noop_all;
|
||||
} Ipmipmn_regext_test_vendor_ext_wr_config_instance_t;
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 6 EXTERN PROTOTYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 7 LOCAL PROTOTYPES
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 8 DATA
|
||||
****************************************************************************
|
||||
*/
|
||||
static Ipmipmn_api_extension_t ipmipmn_regext_test_srv_wr;
|
||||
static Ipmip4_msgext_vendor_parse_ext_t ipmipmn_regext_msgext_wr;
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 9 STATIC FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
IP_STATIC int
|
||||
ipmipmn_regext_test_vendor_wr_parse(Ipmipmn_context_t *ctx,
|
||||
Ipmip_proc_t *proc,
|
||||
Ipmipmn_pktbuf_t *pbuf,
|
||||
union Ipmip4_msgext_uhdr *uhdr,
|
||||
Ipmipmn_regext_test_vendor_ext_wr_config_instance_t *wr)
|
||||
{
|
||||
Ip_size_t sz;
|
||||
|
||||
IPMIP_UNUSED_PARAMETER(pbuf);
|
||||
|
||||
/* There are no CISCO CVSE's */
|
||||
if (IPMIP4_MSGEXT_UHDR_TYPE(uhdr) == IPMIP4_EXT_TYPE_CVSE)
|
||||
{
|
||||
Ipmip4_cvse_t *vse;
|
||||
/* Get the CVSE data */
|
||||
vse = (void *)IPMIP4_MSGEXT_LHDR_EXT_DATA(uhdr);
|
||||
sz = IPMIP4_MSGEXT_CVSE_EXT_SIZE(uhdr);
|
||||
|
||||
switch (IP_GET_NTOHS(&vse->vendor_type))
|
||||
{
|
||||
case IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_MN:
|
||||
/* Must be atleast 4 byte data */
|
||||
if (sz < 4)
|
||||
return IPMIP4_REG_EXT_POORLY_FORMED;
|
||||
wr->cvse_noop_mn = uhdr;
|
||||
|
||||
IPMIP4_EVENT_IF(INFO, proc,
|
||||
ipmip_log_event_add(&ctx->api.ipmip4.ipmip,
|
||||
proc,
|
||||
"Wind River Critical Vendor Extension Extension cvse_noop_mn"));
|
||||
break;
|
||||
case IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_ALL:
|
||||
/* Must be atleast 4 byte data */
|
||||
if (sz < 4)
|
||||
return IPMIP4_REG_EXT_POORLY_FORMED;
|
||||
wr->cvse_noop_all = uhdr;
|
||||
IPMIP4_EVENT_IF(INFO, proc,
|
||||
ipmip_log_event_add(&ctx->api.ipmip4.ipmip,
|
||||
proc,
|
||||
"Wind River Critical Vendor Extension Extension cvse_noop_all"));
|
||||
break;
|
||||
default:
|
||||
IPMIP4_EVENT_IF(INFO, proc,
|
||||
ipmip_log_event_add(&ctx->api.ipmip4.ipmip,
|
||||
proc,
|
||||
"Unknown Wind River Critical Vendor Extension Extension %d", IP_GET_NTOHS(&vse->vendor_type)));
|
||||
return IPMIP4_REG_EXT_UNKNOWN_VSE;
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
Ipmip4_nvse_t *vse;
|
||||
/* Get the NVSE data */
|
||||
vse = (void *)IPMIP4_MSGEXT_SHDR_EXT_DATA(uhdr);
|
||||
sz = IPMIP4_MSGEXT_NVSE_EXT_SIZE(uhdr);
|
||||
|
||||
switch (IP_GET_NTOHS(&vse->vendor_type))
|
||||
{
|
||||
case IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_MN:
|
||||
/* Must be atleast 4 byte data */
|
||||
if (sz < 4)
|
||||
return IPMIP4_REG_EXT_POORLY_FORMED;
|
||||
wr->nvse_noop_mn = uhdr;
|
||||
IPMIP4_EVENT_IF(INFO, proc,
|
||||
ipmip_log_event_add(&ctx->api.ipmip4.ipmip,
|
||||
proc,
|
||||
"Wind River Normal Vendor Extension Extension nvse_noop_mn"));
|
||||
break;
|
||||
case IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_ALL:
|
||||
/* Must be atleast 4 byte data */
|
||||
if (sz < 4)
|
||||
return IPMIP4_REG_EXT_POORLY_FORMED;
|
||||
wr->nvse_noop_all = uhdr;
|
||||
IPMIP4_EVENT_IF(INFO, proc,
|
||||
ipmip_log_event_add(&ctx->api.ipmip4.ipmip,
|
||||
proc,
|
||||
"Wind River Normal Vendor Extension Extension nvse_noop_all"));
|
||||
break;
|
||||
default:
|
||||
IPMIP4_EVENT_IF(INFO, proc,
|
||||
ipmip_log_event_add(&ctx->api.ipmip4.ipmip,
|
||||
proc,
|
||||
"Unknown Wind River Normal Vendor Extension Extension %d", IP_GET_NTOHS(&vse->vendor_type)));
|
||||
return IPMIP4_REG_EXT_UNKNOWN_VSE;
|
||||
}
|
||||
}
|
||||
|
||||
return IPMIP4_REG_EXT_SUCCESS;
|
||||
}
|
||||
|
||||
IP_STATIC Ipmip4_msgext_uhdr_t *
|
||||
ipmipmn_regext_test_vendor_wr_vse_wr(Ip_bool cvse,
|
||||
Ip_u16 subtype,
|
||||
const char *format,
|
||||
...)
|
||||
{
|
||||
va_list ap;
|
||||
char *value;
|
||||
Ipmip4_msgext_uhdr_t *vse = IP_NULL;
|
||||
|
||||
va_start(ap, format);
|
||||
value = ipmip_vsysvar(format, ap);
|
||||
va_end(ap);
|
||||
|
||||
/**/
|
||||
if (value)
|
||||
{
|
||||
if (cvse)
|
||||
vse = ipmip4_sysext_cvse_alloc(IPMIP_SMI_WIND_RIVER,
|
||||
subtype,
|
||||
value,
|
||||
ipcom_strlen(value));
|
||||
else
|
||||
vse = ipmip4_sysext_nvse_alloc(IPMIP_SMI_WIND_RIVER,
|
||||
subtype,
|
||||
value,
|
||||
ipcom_strlen(value));
|
||||
ipcom_free(value);
|
||||
}
|
||||
|
||||
return vse;
|
||||
}
|
||||
|
||||
IP_STATIC void
|
||||
ipmipmn_regext_test_vendor_wr_req_mobile_home(struct Ipmipmn_context *ctx,
|
||||
struct Ipmip_proc *proc,
|
||||
struct Ipmipmn_api_node_conf *conf,
|
||||
Ipmipmn_regext_test_vendor_ext_wr_config_instance_t *inst_config,
|
||||
void *node_config,
|
||||
struct Ipmipmn_node *node,
|
||||
Ip_bool deregister,
|
||||
struct Ipmipmn_pktbuf *pbuf)
|
||||
{
|
||||
IPMIP_UNUSED_PARAMETER(ctx);
|
||||
IPMIP_UNUSED_PARAMETER(proc);
|
||||
IPMIP_UNUSED_PARAMETER(conf);
|
||||
IPMIP_UNUSED_PARAMETER(deregister);
|
||||
IPMIP_UNUSED_PARAMETER(node_config);
|
||||
IPMIP_UNUSED_PARAMETER(node);
|
||||
|
||||
if (inst_config->nvse_noop_mn)
|
||||
ipmip4_msgext_buffer_append_shdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->nvse_noop_mn);
|
||||
if (inst_config->cvse_noop_mn)
|
||||
ipmip4_msgext_buffer_append_lhdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->cvse_noop_mn);
|
||||
if (inst_config->nvse_noop_ha)
|
||||
ipmip4_msgext_buffer_append_shdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->nvse_noop_ha);
|
||||
if (inst_config->cvse_noop_ha)
|
||||
ipmip4_msgext_buffer_append_lhdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->cvse_noop_ha);
|
||||
if (inst_config->nvse_noop_fa)
|
||||
ipmip4_msgext_buffer_append_shdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->nvse_noop_fa);
|
||||
if (inst_config->cvse_noop_fa)
|
||||
ipmip4_msgext_buffer_append_lhdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->cvse_noop_fa);
|
||||
if (inst_config->nvse_noop_all)
|
||||
ipmip4_msgext_buffer_append_shdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->nvse_noop_all);
|
||||
if (inst_config->cvse_noop_all)
|
||||
ipmip4_msgext_buffer_append_lhdr(&pbuf->api.ipmip4.ipmip.packet, inst_config->cvse_noop_all);
|
||||
}
|
||||
|
||||
|
||||
IP_STATIC void
|
||||
ipmipmn_regext_test_vendor_wr_config(struct Ipmipmn_context *ctx,
|
||||
struct Ipmip_proc *proc,
|
||||
int action,
|
||||
const char *pre,
|
||||
const char *spec,
|
||||
struct Ipmipmn_api_node_conf *conf,
|
||||
Ipmipmn_regext_test_vendor_ext_wr_config_instance_t *inst_config,
|
||||
Ipmip_cli_message_t *request)
|
||||
{
|
||||
IPMIP_UNUSED_PARAMETER(ctx);
|
||||
IPMIP_UNUSED_PARAMETER(proc);
|
||||
IPMIP_UNUSED_PARAMETER(conf);
|
||||
IPMIP_UNUSED_PARAMETER(request);
|
||||
|
||||
if (action == IPMIP_CALLBACK_CONFIG_READ)
|
||||
{
|
||||
inst_config->nvse_noop_mn = ipmipmn_regext_test_vendor_wr_vse_wr(IP_FALSE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_MN,
|
||||
"%s.%snvse.wr.mn",
|
||||
pre, spec);
|
||||
inst_config->cvse_noop_mn = ipmipmn_regext_test_vendor_wr_vse_wr(IP_TRUE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_MN,
|
||||
"%s.%scvse.wr.mn",
|
||||
pre, spec);
|
||||
inst_config->nvse_noop_ha = ipmipmn_regext_test_vendor_wr_vse_wr(IP_FALSE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_HA,
|
||||
"%s.%snvse.wr.ha",
|
||||
pre, spec);
|
||||
inst_config->cvse_noop_ha = ipmipmn_regext_test_vendor_wr_vse_wr(IP_TRUE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_HA,
|
||||
"%s.%scvse.wr.ha",
|
||||
pre, spec);
|
||||
inst_config->nvse_noop_fa = ipmipmn_regext_test_vendor_wr_vse_wr(IP_FALSE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_FA,
|
||||
"%s.%snvse.wr.fa",
|
||||
pre, spec);
|
||||
inst_config->cvse_noop_fa = ipmipmn_regext_test_vendor_wr_vse_wr(IP_TRUE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_FA,
|
||||
"%s.%scvse.wr.fa",
|
||||
pre, spec);
|
||||
inst_config->nvse_noop_all = ipmipmn_regext_test_vendor_wr_vse_wr(IP_FALSE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_ALL,
|
||||
"%s.%snvse.wr.all",
|
||||
pre, spec);
|
||||
inst_config->cvse_noop_all = ipmipmn_regext_test_vendor_wr_vse_wr(IP_TRUE,
|
||||
IPMIP4_VENDOR_EXT_MSGEXT_WINDRIVER_NOOP_ALL,
|
||||
"%s.%scvse.wr.all",
|
||||
pre, spec);
|
||||
}
|
||||
else if (action == IPMIP_CALLBACK_CONFIG_FREE)
|
||||
{
|
||||
if (inst_config->nvse_noop_mn)
|
||||
ipcom_free(inst_config->nvse_noop_mn);
|
||||
if (inst_config->cvse_noop_mn)
|
||||
ipcom_free(inst_config->cvse_noop_mn);
|
||||
if (inst_config->nvse_noop_ha)
|
||||
ipcom_free(inst_config->nvse_noop_ha);
|
||||
if (inst_config->cvse_noop_ha)
|
||||
ipcom_free(inst_config->cvse_noop_ha);
|
||||
if (inst_config->nvse_noop_fa)
|
||||
ipcom_free(inst_config->nvse_noop_fa);
|
||||
if (inst_config->cvse_noop_fa)
|
||||
ipcom_free(inst_config->cvse_noop_fa);
|
||||
if (inst_config->nvse_noop_all)
|
||||
ipcom_free(inst_config->nvse_noop_all);
|
||||
if (inst_config->cvse_noop_all)
|
||||
ipcom_free(inst_config->cvse_noop_all);
|
||||
}
|
||||
else if (action == IPMIP_CALLBACK_CONFIG_DUMP)
|
||||
{
|
||||
/* Could dump, but dont bother */
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 10 GLOBAL FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
IP_GLOBAL void ipmipmn_regext_test_install(void);
|
||||
IP_GLOBAL void
|
||||
ipmipmn_regext_test_install(void)
|
||||
{
|
||||
ipcom_memset(&ipmipmn_regext_test_srv_wr, 0, sizeof(ipmipmn_regext_test_srv_wr));
|
||||
|
||||
ipmipmn_regext_test_srv_wr.name = IPMIPMN_REGEXT_TEST_VENDOR_WR;
|
||||
ipmipmn_regext_test_srv_wr.instance_data_size = sizeof(Ipmipmn_regext_test_vendor_ext_wr_config_instance_t);
|
||||
ipmipmn_regext_test_srv_wr.config_instance = (Ipmipmn_api_extension_config_instance_t)ipmipmn_regext_test_vendor_wr_config;
|
||||
|
||||
ipmipmn_regext_test_srv_wr.pkt_req_mobile_home = (Ipmipmn_api_extension_pkt_req_mobile_home_t)ipmipmn_regext_test_vendor_wr_req_mobile_home;
|
||||
|
||||
ipmipmn_context_register_function(&ipmipmn_regext_test_srv_wr);
|
||||
|
||||
ipcom_memset(&ipmipmn_regext_msgext_wr, 0, sizeof(ipmipmn_regext_msgext_wr));
|
||||
ipmipmn_regext_msgext_wr.vendor_id = IPMIP_SMI_WIND_RIVER;
|
||||
ipmipmn_regext_msgext_wr.parse = (Ipmip4_msgext_parse_ext_t) ipmipmn_regext_test_vendor_wr_parse;
|
||||
ipmipmn_regext_msgext_wr.pktaux.pktbuf_data_size = sizeof(Ipmipmn_regext_test_vendor_ext_wr_config_instance_t);
|
||||
ipmipmn_msgext_vendor_parse_ext_register(&ipmipmn_regext_msgext_wr);
|
||||
}
|
||||
|
||||
#else
|
||||
IP_GLOBAL void ipmipmn_regext_test_install(void);
|
||||
IP_GLOBAL void
|
||||
ipmipmn_regext_test_install(void)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* 11 PUBLIC FUNCTIONS
|
||||
****************************************************************************
|
||||
*/
|
||||
|
||||
/*
|
||||
****************************************************************************
|
||||
* END OF FILE
|
||||
****************************************************************************
|
||||
*/
|
||||
Reference in New Issue
Block a user