mib2_module.h File Reference

MIB-II module. More...

#include "core/net.h"
#include "core/udp.h"
#include "core/tcp.h"
#include "ipv4/ipv4.h"
#include "mibs/mib_common.h"

Go to the source code of this file.

Data Structures

struct  Mib2SysGroup
 System group. More...
 
struct  Mib2IfEntry
 Interfaces table entry. More...
 
struct  Mib2IfGroup
 Interfaces group. More...
 
struct  Mib2IpGroup
 IP group. More...
 
struct  Mib2IcmpGroup
 ICMP group. More...
 
struct  Mib2TcpGroup
 TCP group. More...
 
struct  Mib2UdpGroup
 UDP group. More...
 
struct  Mib2SnmpGroup
 SNMP group. More...
 
struct  Mib2Base
 MIB-II base. More...
 

Macros

#define MIB2_SUPPORT   DISABLED
 
#define MIB2_SYS_GROUP_SUPPORT   ENABLED
 
#define MIB2_IF_GROUP_SUPPORT   ENABLED
 
#define MIB2_IP_GROUP_SUPPORT   ENABLED
 
#define MIB2_ICMP_GROUP_SUPPORT   ENABLED
 
#define MIB2_TCP_GROUP_SUPPORT   ENABLED
 
#define MIB2_UDP_GROUP_SUPPORT   ENABLED
 
#define MIB2_SNMP_GROUP_SUPPORT   ENABLED
 
#define MIB2_SYS_DESCR_SIZE   16
 
#define MIB2_SYS_OBJECT_ID_SIZE   16
 
#define MIB2_SYS_CONTACT_SIZE   16
 
#define MIB2_SYS_NAME_SIZE   16
 
#define MIB2_SYS_LOCATION_SIZE   16
 
#define MIB2_IF_SPECIFIC_SIZE   16
 
#define MIB2_PHYS_ADDRESS_SIZE   6
 
#define MIB2_IP_ADDRESS_SIZE   4
 
#define MIB2_SET_TIME_TICKS(name, value)   mib2Base.name = value
 
#define MIB2_INC_COUNTER32(name, value)   mib2Base.name += value
 

Enumerations

enum  Mib2SysService {
  MIB2_SYS_SERVICE_PHYSICAL = 0x01, MIB2_SYS_SERVICE_DATALINK = 0x02, MIB2_SYS_SERVICE_INTERNET = 0x04, MIB2_SYS_SERVICE_END_TO_END = 0x08,
  MIB2_SYS_SERVICE_APPLICATIONS = 0x40
}
 System services. More...
 
enum  Mib2IfType {
  MIB2_IF_TYPE_OTHER = 1, MIB2_IF_TYPE_ETHERNET_CSMACD = 6, MIB2_IF_TYPE_PROP_PTP_SERIAL = 22, MIB2_IF_TYPE_PPP = 23,
  MIB2_IF_TYPE_SOFT_LOOPBACK = 24, MIB2_IF_TYPE_SLIP = 28, MIB2_IF_TYPE_RS232 = 33, MIB2_IF_TYPE_PARA = 34,
  MIB2_IF_TYPE_L2_VLAN = 135, MIB2_IF_TYPE_USB = 160, MIB2_IF_TYPE_IEEE_802_15_4 = 259
}
 Interface types. More...
 
enum  Mib2IfAdminStatus { MIB2_IF_ADMIN_STATUS_UP = 1, MIB2_IF_ADMIN_STATUS_DOWN = 2, MIB2_IF_ADMIN_STATUS_TESTING = 3 }
 The desired state of the interface. More...
 
enum  Mib2IfOperStatus { MIB2_IF_OPER_STATUS_UP = 1, MIB2_IF_OPER_STATUS_DOWN = 2, MIB2_IF_OPER_STATUS_TESTING = 3 }
 The operational state of the interface. More...
 
enum  Mib2IpForwarding { MIB2_IP_FORWARDING_ENABLED = 1, MIB2_IP_FORWARDING_DISABLED = 2 }
 IP forwarding state. More...
 
enum  Mib2IpNetToMediaType { MIB2_IP_NET_TO_MEDIA_TYPE_OTHER = 1, MIB2_IP_NET_TO_MEDIA_TYPE_INVALID = 2, MIB2_IP_NET_TO_MEDIA_TYPE_DYNAMIC = 3, MIB2_IP_NET_TO_MEDIA_TYPE_STATIC = 4 }
 Type of mapping. More...
 
