Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.11.1.2
Data Structures | Macros | Typedefs | Enumerations | Functions
Routing Configuration And Status [OPENAPI_ROUTING_CONFIG]

Data Structures

struct  OPEN_ARP_ENTRY_INFO_t
 
struct  OPEN_ARP_STATIC_ALL_t
 
struct  open_arpCacheStats_s
 

Macros

#define OPEN_DEFAULT_VRF_NAME   ""
 Default VRF name.
 
#define OPEN_DOT1Q_MAX_VLAN_ID   4094
 Maximum VLAN ID value.
 
#define OPEN_DOT1Q_MIN_VLAN_ID   1
 Minimum VLAN ID value.
 
#define OPEN_FD_RTR_MAX_STATIC_ARP_ENTRIES   512
 FD_RTR_MAX_STATIC_ARP_ENTRIES. More...
 
#define OPEN_INVALID_INTF   0
 Invalid internal interface number. More...
 
#define OPEN_RTO_PREFERENCE_MAX   255
 VRF set failure reason codes.
 
#define OPEN_RTO_PREFERENCE_MIN   1
 
#define OPEN_VRF_MAX_NAME_LEN   15
 largest allowable VRF name
 
#define OPEN_VRF_MIN_NAME_LEN   0
 smallest allowable VRF name
 

Typedefs

typedef struct open_arpCacheStats_s open_arpCacheStats_t
 Defines for ARP entry types.
 
typedef enum OPEN_INTF_URPF_MODE_s OPEN_INTF_URPF_MODE_t
 

Enumerations

enum  OPEN_ARP_TYPES_t {
  OPEN_ARP_TYPE_LOCAL = 0x01, OPEN_ARP_TYPE_GATEWAY = 0x02, OPEN_ARP_TYPE_RESOLVED = 0x04, OPEN_ARP_TYPE_NET_DIR_BCAST = 0x08,
  OPEN_ARP_TYPE_DISCARD_WHEN_SOURCE = 0x10, OPEN_ARP_TYPE_STATIC = 0x20, OPEN_ARP_TYPE_UNNUMBERED = 0x40, OPEN_ARP_TYPE_KERNEL = 0x80
}
 
enum  OPEN_INTF_IP6_ADDR_MODE_t { OPEN_IP6_ADDR_MODE_LINK_LOCAL = 0, OPEN_IP6_ADDR_MODE_AUTOCONFIG = 1, OPEN_IP6_ADDR_MODE_DHCP = 2 }
 
enum  OPEN_INTF_IP_ADDR_TYPE_t { OPEN_IP_ADDR_TYPE_STATIC_PRIMARY = 0, OPEN_IP_ADDR_TYPE_STATIC_SECONDARY = 1, OPEN_IP_ADDR_TYPE_DHCP = 2 }
 < Type of IP address. More...
 
enum  OPEN_INTF_URPF_MODE_s { OPEN_IPMAP_INTF_URPF_MODE_DISABLE = 0, OPEN_IPMAP_INTF_URPF_MODE_LOOSE = 1, OPEN_IPMAP_INTF_URPF_MODE_STRICT = 2 }
 
enum  OPEN_IP_ECMP_LB_MODE_t {
  OPEN_IP_ECMP_LB_MIN = 0, OPEN_IP_ECMP_LB_HASH_IN_SIP, OPEN_IP_ECMP_LB_HASH_IN_DIP, OPEN_IP_ECMP_LB_HASH_IN_SIP_DIP,
  OPEN_IP_ECMP_LB_HASH_IN_SIP_SPORT, OPEN_IP_ECMP_LB_HASH_IN_DIP_DPORT, OPEN_IP_ECMP_LB_HASH_IN_SIP_DIP_SPORT_DPORT, OPEN_IP_ECMP_LB_HASH_OUT_SIP,
  OPEN_IP_ECMP_LB_HASH_OUT_DIP, OPEN_IP_ECMP_LB_HASH_OUT_SIP_DIP, OPEN_IP_ECMP_LB_HASH_OUT_SIP_SPORT, OPEN_IP_ECMP_LB_HASH_OUT_DIP_DPORT,
  OPEN_IP_ECMP_LB_HASH_OUT_SIP_DIP_SPORT_DPORT, OPEN_IP_ECMP_LB_MAX
}
 
enum  OPEN_VRF_SET_ERROR_t {
  OPEN_VRF_SET_ERROR_INVALID = 0, OPEN_LOOPBACK_ERROR = 1, OPEN_UNNUMBERED_ERROR, OPEN_SYSLOG_ERROR,
  OPEN_IPV6_ERROR
}
 

Functions

open_error_t openapiArpEntryAdd (openapiClientHandle_t *client_handle, open_inet_addr_t ipAddr, open_buffdesc *mac_addr)
 Add an ARP entry. More...
 
open_error_t openapiArpEntryDel (openapiClientHandle_t *client_handle, open_inet_addr_t ipAddr)
 Delete an ARP entry. More...
 
open_error_t openapiArpEntryNextGet (openapiClientHandle_t *client_handle, uint32_t *intf, open_inet_addr_t *ipAddr, open_buffdesc *mac_addr)
 Get the next ARP entry. More...
 
open_error_t openapiIfBandwidthGet (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *bandwidth)
 Get the bandwidth of the specified interface. More...
 
open_error_t openapiIfBandwidthSet (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t bandwidth)
 Set the bandwidth of the specified interface. More...
 
open_error_t openapiIfBWGet (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *bandwidth)
 Get the bandwidth of the specified interface without making any modification to the SET bandwidth. More...
 
open_error_t openapiIntfEffectiveIpMtuGet (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *ipMtu)
 Gets the IP MTU value being enforced on a given interface. More...
 
open_error_t openapiIntfIPv4MtuGet (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *ipMtu)
 Gets the configured IPv4 MTU value on the given interface. More...
 
open_error_t openapiIntfMaxIpMtuGet (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *maxIpMtu)
 Get the maximum IP MTU that may be set on a given interface. More...
 
open_error_t openapiIPAddrToIntIf (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t ipAddr, uint32_t *ifNum)
 Get the internal interface number of the given VRF and IPv4 address. More...
 
open_error_t openapiIpArpCacheStatsGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, open_arpCacheStats_t *pStats)
 Retrieve various ARP cache statistics. More...
 
open_error_t openapiIpEcmpIpsecSpiGet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t *spiMode)
 Determines the current IP ECMP IPSEC SPI Mode. More...
 
open_error_t openapiIpEcmpIpsecSpiSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t spiMode)
 Sets the current IP ECMP IPSEC SPI Hashing mode. More...
 
open_error_t openapiIpEcmpLbGet (openapiClientHandle_t *client_handle, OPEN_IP_ECMP_LB_MODE_t *lbMode)
 Determines the current IP ECMP global load balancing mode. More...
 
open_error_t openapiIpEcmpLbSet (openapiClientHandle_t *client_handle, OPEN_IP_ECMP_LB_MODE_t lbMode)
 Sets the current IP ECMP global load balancing mode. More...
 
open_error_t openapiIpHelperAddressAdd (openapiClientHandle_t *client_handle, open_inet_addr_t ipAddr, uint32_t udpPort)
 Adds IP Helper Address and UDP port number. More...
 
open_error_t openapiIpHelperAddressDel (openapiClientHandle_t *client_handle, open_inet_addr_t ipAddr, uint32_t udpPort)
 Deletes IP Helper Address and UDP port number. More...
 
open_error_t openapiIpHelperModeSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t ipHelperMode)
 Enables/Disables IP Helper mode. More...
 
open_error_t openapiIpICMPEchoReplyModeSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t echoReplyMode)
 Enables/Disables IP ICMP Echo Reply mode. More...
 
open_error_t openapiIpManagementInterfaceGet (openapiClientHandle_t *client_handle, uint32_t *ifNum)
 Get the configured IPv4 Management interface. More...
 
open_error_t openapiIpManagementInterfaceParamsSet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_BOOL_t dhcpEnabled, uint32_t ipAddr, uint32_t subnetMask)
 Set the IPv4 Management interface and enable dhcp or configure static IP on the management interface. More...
 
