xref: /titanic_44/usr/src/uts/common/inet/mib2.h (revision 6a634c9dca3093f3922e4b7ab826d7bdf17bf78e)
17c478bd9Sstevel@tonic-gate /*
27c478bd9Sstevel@tonic-gate  * CDDL HEADER START
37c478bd9Sstevel@tonic-gate  *
47c478bd9Sstevel@tonic-gate  * The contents of this file are subject to the terms of the
545916cd2Sjpk  * Common Development and Distribution License (the "License").
645916cd2Sjpk  * You may not use this file except in compliance with the License.
77c478bd9Sstevel@tonic-gate  *
87c478bd9Sstevel@tonic-gate  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
97c478bd9Sstevel@tonic-gate  * or http://www.opensolaris.org/os/licensing.
107c478bd9Sstevel@tonic-gate  * See the License for the specific language governing permissions
117c478bd9Sstevel@tonic-gate  * and limitations under the License.
127c478bd9Sstevel@tonic-gate  *
137c478bd9Sstevel@tonic-gate  * When distributing Covered Code, include this CDDL HEADER in each
147c478bd9Sstevel@tonic-gate  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
157c478bd9Sstevel@tonic-gate  * If applicable, add the following below this CDDL HEADER, with the
167c478bd9Sstevel@tonic-gate  * fields enclosed by brackets "[]" replaced with your own identifying
177c478bd9Sstevel@tonic-gate  * information: Portions Copyright [yyyy] [name of copyright owner]
187c478bd9Sstevel@tonic-gate  *
197c478bd9Sstevel@tonic-gate  * CDDL HEADER END
20e11c3f44Smeem  *
21*6f773e29SBaban Kenkre  * Copyright (c) 1991, 2010, Oracle and/or its affiliates. All rights reserved.
227c478bd9Sstevel@tonic-gate  */
237c478bd9Sstevel@tonic-gate /* Copyright (c) 1990 Mentat Inc. */
247c478bd9Sstevel@tonic-gate 
257c478bd9Sstevel@tonic-gate #ifndef	_INET_MIB2_H
267c478bd9Sstevel@tonic-gate #define	_INET_MIB2_H
277c478bd9Sstevel@tonic-gate 
287c478bd9Sstevel@tonic-gate #include <netinet/in.h>	/* For in6_addr_t */
2945916cd2Sjpk #include <sys/tsol/label.h> /* For brange_t */
3045916cd2Sjpk #include <sys/tsol/label_macro.h> /* For brange_t */
317c478bd9Sstevel@tonic-gate 
327c478bd9Sstevel@tonic-gate #ifdef	__cplusplus
337c478bd9Sstevel@tonic-gate extern "C" {
347c478bd9Sstevel@tonic-gate #endif
357c478bd9Sstevel@tonic-gate 
367c478bd9Sstevel@tonic-gate /*
377c478bd9Sstevel@tonic-gate  * The IPv6 parts of this are derived from:
387c478bd9Sstevel@tonic-gate  *	RFC 2465
397c478bd9Sstevel@tonic-gate  *	RFC 2466
407c478bd9Sstevel@tonic-gate  *	RFC 2452
417c478bd9Sstevel@tonic-gate  *	RFC 2454
427c478bd9Sstevel@tonic-gate  */
437c478bd9Sstevel@tonic-gate 
447c478bd9Sstevel@tonic-gate /*
457c478bd9Sstevel@tonic-gate  * SNMP set/get via M_PROTO T_OPTMGMT_REQ.  Structure is that used
467c478bd9Sstevel@tonic-gate  * for [gs]etsockopt() calls.  get uses T_CURRENT, set uses T_NEOGTIATE
477c478bd9Sstevel@tonic-gate  * MGMT_flags value.  The following definition of opthdr is taken from
487c478bd9Sstevel@tonic-gate  * socket.h:
497c478bd9Sstevel@tonic-gate  *
507c478bd9Sstevel@tonic-gate  * An option specification consists of an opthdr, followed by the value of
517c478bd9Sstevel@tonic-gate  * the option.  An options buffer contains one or more options.  The len
527c478bd9Sstevel@tonic-gate  * field of opthdr specifies the length of the option value in bytes.  This
537c478bd9Sstevel@tonic-gate  * length must be a multiple of sizeof(long) (use OPTLEN macro).
547c478bd9Sstevel@tonic-gate  *
557c478bd9Sstevel@tonic-gate  * struct opthdr {
567c478bd9Sstevel@tonic-gate  *	long	level;	protocol level affected
577c478bd9Sstevel@tonic-gate  *	long	name;	option to modify
587c478bd9Sstevel@tonic-gate  *	long	len;	length of option value
597c478bd9Sstevel@tonic-gate  * };
607c478bd9Sstevel@tonic-gate  *
617c478bd9Sstevel@tonic-gate  * #define OPTLEN(x) ((((x) + sizeof(long) - 1) / sizeof(long)) * sizeof(long))
627c478bd9Sstevel@tonic-gate  * #define OPTVAL(opt) ((char *)(opt + 1))
637c478bd9Sstevel@tonic-gate  *
64e11c3f44Smeem  * For get requests (T_CURRENT), any MIB2_xxx value can be used (only
657c478bd9Sstevel@tonic-gate  * "get all" is supported, so all modules get a copy of the request to
66e11c3f44Smeem  * return everything it knows.   In general, we use MIB2_IP.  There is
67e11c3f44Smeem  * one exception: in general, IP will not report information related to
68bd670b35SErik Nordmark  * ire_testhidden and IRE_IF_CLONE routes (e.g., in the MIB2_IP_ROUTE
69bd670b35SErik Nordmark  * table). However, using the special value EXPER_IP_AND_ALL_IRES will cause
70e11c3f44Smeem  * all information to be reported.  This special value should only be
71e11c3f44Smeem  * used by IPMP-aware low-level utilities (e.g. in.mpathd).
727c478bd9Sstevel@tonic-gate  *
737c478bd9Sstevel@tonic-gate  * IMPORTANT:  some fields are grouped in a different structure than
747c478bd9Sstevel@tonic-gate  * suggested by MIB-II, e.g., checksum error counts.  The original MIB-2
757c478bd9Sstevel@tonic-gate  * field name has been retained.  Field names beginning with "mi" are not
767c478bd9Sstevel@tonic-gate  * defined in the MIB but contain important & useful information maintained
777c478bd9Sstevel@tonic-gate  * by the corresponding module.
787c478bd9Sstevel@tonic-gate  */
797c478bd9Sstevel@tonic-gate #ifndef IPPROTO_MAX
807c478bd9Sstevel@tonic-gate #define	IPPROTO_MAX	256
817c478bd9Sstevel@tonic-gate #endif
827c478bd9Sstevel@tonic-gate 
837c478bd9Sstevel@tonic-gate #define	MIB2_SYSTEM		(IPPROTO_MAX+1)
847c478bd9Sstevel@tonic-gate #define	MIB2_INTERFACES		(IPPROTO_MAX+2)
857c478bd9Sstevel@tonic-gate #define	MIB2_AT			(IPPROTO_MAX+3)
867c478bd9Sstevel@tonic-gate #define	MIB2_IP			(IPPROTO_MAX+4)
877c478bd9Sstevel@tonic-gate #define	MIB2_ICMP		(IPPROTO_MAX+5)
887c478bd9Sstevel@tonic-gate #define	MIB2_TCP		(IPPROTO_MAX+6)
897c478bd9Sstevel@tonic-gate #define	MIB2_UDP		(IPPROTO_MAX+7)
907c478bd9Sstevel@tonic-gate #define	MIB2_EGP		(IPPROTO_MAX+8)
917c478bd9Sstevel@tonic-gate #define	MIB2_CMOT		(IPPROTO_MAX+9)
927c478bd9Sstevel@tonic-gate #define	MIB2_TRANSMISSION	(IPPROTO_MAX+10)
937c478bd9Sstevel@tonic-gate #define	MIB2_SNMP		(IPPROTO_MAX+11)
947c478bd9Sstevel@tonic-gate #define	MIB2_IP6		(IPPROTO_MAX+12)
957c478bd9Sstevel@tonic-gate #define	MIB2_ICMP6		(IPPROTO_MAX+13)
967c478bd9Sstevel@tonic-gate #define	MIB2_TCP6		(IPPROTO_MAX+14)
977c478bd9Sstevel@tonic-gate #define	MIB2_UDP6		(IPPROTO_MAX+15)
987c478bd9Sstevel@tonic-gate #define	MIB2_SCTP		(IPPROTO_MAX+16)
997c478bd9Sstevel@tonic-gate 
1007c478bd9Sstevel@tonic-gate /*
1017c478bd9Sstevel@tonic-gate  * Define range of levels for use with MIB2_*
1027c478bd9Sstevel@tonic-gate  */
1037c478bd9Sstevel@tonic-gate #define	MIB2_RANGE_START	(IPPROTO_MAX+1)
1047c478bd9Sstevel@tonic-gate #define	MIB2_RANGE_END		(IPPROTO_MAX+16)
1057c478bd9Sstevel@tonic-gate 
1067c478bd9Sstevel@tonic-gate 
1077c478bd9Sstevel@tonic-gate #define	EXPER			1024	/* experimental - not part of mib */
1087c478bd9Sstevel@tonic-gate #define	EXPER_IGMP		(EXPER+1)
1097c478bd9Sstevel@tonic-gate #define	EXPER_DVMRP		(EXPER+2)
1107c478bd9Sstevel@tonic-gate #define	EXPER_RAWIP		(EXPER+3)
111bd670b35SErik Nordmark #define	EXPER_IP_AND_ALL_IRES	(EXPER+4)
1127c478bd9Sstevel@tonic-gate 
1137c478bd9Sstevel@tonic-gate /*
1147c478bd9Sstevel@tonic-gate  * Define range of levels for experimental use
1157c478bd9Sstevel@tonic-gate  */
1167c478bd9Sstevel@tonic-gate #define	EXPER_RANGE_START	(EXPER+1)
117e11c3f44Smeem #define	EXPER_RANGE_END		(EXPER+4)
1187c478bd9Sstevel@tonic-gate 
1197c478bd9Sstevel@tonic-gate #define	BUMP_MIB(s, x)		{				\
1207c478bd9Sstevel@tonic-gate 	extern void __dtrace_probe___mib_##x(int, void *);	\
1217c478bd9Sstevel@tonic-gate 	void *stataddr = &((s)->x);				\
1227c478bd9Sstevel@tonic-gate 	__dtrace_probe___mib_##x(1, stataddr);			\
1237c478bd9Sstevel@tonic-gate 	(s)->x++;						\
1247c478bd9Sstevel@tonic-gate }
1257c478bd9Sstevel@tonic-gate 
1267c478bd9Sstevel@tonic-gate #define	UPDATE_MIB(s, x, y)	{				\
1277c478bd9Sstevel@tonic-gate 	extern void __dtrace_probe___mib_##x(int, void *);	\
1287c478bd9Sstevel@tonic-gate 	void *stataddr = &((s)->x);				\
1297c478bd9Sstevel@tonic-gate 	__dtrace_probe___mib_##x(y, stataddr);			\
1307c478bd9Sstevel@tonic-gate 	(s)->x += (y);						\
1317c478bd9Sstevel@tonic-gate }
1327c478bd9Sstevel@tonic-gate 
1337c478bd9Sstevel@tonic-gate #define	SET_MIB(x, y)		x = y
1347c478bd9Sstevel@tonic-gate #define	BUMP_LOCAL(x)		(x)++
1357c478bd9Sstevel@tonic-gate #define	UPDATE_LOCAL(x, y)	(x) += (y)
1363173664eSapersson #define	SYNC32_MIB(s, m32, m64)	SET_MIB((s)->m32, (s)->m64 & 0xffffffff)
1377c478bd9Sstevel@tonic-gate 
138*6f773e29SBaban Kenkre /*
139*6f773e29SBaban Kenkre  * Each struct that has been extended have a macro (MIB_FIRST_NEW_ELM_type)
140*6f773e29SBaban Kenkre  * that is set to the first new element of the extended struct.
141*6f773e29SBaban Kenkre  * The LEGACY_MIB_SIZE macro can be used to determine the size of MIB
142*6f773e29SBaban Kenkre  * objects that needs to be returned to older applications unaware of
143*6f773e29SBaban Kenkre  * these extensions.
144*6f773e29SBaban Kenkre  */
145*6f773e29SBaban Kenkre #define	MIB_PTRDIFF(s, e)	(caddr_t)e - (caddr_t)s
146*6f773e29SBaban Kenkre #define	LEGACY_MIB_SIZE(s, t)	MIB_PTRDIFF(s, &(s)->MIB_FIRST_NEW_ELM_##t)
147*6f773e29SBaban Kenkre 
1487c478bd9Sstevel@tonic-gate #define	OCTET_LENGTH	32	/* Must be at least LIFNAMSIZ */
1497c478bd9Sstevel@tonic-gate typedef struct Octet_s {
1507c478bd9Sstevel@tonic-gate 	int	o_length;
1517c478bd9Sstevel@tonic-gate 	char	o_bytes[OCTET_LENGTH];
1527c478bd9Sstevel@tonic-gate } Octet_t;
1537c478bd9Sstevel@tonic-gate 
1547c478bd9Sstevel@tonic-gate typedef uint32_t	Counter;
1557c478bd9Sstevel@tonic-gate typedef uint32_t	Counter32;
1567c478bd9Sstevel@tonic-gate typedef uint64_t	Counter64;
1577c478bd9Sstevel@tonic-gate typedef uint32_t	Gauge;
1587c478bd9Sstevel@tonic-gate typedef uint32_t	IpAddress;
1597c478bd9Sstevel@tonic-gate typedef	struct in6_addr	Ip6Address;
1607c478bd9Sstevel@tonic-gate typedef Octet_t		DeviceName;
1617c478bd9Sstevel@tonic-gate typedef Octet_t		PhysAddress;
1627c478bd9Sstevel@tonic-gate typedef uint32_t	DeviceIndex;	/* Interface index */
1637c478bd9Sstevel@tonic-gate 
1643173664eSapersson #define	MIB2_UNKNOWN_INTERFACE	0
1653173664eSapersson #define	MIB2_UNKNOWN_PROCESS	0
1663173664eSapersson 
1677c478bd9Sstevel@tonic-gate /*
1687c478bd9Sstevel@tonic-gate  *  IP group
1697c478bd9Sstevel@tonic-gate  */
1707c478bd9Sstevel@tonic-gate #define	MIB2_IP_ADDR		20	/* ipAddrEntry */
1717c478bd9Sstevel@tonic-gate #define	MIB2_IP_ROUTE		21	/* ipRouteEntry */
1727c478bd9Sstevel@tonic-gate #define	MIB2_IP_MEDIA		22	/* ipNetToMediaEntry */
1737c478bd9Sstevel@tonic-gate #define	MIB2_IP6_ROUTE		23	/* ipv6RouteEntry */
1747c478bd9Sstevel@tonic-gate #define	MIB2_IP6_MEDIA		24	/* ipv6NetToMediaEntry */
1757c478bd9Sstevel@tonic-gate #define	MIB2_IP6_ADDR		25	/* ipv6AddrEntry */
1763173664eSapersson #define	MIB2_IP_TRAFFIC_STATS	31	/* ipIfStatsEntry (IPv4) */
1777c478bd9Sstevel@tonic-gate #define	EXPER_IP_GROUP_MEMBERSHIP	100
1787c478bd9Sstevel@tonic-gate #define	EXPER_IP6_GROUP_MEMBERSHIP	101
1797c478bd9Sstevel@tonic-gate #define	EXPER_IP_GROUP_SOURCES		102
1807c478bd9Sstevel@tonic-gate #define	EXPER_IP6_GROUP_SOURCES		103
18145916cd2Sjpk #define	EXPER_IP_RTATTR			104
182bd670b35SErik Nordmark #define	EXPER_IP_DCE			105
18345916cd2Sjpk 
18445916cd2Sjpk /*
18545916cd2Sjpk  * There can be one of each of these tables per transport (MIB2_* above).
18645916cd2Sjpk  */
18745916cd2Sjpk #define	EXPER_XPORT_MLP		105	/* transportMLPEntry */
1887c478bd9Sstevel@tonic-gate 
1897c478bd9Sstevel@tonic-gate /* Old names retained for compatibility */
1907c478bd9Sstevel@tonic-gate #define	MIB2_IP_20	MIB2_IP_ADDR
1917c478bd9Sstevel@tonic-gate #define	MIB2_IP_21	MIB2_IP_ROUTE
1927c478bd9Sstevel@tonic-gate #define	MIB2_IP_22	MIB2_IP_MEDIA
1937c478bd9Sstevel@tonic-gate 
1947c478bd9Sstevel@tonic-gate typedef struct mib2_ip {
1957c478bd9Sstevel@tonic-gate 		/* forwarder?  1 gateway, 2 NOT gateway	{ip 1} RW */
1967c478bd9Sstevel@tonic-gate 	int	ipForwarding;
1977c478bd9Sstevel@tonic-gate 		/* default Time-to-Live for iph		{ip 2} RW */
1987c478bd9Sstevel@tonic-gate 	int	ipDefaultTTL;
1997c478bd9Sstevel@tonic-gate 		/* # of input datagrams			{ip 3} */
2007c478bd9Sstevel@tonic-gate 	Counter	ipInReceives;
2017c478bd9Sstevel@tonic-gate 		/* # of dg discards for iph error	{ip 4} */
2027c478bd9Sstevel@tonic-gate 	Counter	ipInHdrErrors;
2037c478bd9Sstevel@tonic-gate 		/* # of dg discards for bad addr	{ip 5} */
2047c478bd9Sstevel@tonic-gate 	Counter	ipInAddrErrors;
2057c478bd9Sstevel@tonic-gate 		/* # of dg being forwarded		{ip 6} */
2067c478bd9Sstevel@tonic-gate 	Counter	ipForwDatagrams;
2077c478bd9Sstevel@tonic-gate 		/* # of dg discards for unk protocol	{ip 7} */
2087c478bd9Sstevel@tonic-gate 	Counter	ipInUnknownProtos;
2097c478bd9Sstevel@tonic-gate 		/* # of dg discards of good dg's	{ip 8} */
2107c478bd9Sstevel@tonic-gate 	Counter	ipInDiscards;
2117c478bd9Sstevel@tonic-gate 		/* # of dg sent upstream		{ip 9} */
2127c478bd9Sstevel@tonic-gate 	Counter ipInDelivers;
2137c478bd9Sstevel@tonic-gate 		/* # of outdgs recv'd from upstream	{ip 10} */
2147c478bd9Sstevel@tonic-gate 	Counter	ipOutRequests;
2157c478bd9Sstevel@tonic-gate 		/* # of good outdgs discarded		{ip 11} */
2167c478bd9Sstevel@tonic-gate 	Counter ipOutDiscards;
2177c478bd9Sstevel@tonic-gate 		/* # of outdg discards: no route found	{ip 12} */
2187c478bd9Sstevel@tonic-gate 	Counter	ipOutNoRoutes;
2197c478bd9Sstevel@tonic-gate 		/* sec's recv'd frags held for reass.	{ip 13}	*/
2207c478bd9Sstevel@tonic-gate 	int	ipReasmTimeout;
2217c478bd9Sstevel@tonic-gate 		/* # of ip frags needing reassembly	{ip 14} */
2227c478bd9Sstevel@tonic-gate 	Counter	ipReasmReqds;
2237c478bd9Sstevel@tonic-gate 		/* # of dg's reassembled		{ip 15} */
2247c478bd9Sstevel@tonic-gate 	Counter	ipReasmOKs;
2257c478bd9Sstevel@tonic-gate 		/* # of reassembly failures (not dg cnt){ip 16} */
2267c478bd9Sstevel@tonic-gate 	Counter	ipReasmFails;
2277c478bd9Sstevel@tonic-gate 		/* # of dg's fragged			{ip 17} */
2287c478bd9Sstevel@tonic-gate 	Counter	ipFragOKs;
2297c478bd9Sstevel@tonic-gate 		/* # of dg discards for no frag set	{ip 18} */
2307c478bd9Sstevel@tonic-gate 	Counter ipFragFails;
2317c478bd9Sstevel@tonic-gate 		/* # of dg frags from fragmentation	{ip 19} */
2327c478bd9Sstevel@tonic-gate 	Counter	ipFragCreates;
2337c478bd9Sstevel@tonic-gate 		/* {ip 20} */
2347c478bd9Sstevel@tonic-gate 	int	ipAddrEntrySize;
2357c478bd9Sstevel@tonic-gate 		/* {ip 21} */
2367c478bd9Sstevel@tonic-gate 	int	ipRouteEntrySize;
2377c478bd9Sstevel@tonic-gate 		/* {ip 22} */
2387c478bd9Sstevel@tonic-gate 	int	ipNetToMediaEntrySize;
2397c478bd9Sstevel@tonic-gate 		/* # of valid route entries discarded 	{ip 23} */
2407c478bd9Sstevel@tonic-gate 	Counter	ipRoutingDiscards;
2417c478bd9Sstevel@tonic-gate /*
2427c478bd9Sstevel@tonic-gate  * following defined in MIB-II as part of TCP & UDP groups:
2437c478bd9Sstevel@tonic-gate  */
2447c478bd9Sstevel@tonic-gate 		/* total # of segments recv'd with error	{ tcp 14 } */
2457c478bd9Sstevel@tonic-gate 	Counter	tcpInErrs;
2467c478bd9Sstevel@tonic-gate 		/* # of recv'd dg's not deliverable (no appl.)	{ udp 2 } */
2477c478bd9Sstevel@tonic-gate 	Counter	udpNoPorts;
2487c478bd9Sstevel@tonic-gate /*
2497c478bd9Sstevel@tonic-gate  * In addition to MIB-II
2507c478bd9Sstevel@tonic-gate  */
2517c478bd9Sstevel@tonic-gate 		/* # of bad IP header checksums */
2527c478bd9Sstevel@tonic-gate 	Counter	ipInCksumErrs;
2537c478bd9Sstevel@tonic-gate 		/* # of complete duplicates in reassembly */
2547c478bd9Sstevel@tonic-gate 	Counter	ipReasmDuplicates;
2557c478bd9Sstevel@tonic-gate 		/* # of partial duplicates in reassembly */
2567c478bd9Sstevel@tonic-gate 	Counter	ipReasmPartDups;
2577c478bd9Sstevel@tonic-gate 		/* # of packets not forwarded due to adminstrative reasons */
2587c478bd9Sstevel@tonic-gate 	Counter	ipForwProhibits;
2597c478bd9Sstevel@tonic-gate 		/* # of UDP packets with bad UDP checksums */
2607c478bd9Sstevel@tonic-gate 	Counter udpInCksumErrs;
2617c478bd9Sstevel@tonic-gate 		/* # of UDP packets droped due to queue overflow */
2627c478bd9Sstevel@tonic-gate 	Counter udpInOverflows;
2637c478bd9Sstevel@tonic-gate 		/*
2647c478bd9Sstevel@tonic-gate 		 * # of RAW IP packets (all IP protocols except UDP, TCP
2657c478bd9Sstevel@tonic-gate 		 * and ICMP) droped due to queue overflow
2667c478bd9Sstevel@tonic-gate 		 */
2677c478bd9Sstevel@tonic-gate 	Counter rawipInOverflows;
2687c478bd9Sstevel@tonic-gate 
2697c478bd9Sstevel@tonic-gate 	/*
2707c478bd9Sstevel@tonic-gate 	 * Folowing are private IPSEC MIB.
2717c478bd9Sstevel@tonic-gate 	 */
2727c478bd9Sstevel@tonic-gate 	/* # of incoming packets that succeeded policy checks */
2737c478bd9Sstevel@tonic-gate 	Counter ipsecInSucceeded;
2747c478bd9Sstevel@tonic-gate 	/* # of incoming packets that failed policy checks */
2757c478bd9Sstevel@tonic-gate 	Counter ipsecInFailed;
2767c478bd9Sstevel@tonic-gate /* Compatible extensions added here */
2777c478bd9Sstevel@tonic-gate 	int	ipMemberEntrySize;	/* Size of ip_member_t */
2787c478bd9Sstevel@tonic-gate 	int	ipGroupSourceEntrySize;	/* Size of ip_grpsrc_t */
2797c478bd9Sstevel@tonic-gate 
280bd670b35SErik Nordmark 	Counter ipInIPv6; /* # of IPv6 packets received by IPv4 and dropped */
281bd670b35SErik Nordmark 	Counter ipOutIPv6;		/* No longer used */
282bd670b35SErik Nordmark 	Counter ipOutSwitchIPv6;	/* No longer used */
28345916cd2Sjpk 
28445916cd2Sjpk 	int	ipRouteAttributeSize;	/* Size of mib2_ipAttributeEntry_t */
28545916cd2Sjpk 	int	transportMLPSize;	/* Size of mib2_transportMLPEntry_t */
286bd670b35SErik Nordmark 	int	ipDestEntrySize;	/* Size of dest_cache_entry_t */
2877c478bd9Sstevel@tonic-gate } mib2_ip_t;
2887c478bd9Sstevel@tonic-gate 
2897c478bd9Sstevel@tonic-gate /*
2907c478bd9Sstevel@tonic-gate  *	ipv6IfStatsEntry OBJECT-TYPE
2917c478bd9Sstevel@tonic-gate  *		SYNTAX     Ipv6IfStatsEntry
2927c478bd9Sstevel@tonic-gate  *		MAX-ACCESS not-accessible
2937c478bd9Sstevel@tonic-gate  *		STATUS     current
2947c478bd9Sstevel@tonic-gate  *		DESCRIPTION
2957c478bd9Sstevel@tonic-gate  *			"An interface statistics entry containing objects
2967c478bd9Sstevel@tonic-gate  *			at a particular IPv6 interface."
2977c478bd9Sstevel@tonic-gate  *		AUGMENTS { ipv6IfEntry }
2987c478bd9Sstevel@tonic-gate  *		::= { ipv6IfStatsTable 1 }
2997c478bd9Sstevel@tonic-gate  *
3007c478bd9Sstevel@tonic-gate  * Per-interface IPv6 statistics table
3017c478bd9Sstevel@tonic-gate  */
3027c478bd9Sstevel@tonic-gate 
3037c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6IfStatsEntry {
3047c478bd9Sstevel@tonic-gate 	/* Local ifindex to identify the interface */
3057c478bd9Sstevel@tonic-gate 	DeviceIndex	ipv6IfIndex;
3067c478bd9Sstevel@tonic-gate 
3077c478bd9Sstevel@tonic-gate 		/* forwarder?  1 gateway, 2 NOT gateway	{ipv6MIBObjects 1} RW */
3087c478bd9Sstevel@tonic-gate 	int	ipv6Forwarding;
3097c478bd9Sstevel@tonic-gate 		/* default Hoplimit for IPv6		{ipv6MIBObjects 2} RW */
3107c478bd9Sstevel@tonic-gate 	int	ipv6DefaultHopLimit;
3117c478bd9Sstevel@tonic-gate 
3127c478bd9Sstevel@tonic-gate 	int	ipv6IfStatsEntrySize;
3137c478bd9Sstevel@tonic-gate 	int	ipv6AddrEntrySize;
3147c478bd9Sstevel@tonic-gate 	int	ipv6RouteEntrySize;
3157c478bd9Sstevel@tonic-gate 	int	ipv6NetToMediaEntrySize;
3167c478bd9Sstevel@tonic-gate 	int	ipv6MemberEntrySize;		/* Size of ipv6_member_t */
3177c478bd9Sstevel@tonic-gate 	int	ipv6GroupSourceEntrySize;	/* Size of ipv6_grpsrc_t */
3187c478bd9Sstevel@tonic-gate 
3197c478bd9Sstevel@tonic-gate 	/* # input datagrams (incl errors)	{ ipv6IfStatsEntry 1 } */
3207c478bd9Sstevel@tonic-gate 	Counter	ipv6InReceives;
3217c478bd9Sstevel@tonic-gate 	/* # errors in IPv6 headers and options	{ ipv6IfStatsEntry 2 } */
3227c478bd9Sstevel@tonic-gate 	Counter	ipv6InHdrErrors;
3237c478bd9Sstevel@tonic-gate 	/* # exceeds outgoing link MTU		{ ipv6IfStatsEntry 3 } */
3247c478bd9Sstevel@tonic-gate 	Counter	ipv6InTooBigErrors;
3257c478bd9Sstevel@tonic-gate 	/* # discarded due to no route to dest 	{ ipv6IfStatsEntry 4 } */
3267c478bd9Sstevel@tonic-gate 	Counter	ipv6InNoRoutes;
3277c478bd9Sstevel@tonic-gate 	/* # invalid or unsupported addresses	{ ipv6IfStatsEntry 5 } */
3287c478bd9Sstevel@tonic-gate 	Counter	ipv6InAddrErrors;
3297c478bd9Sstevel@tonic-gate 	/* # unknown next header 		{ ipv6IfStatsEntry 6 } */
3307c478bd9Sstevel@tonic-gate 	Counter	ipv6InUnknownProtos;
3317c478bd9Sstevel@tonic-gate 	/* # too short packets			{ ipv6IfStatsEntry 7 } */
3327c478bd9Sstevel@tonic-gate 	Counter	ipv6InTruncatedPkts;
3337c478bd9Sstevel@tonic-gate 	/* # discarded e.g. due to no buffers	{ ipv6IfStatsEntry 8 } */
3347c478bd9Sstevel@tonic-gate 	Counter	ipv6InDiscards;
3357c478bd9Sstevel@tonic-gate 	/* # delivered to upper layer protocols	{ ipv6IfStatsEntry 9 } */
3367c478bd9Sstevel@tonic-gate 	Counter	ipv6InDelivers;
3377c478bd9Sstevel@tonic-gate 	/* # forwarded out interface		{ ipv6IfStatsEntry 10 } */
3387c478bd9Sstevel@tonic-gate 	Counter	ipv6OutForwDatagrams;
3397c478bd9Sstevel@tonic-gate 	/* # originated out interface		{ ipv6IfStatsEntry 11 } */
3407c478bd9Sstevel@tonic-gate 	Counter	ipv6OutRequests;
3417c478bd9Sstevel@tonic-gate 	/* # discarded e.g. due to no buffers	{ ipv6IfStatsEntry 12 } */
3427c478bd9Sstevel@tonic-gate 	Counter	ipv6OutDiscards;
3437c478bd9Sstevel@tonic-gate 	/* # sucessfully fragmented packets	{ ipv6IfStatsEntry 13 } */
3447c478bd9Sstevel@tonic-gate 	Counter	ipv6OutFragOKs;
3457c478bd9Sstevel@tonic-gate 	/* # fragmentation failed		{ ipv6IfStatsEntry 14 } */
3467c478bd9Sstevel@tonic-gate 	Counter	ipv6OutFragFails;
3477c478bd9Sstevel@tonic-gate 	/* # fragments created			{ ipv6IfStatsEntry 15 } */
3487c478bd9Sstevel@tonic-gate 	Counter	ipv6OutFragCreates;
3497c478bd9Sstevel@tonic-gate 	/* # fragments to reassemble		{ ipv6IfStatsEntry 16 } */
3507c478bd9Sstevel@tonic-gate 	Counter	ipv6ReasmReqds;
3517c478bd9Sstevel@tonic-gate 	/* # packets after reassembly		{ ipv6IfStatsEntry 17 } */
3527c478bd9Sstevel@tonic-gate 	Counter	ipv6ReasmOKs;
3537c478bd9Sstevel@tonic-gate 	/* # reassembly failed			{ ipv6IfStatsEntry 18 } */
3547c478bd9Sstevel@tonic-gate 	Counter	ipv6ReasmFails;
3557c478bd9Sstevel@tonic-gate 	/* # received multicast packets		{ ipv6IfStatsEntry 19 } */
3567c478bd9Sstevel@tonic-gate 	Counter	ipv6InMcastPkts;
3577c478bd9Sstevel@tonic-gate 	/* # transmitted multicast packets	{ ipv6IfStatsEntry 20 } */
3587c478bd9Sstevel@tonic-gate 	Counter	ipv6OutMcastPkts;
3597c478bd9Sstevel@tonic-gate /*
3607c478bd9Sstevel@tonic-gate  * In addition to defined MIBs
3617c478bd9Sstevel@tonic-gate  */
3627c478bd9Sstevel@tonic-gate 		/* # discarded due to no route to dest */
3637c478bd9Sstevel@tonic-gate 	Counter	ipv6OutNoRoutes;
3647c478bd9Sstevel@tonic-gate 		/* # of complete duplicates in reassembly */
3657c478bd9Sstevel@tonic-gate 	Counter	ipv6ReasmDuplicates;
3667c478bd9Sstevel@tonic-gate 		/* # of partial duplicates in reassembly */
3677c478bd9Sstevel@tonic-gate 	Counter	ipv6ReasmPartDups;
3687c478bd9Sstevel@tonic-gate 		/* # of packets not forwarded due to adminstrative reasons */
3697c478bd9Sstevel@tonic-gate 	Counter	ipv6ForwProhibits;
3707c478bd9Sstevel@tonic-gate 		/* # of UDP packets with bad UDP checksums */
3717c478bd9Sstevel@tonic-gate 	Counter udpInCksumErrs;
3727c478bd9Sstevel@tonic-gate 		/* # of UDP packets droped due to queue overflow */
3737c478bd9Sstevel@tonic-gate 	Counter udpInOverflows;
3747c478bd9Sstevel@tonic-gate 		/*
3757c478bd9Sstevel@tonic-gate 		 * # of RAW IPv6 packets (all IPv6 protocols except UDP, TCP
3767c478bd9Sstevel@tonic-gate 		 * and ICMPv6) droped due to queue overflow
3777c478bd9Sstevel@tonic-gate 		 */
3787c478bd9Sstevel@tonic-gate 	Counter rawipInOverflows;
3797c478bd9Sstevel@tonic-gate 
3807c478bd9Sstevel@tonic-gate 		/* # of IPv4 packets received by IPv6 and dropped */
3817c478bd9Sstevel@tonic-gate 	Counter ipv6InIPv4;
3827c478bd9Sstevel@tonic-gate 		/* # of IPv4 packets transmitted by ip_wput_wput */
3837c478bd9Sstevel@tonic-gate 	Counter ipv6OutIPv4;
3847c478bd9Sstevel@tonic-gate 		/* # of times ip_wput_v6 has switched to become ip_wput */
3857c478bd9Sstevel@tonic-gate 	Counter ipv6OutSwitchIPv4;
3867c478bd9Sstevel@tonic-gate } mib2_ipv6IfStatsEntry_t;
3877c478bd9Sstevel@tonic-gate 
3887c478bd9Sstevel@tonic-gate /*
3893173664eSapersson  * Per interface IP statistics, both v4 and v6.
3903173664eSapersson  *
3913173664eSapersson  * Some applications expect to get mib2_ipv6IfStatsEntry_t structs back when
3923173664eSapersson  * making a request. To ensure backwards compatability, the first
3933173664eSapersson  * sizeof(mib2_ipv6IfStatsEntry_t) bytes of the structure is identical to
3943173664eSapersson  * mib2_ipv6IfStatsEntry_t. This should work as long the application is
3953173664eSapersson  * written correctly (i.e., using ipv6IfStatsEntrySize to get the size of
3963173664eSapersson  * the struct)
3973173664eSapersson  *
3983173664eSapersson  * RFC4293 introduces several new counters, as well as defining 64-bit
3993173664eSapersson  * versions of existing counters. For a new counters, if they have both 32-
4003173664eSapersson  * and 64-bit versions, then we only added the latter. However, for already
4013173664eSapersson  * existing counters, we have added the 64-bit versions without removing the
4023173664eSapersson  * old (32-bit) ones. The 64- and 32-bit counters will only be synchronized
4033173664eSapersson  * when the structure contains IPv6 statistics, which is done to ensure
4043173664eSapersson  * backwards compatibility.
4053173664eSapersson  */
4063173664eSapersson 
4073173664eSapersson /* The following are defined in RFC 4001 and are used for ipIfStatsIPVersion */
4083173664eSapersson #define	MIB2_INETADDRESSTYPE_unknown	0
4093173664eSapersson #define	MIB2_INETADDRESSTYPE_ipv4	1
4103173664eSapersson #define	MIB2_INETADDRESSTYPE_ipv6	2
4113173664eSapersson 
4123173664eSapersson /*
4133173664eSapersson  * On amd64, the alignment requirements for long long's is different for
4143173664eSapersson  * 32 and 64 bits. If we have a struct containing long long's that is being
4153173664eSapersson  * passed between a 64-bit kernel to a 32-bit application, then it is very
4163173664eSapersson  * likely that the size of the struct will differ due to padding. Therefore, we
4173173664eSapersson  * pack the data to ensure that the struct size is the same for 32- and
4183173664eSapersson  * 64-bits.
4193173664eSapersson  */
4203173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
4213173664eSapersson #pragma pack(4)
4223173664eSapersson #endif
4233173664eSapersson 
4243173664eSapersson typedef struct mib2_ipIfStatsEntry {
4253173664eSapersson 
4263173664eSapersson 	/* Local ifindex to identify the interface */
4273173664eSapersson 	DeviceIndex	ipIfStatsIfIndex;
4283173664eSapersson 
4293173664eSapersson 	/* forwarder?  1 gateway, 2 NOT gateway	{ ipv6MIBObjects 1} RW */
4303173664eSapersson 	int	ipIfStatsForwarding;
4313173664eSapersson 	/* default Hoplimit for IPv6		{ ipv6MIBObjects 2} RW */
4323173664eSapersson 	int	ipIfStatsDefaultHopLimit;
4333173664eSapersson #define	ipIfStatsDefaultTTL	ipIfStatsDefaultHopLimit
4343173664eSapersson 
4353173664eSapersson 	int	ipIfStatsEntrySize;
4363173664eSapersson 	int	ipIfStatsAddrEntrySize;
4373173664eSapersson 	int	ipIfStatsRouteEntrySize;
4383173664eSapersson 	int	ipIfStatsNetToMediaEntrySize;
4393173664eSapersson 	int	ipIfStatsMemberEntrySize;
4403173664eSapersson 	int	ipIfStatsGroupSourceEntrySize;
4413173664eSapersson 
4423173664eSapersson 	/* # input datagrams (incl errors)	{ ipIfStatsEntry 3 } */
4433173664eSapersson 	Counter	ipIfStatsInReceives;
4443173664eSapersson 	/* # errors in IP headers and options	{ ipIfStatsEntry 7 } */
4453173664eSapersson 	Counter	ipIfStatsInHdrErrors;
4463173664eSapersson 	/* # exceeds outgoing link MTU(v6 only)	{ ipv6IfStatsEntry 3 } */
4473173664eSapersson 	Counter	ipIfStatsInTooBigErrors;
4483173664eSapersson 	/* # discarded due to no route to dest 	{ ipIfStatsEntry 8 } */
4493173664eSapersson 	Counter	ipIfStatsInNoRoutes;
4503173664eSapersson 	/* # invalid or unsupported addresses	{ ipIfStatsEntry 9 } */
4513173664eSapersson 	Counter	ipIfStatsInAddrErrors;
4523173664eSapersson 	/* # unknown next header 		{ ipIfStatsEntry 10 } */
4533173664eSapersson 	Counter	ipIfStatsInUnknownProtos;
4543173664eSapersson 	/* # too short packets			{ ipIfStatsEntry 11 } */
4553173664eSapersson 	Counter	ipIfStatsInTruncatedPkts;
4563173664eSapersson 	/* # discarded e.g. due to no buffers	{ ipIfStatsEntry 17 } */
4573173664eSapersson 	Counter	ipIfStatsInDiscards;
4583173664eSapersson 	/* # delivered to upper layer protocols	{ ipIfStatsEntry 18 } */
4593173664eSapersson 	Counter	ipIfStatsInDelivers;
4603173664eSapersson 	/* # forwarded out interface		{ ipIfStatsEntry 23 } */
4613173664eSapersson 	Counter	ipIfStatsOutForwDatagrams;
4623173664eSapersson 	/* # originated out interface		{ ipIfStatsEntry 20 } */
4633173664eSapersson 	Counter	ipIfStatsOutRequests;
4643173664eSapersson 	/* # discarded e.g. due to no buffers	{ ipIfStatsEntry 25 } */
4653173664eSapersson 	Counter	ipIfStatsOutDiscards;
4663173664eSapersson 	/* # sucessfully fragmented packets	{ ipIfStatsEntry 27 } */
4673173664eSapersson 	Counter	ipIfStatsOutFragOKs;
4683173664eSapersson 	/* # fragmentation failed		{ ipIfStatsEntry 28 } */
4693173664eSapersson 	Counter	ipIfStatsOutFragFails;
4703173664eSapersson 	/* # fragments created			{ ipIfStatsEntry 29 } */
4713173664eSapersson 	Counter	ipIfStatsOutFragCreates;
4723173664eSapersson 	/* # fragments to reassemble		{ ipIfStatsEntry 14 } */
4733173664eSapersson 	Counter	ipIfStatsReasmReqds;
4743173664eSapersson 	/* # packets after reassembly		{ ipIfStatsEntry 15 } */
4753173664eSapersson 	Counter	ipIfStatsReasmOKs;
4763173664eSapersson 	/* # reassembly failed			{ ipIfStatsEntry 16 } */
4773173664eSapersson 	Counter	ipIfStatsReasmFails;
4783173664eSapersson 	/* # received multicast packets		{ ipIfStatsEntry 34 } */
4793173664eSapersson 	Counter	ipIfStatsInMcastPkts;
4803173664eSapersson 	/* # transmitted multicast packets	{ ipIfStatsEntry 38 } */
4813173664eSapersson 	Counter	ipIfStatsOutMcastPkts;
4823173664eSapersson 
4833173664eSapersson 	/*
4843173664eSapersson 	 * In addition to defined MIBs
4853173664eSapersson 	 */
4863173664eSapersson 
4873173664eSapersson 	/* # discarded due to no route to dest 	{ ipSystemStatsEntry 22 } */
4883173664eSapersson 	Counter	ipIfStatsOutNoRoutes;
4893173664eSapersson 	/* # of complete duplicates in reassembly */
4903173664eSapersson 	Counter	ipIfStatsReasmDuplicates;
4913173664eSapersson 	/* # of partial duplicates in reassembly */
4923173664eSapersson 	Counter	ipIfStatsReasmPartDups;
4933173664eSapersson 	/* # of packets not forwarded due to adminstrative reasons */
4943173664eSapersson 	Counter	ipIfStatsForwProhibits;
4953173664eSapersson 	/* # of UDP packets with bad UDP checksums */
4963173664eSapersson 	Counter udpInCksumErrs;
4973173664eSapersson #define	udpIfStatsInCksumErrs	udpInCksumErrs
4983173664eSapersson 	/* # of UDP packets droped due to queue overflow */
4993173664eSapersson 	Counter udpInOverflows;
5003173664eSapersson #define	udpIfStatsInOverflows	udpInOverflows
5013173664eSapersson 	/*
5023173664eSapersson 	 * # of RAW IP packets (all IP protocols except UDP, TCP
5033173664eSapersson 	 * and ICMP) droped due to queue overflow
5043173664eSapersson 	 */
5053173664eSapersson 	Counter rawipInOverflows;
5063173664eSapersson #define	rawipIfStatsInOverflows	rawipInOverflows
5073173664eSapersson 
5083173664eSapersson 	/*
5093173664eSapersson 	 * # of IP packets received with the wrong version (i.e., not equal
5103173664eSapersson 	 * to ipIfStatsIPVersion) and that were dropped.
5113173664eSapersson 	 */
5123173664eSapersson 	Counter ipIfStatsInWrongIPVersion;
5133173664eSapersson 	/*
514bd670b35SErik Nordmark 	 * This counter is no longer used
5153173664eSapersson 	 */
5163173664eSapersson 	Counter ipIfStatsOutWrongIPVersion;
5173173664eSapersson 	/*
518bd670b35SErik Nordmark 	 * This counter is no longer used
5193173664eSapersson 	 */
5203173664eSapersson 	Counter ipIfStatsOutSwitchIPVersion;
5213173664eSapersson 
5223173664eSapersson 	/*
5233173664eSapersson 	 * Fields defined in RFC 4293
5243173664eSapersson 	 */
5253173664eSapersson 
5263173664eSapersson 	/* ip version				{ ipIfStatsEntry 1 } */
5273173664eSapersson 	int		ipIfStatsIPVersion;
5283173664eSapersson 	/* # input datagrams (incl errors)	{ ipIfStatsEntry 4 } */
5293173664eSapersson 	Counter64	ipIfStatsHCInReceives;
5303173664eSapersson 	/* # input octets (incl errors)		{ ipIfStatsEntry 6 } */
5313173664eSapersson 	Counter64	ipIfStatsHCInOctets;
5323173664eSapersson 	/*
5333173664eSapersson 	 *					{ ipIfStatsEntry 13 }
5343173664eSapersson 	 * # input datagrams for which a forwarding attempt was made
5353173664eSapersson 	 */
5363173664eSapersson 	Counter64	ipIfStatsHCInForwDatagrams;
5373173664eSapersson 	/* # delivered to upper layer protocols	{ ipIfStatsEntry 19 } */
5383173664eSapersson 	Counter64	ipIfStatsHCInDelivers;
5393173664eSapersson 	/* # originated out interface		{ ipIfStatsEntry 21 } */
5403173664eSapersson 	Counter64	ipIfStatsHCOutRequests;
5413173664eSapersson 	/* # forwarded out interface		{ ipIfStatsEntry 23 } */
5423173664eSapersson 	Counter64	ipIfStatsHCOutForwDatagrams;
5433173664eSapersson 	/* # dg's requiring fragmentation 	{ ipIfStatsEntry 26 } */
5443173664eSapersson 	Counter		ipIfStatsOutFragReqds;
5453173664eSapersson 	/* # output datagrams			{ ipIfStatsEntry 31 } */
5463173664eSapersson 	Counter64	ipIfStatsHCOutTransmits;
5473173664eSapersson 	/* # output octets			{ ipIfStatsEntry 33 } */
5483173664eSapersson 	Counter64	ipIfStatsHCOutOctets;
5493173664eSapersson 	/* # received multicast datagrams	{ ipIfStatsEntry 35 } */
5503173664eSapersson 	Counter64	ipIfStatsHCInMcastPkts;
5513173664eSapersson 	/* # received multicast octets		{ ipIfStatsEntry 37 } */
5523173664eSapersson 	Counter64	ipIfStatsHCInMcastOctets;
5533173664eSapersson 	/* # transmitted multicast datagrams	{ ipIfStatsEntry 39 } */
5543173664eSapersson 	Counter64	ipIfStatsHCOutMcastPkts;
5553173664eSapersson 	/* # transmitted multicast octets	{ ipIfStatsEntry 41 } */
5563173664eSapersson 	Counter64	ipIfStatsHCOutMcastOctets;
5573173664eSapersson 	/* # received broadcast datagrams	{ ipIfStatsEntry 43 } */
5583173664eSapersson 	Counter64	ipIfStatsHCInBcastPkts;
5593173664eSapersson 	/* # transmitted broadcast datagrams	{ ipIfStatsEntry 45 } */
5603173664eSapersson 	Counter64	ipIfStatsHCOutBcastPkts;
5613173664eSapersson 
5623173664eSapersson 	/*
5633173664eSapersson 	 * Fields defined in mib2_ip_t
5643173664eSapersson 	 */
5653173664eSapersson 
5663173664eSapersson 	/* # of incoming packets that succeeded policy checks */
5673173664eSapersson 	Counter		ipsecInSucceeded;
5683173664eSapersson #define	ipsecIfStatsInSucceeded	ipsecInSucceeded
5693173664eSapersson 	/* # of incoming packets that failed policy checks */
5703173664eSapersson 	Counter		ipsecInFailed;
5713173664eSapersson #define	ipsecIfStatsInFailed	ipsecInFailed
5723173664eSapersson 	/* # of bad IP header checksums */
5733173664eSapersson 	Counter		ipInCksumErrs;
5743173664eSapersson #define	ipIfStatsInCksumErrs	ipInCksumErrs
5753173664eSapersson 	/* total # of segments recv'd with error	{ tcp 14 } */
5763173664eSapersson 	Counter		tcpInErrs;
5773173664eSapersson #define	tcpIfStatsInErrs	tcpInErrs
5783173664eSapersson 	/* # of recv'd dg's not deliverable (no appl.)	{ udp 2 } */
5793173664eSapersson 	Counter		udpNoPorts;
5803173664eSapersson #define	udpIfStatsNoPorts	udpNoPorts
5813173664eSapersson } mib2_ipIfStatsEntry_t;
582*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_ipIfStatsEntry_t	ipIfStatsIPVersion
5833173664eSapersson 
5843173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
5853173664eSapersson #pragma pack()
5863173664eSapersson #endif
5873173664eSapersson 
5883173664eSapersson /*
5897c478bd9Sstevel@tonic-gate  * The IP address table contains this entity's IP addressing information.
5907c478bd9Sstevel@tonic-gate  *
5917c478bd9Sstevel@tonic-gate  *	ipAddrTable OBJECT-TYPE
5927c478bd9Sstevel@tonic-gate  *		SYNTAX  SEQUENCE OF IpAddrEntry
5937c478bd9Sstevel@tonic-gate  *		ACCESS  not-accessible
5947c478bd9Sstevel@tonic-gate  *		STATUS  mandatory
5957c478bd9Sstevel@tonic-gate  *		DESCRIPTION
5967c478bd9Sstevel@tonic-gate  *			"The table of addressing information relevant to
5977c478bd9Sstevel@tonic-gate  *			this entity's IP addresses."
5987c478bd9Sstevel@tonic-gate  *		::= { ip 20 }
5997c478bd9Sstevel@tonic-gate  */
6007c478bd9Sstevel@tonic-gate 
6017c478bd9Sstevel@tonic-gate typedef struct mib2_ipAddrEntry {
6027c478bd9Sstevel@tonic-gate 			/* IP address of this entry	{ipAddrEntry 1} */
6037c478bd9Sstevel@tonic-gate 	IpAddress	ipAdEntAddr;
6047c478bd9Sstevel@tonic-gate 			/* Unique interface index	{ipAddrEntry 2} */
6057c478bd9Sstevel@tonic-gate 	DeviceName	ipAdEntIfIndex;
6067c478bd9Sstevel@tonic-gate 			/* Subnet mask for this IP addr	{ipAddrEntry 3} */
6077c478bd9Sstevel@tonic-gate 	IpAddress	ipAdEntNetMask;
6087c478bd9Sstevel@tonic-gate 			/* 2^lsb of IP broadcast addr	{ipAddrEntry 4} */
6097c478bd9Sstevel@tonic-gate 	int		ipAdEntBcastAddr;
6107c478bd9Sstevel@tonic-gate 			/* max size for dg reassembly	{ipAddrEntry 5} */
6117c478bd9Sstevel@tonic-gate 	int		ipAdEntReasmMaxSize;
6127c478bd9Sstevel@tonic-gate 			/* additional ipif_t fields */
6137c478bd9Sstevel@tonic-gate 	struct ipAdEntInfo_s {
6147c478bd9Sstevel@tonic-gate 		Gauge		ae_mtu;
6157c478bd9Sstevel@tonic-gate 				/* BSD if metric */
6167c478bd9Sstevel@tonic-gate 		int		ae_metric;
6177c478bd9Sstevel@tonic-gate 				/* ipif broadcast addr.  relation to above?? */
6187c478bd9Sstevel@tonic-gate 		IpAddress	ae_broadcast_addr;
6197c478bd9Sstevel@tonic-gate 				/* point-point dest addr */
6207c478bd9Sstevel@tonic-gate 		IpAddress	ae_pp_dst_addr;
6217c478bd9Sstevel@tonic-gate 		int		ae_flags;	/* IFF_* flags in if.h */
6227c478bd9Sstevel@tonic-gate 		Counter		ae_ibcnt;	/* Inbound packets */
6237c478bd9Sstevel@tonic-gate 		Counter		ae_obcnt;	/* Outbound packets */
6247c478bd9Sstevel@tonic-gate 		Counter		ae_focnt;	/* Forwarded packets */
6257c478bd9Sstevel@tonic-gate 		IpAddress	ae_subnet;	/* Subnet prefix */
6267c478bd9Sstevel@tonic-gate 		int		ae_subnet_len;	/* Subnet prefix length */
6277c478bd9Sstevel@tonic-gate 		IpAddress	ae_src_addr;	/* Source address */
6287c478bd9Sstevel@tonic-gate 	}		ipAdEntInfo;
6293173664eSapersson 	uint32_t	ipAdEntRetransmitTime;  /* ipInterfaceRetransmitTime */
6307c478bd9Sstevel@tonic-gate } mib2_ipAddrEntry_t;
631*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_ipAddrEntry_t	ipAdEntRetransmitTime
6327c478bd9Sstevel@tonic-gate 
6337c478bd9Sstevel@tonic-gate /*
6347c478bd9Sstevel@tonic-gate  *	ipv6AddrTable OBJECT-TYPE
6357c478bd9Sstevel@tonic-gate  *		SYNTAX      SEQUENCE OF Ipv6AddrEntry
6367c478bd9Sstevel@tonic-gate  *		MAX-ACCESS  not-accessible
6377c478bd9Sstevel@tonic-gate  *		STATUS      current
6387c478bd9Sstevel@tonic-gate  *		DESCRIPTION
6397c478bd9Sstevel@tonic-gate  *			"The table of addressing information relevant to
6407c478bd9Sstevel@tonic-gate  *			this node's interface addresses."
6417c478bd9Sstevel@tonic-gate  *		::= { ipv6MIBObjects 8 }
6427c478bd9Sstevel@tonic-gate  */
6437c478bd9Sstevel@tonic-gate 
6447c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6AddrEntry {
6457c478bd9Sstevel@tonic-gate 	/* Unique interface index			{ Part of INDEX } */
6467c478bd9Sstevel@tonic-gate 	DeviceName	ipv6AddrIfIndex;
6477c478bd9Sstevel@tonic-gate 
6487c478bd9Sstevel@tonic-gate 	/* IPv6 address of this entry			{ ipv6AddrEntry 1 } */
6497c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6AddrAddress;
6507c478bd9Sstevel@tonic-gate 	/* Prefix length				{ ipv6AddrEntry 2 } */
6517c478bd9Sstevel@tonic-gate 	uint_t		ipv6AddrPfxLength;
6527c478bd9Sstevel@tonic-gate 	/* Type: stateless(1), stateful(2), unknown(3)	{ ipv6AddrEntry 3 } */
6537c478bd9Sstevel@tonic-gate 	uint_t		ipv6AddrType;
6547c478bd9Sstevel@tonic-gate 	/* Anycast: true(1), false(2)			{ ipv6AddrEntry 4 } */
6557c478bd9Sstevel@tonic-gate 	uint_t		ipv6AddrAnycastFlag;
6567c478bd9Sstevel@tonic-gate 	/*
6577c478bd9Sstevel@tonic-gate 	 * Address status: preferred(1), deprecated(2), invalid(3),
6587c478bd9Sstevel@tonic-gate 	 * inaccessible(4), unknown(5)			{ ipv6AddrEntry 5 }
6597c478bd9Sstevel@tonic-gate 	 */
6607c478bd9Sstevel@tonic-gate 	uint_t		ipv6AddrStatus;
6617c478bd9Sstevel@tonic-gate 	struct ipv6AddrInfo_s {
6627c478bd9Sstevel@tonic-gate 		Gauge		ae_mtu;
6637c478bd9Sstevel@tonic-gate 				/* BSD if metric */
6647c478bd9Sstevel@tonic-gate 		int		ae_metric;
6657c478bd9Sstevel@tonic-gate 				/* point-point dest addr */
6667c478bd9Sstevel@tonic-gate 		Ip6Address	ae_pp_dst_addr;
6677c478bd9Sstevel@tonic-gate 		int		ae_flags;	/* IFF_* flags in if.h */
6687c478bd9Sstevel@tonic-gate 		Counter		ae_ibcnt;	/* Inbound packets */
6697c478bd9Sstevel@tonic-gate 		Counter		ae_obcnt;	/* Outbound packets */
6707c478bd9Sstevel@tonic-gate 		Counter		ae_focnt;	/* Forwarded packets */
6717c478bd9Sstevel@tonic-gate 		Ip6Address	ae_subnet;	/* Subnet prefix */
6727c478bd9Sstevel@tonic-gate 		int		ae_subnet_len;	/* Subnet prefix length */
6737c478bd9Sstevel@tonic-gate 		Ip6Address	ae_src_addr;	/* Source address */
6747c478bd9Sstevel@tonic-gate 	}		ipv6AddrInfo;
6753173664eSapersson 	uint32_t	ipv6AddrReasmMaxSize;	/* InterfaceReasmMaxSize */
6763173664eSapersson 	Ip6Address	ipv6AddrIdentifier;	/* InterfaceIdentifier */
6773173664eSapersson 	uint32_t	ipv6AddrIdentifierLen;
6783173664eSapersson 	uint32_t	ipv6AddrReachableTime;	/* InterfaceReachableTime */
6793173664eSapersson 	uint32_t	ipv6AddrRetransmitTime; /* InterfaceRetransmitTime */
6807c478bd9Sstevel@tonic-gate } mib2_ipv6AddrEntry_t;
681*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_ipv6AddrEntry_t	ipv6AddrReasmMaxSize
6827c478bd9Sstevel@tonic-gate 
6837c478bd9Sstevel@tonic-gate /*
6847c478bd9Sstevel@tonic-gate  * The IP routing table contains an entry for each route presently known to
6857c478bd9Sstevel@tonic-gate  * this entity. (for IPv4 routes)
6867c478bd9Sstevel@tonic-gate  *
6877c478bd9Sstevel@tonic-gate  *	ipRouteTable OBJECT-TYPE
6887c478bd9Sstevel@tonic-gate  *		SYNTAX  SEQUENCE OF IpRouteEntry
6897c478bd9Sstevel@tonic-gate  *		ACCESS  not-accessible
6907c478bd9Sstevel@tonic-gate  *		STATUS  mandatory
6917c478bd9Sstevel@tonic-gate  *		DESCRIPTION
6927c478bd9Sstevel@tonic-gate  *			"This entity's IP Routing table."
6937c478bd9Sstevel@tonic-gate  *		::= { ip 21 }
6947c478bd9Sstevel@tonic-gate  */
6957c478bd9Sstevel@tonic-gate 
6967c478bd9Sstevel@tonic-gate typedef struct mib2_ipRouteEntry {
6977c478bd9Sstevel@tonic-gate 		/* dest ip addr for this route		{ipRouteEntry 1 } RW */
6987c478bd9Sstevel@tonic-gate 	IpAddress	ipRouteDest;
6997c478bd9Sstevel@tonic-gate 		/* unique interface index for this hop	{ipRouteEntry 2 } RW */
7007c478bd9Sstevel@tonic-gate 	DeviceName	ipRouteIfIndex;
7017c478bd9Sstevel@tonic-gate 		/* primary route metric 		{ipRouteEntry 3 } RW */
7027c478bd9Sstevel@tonic-gate 	int		ipRouteMetric1;
7037c478bd9Sstevel@tonic-gate 		/* alternate route metric 		{ipRouteEntry 4 } RW */
7047c478bd9Sstevel@tonic-gate 	int		ipRouteMetric2;
7057c478bd9Sstevel@tonic-gate 		/* alternate route metric 		{ipRouteEntry 5 } RW */
7067c478bd9Sstevel@tonic-gate 	int		ipRouteMetric3;
7077c478bd9Sstevel@tonic-gate 		/* alternate route metric 		{ipRouteEntry 6 } RW */
7087c478bd9Sstevel@tonic-gate 	int		ipRouteMetric4;
7097c478bd9Sstevel@tonic-gate 		/* ip addr of next hop on this route	{ipRouteEntry 7 } RW */
7107c478bd9Sstevel@tonic-gate 	IpAddress	ipRouteNextHop;
7117c478bd9Sstevel@tonic-gate 		/* other(1), inval(2), dir(3), indir(4)	{ipRouteEntry 8 } RW */
7127c478bd9Sstevel@tonic-gate 	int		ipRouteType;
7137c478bd9Sstevel@tonic-gate 		/* mechanism by which route was learned	{ipRouteEntry 9 } */
7147c478bd9Sstevel@tonic-gate 	int		ipRouteProto;
7157c478bd9Sstevel@tonic-gate 		/* sec's since last update of route	{ipRouteEntry 10} RW */
7167c478bd9Sstevel@tonic-gate 	int		ipRouteAge;
7177c478bd9Sstevel@tonic-gate 		/* 					{ipRouteEntry 11} RW */
7187c478bd9Sstevel@tonic-gate 	IpAddress	ipRouteMask;
7197c478bd9Sstevel@tonic-gate 		/* alternate route metric 		{ipRouteEntry 12} RW */
7207c478bd9Sstevel@tonic-gate 	int		ipRouteMetric5;
7217c478bd9Sstevel@tonic-gate 		/* additional info from ire's		{ipRouteEntry 13 } */
7227c478bd9Sstevel@tonic-gate 	struct ipRouteInfo_s {
7237c478bd9Sstevel@tonic-gate 		Gauge		re_max_frag;
7247c478bd9Sstevel@tonic-gate 		Gauge		re_rtt;
7257c478bd9Sstevel@tonic-gate 		Counter		re_ref;
7267c478bd9Sstevel@tonic-gate 		int		re_frag_flag;
7277c478bd9Sstevel@tonic-gate 		IpAddress	re_src_addr;
7287c478bd9Sstevel@tonic-gate 		int		re_ire_type;
7297c478bd9Sstevel@tonic-gate 		Counter		re_obpkt;
7307c478bd9Sstevel@tonic-gate 		Counter		re_ibpkt;
7317c478bd9Sstevel@tonic-gate 		int		re_flags;
732*6f773e29SBaban Kenkre 		/*
733*6f773e29SBaban Kenkre 		 * The following two elements (re_in_ill and re_in_src_addr)
734*6f773e29SBaban Kenkre 		 * are no longer used but are left here for the benefit of
735*6f773e29SBaban Kenkre 		 * old Apps that won't be able to handle the change in the
736*6f773e29SBaban Kenkre 		 * size of this struct. These elements will always be
737*6f773e29SBaban Kenkre 		 * set to zeroes.
738*6f773e29SBaban Kenkre 		 */
739*6f773e29SBaban Kenkre 		DeviceName	re_in_ill;	/* Input interface */
740*6f773e29SBaban Kenkre 		IpAddress	re_in_src_addr;	/* Input source address */
7417c478bd9Sstevel@tonic-gate 	} 		ipRouteInfo;
7427c478bd9Sstevel@tonic-gate } mib2_ipRouteEntry_t;
7437c478bd9Sstevel@tonic-gate 
7447c478bd9Sstevel@tonic-gate /*
7457c478bd9Sstevel@tonic-gate  * The IPv6 routing table contains an entry for each route presently known to
7467c478bd9Sstevel@tonic-gate  * this entity.
7477c478bd9Sstevel@tonic-gate  *
7487c478bd9Sstevel@tonic-gate  *	ipv6RouteTable OBJECT-TYPE
7497c478bd9Sstevel@tonic-gate  *		SYNTAX  SEQUENCE OF IpRouteEntry
7507c478bd9Sstevel@tonic-gate  *		ACCESS  not-accessible
7517c478bd9Sstevel@tonic-gate  *		STATUS  current
7527c478bd9Sstevel@tonic-gate  *		DESCRIPTION
7537c478bd9Sstevel@tonic-gate  *			"IPv6 Routing table. This table contains
7547c478bd9Sstevel@tonic-gate  *			an entry for each valid IPv6 unicast route
7557c478bd9Sstevel@tonic-gate  *			that can be used for packet forwarding
7567c478bd9Sstevel@tonic-gate  *			determination."
7577c478bd9Sstevel@tonic-gate  *		::= { ipv6MIBObjects 11 }
7587c478bd9Sstevel@tonic-gate  */
7597c478bd9Sstevel@tonic-gate 
7607c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6RouteEntry {
7617c478bd9Sstevel@tonic-gate 		/* dest ip addr for this route		{ ipv6RouteEntry 1 } */
7627c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6RouteDest;
7637c478bd9Sstevel@tonic-gate 		/* prefix length 			{ ipv6RouteEntry 2 } */
7647c478bd9Sstevel@tonic-gate 	int		ipv6RoutePfxLength;
7657c478bd9Sstevel@tonic-gate 		/* unique route index 			{ ipv6RouteEntry 3 } */
7667c478bd9Sstevel@tonic-gate 	unsigned	ipv6RouteIndex;
7677c478bd9Sstevel@tonic-gate 		/* unique interface index for this hop	{ ipv6RouteEntry 4 } */
7687c478bd9Sstevel@tonic-gate 	DeviceName	ipv6RouteIfIndex;
7697c478bd9Sstevel@tonic-gate 		/* IPv6 addr of next hop on this route	{ ipv6RouteEntry 5 } */
7707c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6RouteNextHop;
7717c478bd9Sstevel@tonic-gate 		/* other(1), discard(2), local(3), remote(4) */
7727c478bd9Sstevel@tonic-gate 		/* 					{ ipv6RouteEntry 6 } */
7737c478bd9Sstevel@tonic-gate 	int		ipv6RouteType;
7747c478bd9Sstevel@tonic-gate 		/* mechanism by which route was learned	{ ipv6RouteEntry 7 } */
7757c478bd9Sstevel@tonic-gate 		/*
7767c478bd9Sstevel@tonic-gate 		 * other(1), local(2), netmgmt(3), ndisc(4), rip(5), ospf(6),
7777c478bd9Sstevel@tonic-gate 		 * bgp(7), idrp(8), igrp(9)
7787c478bd9Sstevel@tonic-gate 		 */
7797c478bd9Sstevel@tonic-gate 	int		ipv6RouteProtocol;
7807c478bd9Sstevel@tonic-gate 		/* policy hook or traffic class		{ ipv6RouteEntry 8 } */
7817c478bd9Sstevel@tonic-gate 	unsigned	ipv6RoutePolicy;
7827c478bd9Sstevel@tonic-gate 		/* sec's since last update of route	{ ipv6RouteEntry 9} */
7837c478bd9Sstevel@tonic-gate 	int		ipv6RouteAge;
7847c478bd9Sstevel@tonic-gate 		/* Routing domain ID of the next hop	{ ipv6RouteEntry 10 } */
7857c478bd9Sstevel@tonic-gate 	unsigned	ipv6RouteNextHopRDI;
7867c478bd9Sstevel@tonic-gate 		/* route metric				{ ipv6RouteEntry 11 } */
7877c478bd9Sstevel@tonic-gate 	unsigned	ipv6RouteMetric;
7887c478bd9Sstevel@tonic-gate 		/* preference (impl specific)		{ ipv6RouteEntry 12 } */
7897c478bd9Sstevel@tonic-gate 	unsigned	ipv6RouteWeight;
7907c478bd9Sstevel@tonic-gate 		/* additional info from ire's		{ } */
7917c478bd9Sstevel@tonic-gate 	struct ipv6RouteInfo_s {
7927c478bd9Sstevel@tonic-gate 		Gauge		re_max_frag;
7937c478bd9Sstevel@tonic-gate 		Gauge		re_rtt;
7947c478bd9Sstevel@tonic-gate 		Counter		re_ref;
7957c478bd9Sstevel@tonic-gate 		int		re_frag_flag;
7967c478bd9Sstevel@tonic-gate 		Ip6Address	re_src_addr;
7977c478bd9Sstevel@tonic-gate 		int		re_ire_type;
7987c478bd9Sstevel@tonic-gate 		Counter		re_obpkt;
7997c478bd9Sstevel@tonic-gate 		Counter		re_ibpkt;
8007c478bd9Sstevel@tonic-gate 		int		re_flags;
8017c478bd9Sstevel@tonic-gate 	} 		ipv6RouteInfo;
8027c478bd9Sstevel@tonic-gate } mib2_ipv6RouteEntry_t;
8037c478bd9Sstevel@tonic-gate 
80445916cd2Sjpk /*
80545916cd2Sjpk  * The IPv4 and IPv6 routing table entries on a trusted system also have
80645916cd2Sjpk  * security attributes in the form of label ranges.  This experimental
80745916cd2Sjpk  * interface provides information about these labels.
80845916cd2Sjpk  *
80945916cd2Sjpk  * Each entry in this table contains a label range and an index that refers
81045916cd2Sjpk  * back to the entry in the routing table to which it applies.  There may be 0,
81145916cd2Sjpk  * 1, or many label ranges for each routing table entry.
81245916cd2Sjpk  *
81345916cd2Sjpk  * (opthdr.level is set to MIB2_IP for IPv4 entries and MIB2_IP6 for IPv6.
81445916cd2Sjpk  * opthdr.name is set to EXPER_IP_GWATTR.)
81545916cd2Sjpk  *
81645916cd2Sjpk  *	ipRouteAttributeTable OBJECT-TYPE
81745916cd2Sjpk  *		SYNTAX  SEQUENCE OF IpAttributeEntry
81845916cd2Sjpk  *		ACCESS  not-accessible
81945916cd2Sjpk  *		STATUS  current
82045916cd2Sjpk  *		DESCRIPTION
82145916cd2Sjpk  *			"IPv4 routing attributes table.  This table contains
82245916cd2Sjpk  *			an entry for each valid trusted label attached to a
82345916cd2Sjpk  *			route in the system."
82445916cd2Sjpk  *		::= { ip 102 }
82545916cd2Sjpk  *
82645916cd2Sjpk  *	ipv6RouteAttributeTable OBJECT-TYPE
82745916cd2Sjpk  *		SYNTAX  SEQUENCE OF IpAttributeEntry
82845916cd2Sjpk  *		ACCESS  not-accessible
82945916cd2Sjpk  *		STATUS  current
83045916cd2Sjpk  *		DESCRIPTION
83145916cd2Sjpk  *			"IPv6 routing attributes table.  This table contains
83245916cd2Sjpk  *			an entry for each valid trusted label attached to a
83345916cd2Sjpk  *			route in the system."
83445916cd2Sjpk  *		::= { ip6 102 }
83545916cd2Sjpk  */
83645916cd2Sjpk 
83745916cd2Sjpk typedef struct mib2_ipAttributeEntry {
83845916cd2Sjpk 	uint_t		iae_routeidx;
83945916cd2Sjpk 	int		iae_doi;
84045916cd2Sjpk 	brange_t	iae_slrange;
84145916cd2Sjpk } mib2_ipAttributeEntry_t;
8427c478bd9Sstevel@tonic-gate 
8437c478bd9Sstevel@tonic-gate /*
8447c478bd9Sstevel@tonic-gate  * The IP address translation table contain the IpAddress to
8457c478bd9Sstevel@tonic-gate  * `physical' address equivalences.  Some interfaces do not
8467c478bd9Sstevel@tonic-gate  * use translation tables for determining address
8477c478bd9Sstevel@tonic-gate  * equivalences (e.g., DDN-X.25 has an algorithmic method);
8487c478bd9Sstevel@tonic-gate  * if all interfaces are of this type, then the Address
8497c478bd9Sstevel@tonic-gate  * Translation table is empty, i.e., has zero entries.
8507c478bd9Sstevel@tonic-gate  *
8517c478bd9Sstevel@tonic-gate  *	ipNetToMediaTable OBJECT-TYPE
8527c478bd9Sstevel@tonic-gate  *		SYNTAX  SEQUENCE OF IpNetToMediaEntry
8537c478bd9Sstevel@tonic-gate  *		ACCESS  not-accessible
8547c478bd9Sstevel@tonic-gate  *		STATUS  mandatory
8557c478bd9Sstevel@tonic-gate  *		DESCRIPTION
8567c478bd9Sstevel@tonic-gate  *			"The IP Address Translation table used for mapping
8577c478bd9Sstevel@tonic-gate  *			from IP addresses to physical addresses."
8587c478bd9Sstevel@tonic-gate  *		::= { ip 22 }
8597c478bd9Sstevel@tonic-gate  */
8607c478bd9Sstevel@tonic-gate 
8617c478bd9Sstevel@tonic-gate typedef struct mib2_ipNetToMediaEntry {
8627c478bd9Sstevel@tonic-gate 	/* Unique interface index		{ ipNetToMediaEntry 1 } RW */
8637c478bd9Sstevel@tonic-gate 	DeviceName	ipNetToMediaIfIndex;
8647c478bd9Sstevel@tonic-gate 	/* Media dependent physical addr	{ ipNetToMediaEntry 2 } RW */
8657c478bd9Sstevel@tonic-gate 	PhysAddress	ipNetToMediaPhysAddress;
8667c478bd9Sstevel@tonic-gate 	/* ip addr for this physical addr	{ ipNetToMediaEntry 3 } RW */
8677c478bd9Sstevel@tonic-gate 	IpAddress	ipNetToMediaNetAddress;
8687c478bd9Sstevel@tonic-gate 	/* other(1), inval(2), dyn(3), stat(4)	{ ipNetToMediaEntry 4 } RW */
8697c478bd9Sstevel@tonic-gate 	int		ipNetToMediaType;
8707c478bd9Sstevel@tonic-gate 	struct ipNetToMediaInfo_s {
8717c478bd9Sstevel@tonic-gate 		PhysAddress	ntm_mask;	/* subnet mask for entry */
8727c478bd9Sstevel@tonic-gate 		int		ntm_flags;	/* ACE_F_* flags in arp.h */
8737c478bd9Sstevel@tonic-gate 	}		ipNetToMediaInfo;
8747c478bd9Sstevel@tonic-gate } mib2_ipNetToMediaEntry_t;
8757c478bd9Sstevel@tonic-gate 
8767c478bd9Sstevel@tonic-gate /*
8777c478bd9Sstevel@tonic-gate  *	ipv6NetToMediaTable OBJECT-TYPE
8787c478bd9Sstevel@tonic-gate  *		 SYNTAX      SEQUENCE OF Ipv6NetToMediaEntry
8797c478bd9Sstevel@tonic-gate  *		 MAX-ACCESS  not-accessible
8807c478bd9Sstevel@tonic-gate  *		 STATUS      current
8817c478bd9Sstevel@tonic-gate  *		 DESCRIPTION
8827c478bd9Sstevel@tonic-gate  *			"The IPv6 Address Translation table used for
8837c478bd9Sstevel@tonic-gate  *			mapping from IPv6 addresses to physical addresses.
8847c478bd9Sstevel@tonic-gate  *
8857c478bd9Sstevel@tonic-gate  *			The IPv6 address translation table contain the
8867c478bd9Sstevel@tonic-gate  *			Ipv6Address to `physical' address equivalencies.
8877c478bd9Sstevel@tonic-gate  *			Some interfaces do not use translation tables
8887c478bd9Sstevel@tonic-gate  *			for determining address equivalencies; if all
8897c478bd9Sstevel@tonic-gate  *			interfaces are of this type, then the Address
8907c478bd9Sstevel@tonic-gate  *			Translation table is empty, i.e., has zero
8917c478bd9Sstevel@tonic-gate  *			entries."
8927c478bd9Sstevel@tonic-gate  *		::= { ipv6MIBObjects 12 }
8937c478bd9Sstevel@tonic-gate  */
8947c478bd9Sstevel@tonic-gate 
8957c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6NetToMediaEntry {
8967c478bd9Sstevel@tonic-gate 	/* Unique interface index		{ Part of INDEX } */
8977c478bd9Sstevel@tonic-gate 	DeviceIndex	ipv6NetToMediaIfIndex;
8987c478bd9Sstevel@tonic-gate 
8997c478bd9Sstevel@tonic-gate 	/* ip addr for this physical addr	{ ipv6NetToMediaEntry 1 } */
9007c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6NetToMediaNetAddress;
9017c478bd9Sstevel@tonic-gate 	/* Media dependent physical addr	{ ipv6NetToMediaEntry 2 } */
9027c478bd9Sstevel@tonic-gate 	PhysAddress	ipv6NetToMediaPhysAddress;
9037c478bd9Sstevel@tonic-gate 	/*
9047c478bd9Sstevel@tonic-gate 	 * Type of mapping
9057c478bd9Sstevel@tonic-gate 	 * other(1), dynamic(2), static(3), local(4)
9067c478bd9Sstevel@tonic-gate 	 *					{ ipv6NetToMediaEntry 3 }
9077c478bd9Sstevel@tonic-gate 	 */
9087c478bd9Sstevel@tonic-gate 	int		ipv6NetToMediaType;
9097c478bd9Sstevel@tonic-gate 	/*
9107c478bd9Sstevel@tonic-gate 	 * NUD state
9117c478bd9Sstevel@tonic-gate 	 * reachable(1), stale(2), delay(3), probe(4), invalid(5), unknown(6)
9127c478bd9Sstevel@tonic-gate 	 * Note: The kernel returns ND_* states.
9137c478bd9Sstevel@tonic-gate 	 *					{ ipv6NetToMediaEntry 4 }
9147c478bd9Sstevel@tonic-gate 	 */
9157c478bd9Sstevel@tonic-gate 	int		ipv6NetToMediaState;
9167c478bd9Sstevel@tonic-gate 	/* sysUpTime last time entry was updated { ipv6NetToMediaEntry 5 } */
9177c478bd9Sstevel@tonic-gate 	int		ipv6NetToMediaLastUpdated;
9187c478bd9Sstevel@tonic-gate } mib2_ipv6NetToMediaEntry_t;
9197c478bd9Sstevel@tonic-gate 
9207c478bd9Sstevel@tonic-gate 
9217c478bd9Sstevel@tonic-gate /*
9227c478bd9Sstevel@tonic-gate  * List of group members per interface
9237c478bd9Sstevel@tonic-gate  */
9247c478bd9Sstevel@tonic-gate typedef struct ip_member {
9257c478bd9Sstevel@tonic-gate 	/* Interface index */
9267c478bd9Sstevel@tonic-gate 	DeviceName	ipGroupMemberIfIndex;
9277c478bd9Sstevel@tonic-gate 	/* IP Multicast address */
9287c478bd9Sstevel@tonic-gate 	IpAddress	ipGroupMemberAddress;
9297c478bd9Sstevel@tonic-gate 	/* Number of member sockets */
9307c478bd9Sstevel@tonic-gate 	Counter		ipGroupMemberRefCnt;
9317c478bd9Sstevel@tonic-gate 	/* Filter mode: 1 => include, 2 => exclude */
9327c478bd9Sstevel@tonic-gate 	int		ipGroupMemberFilterMode;
9337c478bd9Sstevel@tonic-gate } ip_member_t;
9347c478bd9Sstevel@tonic-gate 
9357c478bd9Sstevel@tonic-gate 
9367c478bd9Sstevel@tonic-gate /*
9377c478bd9Sstevel@tonic-gate  * List of IPv6 group members per interface
9387c478bd9Sstevel@tonic-gate  */
9397c478bd9Sstevel@tonic-gate typedef struct ipv6_member {
9407c478bd9Sstevel@tonic-gate 	/* Interface index */
9417c478bd9Sstevel@tonic-gate 	DeviceIndex	ipv6GroupMemberIfIndex;
9427c478bd9Sstevel@tonic-gate 	/* IP Multicast address */
9437c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6GroupMemberAddress;
9447c478bd9Sstevel@tonic-gate 	/* Number of member sockets */
9457c478bd9Sstevel@tonic-gate 	Counter		ipv6GroupMemberRefCnt;
9467c478bd9Sstevel@tonic-gate 	/* Filter mode: 1 => include, 2 => exclude */
9477c478bd9Sstevel@tonic-gate 	int		ipv6GroupMemberFilterMode;
9487c478bd9Sstevel@tonic-gate } ipv6_member_t;
9497c478bd9Sstevel@tonic-gate 
95045916cd2Sjpk /*
95145916cd2Sjpk  * This is used to mark transport layer entities (e.g., TCP connections) that
95245916cd2Sjpk  * are capable of receiving packets from a range of labels.  'level' is set to
95345916cd2Sjpk  * the protocol of interest (e.g., MIB2_TCP), and 'name' is set to
95445916cd2Sjpk  * EXPER_XPORT_MLP.  The tme_connidx refers back to the entry in MIB2_TCP_CONN,
95545916cd2Sjpk  * MIB2_TCP6_CONN, or MIB2_SCTP_CONN.
95645916cd2Sjpk  *
95745916cd2Sjpk  * It is also used to report connections that receive packets at a single label
95845916cd2Sjpk  * that's other than the zone's label.  This is the case when a TCP connection
95945916cd2Sjpk  * is accepted from a particular peer using an MLP listener.
96045916cd2Sjpk  */
96145916cd2Sjpk typedef struct mib2_transportMLPEntry {
96245916cd2Sjpk 	uint_t		tme_connidx;
96345916cd2Sjpk 	uint_t		tme_flags;
96445916cd2Sjpk 	int		tme_doi;
96545916cd2Sjpk 	bslabel_t	tme_label;
96645916cd2Sjpk } mib2_transportMLPEntry_t;
96745916cd2Sjpk 
96845916cd2Sjpk #define	MIB2_TMEF_PRIVATE	0x00000001	/* MLP on private addresses */
96945916cd2Sjpk #define	MIB2_TMEF_SHARED	0x00000002	/* MLP on shared addresses */
9705f9878b0Sken Powell - Sun Microsystem #define	MIB2_TMEF_ANONMLP	0x00000004	/* Anonymous MLP port */
9715f9878b0Sken Powell - Sun Microsystem #define	MIB2_TMEF_MACEXEMPT	0x00000008	/* MAC-Exempt port */
9725f9878b0Sken Powell - Sun Microsystem #define	MIB2_TMEF_IS_LABELED	0x00000010	/* tme_doi & tme_label exists */
9735d3b8cb7SBill Sommerfeld #define	MIB2_TMEF_MACIMPLICIT	0x00000020	/* MAC-Implicit */
9747c478bd9Sstevel@tonic-gate /*
9757c478bd9Sstevel@tonic-gate  * List of IPv4 source addresses being filtered per interface
9767c478bd9Sstevel@tonic-gate  */
9777c478bd9Sstevel@tonic-gate typedef struct ip_grpsrc {
9787c478bd9Sstevel@tonic-gate 	/* Interface index */
9797c478bd9Sstevel@tonic-gate 	DeviceName	ipGroupSourceIfIndex;
9807c478bd9Sstevel@tonic-gate 	/* IP Multicast address */
9817c478bd9Sstevel@tonic-gate 	IpAddress	ipGroupSourceGroup;
9827c478bd9Sstevel@tonic-gate 	/* IP Source address */
9837c478bd9Sstevel@tonic-gate 	IpAddress	ipGroupSourceAddress;
9847c478bd9Sstevel@tonic-gate } ip_grpsrc_t;
9857c478bd9Sstevel@tonic-gate 
9867c478bd9Sstevel@tonic-gate 
9877c478bd9Sstevel@tonic-gate /*
9887c478bd9Sstevel@tonic-gate  * List of IPv6 source addresses being filtered per interface
9897c478bd9Sstevel@tonic-gate  */
9907c478bd9Sstevel@tonic-gate typedef struct ipv6_grpsrc {
9917c478bd9Sstevel@tonic-gate 	/* Interface index */
9927c478bd9Sstevel@tonic-gate 	DeviceIndex	ipv6GroupSourceIfIndex;
9937c478bd9Sstevel@tonic-gate 	/* IP Multicast address */
9947c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6GroupSourceGroup;
9957c478bd9Sstevel@tonic-gate 	/* IP Source address */
9967c478bd9Sstevel@tonic-gate 	Ip6Address	ipv6GroupSourceAddress;
9977c478bd9Sstevel@tonic-gate } ipv6_grpsrc_t;
9987c478bd9Sstevel@tonic-gate 
9997c478bd9Sstevel@tonic-gate 
10007c478bd9Sstevel@tonic-gate /*
1001bd670b35SErik Nordmark  * List of destination cache entries
1002bd670b35SErik Nordmark  */
1003bd670b35SErik Nordmark typedef struct dest_cache_entry {
1004bd670b35SErik Nordmark 	/* IP Multicast address */
1005bd670b35SErik Nordmark 	IpAddress	DestIpv4Address;
1006bd670b35SErik Nordmark 	Ip6Address	DestIpv6Address;
1007bd670b35SErik Nordmark 	uint_t		DestFlags;	/* DCEF_* */
1008bd670b35SErik Nordmark 	uint32_t	DestPmtu;	/* Path MTU if DCEF_PMTU */
1009bd670b35SErik Nordmark 	uint32_t	DestIdent;	/* Per destination IP ident. */
1010bd670b35SErik Nordmark 	DeviceIndex	DestIfindex;	/* For IPv6 link-locals */
1011bd670b35SErik Nordmark 	uint32_t	DestAge;	/* Age of MTU info in seconds */
1012bd670b35SErik Nordmark } dest_cache_entry_t;
1013bd670b35SErik Nordmark 
1014bd670b35SErik Nordmark 
1015bd670b35SErik Nordmark /*
10167c478bd9Sstevel@tonic-gate  * ICMP Group
10177c478bd9Sstevel@tonic-gate  */
10187c478bd9Sstevel@tonic-gate typedef struct mib2_icmp {
10197c478bd9Sstevel@tonic-gate 	/* total # of recv'd ICMP msgs			{ icmp 1 } */
10207c478bd9Sstevel@tonic-gate 	Counter	icmpInMsgs;
10217c478bd9Sstevel@tonic-gate 	/* recv'd ICMP msgs with errors			{ icmp 2 } */
10227c478bd9Sstevel@tonic-gate 	Counter	icmpInErrors;
10237c478bd9Sstevel@tonic-gate 	/* recv'd "dest unreachable" msg's		{ icmp 3 } */
10247c478bd9Sstevel@tonic-gate 	Counter	icmpInDestUnreachs;
10257c478bd9Sstevel@tonic-gate 	/* recv'd "time exceeded" msg's			{ icmp 4 } */
10267c478bd9Sstevel@tonic-gate 	Counter	icmpInTimeExcds;
10277c478bd9Sstevel@tonic-gate 	/* recv'd "parameter problem" msg's		{ icmp 5 } */
10287c478bd9Sstevel@tonic-gate 	Counter	icmpInParmProbs;
10297c478bd9Sstevel@tonic-gate 	/* recv'd "source quench" msg's			{ icmp 6 } */
10307c478bd9Sstevel@tonic-gate 	Counter	icmpInSrcQuenchs;
10317c478bd9Sstevel@tonic-gate 	/* recv'd "ICMP redirect" msg's			{ icmp 7 } */
10327c478bd9Sstevel@tonic-gate 	Counter	icmpInRedirects;
10337c478bd9Sstevel@tonic-gate 	/* recv'd "echo request" msg's			{ icmp 8 } */
10347c478bd9Sstevel@tonic-gate 	Counter	icmpInEchos;
10357c478bd9Sstevel@tonic-gate 	/* recv'd "echo reply" msg's			{ icmp 9 } */
10367c478bd9Sstevel@tonic-gate 	Counter	icmpInEchoReps;
10377c478bd9Sstevel@tonic-gate 	/* recv'd "timestamp" msg's			{ icmp 10 } */
10387c478bd9Sstevel@tonic-gate 	Counter	icmpInTimestamps;
10397c478bd9Sstevel@tonic-gate 	/* recv'd "timestamp reply" msg's		{ icmp 11 } */
10407c478bd9Sstevel@tonic-gate 	Counter	icmpInTimestampReps;
10417c478bd9Sstevel@tonic-gate 	/* recv'd "address mask request" msg's		{ icmp 12 } */
10427c478bd9Sstevel@tonic-gate 	Counter	icmpInAddrMasks;
10437c478bd9Sstevel@tonic-gate 	/* recv'd "address mask reply" msg's		{ icmp 13 } */
10447c478bd9Sstevel@tonic-gate 	Counter	icmpInAddrMaskReps;
10457c478bd9Sstevel@tonic-gate 	/* total # of sent ICMP msg's			{ icmp 14 } */
10467c478bd9Sstevel@tonic-gate 	Counter	icmpOutMsgs;
10477c478bd9Sstevel@tonic-gate 	/* # of msg's not sent for internal icmp errors	{ icmp 15 } */
10487c478bd9Sstevel@tonic-gate 	Counter	icmpOutErrors;
10497c478bd9Sstevel@tonic-gate 	/* # of "dest unreachable" msg's sent		{ icmp 16 } */
10507c478bd9Sstevel@tonic-gate 	Counter	icmpOutDestUnreachs;
10517c478bd9Sstevel@tonic-gate 	/* # of "time exceeded" msg's sent		{ icmp 17 } */
10527c478bd9Sstevel@tonic-gate 	Counter	icmpOutTimeExcds;
10537c478bd9Sstevel@tonic-gate 	/* # of "parameter problme" msg's sent		{ icmp 18 } */
10547c478bd9Sstevel@tonic-gate 	Counter	icmpOutParmProbs;
10557c478bd9Sstevel@tonic-gate 	/* # of "source quench" msg's sent		{ icmp 19 } */
10567c478bd9Sstevel@tonic-gate 	Counter	icmpOutSrcQuenchs;
10577c478bd9Sstevel@tonic-gate 	/* # of "ICMP redirect" msg's sent		{ icmp 20 } */
10587c478bd9Sstevel@tonic-gate 	Counter	icmpOutRedirects;
10597c478bd9Sstevel@tonic-gate 	/* # of "Echo request" msg's sent		{ icmp 21 } */
10607c478bd9Sstevel@tonic-gate 	Counter	icmpOutEchos;
10617c478bd9Sstevel@tonic-gate 	/* # of "Echo reply" msg's sent			{ icmp 22 } */
10627c478bd9Sstevel@tonic-gate 	Counter	icmpOutEchoReps;
10637c478bd9Sstevel@tonic-gate 	/* # of "timestamp request" msg's sent		{ icmp 23 } */
10647c478bd9Sstevel@tonic-gate 	Counter	icmpOutTimestamps;
10657c478bd9Sstevel@tonic-gate 	/* # of "timestamp reply" msg's sent		{ icmp 24 } */
10667c478bd9Sstevel@tonic-gate 	Counter	icmpOutTimestampReps;
10677c478bd9Sstevel@tonic-gate 	/* # of "address mask request" msg's sent	{ icmp 25 } */
10687c478bd9Sstevel@tonic-gate 	Counter	icmpOutAddrMasks;
10697c478bd9Sstevel@tonic-gate 	/* # of "address mask reply" msg's sent		{ icmp 26 } */
10707c478bd9Sstevel@tonic-gate 	Counter	icmpOutAddrMaskReps;
10717c478bd9Sstevel@tonic-gate /*
10727c478bd9Sstevel@tonic-gate  * In addition to MIB-II
10737c478bd9Sstevel@tonic-gate  */
10747c478bd9Sstevel@tonic-gate 	/* # of received packets with checksum errors */
10757c478bd9Sstevel@tonic-gate 	Counter	icmpInCksumErrs;
10767c478bd9Sstevel@tonic-gate 	/* # of received packets with unknow codes */
10777c478bd9Sstevel@tonic-gate 	Counter	icmpInUnknowns;
10787c478bd9Sstevel@tonic-gate 	/* # of received unreachables with "fragmentation needed" */
10797c478bd9Sstevel@tonic-gate 	Counter	icmpInFragNeeded;
10807c478bd9Sstevel@tonic-gate 	/* # of sent unreachables with "fragmentation needed" */
10817c478bd9Sstevel@tonic-gate 	Counter	icmpOutFragNeeded;
10827c478bd9Sstevel@tonic-gate 	/*
10837c478bd9Sstevel@tonic-gate 	 * # of msg's not sent since original packet was broadcast/multicast
10847c478bd9Sstevel@tonic-gate 	 * or an ICMP error packet
10857c478bd9Sstevel@tonic-gate 	 */
10867c478bd9Sstevel@tonic-gate 	Counter	icmpOutDrops;
10877c478bd9Sstevel@tonic-gate 	/* # of ICMP packets droped due to queue overflow */
10887c478bd9Sstevel@tonic-gate 	Counter icmpInOverflows;
10897c478bd9Sstevel@tonic-gate 	/* recv'd "ICMP redirect" msg's	that are bad thus ignored */
10907c478bd9Sstevel@tonic-gate 	Counter	icmpInBadRedirects;
10917c478bd9Sstevel@tonic-gate } mib2_icmp_t;
10927c478bd9Sstevel@tonic-gate 
10937c478bd9Sstevel@tonic-gate 
10947c478bd9Sstevel@tonic-gate /*
10957c478bd9Sstevel@tonic-gate  *	ipv6IfIcmpEntry OBJECT-TYPE
10967c478bd9Sstevel@tonic-gate  *		SYNTAX      Ipv6IfIcmpEntry
10977c478bd9Sstevel@tonic-gate  *		MAX-ACCESS  not-accessible
10987c478bd9Sstevel@tonic-gate  *		STATUS      current
10997c478bd9Sstevel@tonic-gate  *		DESCRIPTION
11007c478bd9Sstevel@tonic-gate  *			"An ICMPv6 statistics entry containing
11017c478bd9Sstevel@tonic-gate  *			objects at a particular IPv6 interface.
11027c478bd9Sstevel@tonic-gate  *
11037c478bd9Sstevel@tonic-gate  *			Note that a receiving interface is
11047c478bd9Sstevel@tonic-gate  *			the interface to which a given ICMPv6 message
11057c478bd9Sstevel@tonic-gate  *			is addressed which may not be necessarily
11067c478bd9Sstevel@tonic-gate  *			the input interface for the message.
11077c478bd9Sstevel@tonic-gate  *
11087c478bd9Sstevel@tonic-gate  *			Similarly, the sending interface is
11097c478bd9Sstevel@tonic-gate  *			the interface that sources a given
11107c478bd9Sstevel@tonic-gate  *			ICMP message which is usually but not
11117c478bd9Sstevel@tonic-gate  *			necessarily the output interface for the message."
11127c478bd9Sstevel@tonic-gate  *		AUGMENTS { ipv6IfEntry }
11137c478bd9Sstevel@tonic-gate  *		::= { ipv6IfIcmpTable 1 }
11147c478bd9Sstevel@tonic-gate  *
11157c478bd9Sstevel@tonic-gate  * Per-interface ICMPv6 statistics table
11167c478bd9Sstevel@tonic-gate  */
11177c478bd9Sstevel@tonic-gate 
11187c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6IfIcmpEntry {
11197c478bd9Sstevel@tonic-gate 	/* Local ifindex to identify the interface */
11207c478bd9Sstevel@tonic-gate 	DeviceIndex	ipv6IfIcmpIfIndex;
11217c478bd9Sstevel@tonic-gate 
11227c478bd9Sstevel@tonic-gate 	int		ipv6IfIcmpEntrySize;	/* Size of ipv6IfIcmpEntry */
11237c478bd9Sstevel@tonic-gate 
11247c478bd9Sstevel@tonic-gate 	/* The total # ICMP msgs rcvd includes ipv6IfIcmpInErrors */
11257c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInMsgs;
11267c478bd9Sstevel@tonic-gate 	/* # ICMP with ICMP-specific errors (bad checkum, length, etc) */
11277c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInErrors;
11287c478bd9Sstevel@tonic-gate 	/* # ICMP Destination Unreachable */
11297c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInDestUnreachs;
11307c478bd9Sstevel@tonic-gate 	/* # ICMP destination unreachable/communication admin prohibited */
11317c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInAdminProhibs;
11327c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInTimeExcds;
11337c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInParmProblems;
11347c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInPktTooBigs;
11357c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInEchos;
11367c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInEchoReplies;
11377c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInRouterSolicits;
11387c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInRouterAdvertisements;
11397c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInNeighborSolicits;
11407c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInNeighborAdvertisements;
11417c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInRedirects;
11427c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembQueries;
11437c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembResponses;
11447c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembReductions;
11457c478bd9Sstevel@tonic-gate 	/* Total # ICMP messages attempted to send (includes OutErrors) */
11467c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutMsgs;
11477c478bd9Sstevel@tonic-gate 	/* # ICMP messages not sent due to ICMP problems (e.g. no buffers) */
11487c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutErrors;
11497c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutDestUnreachs;
11507c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutAdminProhibs;
11517c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutTimeExcds;
11527c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutParmProblems;
11537c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutPktTooBigs;
11547c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutEchos;
11557c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutEchoReplies;
11567c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutRouterSolicits;
11577c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutRouterAdvertisements;
11587c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutNeighborSolicits;
11597c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutNeighborAdvertisements;
11607c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutRedirects;
11617c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutGroupMembQueries;
11627c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutGroupMembResponses;
11637c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpOutGroupMembReductions;
11647c478bd9Sstevel@tonic-gate /* Additions beyond the MIB */
11657c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInOverflows;
11667c478bd9Sstevel@tonic-gate 	/* recv'd "ICMPv6 redirect" msg's that are bad thus ignored */
11677c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpBadHoplimit;
11687c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInBadNeighborAdvertisements;
11697c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInBadNeighborSolicitations;
11707c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInBadRedirects;
11717c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembTotal;
11727c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembBadQueries;
11737c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembBadReports;
11747c478bd9Sstevel@tonic-gate 	Counter32	ipv6IfIcmpInGroupMembOurReports;
11757c478bd9Sstevel@tonic-gate } mib2_ipv6IfIcmpEntry_t;
11767c478bd9Sstevel@tonic-gate 
11777c478bd9Sstevel@tonic-gate /*
11787c478bd9Sstevel@tonic-gate  * the TCP group
11797c478bd9Sstevel@tonic-gate  *
11807c478bd9Sstevel@tonic-gate  * Note that instances of object types that represent
11817c478bd9Sstevel@tonic-gate  * information about a particular TCP connection are
11827c478bd9Sstevel@tonic-gate  * transient; they persist only as long as the connection
11837c478bd9Sstevel@tonic-gate  * in question.
11847c478bd9Sstevel@tonic-gate  */
11857c478bd9Sstevel@tonic-gate #define	MIB2_TCP_CONN	13	/* tcpConnEntry */
11867c478bd9Sstevel@tonic-gate #define	MIB2_TCP6_CONN	14	/* tcp6ConnEntry */
11877c478bd9Sstevel@tonic-gate 
11887c478bd9Sstevel@tonic-gate /* Old name retained for compatibility */
11897c478bd9Sstevel@tonic-gate #define	MIB2_TCP_13	MIB2_TCP_CONN
11907c478bd9Sstevel@tonic-gate 
11913173664eSapersson /* Pack data in mib2_tcp to make struct size the same for 32- and 64-bits */
11923173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
11933173664eSapersson #pragma pack(4)
11943173664eSapersson #endif
11957c478bd9Sstevel@tonic-gate typedef struct mib2_tcp {
11967c478bd9Sstevel@tonic-gate 		/* algorithm used for transmit timeout value	{ tcp 1 } */
11977c478bd9Sstevel@tonic-gate 	int	tcpRtoAlgorithm;
11987c478bd9Sstevel@tonic-gate 		/* minimum retransmit timeout (ms)		{ tcp 2 } */
11997c478bd9Sstevel@tonic-gate 	int	tcpRtoMin;
12007c478bd9Sstevel@tonic-gate 		/* maximum retransmit timeout (ms)		{ tcp 3 } */
12017c478bd9Sstevel@tonic-gate 	int	tcpRtoMax;
12027c478bd9Sstevel@tonic-gate 		/* maximum # of connections supported		{ tcp 4 } */
12037c478bd9Sstevel@tonic-gate 	int	tcpMaxConn;
12047c478bd9Sstevel@tonic-gate 		/* # of direct transitions CLOSED -> SYN-SENT	{ tcp 5 } */
12057c478bd9Sstevel@tonic-gate 	Counter	tcpActiveOpens;
12067c478bd9Sstevel@tonic-gate 		/* # of direct transitions LISTEN -> SYN-RCVD	{ tcp 6 } */
12077c478bd9Sstevel@tonic-gate 	Counter	tcpPassiveOpens;
12087c478bd9Sstevel@tonic-gate 		/* # of direct SIN-SENT/RCVD -> CLOSED/LISTEN	{ tcp 7 } */
12097c478bd9Sstevel@tonic-gate 	Counter	tcpAttemptFails;
12107c478bd9Sstevel@tonic-gate 		/* # of direct ESTABLISHED/CLOSE-WAIT -> CLOSED	{ tcp 8 } */
12117c478bd9Sstevel@tonic-gate 	Counter	tcpEstabResets;
12127c478bd9Sstevel@tonic-gate 		/* # of connections ESTABLISHED or CLOSE-WAIT	{ tcp 9 } */
12137c478bd9Sstevel@tonic-gate 	Gauge	tcpCurrEstab;
12147c478bd9Sstevel@tonic-gate 		/* total # of segments recv'd			{ tcp 10 } */
12157c478bd9Sstevel@tonic-gate 	Counter	tcpInSegs;
12167c478bd9Sstevel@tonic-gate 		/* total # of segments sent			{ tcp 11 } */
12177c478bd9Sstevel@tonic-gate 	Counter	tcpOutSegs;
12187c478bd9Sstevel@tonic-gate 		/* total # of segments retransmitted		{ tcp 12 } */
12197c478bd9Sstevel@tonic-gate 	Counter	tcpRetransSegs;
12207c478bd9Sstevel@tonic-gate 		/* {tcp 13} */
12217c478bd9Sstevel@tonic-gate 	int	tcpConnTableSize;	/* Size of tcpConnEntry_t */
12227c478bd9Sstevel@tonic-gate 	/* in ip				{tcp 14} */
12237c478bd9Sstevel@tonic-gate 		/* # of segments sent with RST flag		{ tcp 15 } */
12247c478bd9Sstevel@tonic-gate 	Counter	tcpOutRsts;
12257c478bd9Sstevel@tonic-gate /* In addition to MIB-II */
12267c478bd9Sstevel@tonic-gate /* Sender */
12277c478bd9Sstevel@tonic-gate 	/* total # of data segments sent */
12287c478bd9Sstevel@tonic-gate 	Counter tcpOutDataSegs;
12297c478bd9Sstevel@tonic-gate 	/* total # of bytes in data segments sent */
12307c478bd9Sstevel@tonic-gate 	Counter tcpOutDataBytes;
12317c478bd9Sstevel@tonic-gate 	/* total # of bytes in segments retransmitted */
12327c478bd9Sstevel@tonic-gate 	Counter tcpRetransBytes;
12337c478bd9Sstevel@tonic-gate 	/* total # of acks sent */
12347c478bd9Sstevel@tonic-gate 	Counter tcpOutAck;
12357c478bd9Sstevel@tonic-gate 	/* total # of delayed acks sent */
12367c478bd9Sstevel@tonic-gate 	Counter tcpOutAckDelayed;
12377c478bd9Sstevel@tonic-gate 	/* total # of segments sent with the urg flag on */
12387c478bd9Sstevel@tonic-gate 	Counter tcpOutUrg;
12397c478bd9Sstevel@tonic-gate 	/* total # of window updates sent */
12407c478bd9Sstevel@tonic-gate 	Counter tcpOutWinUpdate;
12417c478bd9Sstevel@tonic-gate 	/* total # of zero window probes sent */
12427c478bd9Sstevel@tonic-gate 	Counter tcpOutWinProbe;
12437c478bd9Sstevel@tonic-gate 	/* total # of control segments sent (syn, fin, rst) */
12447c478bd9Sstevel@tonic-gate 	Counter tcpOutControl;
12457c478bd9Sstevel@tonic-gate 	/* total # of segments sent due to "fast retransmit" */
12467c478bd9Sstevel@tonic-gate 	Counter tcpOutFastRetrans;
12477c478bd9Sstevel@tonic-gate /* Receiver */
12487c478bd9Sstevel@tonic-gate 	/* total # of ack segments received */
12497c478bd9Sstevel@tonic-gate 	Counter tcpInAckSegs;
12507c478bd9Sstevel@tonic-gate 	/* total # of bytes acked */
12517c478bd9Sstevel@tonic-gate 	Counter tcpInAckBytes;
12527c478bd9Sstevel@tonic-gate 	/* total # of duplicate acks */
12537c478bd9Sstevel@tonic-gate 	Counter tcpInDupAck;
12547c478bd9Sstevel@tonic-gate 	/* total # of acks acking unsent data */
12557c478bd9Sstevel@tonic-gate 	Counter tcpInAckUnsent;
12567c478bd9Sstevel@tonic-gate 	/* total # of data segments received in order */
12577c478bd9Sstevel@tonic-gate 	Counter tcpInDataInorderSegs;
12587c478bd9Sstevel@tonic-gate 	/* total # of data bytes received in order */
12597c478bd9Sstevel@tonic-gate 	Counter tcpInDataInorderBytes;
12607c478bd9Sstevel@tonic-gate 	/* total # of data segments received out of order */
12617c478bd9Sstevel@tonic-gate 	Counter tcpInDataUnorderSegs;
12627c478bd9Sstevel@tonic-gate 	/* total # of data bytes received out of order */
12637c478bd9Sstevel@tonic-gate 	Counter tcpInDataUnorderBytes;
12647c478bd9Sstevel@tonic-gate 	/* total # of complete duplicate data segments received */
12657c478bd9Sstevel@tonic-gate 	Counter tcpInDataDupSegs;
12667c478bd9Sstevel@tonic-gate 	/* total # of bytes in the complete duplicate data segments received */
12677c478bd9Sstevel@tonic-gate 	Counter tcpInDataDupBytes;
12687c478bd9Sstevel@tonic-gate 	/* total # of partial duplicate data segments received */
12697c478bd9Sstevel@tonic-gate 	Counter tcpInDataPartDupSegs;
12707c478bd9Sstevel@tonic-gate 	/* total # of bytes in the partial duplicate data segments received */
12717c478bd9Sstevel@tonic-gate 	Counter tcpInDataPartDupBytes;
12727c478bd9Sstevel@tonic-gate 	/* total # of data segments received past the window */
12737c478bd9Sstevel@tonic-gate 	Counter tcpInDataPastWinSegs;
12747c478bd9Sstevel@tonic-gate 	/* total # of data bytes received part the window */
12757c478bd9Sstevel@tonic-gate 	Counter tcpInDataPastWinBytes;
12767c478bd9Sstevel@tonic-gate 	/* total # of zero window probes received */
12777c478bd9Sstevel@tonic-gate 	Counter tcpInWinProbe;
12787c478bd9Sstevel@tonic-gate 	/* total # of window updates received */
12797c478bd9Sstevel@tonic-gate 	Counter tcpInWinUpdate;
12807c478bd9Sstevel@tonic-gate 	/* total # of data segments received after the connection has closed */
12817c478bd9Sstevel@tonic-gate 	Counter tcpInClosed;
12827c478bd9Sstevel@tonic-gate /* Others */
12837c478bd9Sstevel@tonic-gate 	/* total # of failed attempts to update the rtt estimate */
12847c478bd9Sstevel@tonic-gate 	Counter tcpRttNoUpdate;
12857c478bd9Sstevel@tonic-gate 	/* total # of successful attempts to update the rtt estimate */
12867c478bd9Sstevel@tonic-gate 	Counter tcpRttUpdate;
12877c478bd9Sstevel@tonic-gate 	/* total # of retransmit timeouts */
12887c478bd9Sstevel@tonic-gate 	Counter tcpTimRetrans;
12897c478bd9Sstevel@tonic-gate 	/* total # of retransmit timeouts dropping the connection */
12907c478bd9Sstevel@tonic-gate 	Counter tcpTimRetransDrop;
12917c478bd9Sstevel@tonic-gate 	/* total # of keepalive timeouts */
12927c478bd9Sstevel@tonic-gate 	Counter tcpTimKeepalive;
12937c478bd9Sstevel@tonic-gate 	/* total # of keepalive timeouts sending a probe */
12947c478bd9Sstevel@tonic-gate 	Counter tcpTimKeepaliveProbe;
12957c478bd9Sstevel@tonic-gate 	/* total # of keepalive timeouts dropping the connection */
12967c478bd9Sstevel@tonic-gate 	Counter tcpTimKeepaliveDrop;
12977c478bd9Sstevel@tonic-gate 	/* total # of connections refused due to backlog full on listen */
12987c478bd9Sstevel@tonic-gate 	Counter tcpListenDrop;
12997c478bd9Sstevel@tonic-gate 	/* total # of connections refused due to half-open queue (q0) full */
13007c478bd9Sstevel@tonic-gate 	Counter tcpListenDropQ0;
13017c478bd9Sstevel@tonic-gate 	/* total # of connections dropped from a full half-open queue (q0) */
13027c478bd9Sstevel@tonic-gate 	Counter tcpHalfOpenDrop;
13037c478bd9Sstevel@tonic-gate 	/* total # of retransmitted segments by SACK retransmission */
13047c478bd9Sstevel@tonic-gate 	Counter	tcpOutSackRetransSegs;
13057c478bd9Sstevel@tonic-gate 
13067c478bd9Sstevel@tonic-gate 	int	tcp6ConnTableSize;	/* Size of tcp6ConnEntry_t */
13073173664eSapersson 
13083173664eSapersson 	/*
13093173664eSapersson 	 * fields from RFC 4022
13103173664eSapersson 	 */
13113173664eSapersson 
13123173664eSapersson 	/* total # of segments recv'd				{ tcp 17 } */
13133173664eSapersson 	Counter64	tcpHCInSegs;
13143173664eSapersson 	/* total # of segments sent				{ tcp 18 } */
13153173664eSapersson 	Counter64	tcpHCOutSegs;
13167c478bd9Sstevel@tonic-gate } mib2_tcp_t;
1317*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_tcp_t	tcpHCInSegs
13187c478bd9Sstevel@tonic-gate 
13193173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
13203173664eSapersson #pragma pack()
13213173664eSapersson #endif
13223173664eSapersson 
13237c478bd9Sstevel@tonic-gate /*
13247c478bd9Sstevel@tonic-gate  * The TCP/IPv4 connection table {tcp 13} contains information about this
13257c478bd9Sstevel@tonic-gate  * entity's existing TCP connections over IPv4.
13267c478bd9Sstevel@tonic-gate  */
13277c478bd9Sstevel@tonic-gate /* For tcpConnState and tcp6ConnState */
13287c478bd9Sstevel@tonic-gate #define	MIB2_TCP_closed		1
13297c478bd9Sstevel@tonic-gate #define	MIB2_TCP_listen		2
13307c478bd9Sstevel@tonic-gate #define	MIB2_TCP_synSent	3
13317c478bd9Sstevel@tonic-gate #define	MIB2_TCP_synReceived	4
13327c478bd9Sstevel@tonic-gate #define	MIB2_TCP_established	5
13337c478bd9Sstevel@tonic-gate #define	MIB2_TCP_finWait1	6
13347c478bd9Sstevel@tonic-gate #define	MIB2_TCP_finWait2	7
13357c478bd9Sstevel@tonic-gate #define	MIB2_TCP_closeWait	8
13367c478bd9Sstevel@tonic-gate #define	MIB2_TCP_lastAck	9
13377c478bd9Sstevel@tonic-gate #define	MIB2_TCP_closing	10
13387c478bd9Sstevel@tonic-gate #define	MIB2_TCP_timeWait	11
13397c478bd9Sstevel@tonic-gate #define	MIB2_TCP_deleteTCB	12		/* only writeable value */
13407c478bd9Sstevel@tonic-gate 
13413173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */
13423173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
13433173664eSapersson #pragma pack(4)
13443173664eSapersson #endif
13457c478bd9Sstevel@tonic-gate typedef struct mib2_tcpConnEntry {
13467c478bd9Sstevel@tonic-gate 		/* state of tcp connection		{ tcpConnEntry 1} RW */
13477c478bd9Sstevel@tonic-gate 	int		tcpConnState;
13487c478bd9Sstevel@tonic-gate 		/* local ip addr for this connection	{ tcpConnEntry 2 } */
13497c478bd9Sstevel@tonic-gate 	IpAddress	tcpConnLocalAddress;
13507c478bd9Sstevel@tonic-gate 		/* local port for this connection	{ tcpConnEntry 3 } */
13517c478bd9Sstevel@tonic-gate 	int		tcpConnLocalPort;	/* In host byte order */
13527c478bd9Sstevel@tonic-gate 		/* remote ip addr for this connection	{ tcpConnEntry 4 } */
13537c478bd9Sstevel@tonic-gate 	IpAddress	tcpConnRemAddress;
13547c478bd9Sstevel@tonic-gate 		/* remote port for this connection	{ tcpConnEntry 5 } */
13557c478bd9Sstevel@tonic-gate 	int		tcpConnRemPort;		/* In host byte order */
13567c478bd9Sstevel@tonic-gate 	struct tcpConnEntryInfo_s {
13577c478bd9Sstevel@tonic-gate 			/* seq # of next segment to send */
13587c478bd9Sstevel@tonic-gate 		Gauge		ce_snxt;
13597c478bd9Sstevel@tonic-gate 				/* seq # of of last segment unacknowledged */
13607c478bd9Sstevel@tonic-gate 		Gauge		ce_suna;
13617c478bd9Sstevel@tonic-gate 				/* currect send window size */
13627c478bd9Sstevel@tonic-gate 		Gauge		ce_swnd;
13637c478bd9Sstevel@tonic-gate 				/* seq # of next expected segment */
13647c478bd9Sstevel@tonic-gate 		Gauge		ce_rnxt;
13657c478bd9Sstevel@tonic-gate 				/* seq # of last ack'd segment */
13667c478bd9Sstevel@tonic-gate 		Gauge		ce_rack;
13677c478bd9Sstevel@tonic-gate 				/* currenct receive window size */
13687c478bd9Sstevel@tonic-gate 		Gauge		ce_rwnd;
13697c478bd9Sstevel@tonic-gate 					/* current rto (retransmit timeout) */
13707c478bd9Sstevel@tonic-gate 		Gauge		ce_rto;
13717c478bd9Sstevel@tonic-gate 					/* current max segment size */
13727c478bd9Sstevel@tonic-gate 		Gauge		ce_mss;
13737c478bd9Sstevel@tonic-gate 				/* actual internal state */
13747c478bd9Sstevel@tonic-gate 		int		ce_state;
13757c478bd9Sstevel@tonic-gate 	} 		tcpConnEntryInfo;
13763173664eSapersson 
13773173664eSapersson 	/* pid of the processes that created this connection */
13783173664eSapersson 	uint32_t	tcpConnCreationProcess;
13793173664eSapersson 	/* system uptime when the connection was created */
13803173664eSapersson 	uint64_t	tcpConnCreationTime;
13817c478bd9Sstevel@tonic-gate } mib2_tcpConnEntry_t;
1382*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_tcpConnEntry_t	tcpConnCreationProcess
1383*6f773e29SBaban Kenkre 
13843173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
13853173664eSapersson #pragma pack()
13863173664eSapersson #endif
13877c478bd9Sstevel@tonic-gate 
13887c478bd9Sstevel@tonic-gate 
13897c478bd9Sstevel@tonic-gate /*
13907c478bd9Sstevel@tonic-gate  * The TCP/IPv6 connection table {tcp 14} contains information about this
13917c478bd9Sstevel@tonic-gate  * entity's existing TCP connections over IPv6.
13927c478bd9Sstevel@tonic-gate  */
13937c478bd9Sstevel@tonic-gate 
13943173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */
13953173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
13963173664eSapersson #pragma pack(4)
13973173664eSapersson #endif
13987c478bd9Sstevel@tonic-gate typedef struct mib2_tcp6ConnEntry {
13997c478bd9Sstevel@tonic-gate 	/* local ip addr for this connection	{ ipv6TcpConnEntry 1 } */
14007c478bd9Sstevel@tonic-gate 	Ip6Address	tcp6ConnLocalAddress;
14017c478bd9Sstevel@tonic-gate 	/* local port for this connection	{ ipv6TcpConnEntry 2 } */
14027c478bd9Sstevel@tonic-gate 	int		tcp6ConnLocalPort;
14037c478bd9Sstevel@tonic-gate 	/* remote ip addr for this connection	{ ipv6TcpConnEntry 3 } */
14047c478bd9Sstevel@tonic-gate 	Ip6Address	tcp6ConnRemAddress;
14057c478bd9Sstevel@tonic-gate 	/* remote port for this connection	{ ipv6TcpConnEntry 4 } */
14067c478bd9Sstevel@tonic-gate 	int		tcp6ConnRemPort;
14077c478bd9Sstevel@tonic-gate 	/* interface index or zero		{ ipv6TcpConnEntry 5 } */
14087c478bd9Sstevel@tonic-gate 	DeviceIndex	tcp6ConnIfIndex;
14097c478bd9Sstevel@tonic-gate 	/* state of tcp6 connection		{ ipv6TcpConnEntry 6 } RW */
14107c478bd9Sstevel@tonic-gate 	int		tcp6ConnState;
14117c478bd9Sstevel@tonic-gate 	struct tcp6ConnEntryInfo_s {
14127c478bd9Sstevel@tonic-gate 			/* seq # of next segment to send */
14137c478bd9Sstevel@tonic-gate 		Gauge		ce_snxt;
14147c478bd9Sstevel@tonic-gate 				/* seq # of of last segment unacknowledged */
14157c478bd9Sstevel@tonic-gate 		Gauge		ce_suna;
14167c478bd9Sstevel@tonic-gate 				/* currect send window size */
14177c478bd9Sstevel@tonic-gate 		Gauge		ce_swnd;
14187c478bd9Sstevel@tonic-gate 				/* seq # of next expected segment */
14197c478bd9Sstevel@tonic-gate 		Gauge		ce_rnxt;
14207c478bd9Sstevel@tonic-gate 				/* seq # of last ack'd segment */
14217c478bd9Sstevel@tonic-gate 		Gauge		ce_rack;
14227c478bd9Sstevel@tonic-gate 				/* currenct receive window size */
14237c478bd9Sstevel@tonic-gate 		Gauge		ce_rwnd;
14247c478bd9Sstevel@tonic-gate 					/* current rto (retransmit timeout) */
14257c478bd9Sstevel@tonic-gate 		Gauge		ce_rto;
14267c478bd9Sstevel@tonic-gate 					/* current max segment size */
14277c478bd9Sstevel@tonic-gate 		Gauge		ce_mss;
14287c478bd9Sstevel@tonic-gate 				/* actual internal state */
14297c478bd9Sstevel@tonic-gate 		int		ce_state;
14307c478bd9Sstevel@tonic-gate 	} 		tcp6ConnEntryInfo;
14313173664eSapersson 
14323173664eSapersson 	/* pid of the processes that created this connection */
14333173664eSapersson 	uint32_t	tcp6ConnCreationProcess;
14343173664eSapersson 	/* system uptime when the connection was created */
14353173664eSapersson 	uint64_t	tcp6ConnCreationTime;
14367c478bd9Sstevel@tonic-gate } mib2_tcp6ConnEntry_t;
1437*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_tcp6ConnEntry_t	tcp6ConnCreationProcess
1438*6f773e29SBaban Kenkre 
14393173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
14403173664eSapersson #pragma pack()
14413173664eSapersson #endif
14427c478bd9Sstevel@tonic-gate 
14437c478bd9Sstevel@tonic-gate /*
14447c478bd9Sstevel@tonic-gate  * the UDP group
14457c478bd9Sstevel@tonic-gate  */
14467c478bd9Sstevel@tonic-gate #define	MIB2_UDP_ENTRY	5	/* udpEntry */
14477c478bd9Sstevel@tonic-gate #define	MIB2_UDP6_ENTRY	6	/* udp6Entry */
14487c478bd9Sstevel@tonic-gate 
14497c478bd9Sstevel@tonic-gate /* Old name retained for compatibility */
14507c478bd9Sstevel@tonic-gate #define	MIB2_UDP_5	MIB2_UDP_ENTRY
14517c478bd9Sstevel@tonic-gate 
14523173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */
14533173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
14543173664eSapersson #pragma pack(4)
14553173664eSapersson #endif
14567c478bd9Sstevel@tonic-gate typedef struct mib2_udp {
14577c478bd9Sstevel@tonic-gate 		/* total # of UDP datagrams sent upstream	{ udp 1 } */
14587c478bd9Sstevel@tonic-gate 	Counter	udpInDatagrams;
14597c478bd9Sstevel@tonic-gate 	/* in ip				{ udp 2 } */
14607c478bd9Sstevel@tonic-gate 		/* # of recv'd dg's not deliverable (other)	{ udp 3 }  */
14617c478bd9Sstevel@tonic-gate 	Counter	udpInErrors;
14627c478bd9Sstevel@tonic-gate 		/* total # of dg's sent				{ udp 4 } */
14637c478bd9Sstevel@tonic-gate 	Counter	udpOutDatagrams;
14647c478bd9Sstevel@tonic-gate 		/* { udp 5 } */
14657c478bd9Sstevel@tonic-gate 	int	udpEntrySize;			/* Size of udpEntry_t */
14667c478bd9Sstevel@tonic-gate 	int	udp6EntrySize;			/* Size of udp6Entry_t */
14677c478bd9Sstevel@tonic-gate 	Counter	udpOutErrors;
14683173664eSapersson 
14693173664eSapersson 	/*
14703173664eSapersson 	 * fields from RFC 4113
14713173664eSapersson 	 */
14723173664eSapersson 
14733173664eSapersson 	/* total # of UDP datagrams sent upstream		{ udp 8 } */
14743173664eSapersson 	Counter64	udpHCInDatagrams;
14753173664eSapersson 	/* total # of dg's sent					{ udp 9 } */
14763173664eSapersson 	Counter64	udpHCOutDatagrams;
14777c478bd9Sstevel@tonic-gate } mib2_udp_t;
1478*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_udp_t	udpHCInDatagrams
1479*6f773e29SBaban Kenkre 
14803173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
14813173664eSapersson #pragma pack()
14823173664eSapersson #endif
14837c478bd9Sstevel@tonic-gate 
14847c478bd9Sstevel@tonic-gate /*
14857c478bd9Sstevel@tonic-gate  * The UDP listener table contains information about this entity's UDP
14867c478bd9Sstevel@tonic-gate  * end-points on which a local application is currently accepting datagrams.
14877c478bd9Sstevel@tonic-gate  */
14887c478bd9Sstevel@tonic-gate 
14897c478bd9Sstevel@tonic-gate /* For both IPv4 and IPv6 ue_state: */
14907c478bd9Sstevel@tonic-gate #define	MIB2_UDP_unbound	1
14917c478bd9Sstevel@tonic-gate #define	MIB2_UDP_idle		2
14927c478bd9Sstevel@tonic-gate #define	MIB2_UDP_connected	3
14937c478bd9Sstevel@tonic-gate #define	MIB2_UDP_unknown	4
14947c478bd9Sstevel@tonic-gate 
14953173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */
14963173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
14973173664eSapersson #pragma pack(4)
14983173664eSapersson #endif
14997c478bd9Sstevel@tonic-gate typedef struct mib2_udpEntry {
15007c478bd9Sstevel@tonic-gate 		/* local ip addr of listener		{ udpEntry 1 } */
15017c478bd9Sstevel@tonic-gate 	IpAddress	udpLocalAddress;
15027c478bd9Sstevel@tonic-gate 		/* local port of listener		{ udpEntry 2 } */
15037c478bd9Sstevel@tonic-gate 	int		udpLocalPort;		/* In host byte order */
15047c478bd9Sstevel@tonic-gate 	struct udpEntryInfo_s {
15057c478bd9Sstevel@tonic-gate 		int		ue_state;
15067c478bd9Sstevel@tonic-gate 		IpAddress	ue_RemoteAddress;
15077c478bd9Sstevel@tonic-gate 		int		ue_RemotePort;	/* In host byte order */
15087c478bd9Sstevel@tonic-gate 	}		udpEntryInfo;
15093173664eSapersson 
15103173664eSapersson 	/*
15113173664eSapersson 	 * RFC 4113
15123173664eSapersson 	 */
15133173664eSapersson 
15143173664eSapersson 	/* Unique id for this 4-tuple		{ udpEndpointEntry 7 } */
15153173664eSapersson 	uint32_t	udpInstance;
15163173664eSapersson 	/* pid of the processes that created this endpoint */
15173173664eSapersson 	uint32_t	udpCreationProcess;
15183173664eSapersson 	/* system uptime when the endpoint was created */
15193173664eSapersson 	uint64_t	udpCreationTime;
15207c478bd9Sstevel@tonic-gate } mib2_udpEntry_t;
1521*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_udpEntry_t	udpInstance
1522*6f773e29SBaban Kenkre 
15233173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
15243173664eSapersson #pragma pack()
15253173664eSapersson #endif
15267c478bd9Sstevel@tonic-gate 
15277c478bd9Sstevel@tonic-gate /*
15287c478bd9Sstevel@tonic-gate  * The UDP (for IPv6) listener table contains information about this
15297c478bd9Sstevel@tonic-gate  * entity's UDP end-points on which a local application is
15307c478bd9Sstevel@tonic-gate  * currently accepting datagrams.
15317c478bd9Sstevel@tonic-gate  */
15327c478bd9Sstevel@tonic-gate 
15333173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */
15343173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
15353173664eSapersson #pragma pack(4)
15363173664eSapersson #endif
15377c478bd9Sstevel@tonic-gate typedef	struct mib2_udp6Entry {
15387c478bd9Sstevel@tonic-gate 		/* local ip addr of listener		{ ipv6UdpEntry 1 } */
15397c478bd9Sstevel@tonic-gate 	Ip6Address	udp6LocalAddress;
15407c478bd9Sstevel@tonic-gate 		/* local port of listener		{ ipv6UdpEntry 2 } */
15417c478bd9Sstevel@tonic-gate 	int		udp6LocalPort;		/* In host byte order */
15427c478bd9Sstevel@tonic-gate 		/* interface index or zero 		{ ipv6UdpEntry 3 } */
15437c478bd9Sstevel@tonic-gate 	DeviceIndex	udp6IfIndex;
15447c478bd9Sstevel@tonic-gate 	struct udp6EntryInfo_s {
15457c478bd9Sstevel@tonic-gate 		int	ue_state;
15467c478bd9Sstevel@tonic-gate 		Ip6Address	ue_RemoteAddress;
15477c478bd9Sstevel@tonic-gate 		int		ue_RemotePort;	/* In host byte order */
15487c478bd9Sstevel@tonic-gate 	}		udp6EntryInfo;
15493173664eSapersson 
15503173664eSapersson 	/*
15513173664eSapersson 	 * RFC 4113
15523173664eSapersson 	 */
15533173664eSapersson 
15543173664eSapersson 	/* Unique id for this 4-tuple		{ udpEndpointEntry 7 } */
15553173664eSapersson 	uint32_t	udp6Instance;
15563173664eSapersson 	/* pid of the processes that created this endpoint */
15573173664eSapersson 	uint32_t	udp6CreationProcess;
15583173664eSapersson 	/* system uptime when the endpoint was created */
15593173664eSapersson 	uint64_t	udp6CreationTime;
15607c478bd9Sstevel@tonic-gate } mib2_udp6Entry_t;
1561*6f773e29SBaban Kenkre #define	MIB_FIRST_NEW_ELM_mib2_udp6Entry_t	udp6Instance
1562*6f773e29SBaban Kenkre 
15633173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
15643173664eSapersson #pragma pack()
15653173664eSapersson #endif
15667c478bd9Sstevel@tonic-gate 
15677c478bd9Sstevel@tonic-gate /*
15687c478bd9Sstevel@tonic-gate  * the RAWIP group
15697c478bd9Sstevel@tonic-gate  */
15707c478bd9Sstevel@tonic-gate typedef struct mib2_rawip {
15717c478bd9Sstevel@tonic-gate 		/* total # of RAWIP datagrams sent upstream */
15727c478bd9Sstevel@tonic-gate 	Counter	rawipInDatagrams;
15737c478bd9Sstevel@tonic-gate 		/* # of RAWIP packets with bad IPV6_CHECKSUM checksums */
15747c478bd9Sstevel@tonic-gate 	Counter rawipInCksumErrs;
15757c478bd9Sstevel@tonic-gate 		/* # of recv'd dg's not deliverable (other) */
15767c478bd9Sstevel@tonic-gate 	Counter	rawipInErrors;
15777c478bd9Sstevel@tonic-gate 		/* total # of dg's sent */
15787c478bd9Sstevel@tonic-gate 	Counter	rawipOutDatagrams;
15797c478bd9Sstevel@tonic-gate 		/* total # of dg's not sent (e.g. no memory) */
15807c478bd9Sstevel@tonic-gate 	Counter	rawipOutErrors;
15817c478bd9Sstevel@tonic-gate } mib2_rawip_t;
15827c478bd9Sstevel@tonic-gate 
15837c478bd9Sstevel@tonic-gate /* DVMRP group */
15847c478bd9Sstevel@tonic-gate #define	EXPER_DVMRP_VIF		1
15857c478bd9Sstevel@tonic-gate #define	EXPER_DVMRP_MRT		2
15867c478bd9Sstevel@tonic-gate 
15877c478bd9Sstevel@tonic-gate 
15887c478bd9Sstevel@tonic-gate /*
15897c478bd9Sstevel@tonic-gate  * The SCTP group
15907c478bd9Sstevel@tonic-gate  */
15917c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_CONN			15
15927c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_CONN_LOCAL		16
15937c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_CONN_REMOTE		17
15947c478bd9Sstevel@tonic-gate 
15957c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_closed		1
15967c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_cookieWait		2
15977c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_cookieEchoed		3
15987c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_established		4
15997c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_shutdownPending	5
16007c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_shutdownSent		6
16017c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_shutdownReceived	7
16027c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_shutdownAckSent	8
16037c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_deleteTCB		9
16047c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_listen		10	/* Not in the MIB */
16057c478bd9Sstevel@tonic-gate 
16067c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_ACTIVE		1
16077c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_INACTIVE		2
16087c478bd9Sstevel@tonic-gate 
16097c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_ADDR_V4		1
16107c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_ADDR_V6		2
16117c478bd9Sstevel@tonic-gate 
16127c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_RTOALGO_OTHER		1
16137c478bd9Sstevel@tonic-gate #define	MIB2_SCTP_RTOALGO_VANJ		2
16147c478bd9Sstevel@tonic-gate 
16157c478bd9Sstevel@tonic-gate typedef struct mib2_sctpConnEntry {
16167c478bd9Sstevel@tonic-gate 		/* connection identifier	{ sctpAssocEntry 1 } */
16177c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocId;
16187c478bd9Sstevel@tonic-gate 		/* remote hostname (not used)	{ sctpAssocEntry 2 } */
16197c478bd9Sstevel@tonic-gate 	Octet_t		sctpAssocRemHostName;
16207c478bd9Sstevel@tonic-gate 		/* local port number		{ sctpAssocEntry 3 } */
16217c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocLocalPort;
16227c478bd9Sstevel@tonic-gate 		/* remote port number		{ sctpAssocEntry 4 } */
16237c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocRemPort;
16247c478bd9Sstevel@tonic-gate 		/* type of primary remote addr	{ sctpAssocEntry 5 } */
16257c478bd9Sstevel@tonic-gate 	int		sctpAssocRemPrimAddrType;
16267c478bd9Sstevel@tonic-gate 		/* primary remote address	{ sctpAssocEntry 6 } */
16277c478bd9Sstevel@tonic-gate 	Ip6Address	sctpAssocRemPrimAddr;
16287c478bd9Sstevel@tonic-gate 		/* local address */
16297c478bd9Sstevel@tonic-gate 	Ip6Address	sctpAssocLocPrimAddr;
16307c478bd9Sstevel@tonic-gate 		/* current heartbeat interval	{ sctpAssocEntry 7 } */
16317c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocHeartBeatInterval;
16327c478bd9Sstevel@tonic-gate 		/* state of this association	{ sctpAssocEntry 8 } */
16337c478bd9Sstevel@tonic-gate 	int		sctpAssocState;
16347c478bd9Sstevel@tonic-gate 		/* # of inbound streams		{ sctpAssocEntry 9 } */
16357c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocInStreams;
16367c478bd9Sstevel@tonic-gate 		/* # of outbound streams	{ sctpAssocEntry 10 } */
16377c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocOutStreams;
16387c478bd9Sstevel@tonic-gate 		/* max # of data retans		{ sctpAssocEntry 11 } */
16397c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocMaxRetr;
16407c478bd9Sstevel@tonic-gate 		/* sysId for assoc owner	{ sctpAssocEntry 12 } */
16417c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocPrimProcess;
16427c478bd9Sstevel@tonic-gate 		/* # of rxmit timeouts during hanshake */
16437c478bd9Sstevel@tonic-gate 	Counter32	sctpAssocT1expired;	/* { sctpAssocEntry 13 } */
16447c478bd9Sstevel@tonic-gate 		/* # of rxmit timeouts during shutdown */
16457c478bd9Sstevel@tonic-gate 	Counter32	sctpAssocT2expired;	/* { sctpAssocEntry 14 } */
16467c478bd9Sstevel@tonic-gate 		/* # of rxmit timeouts during data transfer */
16477c478bd9Sstevel@tonic-gate 	Counter32	sctpAssocRtxChunks;	/* { sctpAssocEntry 15 } */
16487c478bd9Sstevel@tonic-gate 		/* assoc start-up time		{ sctpAssocEntry 16 } */
16497c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocStartTime;
16507c478bd9Sstevel@tonic-gate 	struct sctpConnEntryInfo_s {
16517c478bd9Sstevel@tonic-gate 				/* amount of data in send Q */
16527c478bd9Sstevel@tonic-gate 		Gauge		ce_sendq;
16537c478bd9Sstevel@tonic-gate 				/* amount of data in recv Q */
16547c478bd9Sstevel@tonic-gate 		Gauge		ce_recvq;
16557c478bd9Sstevel@tonic-gate 				/* currect send window size */
16567c478bd9Sstevel@tonic-gate 		Gauge		ce_swnd;
16577c478bd9Sstevel@tonic-gate 				/* currenct receive window size */
16587c478bd9Sstevel@tonic-gate 		Gauge		ce_rwnd;
16597c478bd9Sstevel@tonic-gate 				/* current max segment size */
16607c478bd9Sstevel@tonic-gate 		Gauge		ce_mss;
16617c478bd9Sstevel@tonic-gate 	} sctpConnEntryInfo;
16627c478bd9Sstevel@tonic-gate } mib2_sctpConnEntry_t;
16637c478bd9Sstevel@tonic-gate 
16647c478bd9Sstevel@tonic-gate typedef struct mib2_sctpConnLocalAddrEntry {
16657c478bd9Sstevel@tonic-gate 		/* connection identifier */
16667c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocId;
16677c478bd9Sstevel@tonic-gate 		/* type of local addr		{ sctpAssocLocalEntry 1 } */
16687c478bd9Sstevel@tonic-gate 	int		sctpAssocLocalAddrType;
16697c478bd9Sstevel@tonic-gate 		/* local address		{ sctpAssocLocalEntry 2 } */
16707c478bd9Sstevel@tonic-gate 	Ip6Address	sctpAssocLocalAddr;
16717c478bd9Sstevel@tonic-gate } mib2_sctpConnLocalEntry_t;
16727c478bd9Sstevel@tonic-gate 
16737c478bd9Sstevel@tonic-gate typedef struct mib2_sctpConnRemoteAddrEntry {
16747c478bd9Sstevel@tonic-gate 		/* connection identier */
16757c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocId;
16767c478bd9Sstevel@tonic-gate 		/* remote addr type		{ sctpAssocRemEntry 1 } */
16777c478bd9Sstevel@tonic-gate 	int		sctpAssocRemAddrType;
16787c478bd9Sstevel@tonic-gate 		/* remote address		{ sctpAssocRemEntry 2 } */
16797c478bd9Sstevel@tonic-gate 	Ip6Address	sctpAssocRemAddr;
16807c478bd9Sstevel@tonic-gate 		/* is the address active	{ sctpAssocRemEntry 3 } */
16817c478bd9Sstevel@tonic-gate 	int		sctpAssocRemAddrActive;
16827c478bd9Sstevel@tonic-gate 		/* whether hearbeat is active	{ sctpAssocRemEntry 4 } */
16837c478bd9Sstevel@tonic-gate 	int		sctpAssocRemAddrHBActive;
16847c478bd9Sstevel@tonic-gate 		/* current RTO			{ sctpAssocRemEntry 5 } */
16857c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocRemAddrRTO;
16867c478bd9Sstevel@tonic-gate 		/* max # of rexmits before becoming inactive */
16877c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocRemAddrMaxPathRtx; /* {sctpAssocRemEntry 6} */
16887c478bd9Sstevel@tonic-gate 		/* # of rexmits to this dest	{ sctpAssocRemEntry 7 } */
16897c478bd9Sstevel@tonic-gate 	uint32_t	sctpAssocRemAddrRtx;
16907c478bd9Sstevel@tonic-gate } mib2_sctpConnRemoteEntry_t;
16917c478bd9Sstevel@tonic-gate 
16927c478bd9Sstevel@tonic-gate 
16937c478bd9Sstevel@tonic-gate 
16947c478bd9Sstevel@tonic-gate /* Pack data in mib2_sctp to make struct size the same for 32- and 64-bits */
16957c478bd9Sstevel@tonic-gate #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
16967c478bd9Sstevel@tonic-gate #pragma pack(4)
16977c478bd9Sstevel@tonic-gate #endif
16987c478bd9Sstevel@tonic-gate 
16997c478bd9Sstevel@tonic-gate typedef struct mib2_sctp {
17007c478bd9Sstevel@tonic-gate 		/* algorithm used to determine rto	{ sctpParams 1 } */
17017c478bd9Sstevel@tonic-gate 	int		sctpRtoAlgorithm;
17027c478bd9Sstevel@tonic-gate 		/* min RTO in msecs			{ sctpParams 2 } */
17037c478bd9Sstevel@tonic-gate 	uint32_t	sctpRtoMin;
17047c478bd9Sstevel@tonic-gate 		/* max RTO in msecs			{ sctpParams 3 } */
17057c478bd9Sstevel@tonic-gate 	uint32_t	sctpRtoMax;
17067c478bd9Sstevel@tonic-gate 		/* initial RTO in msecs			{ sctpParams 4 } */
17077c478bd9Sstevel@tonic-gate 	uint32_t	sctpRtoInitial;
17087c478bd9Sstevel@tonic-gate 		/* max # of assocs			{ sctpParams 5 } */
17097c478bd9Sstevel@tonic-gate 	int32_t		sctpMaxAssocs;
17107c478bd9Sstevel@tonic-gate 		/* cookie lifetime in msecs		{ sctpParams 6 } */
17117c478bd9Sstevel@tonic-gate 	uint32_t	sctpValCookieLife;
17127c478bd9Sstevel@tonic-gate 		/* max # of retrans in startup		{ sctpParams 7 } */
17137c478bd9Sstevel@tonic-gate 	uint32_t	sctpMaxInitRetr;
17147c478bd9Sstevel@tonic-gate 	/* # of conns ESTABLISHED, SHUTDOWN-RECEIVED or SHUTDOWN-PENDING */
17157c478bd9Sstevel@tonic-gate 	Counter32	sctpCurrEstab;		/* { sctpStats 1 } */
17167c478bd9Sstevel@tonic-gate 		/* # of active opens			{ sctpStats 2 } */
17177c478bd9Sstevel@tonic-gate 	Counter32	sctpActiveEstab;
17187c478bd9Sstevel@tonic-gate 		/* # of passive opens			{ sctpStats 3 } */
17197c478bd9Sstevel@tonic-gate 	Counter32	sctpPassiveEstab;
17207c478bd9Sstevel@tonic-gate 		/* # of aborted conns			{ sctpStats 4 } */
17217c478bd9Sstevel@tonic-gate 	Counter32	sctpAborted;
17227c478bd9Sstevel@tonic-gate 		/* # of graceful shutdowns		{ sctpStats 5 } */
17237c478bd9Sstevel@tonic-gate 	Counter32	sctpShutdowns;
17247c478bd9Sstevel@tonic-gate 		/* # of OOB packets			{ sctpStats 6 } */
17257c478bd9Sstevel@tonic-gate 	Counter32	sctpOutOfBlue;
17267c478bd9Sstevel@tonic-gate 		/* # of packets discarded due to cksum	{ sctpStats 7 } */
17277c478bd9Sstevel@tonic-gate 	Counter32	sctpChecksumError;
17287c478bd9Sstevel@tonic-gate 		/* # of control chunks sent		{ sctpStats 8 } */
17297c478bd9Sstevel@tonic-gate 	Counter64	sctpOutCtrlChunks;
17307c478bd9Sstevel@tonic-gate 		/* # of ordered data chunks sent	{ sctpStats 9 } */
17317c478bd9Sstevel@tonic-gate 	Counter64	sctpOutOrderChunks;
17327c478bd9Sstevel@tonic-gate 		/* # of unordered data chunks sent	{ sctpStats 10 } */
17337c478bd9Sstevel@tonic-gate 	Counter64	sctpOutUnorderChunks;
17347c478bd9Sstevel@tonic-gate 		/* # of retransmitted data chunks */
17357c478bd9Sstevel@tonic-gate 	Counter64	sctpRetransChunks;
17367c478bd9Sstevel@tonic-gate 		/* # of SACK chunks sent */
17377c478bd9Sstevel@tonic-gate 	Counter		sctpOutAck;
17387c478bd9Sstevel@tonic-gate 		/* # of delayed ACK timeouts */
17397c478bd9Sstevel@tonic-gate 	Counter		sctpOutAckDelayed;
17407c478bd9Sstevel@tonic-gate 		/* # of SACK chunks sent to update window */
17417c478bd9Sstevel@tonic-gate 	Counter		sctpOutWinUpdate;
17427c478bd9Sstevel@tonic-gate 		/* # of fast retransmits */
17437c478bd9Sstevel@tonic-gate 	Counter		sctpOutFastRetrans;
17447c478bd9Sstevel@tonic-gate 		/* # of window probes sent */
17457c478bd9Sstevel@tonic-gate 	Counter		sctpOutWinProbe;
17467c478bd9Sstevel@tonic-gate 		/* # of control chunks received		{ sctpStats 11 } */
17477c478bd9Sstevel@tonic-gate 	Counter64	sctpInCtrlChunks;
17487c478bd9Sstevel@tonic-gate 		/* # of ordered data chunks rcvd	{ sctpStats 12 } */
17497c478bd9Sstevel@tonic-gate 	Counter64	sctpInOrderChunks;
17507c478bd9Sstevel@tonic-gate 		/* # of unord data chunks rcvd		{ sctpStats 13 } */
17517c478bd9Sstevel@tonic-gate 	Counter64	sctpInUnorderChunks;
17527c478bd9Sstevel@tonic-gate 		/* # of received SACK chunks */
17537c478bd9Sstevel@tonic-gate 	Counter		sctpInAck;
17547c478bd9Sstevel@tonic-gate 		/* # of received SACK chunks with duplicate TSN */
17557c478bd9Sstevel@tonic-gate 	Counter		sctpInDupAck;
17567c478bd9Sstevel@tonic-gate 		/* # of SACK chunks acking unsent data */
17577c478bd9Sstevel@tonic-gate 	Counter 	sctpInAckUnsent;
17587c478bd9Sstevel@tonic-gate 		/* # of Fragmented User Messages	{ sctpStats 14 } */
17597c478bd9Sstevel@tonic-gate 	Counter64	sctpFragUsrMsgs;
17607c478bd9Sstevel@tonic-gate 		/* # of Reassembled User Messages	{ sctpStats 15 } */
17617c478bd9Sstevel@tonic-gate 	Counter64	sctpReasmUsrMsgs;
17627c478bd9Sstevel@tonic-gate 		/* # of Sent SCTP Packets		{ sctpStats 16 } */
17637c478bd9Sstevel@tonic-gate 	Counter64	sctpOutSCTPPkts;
17647c478bd9Sstevel@tonic-gate 		/* # of Received SCTP Packets		{ sctpStats 17 } */
17657c478bd9Sstevel@tonic-gate 	Counter64	sctpInSCTPPkts;
17667c478bd9Sstevel@tonic-gate 		/* # of invalid cookies received */
17677c478bd9Sstevel@tonic-gate 	Counter		sctpInInvalidCookie;
17687c478bd9Sstevel@tonic-gate 		/* total # of retransmit timeouts */
17697c478bd9Sstevel@tonic-gate 	Counter		sctpTimRetrans;
17707c478bd9Sstevel@tonic-gate 		/* total # of retransmit timeouts dropping the connection */
17717c478bd9Sstevel@tonic-gate 	Counter		sctpTimRetransDrop;
17727c478bd9Sstevel@tonic-gate 		/* total # of heartbeat probes */
17737c478bd9Sstevel@tonic-gate 	Counter		sctpTimHeartBeatProbe;
17747c478bd9Sstevel@tonic-gate 		/* total # of heartbeat timeouts dropping the connection */
17757c478bd9Sstevel@tonic-gate 	Counter		sctpTimHeartBeatDrop;
17767c478bd9Sstevel@tonic-gate 		/* total # of conns refused due to backlog full on listen */
17777c478bd9Sstevel@tonic-gate 	Counter		sctpListenDrop;
17787c478bd9Sstevel@tonic-gate 		/* total # of pkts received after the association has closed */
17797c478bd9Sstevel@tonic-gate 	Counter		sctpInClosed;
17807c478bd9Sstevel@tonic-gate 	int		sctpEntrySize;
17817c478bd9Sstevel@tonic-gate 	int		sctpLocalEntrySize;
17827c478bd9Sstevel@tonic-gate 	int		sctpRemoteEntrySize;
17837c478bd9Sstevel@tonic-gate } mib2_sctp_t;
17847c478bd9Sstevel@tonic-gate 
17857c478bd9Sstevel@tonic-gate #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
17867c478bd9Sstevel@tonic-gate #pragma pack()
17877c478bd9Sstevel@tonic-gate #endif
17887c478bd9Sstevel@tonic-gate 
17897c478bd9Sstevel@tonic-gate 
17907c478bd9Sstevel@tonic-gate #ifdef	__cplusplus
17917c478bd9Sstevel@tonic-gate }
17927c478bd9Sstevel@tonic-gate #endif
17937c478bd9Sstevel@tonic-gate 
17947c478bd9Sstevel@tonic-gate #endif	/* _INET_MIB2_H */
1795