enum  Mib2TcpRtoAlgorithm { MIB2_TCP_RTO_ALGORITHM_OTHER = 1, MIB2_TCP_RTO_ALGORITHM_CONSTANT = 2, MIB2_TCP_RTO_ALGORITHM_RSRE = 3, MIB2_TCP_RTO_ALGORITHM_VANJ = 4 }
 RTO calculation algorithm. More...
 
enum  Mib2TcpConnState {
  MIB2_TCP_CONN_STATE_CLOSED = 1, MIB2_TCP_CONN_STATE_LISTEN = 2, MIB2_TCP_CONN_STATE_SYN_SENT = 3, MIB2_TCP_CONN_STATE_SYN_RECEIVED = 4,
  MIB2_TCP_CONN_STATE_ESTABLISHED = 5, MIB2_TCP_CONN_STATE_FIN_WAIT_1 = 6, MIB2_TCP_CONN_STATE_FIN_WAIT_2 = 7, MIB2_TCP_CONN_STATE_CLOSE_WAIT = 8,
  MIB2_TCP_CONN_STATE_LAST_ACK = 9, MIB2_TCP_CONN_STATE_CLOSING = 10, MIB2_TCP_CONN_STATE_TIME_WAIT = 11, MIB2_TCP_CONN_STATE_DELETE_TCB = 12
}
 TCP connection states. More...
 

Variables

Mib2Base mib2Base
 MIB-II base. More...
 
const MibObject mib2Objects []
 MIB-II objects. More...
 
const MibModule mib2Module
 MIB-II module. More...
 

Detailed Description

MIB-II module.

License

Copyright (C) 2010-2018 Oryx Embedded SARL. All rights reserved.

This file is part of CycloneTCP Open.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

Author
Oryx Embedded SARL (www.oryx-embedded.com)
Version
1.9.0

Definition in file mib2_module.h.

Macro Definition Documentation

◆ MIB2_ICMP_GROUP_SUPPORT

#define MIB2_ICMP_GROUP_SUPPORT   ENABLED

Definition at line 69 of file mib2_module.h.

◆ MIB2_IF_GROUP_SUPPORT

#define MIB2_IF_GROUP_SUPPORT   ENABLED

Definition at line 55 of file mib2_module.h.

◆ MIB2_IF_SPECIFIC_SIZE

#define MIB2_IF_SPECIFIC_SIZE   16

Definition at line 132 of file mib2_module.h.

◆ MIB2_INC_COUNTER32

#define MIB2_INC_COUNTER32 (   name,
  value 
)    mib2Base.name += value

Definition at line 154 of file mib2_module.h.

◆ MIB2_IP_ADDRESS_SIZE

#define MIB2_IP_ADDRESS_SIZE   4

Definition at line 146 of file mib2_module.h.

◆ MIB2_IP_GROUP_SUPPORT

#define MIB2_IP_GROUP_SUPPORT   ENABLED

Definition at line 62 of file mib2_module.h.

◆ MIB2_PHYS_ADDRESS_SIZE

#define MIB2_PHYS_ADDRESS_SIZE   6

Definition at line 139 of file mib2_module.h.

◆ MIB2_SET_TIME_TICKS

#define MIB2_SET_TIME_TICKS (   name,
  value 
)    mib2Base.name = value

Definition at line 153 of file mib2_module.h.

◆ MIB2_SNMP_GROUP_SUPPORT

#define MIB2_SNMP_GROUP_SUPPORT   ENABLED

Definition at line 90 of file mib2_module.h.

◆ MIB2_SUPPORT

#define MIB2_SUPPORT   DISABLED

Definition at line 41 of file mib2_module.h.

◆ MIB2_SYS_CONTACT_SIZE

#define MIB2_SYS_CONTACT_SIZE   16

Definition at line 111 of file mib2_module.h.

◆ MIB2_SYS_DESCR_SIZE

#define MIB2_SYS_DESCR_SIZE   16

Definition at line 97 of file mib2_module.h.

◆ MIB2_SYS_GROUP_SUPPORT

#define MIB2_SYS_GROUP_SUPPORT   ENABLED

Definition at line 48 of file mib2_module.h.

◆ MIB2_SYS_LOCATION_SIZE

#define MIB2_SYS_LOCATION_SIZE   16

Definition at line 125 of file mib2_module.h.

◆ MIB2_SYS_NAME_SIZE

#define MIB2_SYS_NAME_SIZE   16

Definition at line 118 of file mib2_module.h.

◆ MIB2_SYS_OBJECT_ID_SIZE

#define MIB2_SYS_OBJECT_ID_SIZE   16

Definition at line 104 of file mib2_module.h.