open_error_t openapiIpManagementInterfaceSet (openapiClientHandle_t *client_handle, uint32_t ifNum)
 Set the IPv4 Management interface. More...
 
open_error_t openapiIpMapForwardingStatsGet (openapiClientHandle_t *client_handle, uint32_t *val)
 Gets the packets forwarded by CPU. More...
 
open_error_t openapiIpMapICMPUnreachablesModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *mode)
 Get the administrative mode of sending ICMP Unreachables. More...
 
open_error_t openapiIpMapIfICMPRedirectsModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *mode)
 Get the interface mode of sending ICMP Redirects. More...
 
open_error_t openapiIpMapIntfUrpfModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_INTF_URPF_MODE_t *mode, OPEN_BOOL_t *allowDefault)
 Get the interface uRPF mode and allowDefault option. More...
 
open_error_t openapiIpMapIntfUrpfModeSet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_INTF_URPF_MODE_t mode, OPEN_BOOL_t allowDefault)
 Set the interface uRPF mode and allowDefault option. More...
 
open_error_t openapiIpMapIpEvtDampGetDampParams (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *flaps, uint32_t *penalty, uint32_t *isSuppressed, uint32_t *reuseTime, uint32_t *maxPenalty)
 Invokes the IPMAP API funciton to get the dampening operational values. More...
 
open_error_t openapiIpMapIpPacketsReceivedGet (openapiClientHandle_t *client_handle, uint32_t *val)
 Get the IP packets count received by IP-Stack. More...
 
open_error_t openapiIpMapProtoNextGet (openapiClientHandle_t *client_handle, uint32_t *protoId)
 Get the next protocol ID by iterating through all registered protocols. More...
 
open_error_t openapiIpMapResilientHashingModeGet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t *resHashMode)
 Gets the global resilient hashing mode for ECMP trunks. More...
 
open_error_t openapiIpMapResilientHashingModeSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t resHashMode)
 Sets the global resilient hashing mode for ECMP trunks. More...
 
open_error_t openapiIpMapRouteTypeToProtoId (openapiClientHandle_t *client_handle, uint32_t routeType, uint32_t *protoId)
 Get the protocol ID for a given route type. More...
 
open_error_t openapiIpMapRtrICMPEchoReplyModeGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_CONTROL_t *mode)
 Get the administrative mode of sending ICMP Echo Replies. More...
 
open_error_t openapiIpMapRtrICMPEchoReplyModeSet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_CONTROL_t mode)
 Set ignore mode for ICMP ECHO Requests. More...
 
open_error_t openapiIpMapRtrICMPRatelimitGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t *burstSize, uint32_t *interval)
 Get the ICMP Rate Limiting parameters like burst size and interval. More...
 
open_error_t openapiIpMapRtrICMPRatelimitSet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t burstSize, uint32_t interval)
 Set the ICMP Rate Limiting parameters like burst size and interval. More...
 
open_error_t openapiIpMapRtrICMPRedirectsModeGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_CONTROL_t *mode)
 Get the administrative mode of sending ICMP Redirects. More...
 
open_error_t openapiIpMapRtrICMPRedirectsModeSet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_CONTROL_t mode)
 Set the administrative mode of sending ICMP Redirects. More...
 
open_error_t openapiIpMapRtrIntfVrfReset (openapiClientHandle_t *client_handle, uint32_t ifNum)
 Unset the VRF participation on an interface. More...
 
open_error_t openapiIpMapRtrIntfVrfSet (openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *vrfName, OPEN_VRF_SET_ERROR_t *vrfSetError)
 Set the VRF participation of an interface. More...
 
open_error_t openapiIpMapStaticArpAdd (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, open_inet_addr_t ipAddress, uint32_t intIfNum, open_buffdesc *macAddrBuf)
 Add a static ARP entry of a given VRF instance. More...
 
open_error_t openapiIpMapStaticArpDelete (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, open_inet_addr_t ipAddress, uint32_t intIfNum)
 Delete a static ARP entry of a given VRF instance. More...
 
open_error_t openapiIpMapSystemUrpfModeGet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t *urpfEnabled)
 Get the System mode for uRPF. More...
 
open_error_t openapiIpMapSystemUrpfModeSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t urpfEnabled)
 Set the System mode for uRPF. More...
 
open_error_t openapiIpMapValidIntfFirstGet (openapiClientHandle_t *client_handle, uint32_t *ifNum)
 Get the first valid interface. More...
 
open_error_t openapiIpMapValidIntfNextGet (openapiClientHandle_t *client_handle, uint32_t prevIfNum, uint32_t *ifNum)
 Get the next valid interface. More...
 
open_error_t openapiIpMcastsFwdModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *mode)
 Determine whether an interface is configured to forward multicast packets. More...
 
open_error_t openapiIpNetDirectBcastsGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *adminMode)
 Gets the admin mode for IP forwarding of net-directed broadcasts. More...
 
open_error_t openapiIpNetPrototypeRoutesDelete (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t protoId)
 Delete all net-prototype route entries. More...
 
open_error_t openapiIpRedirectsModeSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t redirectsMode)
 Enables/Disables generation of IP Redirects messages. More...
 
open_error_t openapiIpRouteAdd (openapiClientHandle_t *client_handle, OPEN_AF_t af, open_inet_pfx_t *ipAddr, open_inet_addr_t *nextHop, uint32_t rtPref, uint32_t intf, OPEN_MPLS_LABELS_t *mpls)
 Add an IP Route for a given address family. More...
 
open_error_t openapiIpRouteDel (openapiClientHandle_t *client_handle, OPEN_AF_t af, open_inet_pfx_t *ipAddr, open_inet_addr_t *nextHop, uint32_t intf, OPEN_MPLS_LABELS_t *mpls)
 Delete an IP Route for a given address family. More...
 
open_error_t openapiIpRtrInternalVlanIdToIntIfNum (openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *ifNum)
 Get the internal interface number associated with the port-based routing interface corresponding to this internal VLAN. More...
 
open_error_t openapiIpRtrIntfAutoStateModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *mode)
 Get the mode of AutoState feature of an interface. More...
 
open_error_t openapiIpRtrIntfAutoStateModeSet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t mode)
 Enable or disable the mode of AutoState feature of an interface. More...
 
open_error_t openapiIpRtrIntfModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *mode)
 Gets the router interface mode. More...
 
open_error_t openapiIpRtrIntfOperModeGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *mode)
 Determine whether a given IP interface is up for IPv4. More...
 
open_error_t openapiIpUnnumberedGet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_BOOL_t *isUnnumbered, uint32_t *numberedIfc)
 Determine whether a given interface is unnumbered and if it is, determine the interface whose address the unnumbered interface borrows. More...
 
open_error_t openapiIpUnnumberedSet (openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_BOOL_t isUnnumbered, uint32_t numberedIfc)
 Set the unnumbered status of an interface. More...
 
open_error_t openapiIpVlanRtrIntIfNumToVlanId (openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *vlanId)
 Get the VLAN ID corresponding to the given internal interface number. More...
 
open_error_t openapiIpVlanRtrVlanIdGetNext (openapiClientHandle_t *client_handle, uint32_t *vlanId)
 Get the next vlan after this vlan on which routing is enabled. More...
 
open_error_t openapiRtrAdminModeSet (openapiClientHandle_t *client_handle, OPEN_AF_t af, OPEN_CONTROL_t routingMode)
 Enables/Disables IP Routing Admin mode. More...
 
open_error_t openapiRtrArpSwitchClear (openapiClientHandle_t *client_handle)
 Clear the switch/management ARP entries. More...
 
open_error_t openapiRtrGratArpSet (openapiClientHandle_t *client_handle, uint32_t intIfNum, OPEN_CONTROL_t gratArpState)
 Enable or disable gratuitous ARP on an interface. More...
 
open_error_t openapiRtrIntfIpAddrAdd (openapiClientHandle_t *client_handle, OPEN_AF_t af, uint32_t intf, OPEN_INTF_IP_ADDR_TYPE_t addrType, open_inet_pfx_t *ipAddr, OPEN_CONTROL_t extArg)
 Add an IP address on a given router interface for a given address family. More...
 
open_error_t openapiRtrIntfIpAddrDel (openapiClientHandle_t *client_handle, OPEN_AF_t af, uint32_t intf, OPEN_INTF_IP_ADDR_TYPE_t addrType, open_inet_pfx_t *ipAddr, OPEN_CONTROL_t extArg)
 Delete an IP address on a given router interface for a given address family. More...
 
open_error_t openapiRtrIntfIpDestUnreachableModeSet (openapiClientHandle_t *client_handle, uint32_t intf, OPEN_CONTROL_t unreachableMode)
 Enables/Disables generation of IP Destination Unreachable messages on a Router interface. More...
 
open_error_t openapiRtrIntfIpHelperAddressAdd (openapiClientHandle_t *client_handle, uint32_t intf, open_inet_addr_t ipAddr, uint32_t udpPort)
 Adds IP Helper Address and UDP port number on an interface. More...
 
open_error_t openapiRtrIntfIpHelperAddressDel (openapiClientHandle_t *client_handle, uint32_t intf, open_inet_addr_t ipAddr, uint32_t udpPort)
 Deletes IP Helper Address and UDP port number on an interface. More...
 
open_error_t openapiRtrIntfIpHelperDiscardAdd (openapiClientHandle_t *client_handle, uint32_t intf, uint32_t udpPort)
 Adds IP Helper Discard entry in an interface. More...
 
open_error_t openapiRtrIntfIpHelperDiscardDel (openapiClientHandle_t *client_handle, uint32_t intf, uint32_t udpPort)
 Deletes IP Helper Discard entry in an interface. More...
 
open_error_t openapiRtrIntfIpNetDirBroadcastModeSet (openapiClientHandle_t *client_handle, uint32_t intf, OPEN_CONTROL_t ipNetBroadcastMode)
 Enables/Disables forwarding of Network-directed broadcast on a Router Interface. More...
 
open_error_t openapiRtrIntfIpProxyArpModeGet (openapiClientHandle_t *client_handle, uint32_t intIfNum, OPEN_CONTROL_t *ipProxyArpMode)
 Determine whether proxy ARP is enabled on an interface. More...
 
open_error_t openapiRtrIntfIpProxyArpModeSet (openapiClientHandle_t *client_handle, uint32_t intf, OPEN_CONTROL_t ipProxyArpMode)
 Enables/Disables IP Proxy ARP mode on a Router Interface. More...
 
open_error_t openapiRtrIntfIpRedirectsModeSet (openapiClientHandle_t *client_handle, uint32_t intf, OPEN_CONTROL_t redirectsMode)
 Enables/Disables generation of IP Redirects messages on a Router interface. More...
 
open_error_t openapiRtrIntfIpv6AddressModeSet (openapiClientHandle_t *client_handle, uint32_t intf, OPEN_INTF_IP6_ADDR_MODE_t addrMode, OPEN_BOOL_t setFlag)
 Set or reset the IPv6 address mode on a given router interface. More...
 
open_error_t openapiRtrIntfMTUSet (openapiClientHandle_t *client_handle, OPEN_AF_t af, uint32_t intf, uint32_t MTU)
 Configures Router Interface MTU. More...
 
open_error_t openapiRtrIntfRtrAdminModeSet (openapiClientHandle_t *client_handle, uint32_t intf, OPEN_CONTROL_t routingMode)
 Enables/Disables IP Routing mode (both v4 and v6) on a Router interface. More...
 
open_error_t openapiRtrIpArpAgeTimeSet (openapiClientHandle_t *client_handle, uint32_t timeout)
 Sets the ARP entry ageout time. More...
 
open_error_t openapiRtrIpArpCacheClear (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_BOOL_t gateway)
 Clears the ARP cache of all dynamic/gateway entries. More...
 
open_error_t openapiRtrIpArpCacheSizeSet (openapiClientHandle_t *client_handle, uint32_t cacheSize)
 Sets the maximum number of entries in the ARP cache. More...
 
open_error_t openapiRtrIpArpDynamicRenewGet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t *dynRenewMode)
 Returns the ARP dynamic entry renew mode. More...
 
open_error_t openapiRtrIpArpDynamicRenewSet (openapiClientHandle_t *client_handle, OPEN_CONTROL_t dynRenewMode)
 Enable or disable the ARP dynamic entry renew mode. More...
 
open_error_t openapiRtrIpArpEntryPurge (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, open_inet_addr_t ipAddr, uint32_t intIfNum)
 Purges a specific dynamic/gateway entry from the ARP cache. More...
 
open_error_t openapiRtrIpArpRespTimeSet (openapiClientHandle_t *client_handle, uint32_t timeout)
 Sets the ARP request response timeout. More...
 
open_error_t openapiRtrIpArpRetriesSet (openapiClientHandle_t *client_handle, uint32_t count)
 Sets the ARP request max retries count. More...
 
open_error_t openapiRtrIpMapStaticArpGetAll (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_ARP_STATIC_ALL_t *openArpEntries)
 Get a list of all static ARP entries currently configured. More...
 
open_error_t openapiRtrIpUnnumberedGratArpGet (openapiClientHandle_t *client_handle, uint32_t intIfNum, OPEN_BOOL_t *isEnabled)
 Get the behavior of gratuitous ARP received on unnumbered interface. More...
 
open_error_t openapiRtrIpUnnumberedGratArpSet (openapiClientHandle_t *client_handle, uint32_t intIfNum, OPEN_BOOL_t isEnabled)
 Set the behavior of gratuitous ARP received on unnumbered interface. More...
 
open_error_t openapiRtrLocalProxyArpModeGet (openapiClientHandle_t *client_handle, uint32_t intIfNum, OPEN_CONTROL_t *localProxyArpMode)
 Determine whether local proxy ARP is enabled on an interface. More...
 
open_error_t openapiRtrLocalProxyArpModeSet (openapiClientHandle_t *client_handle, uint32_t intIfNum, OPEN_CONTROL_t localProxyArpMode)
 Enable or disable local proxy ARP on an interface. More...
 
open_error_t openapiRtrRouteMaxEqualCostEntriesGet (openapiClientHandle_t *client_handle, uint32_t *maxhops)
 Get the routing max equal cost entries. More...
 
open_error_t openapiRtrRouteMaxRouteEntriesGet (openapiClientHandle_t *client_handle, uint32_t *maxroutes)
 Get the routing max routes entries. More...
 
open_error_t openapiRtrVlanIntfCreate (openapiClientHandle_t *client_handle, uint32_t vlanId)
 Create a VLAN Routing Interface. More...
 
open_error_t openapiRtrVlanIntfDelete (openapiClientHandle_t *client_handle, uint32_t vlanId)
 Delete a VLAN Routing Interface. More...
 
open_error_t openapiRtrVlanIntfIfNumGet (openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *intf)
 Get the interface number for a VLAN Routing Interface. More...
 
open_error_t openapiSourceInterfacesGet (openapiClientHandle_t *client_handle, uint32_t *ifNum)
 Get source IP interface from Syslog, SNMP Traps, SNTP, DNS Client, RADIUS, TACACS+ and sFlow apps. More...
 
open_error_t openapiSourceInterfacesSet (openapiClientHandle_t *client_handle, uint32_t ifNum)
 Set source IP interface for Syslog, SNMP Traps, SNTP, DNS Client, RADIUS, TACACS+ and sFlow apps. More...
 
open_error_t openapiVlanIntfIdGet (openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *ifNum)
 Get the interface ID for a given VLAN. More...
 
open_error_t openapiVrAddrConflictDetectStatusClear (openapiClientHandle_t *client_handle, open_buffdesc *vrfName)
 Clear the Address Conflict Detection Status of a given VRF instance. More...
 
open_error_t openapiVrAddrConflictDetectStatusGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, OPEN_BOOL_t *conflictDetectStatus)
 Get the Address Conflict Detection Status of a VRF instance. More...
 
open_error_t openapiVrAddrConflictLastDetectMACGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, open_buffdesc *conflictMAC)
 Get the MAC Address of the last detected address conflict in a VRF instance. More...
 