◆ MIB2_TCP_GROUP_SUPPORT

#define MIB2_TCP_GROUP_SUPPORT   ENABLED

Definition at line 76 of file mib2_module.h.

◆ MIB2_UDP_GROUP_SUPPORT

#define MIB2_UDP_GROUP_SUPPORT   ENABLED

Definition at line 83 of file mib2_module.h.

Enumeration Type Documentation

◆ Mib2IfAdminStatus

The desired state of the interface.

Enumerator
MIB2_IF_ADMIN_STATUS_UP 
MIB2_IF_ADMIN_STATUS_DOWN 
MIB2_IF_ADMIN_STATUS_TESTING 

Definition at line 204 of file mib2_module.h.

◆ Mib2IfOperStatus

The operational state of the interface.

Enumerator
MIB2_IF_OPER_STATUS_UP 
MIB2_IF_OPER_STATUS_DOWN 
MIB2_IF_OPER_STATUS_TESTING 

Definition at line 216 of file mib2_module.h.

◆ Mib2IfType

enum Mib2IfType

Interface types.

Enumerator
MIB2_IF_TYPE_OTHER 
MIB2_IF_TYPE_ETHERNET_CSMACD 
MIB2_IF_TYPE_PROP_PTP_SERIAL 
MIB2_IF_TYPE_PPP 
MIB2_IF_TYPE_SOFT_LOOPBACK 
MIB2_IF_TYPE_SLIP 
MIB2_IF_TYPE_RS232 
MIB2_IF_TYPE_PARA 
MIB2_IF_TYPE_L2_VLAN 
MIB2_IF_TYPE_USB 
MIB2_IF_TYPE_IEEE_802_15_4 

Definition at line 184 of file mib2_module.h.

◆ Mib2IpForwarding

IP forwarding state.

Enumerator
MIB2_IP_FORWARDING_ENABLED 
MIB2_IP_FORWARDING_DISABLED 

Definition at line 228 of file mib2_module.h.

◆ Mib2IpNetToMediaType

Type of mapping.

Enumerator
MIB2_IP_NET_TO_MEDIA_TYPE_OTHER 
MIB2_IP_NET_TO_MEDIA_TYPE_INVALID 
MIB2_IP_NET_TO_MEDIA_TYPE_DYNAMIC 
MIB2_IP_NET_TO_MEDIA_TYPE_STATIC 

Definition at line 239 of file mib2_module.h.

◆ Mib2SysService

System services.

Enumerator
MIB2_SYS_SERVICE_PHYSICAL 
MIB2_SYS_SERVICE_DATALINK 
MIB2_SYS_SERVICE_INTERNET 
MIB2_SYS_SERVICE_END_TO_END 
MIB2_SYS_SERVICE_APPLICATIONS 

Definition at line 170 of file mib2_module.h.

◆ Mib2TcpConnState

TCP connection states.

Enumerator
MIB2_TCP_CONN_STATE_CLOSED 
MIB2_TCP_CONN_STATE_LISTEN 
MIB2_TCP_CONN_STATE_SYN_SENT 
MIB2_TCP_CONN_STATE_SYN_RECEIVED 
MIB2_TCP_CONN_STATE_ESTABLISHED 
MIB2_TCP_CONN_STATE_FIN_WAIT_1 
MIB2_TCP_CONN_STATE_FIN_WAIT_2 
MIB2_TCP_CONN_STATE_CLOSE_WAIT 
MIB2_TCP_CONN_STATE_LAST_ACK 
MIB2_TCP_CONN_STATE_CLOSING 
MIB2_TCP_CONN_STATE_TIME_WAIT 
MIB2_TCP_CONN_STATE_DELETE_TCB 

Definition at line 265 of file mib2_module.h.

◆ Mib2TcpRtoAlgorithm

RTO calculation algorithm.

Enumerator
MIB2_TCP_RTO_ALGORITHM_OTHER 
MIB2_TCP_RTO_ALGORITHM_CONSTANT 
MIB2_TCP_RTO_ALGORITHM_RSRE 
MIB2_TCP_RTO_ALGORITHM_VANJ 

Definition at line 252 of file mib2_module.h.

Variable Documentation

◆ mib2Base

Mib2Base mib2Base

MIB-II base.

Definition at line 56 of file mib2_module.c.

◆ mib2Module

const MibModule mib2Module

MIB-II module.

Definition at line 2201 of file mib2_module.c.

◆ mib2Objects

const MibObject mib2Objects[]

MIB-II objects.

Definition at line 63 of file mib2_module.c.