open_error_t openapiVrAddrConflictLastDetectTimeGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t *conflictDetectTime)
 Get the time in seconds since the last address conflict was detected in a VRF instance. More...
 
open_error_t openapiVrIpRouterPreferenceGet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t origin, uint32_t *pref)
 Get the Router preference for the given protocol and VRF name. More...
 
open_error_t openapiVrIpRouterPreferenceSet (openapiClientHandle_t *client_handle, open_buffdesc *vrfName, uint32_t origin, uint32_t pref)
 Set the Router preference for the given protocol and VRF name. More...
 

Detailed Description

Macro Definition Documentation

#define OPEN_FD_RTR_MAX_STATIC_ARP_ENTRIES   512

FD_RTR_MAX_STATIC_ARP_ENTRIES.

various ARP cache statistics (useful for 'show' functions, etc.)

Examples:
routing_example.c.

Definition at line 83 of file openapi_routing_config.h.

#define OPEN_INVALID_INTF   0

Invalid internal interface number.

Definition at line 82 of file openapi_routing_config.h.

Enumeration Type Documentation

Enumerator
OPEN_ARP_TYPE_LOCAL 

IP address is one of switch's MAC addresses.

OPEN_ARP_TYPE_GATEWAY 

Destination is a router.

OPEN_ARP_TYPE_RESOLVED 

Resolved ARP entry, dest MAC address known.

OPEN_ARP_TYPE_NET_DIR_BCAST 

Net directed broadcast addr.

OPEN_ARP_TYPE_DISCARD_WHEN_SOURCE 

Discard when seen as source.

OPEN_ARP_TYPE_STATIC 

Static ARP entry.

OPEN_ARP_TYPE_UNNUMBERED 

Unnumbered intf ARP entry.

OPEN_ARP_TYPE_KERNEL 

Kernel ARP entry.

Definition at line 96 of file openapi_routing_config.h.

Enumerator
OPEN_IP6_ADDR_MODE_LINK_LOCAL 

IPv6 Link local address mode.

OPEN_IP6_ADDR_MODE_AUTOCONFIG 

IPv6 Auto-config address mode.

OPEN_IP6_ADDR_MODE_DHCP 

IPv6 DHCP address mode.

Definition at line 69 of file openapi_routing_config.h.

< Type of IP address.

Enumerator
OPEN_IP_ADDR_TYPE_STATIC_PRIMARY 

Primary Static.

OPEN_IP_ADDR_TYPE_STATIC_SECONDARY 

Primary Secondary.

OPEN_IP_ADDR_TYPE_DHCP 

DHCP.

Definition at line 61 of file openapi_routing_config.h.

Enumerator
OPEN_IPMAP_INTF_URPF_MODE_DISABLE 

no uRPF

OPEN_IPMAP_INTF_URPF_MODE_LOOSE 

Loose Mode uRPF.

OPEN_IPMAP_INTF_URPF_MODE_STRICT 

Strict Mode uRPF.

Definition at line 152 of file openapi_routing_config.h.

Function Documentation

open_error_t openapiArpEntryAdd ( openapiClientHandle_t client_handle,
open_inet_addr_t  ipAddr,
open_buffdesc mac_addr 
)

Add an ARP entry.

Parameters
[in]client_handleclient handle from registration API
[in]ipAddrIP address.
[in]mac_addrMAC address.
-Maximum value OPENAPI_L7_MAC_ADDR_LEN
Return values
OPEN_E_NONEEntry added.
L7_ADDR_INUSEAddress is assigned to a local interface.
OPEN_E_PARAMIf an input parameter is invalid.
L7_TABLE_IS_FULLMaximum static ARP entries already configured.
OPEN_E_FAILAny other failure.
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiArpEntryDel ( openapiClientHandle_t client_handle,
open_inet_addr_t  ipAddr 
)

Delete an ARP entry.

Parameters
[in]client_handleclient handle from registration API
[in]ipAddrIP address.
Return values
OPEN_E_NONEEntry deleted.
OPEN_E_NOT_FOUNDCould not find entry to delete.
OPEN_E_PARAMIf an input parameter is invalid.
OPEN_E_FAILAny other failure.
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiArpEntryNextGet ( openapiClientHandle_t client_handle,
uint32_t *  intf,
open_inet_addr_t ipAddr,
open_buffdesc mac_addr 
)

Get the next ARP entry.

Parameters
[in]client_handleclient handle from registration API
[in,out]intfRouter Interface.
-Set this to 0 to get the first entry
[in,out]ipAddrIP address.
-Set this to 0 to get the first entry
[out]mac_addrMAC address.
-Maximum value OPENAPI_L7_MAC_ADDR_STRING_LEN
Return values
OPEN_E_NONEGet successful.
OPEN_E_FAILNo more entries.
OPEN_E_PARAMIf an input parameter is invalid.
Note
The addr.ipv4 field of the ipAddr argument is returned by this function in network byte order. Values of this field passed as input must also be in network byte order as well. This violates the convention documented for open_inet_addr_t, which is to represent ipv4 addresses in the open_inet_addr type in host byte order.

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIfBandwidthGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  bandwidth 
)

Get the bandwidth of the specified interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]bandwidthbandwidth value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIfBandwidthSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t  bandwidth 
)

Set the bandwidth of the specified interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[in]bandwidthbandwidth value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIfBWGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  bandwidth 
)

Get the bandwidth of the specified interface without making any modification to the SET bandwidth.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]bandwidthbandwidth value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIntfEffectiveIpMtuGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  ipMtu 
)

Gets the IP MTU value being enforced on a given interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]ipMtuThe effective IP MTU value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
If the IP MTU is not configured, it is derived from the link MTU.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIntfIPv4MtuGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  ipMtu 
)

Gets the configured IPv4 MTU value on the given interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]ipMtuThe ip mtu value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIntfMaxIpMtuGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  maxIpMtu 
)

Get the maximum IP MTU that may be set on a given interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]maxIpMtuThe maximum IP MTU value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIPAddrToIntIf ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t  ipAddr,
uint32_t *  ifNum 
)

Get the internal interface number of the given VRF and IPv4 address.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]ipAddrIP address of interest
[out]ifNumInternal interface number for the specified IP address
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpArpCacheStatsGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
open_arpCacheStats_t pStats 
)

Retrieve various ARP cache statistics.

Parameters
[in]client_handleClient handle from registration API.
[in]vrfNameVRF Name.
[out]pStatspointer to ARP cache statistics structure to be filled in.
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpEcmpIpsecSpiGet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t spiMode 
)

Determines the current IP ECMP IPSEC SPI Mode.

Parameters
[in]client_handleClient handle from registration API
[out]spiModeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpEcmpIpsecSpiSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  spiMode 
)

Sets the current IP ECMP IPSEC SPI Hashing mode.

Parameters
[in]client_handleClient handle from registration API
[in]spiModeIPSEC SPI Mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpEcmpLbGet ( openapiClientHandle_t client_handle,
OPEN_IP_ECMP_LB_MODE_t *  lbMode 
)

Determines the current IP ECMP global load balancing mode.

Parameters
[in]client_handleClient handle from registration API
[out]lbModeLoad balancing mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpEcmpLbSet ( openapiClientHandle_t client_handle,
OPEN_IP_ECMP_LB_MODE_t  lbMode 
)

Sets the current IP ECMP global load balancing mode.

Parameters
[in]client_handleClient handle from registration API
[in]lbModeLoad balancing mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpHelperAddressAdd ( openapiClientHandle_t client_handle,
open_inet_addr_t  ipAddr,
uint32_t  udpPort 
)

Adds IP Helper Address and UDP port number.

Parameters
[in]client_handleclient handle from registration API
[in]ipAddrServer IP address.
[in]udpPortUDP port from <1 - 65535>
Return values
OPEN_E_NONEadd successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_EXISTSserver address already configured.
OPEN_E_FULLmaximum entries already configured.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpHelperAddressDel ( openapiClientHandle_t client_handle,
open_inet_addr_t  ipAddr,
uint32_t  udpPort 
)

Deletes IP Helper Address and UDP port number.

Parameters
[in]client_handleclient handle from registration API
[in]ipAddrServer IP address.
[in]udpPortUDP port from <1 - 65535>
Return values
OPEN_E_NONEdelete successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpHelperModeSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  ipHelperMode 
)

Enables/Disables IP Helper mode.

Parameters
[in]client_handleclient handle from registration API
[in]ipHelperModeIP helper mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpICMPEchoReplyModeSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  echoReplyMode 
)

Enables/Disables IP ICMP Echo Reply mode.

Parameters
[in]client_handleclient handle from registration API
[in]echoReplyModeIP ICMP Echo Reply mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpManagementInterfaceGet ( openapiClientHandle_t client_handle,
uint32_t *  ifNum 
)

Get the configured IPv4 Management interface.

Parameters
[in]client_handleClient handle from registration API
[out]ifNumInternal interface number
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpManagementInterfaceParamsSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_BOOL_t  dhcpEnabled,
uint32_t  ipAddr,
uint32_t  subnetMask 
)

Set the IPv4 Management interface and enable dhcp or configure static IP on the management interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[in]dhcpEnabledOPEN_TRUE or OPEN_FALSE
[in]ipAddrIP address
[in]subnetMaskSubnetMask
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpManagementInterfaceSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum 
)

Set the IPv4 Management interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapForwardingStatsGet ( openapiClientHandle_t client_handle,
uint32_t *  val 
)

Gets the packets forwarded by CPU.

Parameters
[in]client_handleClient handle from registration API
[out]valNumber of packets forwarded by CPU
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapICMPUnreachablesModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t mode 
)

Get the administrative mode of sending ICMP Unreachables.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]modeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapIfICMPRedirectsModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t mode 
)

Get the interface mode of sending ICMP Redirects.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]modeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapIntfUrpfModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_INTF_URPF_MODE_t *  mode,
OPEN_BOOL_t allowDefault 
)

Get the interface uRPF mode and allowDefault option.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number of interface for which to get the urpf mode
[out]modeStrict or loose or disabled as defined by OPEN_INTF_URPF_MODE_t
[out]allowDefaultShould take default route into consideration or not
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapIntfUrpfModeSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_INTF_URPF_MODE_t  mode,
OPEN_BOOL_t  allowDefault 
)

Set the interface uRPF mode and allowDefault option.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number of interface for which to set the urpf mode
[in]modeStrict or loose or disabled as defined by OPEN_INTF_URPF_MODE_t
[in]allowDefaultShould take default route into consideration or not
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapIpEvtDampGetDampParams ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  flaps,
uint32_t *  penalty,
uint32_t *  isSuppressed,
uint32_t *  reuseTime,
uint32_t *  maxPenalty 
)

Invokes the IPMAP API funciton to get the dampening operational values.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal Interface Number
[out]flapsNumber of flaps after last reset
[out]penaltyMaximum penalty of an interface
[out]isSuppressedIs interface suppressed or not
[out]reuseTimeReuse time of a suppressed interface
[out]maxPenaltyMaximum penalty of an interface
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapIpPacketsReceivedGet ( openapiClientHandle_t client_handle,
uint32_t *  val 
)

Get the IP packets count received by IP-Stack.

Parameters
[in]client_handleClient handle from registration API
[out]valThe number of IP packets received by IP-Stack
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapProtoNextGet ( openapiClientHandle_t client_handle,
uint32_t *  protoId 
)

Get the next protocol ID by iterating through all registered protocols.

Parameters
[in]client_handleClient handle from registration API
[in,out]protoIdProtocol ID. Set to 0 on input to get the first value. Set to previous value on input to get the next value.
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
These are not returned in numeric order.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapResilientHashingModeGet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t resHashMode 
)

Gets the global resilient hashing mode for ECMP trunks.

Parameters
[in]client_handleClient handle from registration API
[out]resHashModeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapResilientHashingModeSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  resHashMode 
)

Sets the global resilient hashing mode for ECMP trunks.

Parameters
[in]client_handleClient handle from registration API
[in]resHashModeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRouteTypeToProtoId ( openapiClientHandle_t client_handle,
uint32_t  routeType,
uint32_t *  protoId 
)

Get the protocol ID for a given route type.

Parameters
[in]client_handleClient handle from registration API
[in]routeTypeRoute type
[out]protoIdprotocol ID for protocol that uses route type
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrICMPEchoReplyModeGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_CONTROL_t mode 
)

Get the administrative mode of sending ICMP Echo Replies.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[out]modeOPEN_ENABLE or OPEN_DISABLE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrICMPEchoReplyModeSet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_CONTROL_t  mode 
)

Set ignore mode for ICMP ECHO Requests.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]modeOPEN_ENABLE or OPEN_DISABLE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrICMPRatelimitGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t *  burstSize,
uint32_t *  interval 
)

Get the ICMP Rate Limiting parameters like burst size and interval.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[out]burstSizeNumber of ICMP messages the IPMAP is allowed per interval
[out]intervalThe time interval between tokens being placed in the bucket
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrICMPRatelimitSet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t  burstSize,
uint32_t  interval 
)

Set the ICMP Rate Limiting parameters like burst size and interval.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]burstSizeNumber of ICMP messages the IPMAP is allowed per interval
[in]intervalThe time interval between tokens being placed in the bucket
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
To disable ICMP rate limiting, set the interval to zero.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrICMPRedirectsModeGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_CONTROL_t mode 
)

Get the administrative mode of sending ICMP Redirects.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[out]modeOPEN_ENABLE or OPEN_DISABLE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrICMPRedirectsModeSet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_CONTROL_t  mode 
)

Set the administrative mode of sending ICMP Redirects.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]modeOPEN_ENABLE or OPEN_DISABLE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrIntfVrfReset ( openapiClientHandle_t client_handle,
uint32_t  ifNum 
)

Unset the VRF participation on an interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal Interface Number
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
This function removes the participation of an interface from its current VRF and restores it to default router. If the interface is already part of the default router, nothing is done.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapRtrIntfVrfSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
open_buffdesc vrfName,
OPEN_VRF_SET_ERROR_t *  vrfSetError 
)

Set the VRF participation of an interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal Interface Number
[in]vrfNameVRF name
[out]vrfSetErrorVRF Error message
Return values
OPEN_E_NONEOn success.
OPEN_E_PARAMInvalid argument.
OPEN_E_ERRORSubnet conflict between interface IP address and IP address in the virtual router.
OPEN_E_FULLUnable to add connected route as RTO is FULL.
OPEN_E_INTERNALEarlier operation on the interface is in progress. Try again later.
OPEN_E_FAILOn failures due to errors mentioned in vrfSetError.
OPEN_E_NOT_FOUNDOn any other failure.
Note
Assumes vrfName is OPEN_VRF_MAX_NAME_LEN+1 long.
OPEN_VRF_SET_ERROR_t has the following error-codes and corresponding meaning: OPEN_LOOPBACK_ERROR Loopback interface is used by unnumbered interface and so cannot be part of non-default VRF. OPEN_UNNUMBERED_ERROR Unnumbered interface cannot be part of a non-default VRF. OPEN_SYSLOG_ERROR This routing interface is being used as a syslog source interface, cannot be part of non-default VRF. OPEN_IPV6_ERROR This routing interface has IPv6 address config, cannot be part of non-default VRF.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapStaticArpAdd ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
open_inet_addr_t  ipAddress,
uint32_t  intIfNum,
open_buffdesc macAddrBuf 
)

Add a static ARP entry of a given VRF instance.

Parameters
[in]client_handleClient handle from registration API.
[in]vrfNameVRF Name.
[in]ipAddressIP Address of the entry to be added
[in]intIfNumInternal interface number of the entry. OPEN_INVALID_INTF(0) if interface is not configured.
[in]macAddrBufMAC Address
Return values
OPEN_E_NONEOn success. Entry added.
OPEN_E_PARAMInvalid argument.
OPEN_E_FULLMaximum static ARP entries already configured.
OPEN_E_EXISTSAddress is assigned to a local interface.
OPEN_E_INTERNALIf there is not yet a router interface in the same subnet as the target. Config is applied in this case.
OPEN_E_UNAVAILAddress can neither be network directed broadcast nor subnet address
OPEN_E_FAILAny other failure.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapStaticArpDelete ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
open_inet_addr_t  ipAddress,
uint32_t  intIfNum 
)

Delete a static ARP entry of a given VRF instance.

Parameters
[in]client_handleClient handle from registration API.
[in]vrfNameVRF Name.
[in]ipAddressIP Address of the entry to be deleted
[in]intIfNumInternal interface number of the entry. OPEN_INVALID_INTF(0) if interface is not configured.
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_NOT_FOUNDIf entry is not found.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapSystemUrpfModeGet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t urpfEnabled 
)

Get the System mode for uRPF.

Parameters
[in]client_handleClient handle from registration API
[out]urpfEnabledOPEN_ENABLE or OPEN_DISABLE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapSystemUrpfModeSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  urpfEnabled 
)

Set the System mode for uRPF.

Parameters
[in]client_handleClient handle from registration API
[in]urpfEnabledOPEN_TRUE or OPEN_FALSE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapValidIntfFirstGet ( openapiClientHandle_t client_handle,
uint32_t *  ifNum 
)

Get the first valid interface.

Parameters
[in]client_handleClient handle from registration API
[out]ifNumInternal interface number
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMapValidIntfNextGet ( openapiClientHandle_t client_handle,
uint32_t  prevIfNum,
uint32_t *  ifNum 
)

Get the next valid interface.

Parameters
[in]client_handleClient handle from registration API
[in]prevIfNumInternal interface number
[out]ifNumInternal interface number of next valid interface
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpMcastsFwdModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t mode 
)

Determine whether an interface is configured to forward multicast packets.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]modeForwarding admin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpNetDirectBcastsGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t adminMode 
)

Gets the admin mode for IP forwarding of net-directed broadcasts.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]adminModeForwarding admin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpNetPrototypeRoutesDelete ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t  protoId 
)

Delete all net-prototype route entries.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]protoIdProtocol Id
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpRedirectsModeSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  redirectsMode 
)

Enables/Disables generation of IP Redirects messages.

Parameters
[in]client_handleclient handle from registration API
[in]redirectsModeRedirects mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILother internal error.
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpRouteAdd ( openapiClientHandle_t client_handle,
OPEN_AF_t  af,
open_inet_pfx_t ipAddr,
open_inet_addr_t nextHop,
uint32_t  rtPref,
uint32_t  intf,
OPEN_MPLS_LABELS_t mpls 
)

Add an IP Route for a given address family.

Parameters
[in]client_handleclient handle from registration API
[in]afAddress Family (IPv4 or IPv6)
[in]ipAddrIP address and prefix length.
[in]nextHopNext Hop
[in]rtPrefRoute preference
[in]intfRouter Interface
[in]mplsList of MPLS labels associated with this route
Return values
OPEN_E_NONEadd successful
OPEN_E_PARAMif an input parameter is invalid
OPEN_E_UNAVAILinvalid router interface
OPEN_E_FULLmaximum number of IP Addresses already assigned
OPEN_E_EXISTSaddress already assigned
OPEN_E_FAILfor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpRouteDel ( openapiClientHandle_t client_handle,
OPEN_AF_t  af,
open_inet_pfx_t ipAddr,
open_inet_addr_t nextHop,
uint32_t  intf,
OPEN_MPLS_LABELS_t mpls 
)

Delete an IP Route for a given address family.

Parameters
[in]client_handleclient handle from registration API
[in]afAddress Family (IPv4 or IPv6)
[in]ipAddrIP address and prefix length.
[in]nextHopNext Hop
[in]intfRouter Interface
Return values
OPEN_E_NONEdelete successful
OPEN_E_PARAMif an input parameter is invalid
OPEN_E_UNAVAILinvalid router interface
OPEN_E_NOT_FOUNDaddress not found
OPEN_E_FAILfor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiIpRtrInternalVlanIdToIntIfNum ( openapiClientHandle_t client_handle,
uint32_t  vlanId,
uint32_t *  ifNum 
)

Get the internal interface number associated with the port-based routing interface corresponding to this internal VLAN.

Parameters
[in]client_handleClient handle from registration API
[in]vlanIdId of the VLAN
[out]ifNumInternal interface number of port-based routing interface
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
Cannot be used to find the intIfNum for a VLAN ID used for a VLAN routing interface.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpRtrIntfAutoStateModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t mode 
)

Get the mode of AutoState feature of an interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]modeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpRtrIntfAutoStateModeSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t  mode 
)

Enable or disable the mode of AutoState feature of an interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[in]modeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpRtrIntfModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t mode 
)

Gets the router interface mode.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]modeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpRtrIntfOperModeGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_CONTROL_t mode 
)

Determine whether a given IP interface is up for IPv4.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]modeAdmin mode
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpUnnumberedGet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_BOOL_t isUnnumbered,
uint32_t *  numberedIfc 
)

Determine whether a given interface is unnumbered and if it is, determine the interface whose address the unnumbered interface borrows.

Parameters
[in]client_handleclient handle from registration API
[in]ifNumInternal interface number
[out]isUnnumberedOPEN_TRUE or OPEN_FALSE
[out]numberedIfcInternal interface number of the numbered interface
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpUnnumberedSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
OPEN_BOOL_t  isUnnumbered,
uint32_t  numberedIfc 
)

Set the unnumbered status of an interface.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[in]isUnnumberedOPEN_TRUE or OPEN_FALSE
[in]numberedIfcInternal interface number of the numbered interface whose IP address the unnumbered interface is to borrow
Return values
OPEN_E_EXISTSIf the interface has IP address is already configured
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
Fails if an address is already configured on the interface.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpVlanRtrIntIfNumToVlanId ( openapiClientHandle_t client_handle,
uint32_t  ifNum,
uint32_t *  vlanId 
)

Get the VLAN ID corresponding to the given internal interface number.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number
[out]vlanIdVLAN ID
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiIpVlanRtrVlanIdGetNext ( openapiClientHandle_t client_handle,
uint32_t *  vlanId 
)

Get the next vlan after this vlan on which routing is enabled.

Parameters
[in]client_handleClient handle from registration API
[in,out]vlanIdThe id of the VLAN
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrAdminModeSet ( openapiClientHandle_t client_handle,
OPEN_AF_t  af,
OPEN_CONTROL_t  routingMode 
)

Enables/Disables IP Routing Admin mode.

Parameters
[in]client_handleclient handle from registration API
[in]afAddress Family (IPv4 or IPv6)
[in]routingModeRouting mode
Return values
OPEN_E_NONEset successful.
OPEN_E_FAILset failed.
OPEN_E_PARAMError in parameter passed.
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrArpSwitchClear ( openapiClientHandle_t client_handle)

Clear the switch/management ARP entries.

Parameters
[in]client_handleClient handle from registration API
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrGratArpSet ( openapiClientHandle_t client_handle,
uint32_t  intIfNum,
OPEN_CONTROL_t  gratArpState 
)

Enable or disable gratuitous ARP on an interface.

Parameters
[in]client_handleClient handle from registration API
[in]intIfNumInternal interface number
[in]gratArpStateGrat ARP mode (OPEN_ENABLE/OPEN_DISABLE)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpAddrAdd ( openapiClientHandle_t client_handle,
OPEN_AF_t  af,
uint32_t  intf,
OPEN_INTF_IP_ADDR_TYPE_t  addrType,
open_inet_pfx_t ipAddr,
OPEN_CONTROL_t  extArg 
)

Add an IP address on a given router interface for a given address family.

Parameters
[in]client_handleclient handle from registration API
[in]afAddress Family (IPv4 or IPv6)
[in]intfA routing interface ID
[in]addrTypeAddress Type
[in]ipAddrIP address and prefix length. This argument is not applicable when addrType of DHCP is used.
[in]extArgIf used for Address Family IPv4: Enable the DHCP client to specify the unique client Id Option 61. If used for Address Family IPv6: Enable use of eui-64 Interface Identifier.
Return values
OPEN_E_NONEadd successful
OPEN_E_PARAMif an input parameter is invalid
OPEN_E_UNAVAILinvalid router interface
OPEN_E_FULLmaximum number of IP Addresses already assigned
OPEN_E_EXISTSaddress already assigned
OPEN_E_FAILfor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpAddrDel ( openapiClientHandle_t client_handle,
OPEN_AF_t  af,
uint32_t  intf,
OPEN_INTF_IP_ADDR_TYPE_t  addrType,
open_inet_pfx_t ipAddr,
OPEN_CONTROL_t  extArg 
)

Delete an IP address on a given router interface for a given address family.

Parameters
[in]client_handleclient handle from registration API
[in]afAddress Family (IPv4 or IPv6)
[in]intfA routing interface ID
[in]addrTypeAddress Type
[in]ipAddrIP address and prefix length. This argument is not applicable when addrType of DHCP is used. Passing NULL with Address Type as OPEN_IP_ADDR_TYPE_STATIC_PRIMARY of OPEN_IP_ADDR_TYPE_STATIC_SECONDARY will delete all configured addresses on the interface.
[in]extArgIf used for Address Family IPv4: Enable the DHCP client to specify the unique client Id Option 61. If used for Address Family IPv6: Enable use of eui-64 Interface Identifier.
Return values
OPEN_E_NONEdelete successful
OPEN_E_PARAMif an input parameter is invalid
OPEN_E_FAILfor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpDestUnreachableModeSet ( openapiClientHandle_t client_handle,
uint32_t  intf,
OPEN_CONTROL_t  unreachableMode 
)

Enables/Disables generation of IP Destination Unreachable messages on a Router interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]unreachableModeUnreachable mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpHelperAddressAdd ( openapiClientHandle_t client_handle,
uint32_t  intf,
open_inet_addr_t  ipAddr,
uint32_t  udpPort 
)

Adds IP Helper Address and UDP port number on an interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]ipAddrServer IP address.
[in]udpPortUDP port from <1 - 65535>
Return values
OPEN_E_NONEadd successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpHelperAddressDel ( openapiClientHandle_t client_handle,
uint32_t  intf,
open_inet_addr_t  ipAddr,
uint32_t  udpPort 
)

Deletes IP Helper Address and UDP port number on an interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]ipAddrServer IP address. Use 0 to delete all global entries
[in]udpPortUDP port from <1 - 65535>
Return values
OPEN_E_NONEdelete successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpHelperDiscardAdd ( openapiClientHandle_t client_handle,
uint32_t  intf,
uint32_t  udpPort 
)

Adds IP Helper Discard entry in an interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]udpPortUDP port from <1 - 65535>
Return values
OPEN_E_NONEadd successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpHelperDiscardDel ( openapiClientHandle_t client_handle,
uint32_t  intf,
uint32_t  udpPort 
)

Deletes IP Helper Discard entry in an interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]udpPortUDP port from <1 - 65535>
Return values
OPEN_E_NONEdelete successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpNetDirBroadcastModeSet ( openapiClientHandle_t client_handle,
uint32_t  intf,
OPEN_CONTROL_t  ipNetBroadcastMode 
)

Enables/Disables forwarding of Network-directed broadcast on a Router Interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]ipNetBroadcastModeIP Network-directed broadcast mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpProxyArpModeGet ( openapiClientHandle_t client_handle,
uint32_t  intIfNum,
OPEN_CONTROL_t ipProxyArpMode 
)

Determine whether proxy ARP is enabled on an interface.

Parameters
[in]client_handleClient handle from registration API
[in]intIfNumInternal interface number
[out]ipProxyArpModeIP Proxy ARP mode (OPEN_ENABLE/OPEN_DISABLE)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
OPEN_E_UNAVAILIf not supported.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpProxyArpModeSet ( openapiClientHandle_t client_handle,
uint32_t  intf,
OPEN_CONTROL_t  ipProxyArpMode 
)

Enables/Disables IP Proxy ARP mode on a Router Interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]ipProxyArpModeIP Proxy ARP mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
OPEN_E_UNAVAILIf not supported.
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpRedirectsModeSet ( openapiClientHandle_t client_handle,
uint32_t  intf,
OPEN_CONTROL_t  redirectsMode 
)

Enables/Disables generation of IP Redirects messages on a Router interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]redirectsModeRedirects mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfIpv6AddressModeSet ( openapiClientHandle_t client_handle,
uint32_t  intf,
OPEN_INTF_IP6_ADDR_MODE_t  addrMode,
OPEN_BOOL_t  setFlag 
)

Set or reset the IPv6 address mode on a given router interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfA routing interface ID
[in]addrModeAddress mode
[in]setFlagSet flag (OPEN_TRUE for set or OPEN_FALSE for reset)
Return values
OPEN_E_NONEOn successful set or reset of the address mode
OPEN_E_PARAMIf an input parameter is invalid
OPEN_E_UNAVAILFeature not supported
OPEN_E_FAILFor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIntfMTUSet ( openapiClientHandle_t client_handle,
OPEN_AF_t  af,
uint32_t  intf,
uint32_t  MTU 
)

Configures Router Interface MTU.

Parameters
[in]client_handleclient handle from registration API
[in]afAddress Family (IPv4 or IPv6)
[in]intfRouter Interface
[in]MTUMTU
Return values
OPEN_E_NONEset successful.
OPEN_E_UNAVAILinterface not valid for routing.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIntfRtrAdminModeSet ( openapiClientHandle_t client_handle,
uint32_t  intf,
OPEN_CONTROL_t  routingMode 
)

Enables/Disables IP Routing mode (both v4 and v6) on a Router interface.

Parameters
[in]client_handleclient handle from registration API
[in]intfRouter Interface
[in]routingModeRouting mode
Return values
OPEN_E_NONEset successful.
OPEN_E_PARAMerror in parameter passed.
OPEN_E_FAILany other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrIpArpAgeTimeSet ( openapiClientHandle_t client_handle,
uint32_t  timeout 
)

Sets the ARP entry ageout time.

Parameters
[in]client_handleClient handle from registration API
[in]timeoutARP entry ageout time (in seconds)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpCacheClear ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_BOOL_t  gateway 
)

Clears the ARP cache of all dynamic/gateway entries.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF Name in Bufdescriptor format
[in]gatewayflag to clear gateway entries as well
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
All dynamic entries currently in the ARP cache are cleared. The gateway entries are conditionally cleared based on the value of the gateway parm. No local/static entries are affected.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpCacheSizeSet ( openapiClientHandle_t client_handle,
uint32_t  cacheSize 
)

Sets the maximum number of entries in the ARP cache.

Parameters
[in]client_handleClient handle from registration API
[in]cacheSizeARP cache entries max
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpDynamicRenewGet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t dynRenewMode 
)

Returns the ARP dynamic entry renew mode.

Parameters
[in]client_handleClient handle from registration API
[out]dynRenewModeARP dynamic entry renew mode (OPEN_ENABLE/OPEN_DISABLE)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpDynamicRenewSet ( openapiClientHandle_t client_handle,
OPEN_CONTROL_t  dynRenewMode 
)

Enable or disable the ARP dynamic entry renew mode.

Parameters
[in]client_handleClient handle from registration API
[in]dynRenewModeARP dynamic entry renew mode (OPEN_ENABLE/OPEN_DISABLE)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpEntryPurge ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
open_inet_addr_t  ipAddr,
uint32_t  intIfNum 
)

Purges a specific dynamic/gateway entry from the ARP cache.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF Name
[in]ipAddrIP address of the ARP entry to purge
[in]intIfNumInternal interface number of the entry
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
Does not support deleting local/static ARP entries, as there are other APIs for handling those.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpRespTimeSet ( openapiClientHandle_t client_handle,
uint32_t  timeout 
)

Sets the ARP request response timeout.

Parameters
[in]client_handleClient handle from registration API
[in]timeoutARP request response timeout (in seconds)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpArpRetriesSet ( openapiClientHandle_t client_handle,
uint32_t  count 
)

Sets the ARP request max retries count.

Parameters
[in]client_handleClient handle from registration API
[in]countARP request max retries count
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpMapStaticArpGetAll ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_ARP_STATIC_ALL_t openArpEntries 
)

Get a list of all static ARP entries currently configured.

Parameters
[in]client_handleClient handle from registration API.
[in]vrfNameVRF Name.
[out]openArpEntriesA data-structure containing an array of max ARP entries. On return, the array is filled with the static ARP entries. The first entry with an IP address of 0 indicates the end of the list.
Return values
OPEN_E_NONEOn success.
OPEN_E_PARAMInvalid argument.
OPEN_E_FAILAny other failure.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpUnnumberedGratArpGet ( openapiClientHandle_t client_handle,
uint32_t  intIfNum,
OPEN_BOOL_t isEnabled 
)

Get the behavior of gratuitous ARP received on unnumbered interface.

Parameters
[in]client_handleClient handle from registration API
[in]intIfNumInternal interface number
[out]isEnabledGrat ARP mode flag (OPEN_TRUE or OPEN_FALSE)
  • OPEN_TRUE: install interface route to unnumebred peer on receiving grat ARP
  • OPEN_FALSE: don't install any interface route
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrIpUnnumberedGratArpSet ( openapiClientHandle_t client_handle,
uint32_t  intIfNum,
OPEN_BOOL_t  isEnabled 
)

Set the behavior of gratuitous ARP received on unnumbered interface.

Parameters
[in]client_handleClient handle from registration API
[in]intIfNumInternal interface number
[in]isEnabledGrat ARP mode flag (OPEN_TRUE or OPEN_FALSE)
  • OPEN_TRUE: install interface route to unnumebred peer on receiving grat ARP
  • OPEN_FALSE: don't install any interface route
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrLocalProxyArpModeGet ( openapiClientHandle_t client_handle,
uint32_t  intIfNum,
OPEN_CONTROL_t localProxyArpMode 
)

Determine whether local proxy ARP is enabled on an interface.

Parameters
[in]client_handleClient handle from registration API
[in]intIfNumInternal interface number
[out]localProxyArpModeLocal Proxy ARP mode (OPEN_ENABLE/OPEN_DISABLE)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
OPEN_E_UNAVAILIf not supported.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrLocalProxyArpModeSet ( openapiClientHandle_t client_handle,
uint32_t  intIfNum,
OPEN_CONTROL_t  localProxyArpMode 
)

Enable or disable local proxy ARP on an interface.

Parameters
[in]client_handleClient handle from registration API
[in]intIfNumInternal interface number
[in]localProxyArpModeLocal Proxy ARP mode (OPEN_ENABLE/OPEN_DISABLE)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
OPEN_E_UNAVAILIf not supported.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrRouteMaxEqualCostEntriesGet ( openapiClientHandle_t client_handle,
uint32_t *  maxhops 
)

Get the routing max equal cost entries.

Parameters
[in]client_handleClient handle from registration API
[out]maxhopsmaxhops value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrRouteMaxRouteEntriesGet ( openapiClientHandle_t client_handle,
uint32_t *  maxroutes 
)

Get the routing max routes entries.

Parameters
[in]client_handleClient handle from registration API
[out]maxroutesmax routes value
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiRtrVlanIntfCreate ( openapiClientHandle_t client_handle,
uint32_t  vlanId 
)

Create a VLAN Routing Interface.

Parameters
[in]client_handleclient handle from registration API
[in]vlanIdVLAN ID
Return values
OPEN_E_NONEcreate successful
OPEN_E_PARAMif an input parameter is invalid
OPEN_E_EXISTSVLAN ID already in use for port based routing
OPEN_E_FULLmaximum number of Routing VLANs already configured
OPEN_E_NOT_FOUNDdependency not met
OPEN_E_FAILfor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrVlanIntfDelete ( openapiClientHandle_t client_handle,
uint32_t  vlanId 
)

Delete a VLAN Routing Interface.

Parameters
[in]client_handleclient handle from registration API
[in]vlanIdVLAN ID
Return values
OPEN_E_NONEdelete successful
OPEN_E_PARAMif an input parameter is invalid
OPEN_E_NOT_FOUNDVLAN routing interface does not exist
OPEN_E_FAILfor any other failure
Note
Calling this API will change the running configuration of the switch

OpEN API Version: 1.1

Examples:
routing_example.c.
open_error_t openapiRtrVlanIntfIfNumGet ( openapiClientHandle_t client_handle,
uint32_t  vlanId,
uint32_t *  intf 
)

Get the interface number for a VLAN Routing Interface.

Parameters
[in]client_handleclient handle from registration API
[in]vlanIdVLAN ID
[out]intfInterface number if call successful
Return values
OPEN_E_NONEsuccess, intf contains the interface number
OPEN_E_PARAMan input parameter is invalid
OPEN_E_NOT_FOUNDinterface number could not be found for VLAN.
OPEN_E_FAILa failure occurred

OpEN API Version: 1.17

Examples:
routing_example.c.
open_error_t openapiSourceInterfacesGet ( openapiClientHandle_t client_handle,
uint32_t *  ifNum 
)

Get source IP interface from Syslog, SNMP Traps, SNTP, DNS Client, RADIUS, TACACS+ and sFlow apps.

Parameters
[in]client_handleClient handle from registration API
[out]ifNumInternal interface number of the source interface
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure. Source interfaces are different.
OPEN_E_PARAMInvalid argument.
OPEN_E_UNAVAILCan't receive one of source interfaces
OPEN_E_NOT_FOUNDFeature unsupported

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiSourceInterfacesSet ( openapiClientHandle_t client_handle,
uint32_t  ifNum 
)

Set source IP interface for Syslog, SNMP Traps, SNTP, DNS Client, RADIUS, TACACS+ and sFlow apps.

Parameters
[in]client_handleClient handle from registration API
[in]ifNumInternal interface number for setting as source interface
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVlanIntfIdGet ( openapiClientHandle_t client_handle,
uint32_t  vlanId,
uint32_t *  ifNum 
)

Get the interface ID for a given VLAN.

Parameters
[in]client_handleClient handle from registration API
[in]vlanIdVLAN ID
[out]ifNumInterface ID (not internal interface number)
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
The interface ID is an internally assigned integer in the range [1, L7_MAX_NUM_VLAN_INTF].

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVrAddrConflictDetectStatusClear ( openapiClientHandle_t client_handle,
open_buffdesc vrfName 
)

Clear the Address Conflict Detection Status of a given VRF instance.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVrAddrConflictDetectStatusGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
OPEN_BOOL_t conflictDetectStatus 
)

Get the Address Conflict Detection Status of a VRF instance.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[out]conflictDetectStatusOPEN_TRUE or OPEN_FALSE
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.
Note
Status would be returned as OPEN_TRUE if there was at least one conflict detected since last reset of the status. Else status is returned as OPEN_FALSE.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVrAddrConflictLastDetectMACGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
open_buffdesc conflictMAC 
)

Get the MAC Address of the last detected address conflict in a VRF instance.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[out]conflictMACMAC of last detected conflicting host
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVrAddrConflictLastDetectTimeGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t *  conflictDetectTime 
)

Get the time in seconds since the last address conflict was detected in a VRF instance.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[out]conflictDetectTimeTime since the last detected conflict
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVrIpRouterPreferenceGet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t  origin,
uint32_t *  pref 
)

Get the Router preference for the given protocol and VRF name.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]originRouter protocol type
[out]prefPreference associated with the protocol
Return values
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.
open_error_t openapiVrIpRouterPreferenceSet ( openapiClientHandle_t client_handle,
open_buffdesc vrfName,
uint32_t  origin,
uint32_t  pref 
)

Set the Router preference for the given protocol and VRF name.

Parameters
[in]client_handleClient handle from registration API
[in]vrfNameVRF name
[in]originRouter protocol type (one of L7_RTO_PROTOCOL_INDICES_t)
[in]prefPreference associated with the protocol
Return values
OPEN_E_UNAVAILPreference value is in use by another protocol
OPEN_E_ERRORInvalid preference change
OPEN_E_NONEOn success.
OPEN_E_FAILOn failure.
OPEN_E_PARAMInvalid argument.

OpEN API Version: 1.25

Examples:
routing_example.c.