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 * 21e11c3f44Smeem * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 227c478bd9Sstevel@tonic-gate * Use is subject to license terms. 237c478bd9Sstevel@tonic-gate */ 247c478bd9Sstevel@tonic-gate /* Copyright (c) 1990 Mentat Inc. */ 257c478bd9Sstevel@tonic-gate 267c478bd9Sstevel@tonic-gate #ifndef _INET_MIB2_H 277c478bd9Sstevel@tonic-gate #define _INET_MIB2_H 287c478bd9Sstevel@tonic-gate 297c478bd9Sstevel@tonic-gate #include <netinet/in.h> /* For in6_addr_t */ 3045916cd2Sjpk #include <sys/tsol/label.h> /* For brange_t */ 3145916cd2Sjpk #include <sys/tsol/label_macro.h> /* For brange_t */ 327c478bd9Sstevel@tonic-gate 337c478bd9Sstevel@tonic-gate #ifdef __cplusplus 347c478bd9Sstevel@tonic-gate extern "C" { 357c478bd9Sstevel@tonic-gate #endif 367c478bd9Sstevel@tonic-gate 377c478bd9Sstevel@tonic-gate /* 387c478bd9Sstevel@tonic-gate * The IPv6 parts of this are derived from: 397c478bd9Sstevel@tonic-gate * RFC 2465 407c478bd9Sstevel@tonic-gate * RFC 2466 417c478bd9Sstevel@tonic-gate * RFC 2452 427c478bd9Sstevel@tonic-gate * RFC 2454 437c478bd9Sstevel@tonic-gate */ 447c478bd9Sstevel@tonic-gate 457c478bd9Sstevel@tonic-gate /* 467c478bd9Sstevel@tonic-gate * SNMP set/get via M_PROTO T_OPTMGMT_REQ. Structure is that used 477c478bd9Sstevel@tonic-gate * for [gs]etsockopt() calls. get uses T_CURRENT, set uses T_NEOGTIATE 487c478bd9Sstevel@tonic-gate * MGMT_flags value. The following definition of opthdr is taken from 497c478bd9Sstevel@tonic-gate * socket.h: 507c478bd9Sstevel@tonic-gate * 517c478bd9Sstevel@tonic-gate * An option specification consists of an opthdr, followed by the value of 527c478bd9Sstevel@tonic-gate * the option. An options buffer contains one or more options. The len 537c478bd9Sstevel@tonic-gate * field of opthdr specifies the length of the option value in bytes. This 547c478bd9Sstevel@tonic-gate * length must be a multiple of sizeof(long) (use OPTLEN macro). 557c478bd9Sstevel@tonic-gate * 567c478bd9Sstevel@tonic-gate * struct opthdr { 577c478bd9Sstevel@tonic-gate * long level; protocol level affected 587c478bd9Sstevel@tonic-gate * long name; option to modify 597c478bd9Sstevel@tonic-gate * long len; length of option value 607c478bd9Sstevel@tonic-gate * }; 617c478bd9Sstevel@tonic-gate * 627c478bd9Sstevel@tonic-gate * #define OPTLEN(x) ((((x) + sizeof(long) - 1) / sizeof(long)) * sizeof(long)) 637c478bd9Sstevel@tonic-gate * #define OPTVAL(opt) ((char *)(opt + 1)) 647c478bd9Sstevel@tonic-gate * 65e11c3f44Smeem * For get requests (T_CURRENT), any MIB2_xxx value can be used (only 667c478bd9Sstevel@tonic-gate * "get all" is supported, so all modules get a copy of the request to 67e11c3f44Smeem * return everything it knows. In general, we use MIB2_IP. There is 68e11c3f44Smeem * one exception: in general, IP will not report information related to 69*bd670b35SErik Nordmark * ire_testhidden and IRE_IF_CLONE routes (e.g., in the MIB2_IP_ROUTE 70*bd670b35SErik Nordmark * table). However, using the special value EXPER_IP_AND_ALL_IRES will cause 71e11c3f44Smeem * all information to be reported. This special value should only be 72e11c3f44Smeem * used by IPMP-aware low-level utilities (e.g. in.mpathd). 737c478bd9Sstevel@tonic-gate * 747c478bd9Sstevel@tonic-gate * IMPORTANT: some fields are grouped in a different structure than 757c478bd9Sstevel@tonic-gate * suggested by MIB-II, e.g., checksum error counts. The original MIB-2 767c478bd9Sstevel@tonic-gate * field name has been retained. Field names beginning with "mi" are not 777c478bd9Sstevel@tonic-gate * defined in the MIB but contain important & useful information maintained 787c478bd9Sstevel@tonic-gate * by the corresponding module. 797c478bd9Sstevel@tonic-gate */ 807c478bd9Sstevel@tonic-gate #ifndef IPPROTO_MAX 817c478bd9Sstevel@tonic-gate #define IPPROTO_MAX 256 827c478bd9Sstevel@tonic-gate #endif 837c478bd9Sstevel@tonic-gate 847c478bd9Sstevel@tonic-gate #define MIB2_SYSTEM (IPPROTO_MAX+1) 857c478bd9Sstevel@tonic-gate #define MIB2_INTERFACES (IPPROTO_MAX+2) 867c478bd9Sstevel@tonic-gate #define MIB2_AT (IPPROTO_MAX+3) 877c478bd9Sstevel@tonic-gate #define MIB2_IP (IPPROTO_MAX+4) 887c478bd9Sstevel@tonic-gate #define MIB2_ICMP (IPPROTO_MAX+5) 897c478bd9Sstevel@tonic-gate #define MIB2_TCP (IPPROTO_MAX+6) 907c478bd9Sstevel@tonic-gate #define MIB2_UDP (IPPROTO_MAX+7) 917c478bd9Sstevel@tonic-gate #define MIB2_EGP (IPPROTO_MAX+8) 927c478bd9Sstevel@tonic-gate #define MIB2_CMOT (IPPROTO_MAX+9) 937c478bd9Sstevel@tonic-gate #define MIB2_TRANSMISSION (IPPROTO_MAX+10) 947c478bd9Sstevel@tonic-gate #define MIB2_SNMP (IPPROTO_MAX+11) 957c478bd9Sstevel@tonic-gate #define MIB2_IP6 (IPPROTO_MAX+12) 967c478bd9Sstevel@tonic-gate #define MIB2_ICMP6 (IPPROTO_MAX+13) 977c478bd9Sstevel@tonic-gate #define MIB2_TCP6 (IPPROTO_MAX+14) 987c478bd9Sstevel@tonic-gate #define MIB2_UDP6 (IPPROTO_MAX+15) 997c478bd9Sstevel@tonic-gate #define MIB2_SCTP (IPPROTO_MAX+16) 1007c478bd9Sstevel@tonic-gate 1017c478bd9Sstevel@tonic-gate /* 1027c478bd9Sstevel@tonic-gate * Define range of levels for use with MIB2_* 1037c478bd9Sstevel@tonic-gate */ 1047c478bd9Sstevel@tonic-gate #define MIB2_RANGE_START (IPPROTO_MAX+1) 1057c478bd9Sstevel@tonic-gate #define MIB2_RANGE_END (IPPROTO_MAX+16) 1067c478bd9Sstevel@tonic-gate 1077c478bd9Sstevel@tonic-gate 1087c478bd9Sstevel@tonic-gate #define EXPER 1024 /* experimental - not part of mib */ 1097c478bd9Sstevel@tonic-gate #define EXPER_IGMP (EXPER+1) 1107c478bd9Sstevel@tonic-gate #define EXPER_DVMRP (EXPER+2) 1117c478bd9Sstevel@tonic-gate #define EXPER_RAWIP (EXPER+3) 112*bd670b35SErik Nordmark #define EXPER_IP_AND_ALL_IRES (EXPER+4) 1137c478bd9Sstevel@tonic-gate 1147c478bd9Sstevel@tonic-gate /* 1157c478bd9Sstevel@tonic-gate * Define range of levels for experimental use 1167c478bd9Sstevel@tonic-gate */ 1177c478bd9Sstevel@tonic-gate #define EXPER_RANGE_START (EXPER+1) 118e11c3f44Smeem #define EXPER_RANGE_END (EXPER+4) 1197c478bd9Sstevel@tonic-gate 1207c478bd9Sstevel@tonic-gate #define BUMP_MIB(s, x) { \ 1217c478bd9Sstevel@tonic-gate extern void __dtrace_probe___mib_##x(int, void *); \ 1227c478bd9Sstevel@tonic-gate void *stataddr = &((s)->x); \ 1237c478bd9Sstevel@tonic-gate __dtrace_probe___mib_##x(1, stataddr); \ 1247c478bd9Sstevel@tonic-gate (s)->x++; \ 1257c478bd9Sstevel@tonic-gate } 1267c478bd9Sstevel@tonic-gate 1277c478bd9Sstevel@tonic-gate #define UPDATE_MIB(s, x, y) { \ 1287c478bd9Sstevel@tonic-gate extern void __dtrace_probe___mib_##x(int, void *); \ 1297c478bd9Sstevel@tonic-gate void *stataddr = &((s)->x); \ 1307c478bd9Sstevel@tonic-gate __dtrace_probe___mib_##x(y, stataddr); \ 1317c478bd9Sstevel@tonic-gate (s)->x += (y); \ 1327c478bd9Sstevel@tonic-gate } 1337c478bd9Sstevel@tonic-gate 1347c478bd9Sstevel@tonic-gate #define SET_MIB(x, y) x = y 1357c478bd9Sstevel@tonic-gate #define BUMP_LOCAL(x) (x)++ 1367c478bd9Sstevel@tonic-gate #define UPDATE_LOCAL(x, y) (x) += (y) 1373173664eSapersson #define SYNC32_MIB(s, m32, m64) SET_MIB((s)->m32, (s)->m64 & 0xffffffff) 1387c478bd9Sstevel@tonic-gate 1397c478bd9Sstevel@tonic-gate #define OCTET_LENGTH 32 /* Must be at least LIFNAMSIZ */ 1407c478bd9Sstevel@tonic-gate typedef struct Octet_s { 1417c478bd9Sstevel@tonic-gate int o_length; 1427c478bd9Sstevel@tonic-gate char o_bytes[OCTET_LENGTH]; 1437c478bd9Sstevel@tonic-gate } Octet_t; 1447c478bd9Sstevel@tonic-gate 1457c478bd9Sstevel@tonic-gate typedef uint32_t Counter; 1467c478bd9Sstevel@tonic-gate typedef uint32_t Counter32; 1477c478bd9Sstevel@tonic-gate typedef uint64_t Counter64; 1487c478bd9Sstevel@tonic-gate typedef uint32_t Gauge; 1497c478bd9Sstevel@tonic-gate typedef uint32_t IpAddress; 1507c478bd9Sstevel@tonic-gate typedef struct in6_addr Ip6Address; 1517c478bd9Sstevel@tonic-gate typedef Octet_t DeviceName; 1527c478bd9Sstevel@tonic-gate typedef Octet_t PhysAddress; 1537c478bd9Sstevel@tonic-gate typedef uint32_t DeviceIndex; /* Interface index */ 1547c478bd9Sstevel@tonic-gate 1553173664eSapersson #define MIB2_UNKNOWN_INTERFACE 0 1563173664eSapersson #define MIB2_UNKNOWN_PROCESS 0 1573173664eSapersson 1587c478bd9Sstevel@tonic-gate /* 1597c478bd9Sstevel@tonic-gate * IP group 1607c478bd9Sstevel@tonic-gate */ 1617c478bd9Sstevel@tonic-gate #define MIB2_IP_ADDR 20 /* ipAddrEntry */ 1627c478bd9Sstevel@tonic-gate #define MIB2_IP_ROUTE 21 /* ipRouteEntry */ 1637c478bd9Sstevel@tonic-gate #define MIB2_IP_MEDIA 22 /* ipNetToMediaEntry */ 1647c478bd9Sstevel@tonic-gate #define MIB2_IP6_ROUTE 23 /* ipv6RouteEntry */ 1657c478bd9Sstevel@tonic-gate #define MIB2_IP6_MEDIA 24 /* ipv6NetToMediaEntry */ 1667c478bd9Sstevel@tonic-gate #define MIB2_IP6_ADDR 25 /* ipv6AddrEntry */ 1673173664eSapersson #define MIB2_IP_TRAFFIC_STATS 31 /* ipIfStatsEntry (IPv4) */ 1687c478bd9Sstevel@tonic-gate #define EXPER_IP_GROUP_MEMBERSHIP 100 1697c478bd9Sstevel@tonic-gate #define EXPER_IP6_GROUP_MEMBERSHIP 101 1707c478bd9Sstevel@tonic-gate #define EXPER_IP_GROUP_SOURCES 102 1717c478bd9Sstevel@tonic-gate #define EXPER_IP6_GROUP_SOURCES 103 17245916cd2Sjpk #define EXPER_IP_RTATTR 104 173*bd670b35SErik Nordmark #define EXPER_IP_DCE 105 17445916cd2Sjpk 17545916cd2Sjpk /* 17645916cd2Sjpk * There can be one of each of these tables per transport (MIB2_* above). 17745916cd2Sjpk */ 17845916cd2Sjpk #define EXPER_XPORT_MLP 105 /* transportMLPEntry */ 1797c478bd9Sstevel@tonic-gate 1807c478bd9Sstevel@tonic-gate /* Old names retained for compatibility */ 1817c478bd9Sstevel@tonic-gate #define MIB2_IP_20 MIB2_IP_ADDR 1827c478bd9Sstevel@tonic-gate #define MIB2_IP_21 MIB2_IP_ROUTE 1837c478bd9Sstevel@tonic-gate #define MIB2_IP_22 MIB2_IP_MEDIA 1847c478bd9Sstevel@tonic-gate 1857c478bd9Sstevel@tonic-gate typedef struct mib2_ip { 1867c478bd9Sstevel@tonic-gate /* forwarder? 1 gateway, 2 NOT gateway {ip 1} RW */ 1877c478bd9Sstevel@tonic-gate int ipForwarding; 1887c478bd9Sstevel@tonic-gate /* default Time-to-Live for iph {ip 2} RW */ 1897c478bd9Sstevel@tonic-gate int ipDefaultTTL; 1907c478bd9Sstevel@tonic-gate /* # of input datagrams {ip 3} */ 1917c478bd9Sstevel@tonic-gate Counter ipInReceives; 1927c478bd9Sstevel@tonic-gate /* # of dg discards for iph error {ip 4} */ 1937c478bd9Sstevel@tonic-gate Counter ipInHdrErrors; 1947c478bd9Sstevel@tonic-gate /* # of dg discards for bad addr {ip 5} */ 1957c478bd9Sstevel@tonic-gate Counter ipInAddrErrors; 1967c478bd9Sstevel@tonic-gate /* # of dg being forwarded {ip 6} */ 1977c478bd9Sstevel@tonic-gate Counter ipForwDatagrams; 1987c478bd9Sstevel@tonic-gate /* # of dg discards for unk protocol {ip 7} */ 1997c478bd9Sstevel@tonic-gate Counter ipInUnknownProtos; 2007c478bd9Sstevel@tonic-gate /* # of dg discards of good dg's {ip 8} */ 2017c478bd9Sstevel@tonic-gate Counter ipInDiscards; 2027c478bd9Sstevel@tonic-gate /* # of dg sent upstream {ip 9} */ 2037c478bd9Sstevel@tonic-gate Counter ipInDelivers; 2047c478bd9Sstevel@tonic-gate /* # of outdgs recv'd from upstream {ip 10} */ 2057c478bd9Sstevel@tonic-gate Counter ipOutRequests; 2067c478bd9Sstevel@tonic-gate /* # of good outdgs discarded {ip 11} */ 2077c478bd9Sstevel@tonic-gate Counter ipOutDiscards; 2087c478bd9Sstevel@tonic-gate /* # of outdg discards: no route found {ip 12} */ 2097c478bd9Sstevel@tonic-gate Counter ipOutNoRoutes; 2107c478bd9Sstevel@tonic-gate /* sec's recv'd frags held for reass. {ip 13} */ 2117c478bd9Sstevel@tonic-gate int ipReasmTimeout; 2127c478bd9Sstevel@tonic-gate /* # of ip frags needing reassembly {ip 14} */ 2137c478bd9Sstevel@tonic-gate Counter ipReasmReqds; 2147c478bd9Sstevel@tonic-gate /* # of dg's reassembled {ip 15} */ 2157c478bd9Sstevel@tonic-gate Counter ipReasmOKs; 2167c478bd9Sstevel@tonic-gate /* # of reassembly failures (not dg cnt){ip 16} */ 2177c478bd9Sstevel@tonic-gate Counter ipReasmFails; 2187c478bd9Sstevel@tonic-gate /* # of dg's fragged {ip 17} */ 2197c478bd9Sstevel@tonic-gate Counter ipFragOKs; 2207c478bd9Sstevel@tonic-gate /* # of dg discards for no frag set {ip 18} */ 2217c478bd9Sstevel@tonic-gate Counter ipFragFails; 2227c478bd9Sstevel@tonic-gate /* # of dg frags from fragmentation {ip 19} */ 2237c478bd9Sstevel@tonic-gate Counter ipFragCreates; 2247c478bd9Sstevel@tonic-gate /* {ip 20} */ 2257c478bd9Sstevel@tonic-gate int ipAddrEntrySize; 2267c478bd9Sstevel@tonic-gate /* {ip 21} */ 2277c478bd9Sstevel@tonic-gate int ipRouteEntrySize; 2287c478bd9Sstevel@tonic-gate /* {ip 22} */ 2297c478bd9Sstevel@tonic-gate int ipNetToMediaEntrySize; 2307c478bd9Sstevel@tonic-gate /* # of valid route entries discarded {ip 23} */ 2317c478bd9Sstevel@tonic-gate Counter ipRoutingDiscards; 2327c478bd9Sstevel@tonic-gate /* 2337c478bd9Sstevel@tonic-gate * following defined in MIB-II as part of TCP & UDP groups: 2347c478bd9Sstevel@tonic-gate */ 2357c478bd9Sstevel@tonic-gate /* total # of segments recv'd with error { tcp 14 } */ 2367c478bd9Sstevel@tonic-gate Counter tcpInErrs; 2377c478bd9Sstevel@tonic-gate /* # of recv'd dg's not deliverable (no appl.) { udp 2 } */ 2387c478bd9Sstevel@tonic-gate Counter udpNoPorts; 2397c478bd9Sstevel@tonic-gate /* 2407c478bd9Sstevel@tonic-gate * In addition to MIB-II 2417c478bd9Sstevel@tonic-gate */ 2427c478bd9Sstevel@tonic-gate /* # of bad IP header checksums */ 2437c478bd9Sstevel@tonic-gate Counter ipInCksumErrs; 2447c478bd9Sstevel@tonic-gate /* # of complete duplicates in reassembly */ 2457c478bd9Sstevel@tonic-gate Counter ipReasmDuplicates; 2467c478bd9Sstevel@tonic-gate /* # of partial duplicates in reassembly */ 2477c478bd9Sstevel@tonic-gate Counter ipReasmPartDups; 2487c478bd9Sstevel@tonic-gate /* # of packets not forwarded due to adminstrative reasons */ 2497c478bd9Sstevel@tonic-gate Counter ipForwProhibits; 2507c478bd9Sstevel@tonic-gate /* # of UDP packets with bad UDP checksums */ 2517c478bd9Sstevel@tonic-gate Counter udpInCksumErrs; 2527c478bd9Sstevel@tonic-gate /* # of UDP packets droped due to queue overflow */ 2537c478bd9Sstevel@tonic-gate Counter udpInOverflows; 2547c478bd9Sstevel@tonic-gate /* 2557c478bd9Sstevel@tonic-gate * # of RAW IP packets (all IP protocols except UDP, TCP 2567c478bd9Sstevel@tonic-gate * and ICMP) droped due to queue overflow 2577c478bd9Sstevel@tonic-gate */ 2587c478bd9Sstevel@tonic-gate Counter rawipInOverflows; 2597c478bd9Sstevel@tonic-gate 2607c478bd9Sstevel@tonic-gate /* 2617c478bd9Sstevel@tonic-gate * Folowing are private IPSEC MIB. 2627c478bd9Sstevel@tonic-gate */ 2637c478bd9Sstevel@tonic-gate /* # of incoming packets that succeeded policy checks */ 2647c478bd9Sstevel@tonic-gate Counter ipsecInSucceeded; 2657c478bd9Sstevel@tonic-gate /* # of incoming packets that failed policy checks */ 2667c478bd9Sstevel@tonic-gate Counter ipsecInFailed; 2677c478bd9Sstevel@tonic-gate /* Compatible extensions added here */ 2687c478bd9Sstevel@tonic-gate int ipMemberEntrySize; /* Size of ip_member_t */ 2697c478bd9Sstevel@tonic-gate int ipGroupSourceEntrySize; /* Size of ip_grpsrc_t */ 2707c478bd9Sstevel@tonic-gate 271*bd670b35SErik Nordmark Counter ipInIPv6; /* # of IPv6 packets received by IPv4 and dropped */ 272*bd670b35SErik Nordmark Counter ipOutIPv6; /* No longer used */ 273*bd670b35SErik Nordmark Counter ipOutSwitchIPv6; /* No longer used */ 27445916cd2Sjpk 27545916cd2Sjpk int ipRouteAttributeSize; /* Size of mib2_ipAttributeEntry_t */ 27645916cd2Sjpk int transportMLPSize; /* Size of mib2_transportMLPEntry_t */ 277*bd670b35SErik Nordmark int ipDestEntrySize; /* Size of dest_cache_entry_t */ 2787c478bd9Sstevel@tonic-gate } mib2_ip_t; 2797c478bd9Sstevel@tonic-gate 2807c478bd9Sstevel@tonic-gate /* 2817c478bd9Sstevel@tonic-gate * ipv6IfStatsEntry OBJECT-TYPE 2827c478bd9Sstevel@tonic-gate * SYNTAX Ipv6IfStatsEntry 2837c478bd9Sstevel@tonic-gate * MAX-ACCESS not-accessible 2847c478bd9Sstevel@tonic-gate * STATUS current 2857c478bd9Sstevel@tonic-gate * DESCRIPTION 2867c478bd9Sstevel@tonic-gate * "An interface statistics entry containing objects 2877c478bd9Sstevel@tonic-gate * at a particular IPv6 interface." 2887c478bd9Sstevel@tonic-gate * AUGMENTS { ipv6IfEntry } 2897c478bd9Sstevel@tonic-gate * ::= { ipv6IfStatsTable 1 } 2907c478bd9Sstevel@tonic-gate * 2917c478bd9Sstevel@tonic-gate * Per-interface IPv6 statistics table 2927c478bd9Sstevel@tonic-gate */ 2937c478bd9Sstevel@tonic-gate 2947c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6IfStatsEntry { 2957c478bd9Sstevel@tonic-gate /* Local ifindex to identify the interface */ 2967c478bd9Sstevel@tonic-gate DeviceIndex ipv6IfIndex; 2977c478bd9Sstevel@tonic-gate 2987c478bd9Sstevel@tonic-gate /* forwarder? 1 gateway, 2 NOT gateway {ipv6MIBObjects 1} RW */ 2997c478bd9Sstevel@tonic-gate int ipv6Forwarding; 3007c478bd9Sstevel@tonic-gate /* default Hoplimit for IPv6 {ipv6MIBObjects 2} RW */ 3017c478bd9Sstevel@tonic-gate int ipv6DefaultHopLimit; 3027c478bd9Sstevel@tonic-gate 3037c478bd9Sstevel@tonic-gate int ipv6IfStatsEntrySize; 3047c478bd9Sstevel@tonic-gate int ipv6AddrEntrySize; 3057c478bd9Sstevel@tonic-gate int ipv6RouteEntrySize; 3067c478bd9Sstevel@tonic-gate int ipv6NetToMediaEntrySize; 3077c478bd9Sstevel@tonic-gate int ipv6MemberEntrySize; /* Size of ipv6_member_t */ 3087c478bd9Sstevel@tonic-gate int ipv6GroupSourceEntrySize; /* Size of ipv6_grpsrc_t */ 3097c478bd9Sstevel@tonic-gate 3107c478bd9Sstevel@tonic-gate /* # input datagrams (incl errors) { ipv6IfStatsEntry 1 } */ 3117c478bd9Sstevel@tonic-gate Counter ipv6InReceives; 3127c478bd9Sstevel@tonic-gate /* # errors in IPv6 headers and options { ipv6IfStatsEntry 2 } */ 3137c478bd9Sstevel@tonic-gate Counter ipv6InHdrErrors; 3147c478bd9Sstevel@tonic-gate /* # exceeds outgoing link MTU { ipv6IfStatsEntry 3 } */ 3157c478bd9Sstevel@tonic-gate Counter ipv6InTooBigErrors; 3167c478bd9Sstevel@tonic-gate /* # discarded due to no route to dest { ipv6IfStatsEntry 4 } */ 3177c478bd9Sstevel@tonic-gate Counter ipv6InNoRoutes; 3187c478bd9Sstevel@tonic-gate /* # invalid or unsupported addresses { ipv6IfStatsEntry 5 } */ 3197c478bd9Sstevel@tonic-gate Counter ipv6InAddrErrors; 3207c478bd9Sstevel@tonic-gate /* # unknown next header { ipv6IfStatsEntry 6 } */ 3217c478bd9Sstevel@tonic-gate Counter ipv6InUnknownProtos; 3227c478bd9Sstevel@tonic-gate /* # too short packets { ipv6IfStatsEntry 7 } */ 3237c478bd9Sstevel@tonic-gate Counter ipv6InTruncatedPkts; 3247c478bd9Sstevel@tonic-gate /* # discarded e.g. due to no buffers { ipv6IfStatsEntry 8 } */ 3257c478bd9Sstevel@tonic-gate Counter ipv6InDiscards; 3267c478bd9Sstevel@tonic-gate /* # delivered to upper layer protocols { ipv6IfStatsEntry 9 } */ 3277c478bd9Sstevel@tonic-gate Counter ipv6InDelivers; 3287c478bd9Sstevel@tonic-gate /* # forwarded out interface { ipv6IfStatsEntry 10 } */ 3297c478bd9Sstevel@tonic-gate Counter ipv6OutForwDatagrams; 3307c478bd9Sstevel@tonic-gate /* # originated out interface { ipv6IfStatsEntry 11 } */ 3317c478bd9Sstevel@tonic-gate Counter ipv6OutRequests; 3327c478bd9Sstevel@tonic-gate /* # discarded e.g. due to no buffers { ipv6IfStatsEntry 12 } */ 3337c478bd9Sstevel@tonic-gate Counter ipv6OutDiscards; 3347c478bd9Sstevel@tonic-gate /* # sucessfully fragmented packets { ipv6IfStatsEntry 13 } */ 3357c478bd9Sstevel@tonic-gate Counter ipv6OutFragOKs; 3367c478bd9Sstevel@tonic-gate /* # fragmentation failed { ipv6IfStatsEntry 14 } */ 3377c478bd9Sstevel@tonic-gate Counter ipv6OutFragFails; 3387c478bd9Sstevel@tonic-gate /* # fragments created { ipv6IfStatsEntry 15 } */ 3397c478bd9Sstevel@tonic-gate Counter ipv6OutFragCreates; 3407c478bd9Sstevel@tonic-gate /* # fragments to reassemble { ipv6IfStatsEntry 16 } */ 3417c478bd9Sstevel@tonic-gate Counter ipv6ReasmReqds; 3427c478bd9Sstevel@tonic-gate /* # packets after reassembly { ipv6IfStatsEntry 17 } */ 3437c478bd9Sstevel@tonic-gate Counter ipv6ReasmOKs; 3447c478bd9Sstevel@tonic-gate /* # reassembly failed { ipv6IfStatsEntry 18 } */ 3457c478bd9Sstevel@tonic-gate Counter ipv6ReasmFails; 3467c478bd9Sstevel@tonic-gate /* # received multicast packets { ipv6IfStatsEntry 19 } */ 3477c478bd9Sstevel@tonic-gate Counter ipv6InMcastPkts; 3487c478bd9Sstevel@tonic-gate /* # transmitted multicast packets { ipv6IfStatsEntry 20 } */ 3497c478bd9Sstevel@tonic-gate Counter ipv6OutMcastPkts; 3507c478bd9Sstevel@tonic-gate /* 3517c478bd9Sstevel@tonic-gate * In addition to defined MIBs 3527c478bd9Sstevel@tonic-gate */ 3537c478bd9Sstevel@tonic-gate /* # discarded due to no route to dest */ 3547c478bd9Sstevel@tonic-gate Counter ipv6OutNoRoutes; 3557c478bd9Sstevel@tonic-gate /* # of complete duplicates in reassembly */ 3567c478bd9Sstevel@tonic-gate Counter ipv6ReasmDuplicates; 3577c478bd9Sstevel@tonic-gate /* # of partial duplicates in reassembly */ 3587c478bd9Sstevel@tonic-gate Counter ipv6ReasmPartDups; 3597c478bd9Sstevel@tonic-gate /* # of packets not forwarded due to adminstrative reasons */ 3607c478bd9Sstevel@tonic-gate Counter ipv6ForwProhibits; 3617c478bd9Sstevel@tonic-gate /* # of UDP packets with bad UDP checksums */ 3627c478bd9Sstevel@tonic-gate Counter udpInCksumErrs; 3637c478bd9Sstevel@tonic-gate /* # of UDP packets droped due to queue overflow */ 3647c478bd9Sstevel@tonic-gate Counter udpInOverflows; 3657c478bd9Sstevel@tonic-gate /* 3667c478bd9Sstevel@tonic-gate * # of RAW IPv6 packets (all IPv6 protocols except UDP, TCP 3677c478bd9Sstevel@tonic-gate * and ICMPv6) droped due to queue overflow 3687c478bd9Sstevel@tonic-gate */ 3697c478bd9Sstevel@tonic-gate Counter rawipInOverflows; 3707c478bd9Sstevel@tonic-gate 3717c478bd9Sstevel@tonic-gate /* # of IPv4 packets received by IPv6 and dropped */ 3727c478bd9Sstevel@tonic-gate Counter ipv6InIPv4; 3737c478bd9Sstevel@tonic-gate /* # of IPv4 packets transmitted by ip_wput_wput */ 3747c478bd9Sstevel@tonic-gate Counter ipv6OutIPv4; 3757c478bd9Sstevel@tonic-gate /* # of times ip_wput_v6 has switched to become ip_wput */ 3767c478bd9Sstevel@tonic-gate Counter ipv6OutSwitchIPv4; 3777c478bd9Sstevel@tonic-gate } mib2_ipv6IfStatsEntry_t; 3787c478bd9Sstevel@tonic-gate 3797c478bd9Sstevel@tonic-gate /* 3803173664eSapersson * Per interface IP statistics, both v4 and v6. 3813173664eSapersson * 3823173664eSapersson * Some applications expect to get mib2_ipv6IfStatsEntry_t structs back when 3833173664eSapersson * making a request. To ensure backwards compatability, the first 3843173664eSapersson * sizeof(mib2_ipv6IfStatsEntry_t) bytes of the structure is identical to 3853173664eSapersson * mib2_ipv6IfStatsEntry_t. This should work as long the application is 3863173664eSapersson * written correctly (i.e., using ipv6IfStatsEntrySize to get the size of 3873173664eSapersson * the struct) 3883173664eSapersson * 3893173664eSapersson * RFC4293 introduces several new counters, as well as defining 64-bit 3903173664eSapersson * versions of existing counters. For a new counters, if they have both 32- 3913173664eSapersson * and 64-bit versions, then we only added the latter. However, for already 3923173664eSapersson * existing counters, we have added the 64-bit versions without removing the 3933173664eSapersson * old (32-bit) ones. The 64- and 32-bit counters will only be synchronized 3943173664eSapersson * when the structure contains IPv6 statistics, which is done to ensure 3953173664eSapersson * backwards compatibility. 3963173664eSapersson */ 3973173664eSapersson 3983173664eSapersson /* The following are defined in RFC 4001 and are used for ipIfStatsIPVersion */ 3993173664eSapersson #define MIB2_INETADDRESSTYPE_unknown 0 4003173664eSapersson #define MIB2_INETADDRESSTYPE_ipv4 1 4013173664eSapersson #define MIB2_INETADDRESSTYPE_ipv6 2 4023173664eSapersson 4033173664eSapersson /* 4043173664eSapersson * On amd64, the alignment requirements for long long's is different for 4053173664eSapersson * 32 and 64 bits. If we have a struct containing long long's that is being 4063173664eSapersson * passed between a 64-bit kernel to a 32-bit application, then it is very 4073173664eSapersson * likely that the size of the struct will differ due to padding. Therefore, we 4083173664eSapersson * pack the data to ensure that the struct size is the same for 32- and 4093173664eSapersson * 64-bits. 4103173664eSapersson */ 4113173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 4123173664eSapersson #pragma pack(4) 4133173664eSapersson #endif 4143173664eSapersson 4153173664eSapersson typedef struct mib2_ipIfStatsEntry { 4163173664eSapersson 4173173664eSapersson /* Local ifindex to identify the interface */ 4183173664eSapersson DeviceIndex ipIfStatsIfIndex; 4193173664eSapersson 4203173664eSapersson /* forwarder? 1 gateway, 2 NOT gateway { ipv6MIBObjects 1} RW */ 4213173664eSapersson int ipIfStatsForwarding; 4223173664eSapersson /* default Hoplimit for IPv6 { ipv6MIBObjects 2} RW */ 4233173664eSapersson int ipIfStatsDefaultHopLimit; 4243173664eSapersson #define ipIfStatsDefaultTTL ipIfStatsDefaultHopLimit 4253173664eSapersson 4263173664eSapersson int ipIfStatsEntrySize; 4273173664eSapersson int ipIfStatsAddrEntrySize; 4283173664eSapersson int ipIfStatsRouteEntrySize; 4293173664eSapersson int ipIfStatsNetToMediaEntrySize; 4303173664eSapersson int ipIfStatsMemberEntrySize; 4313173664eSapersson int ipIfStatsGroupSourceEntrySize; 4323173664eSapersson 4333173664eSapersson /* # input datagrams (incl errors) { ipIfStatsEntry 3 } */ 4343173664eSapersson Counter ipIfStatsInReceives; 4353173664eSapersson /* # errors in IP headers and options { ipIfStatsEntry 7 } */ 4363173664eSapersson Counter ipIfStatsInHdrErrors; 4373173664eSapersson /* # exceeds outgoing link MTU(v6 only) { ipv6IfStatsEntry 3 } */ 4383173664eSapersson Counter ipIfStatsInTooBigErrors; 4393173664eSapersson /* # discarded due to no route to dest { ipIfStatsEntry 8 } */ 4403173664eSapersson Counter ipIfStatsInNoRoutes; 4413173664eSapersson /* # invalid or unsupported addresses { ipIfStatsEntry 9 } */ 4423173664eSapersson Counter ipIfStatsInAddrErrors; 4433173664eSapersson /* # unknown next header { ipIfStatsEntry 10 } */ 4443173664eSapersson Counter ipIfStatsInUnknownProtos; 4453173664eSapersson /* # too short packets { ipIfStatsEntry 11 } */ 4463173664eSapersson Counter ipIfStatsInTruncatedPkts; 4473173664eSapersson /* # discarded e.g. due to no buffers { ipIfStatsEntry 17 } */ 4483173664eSapersson Counter ipIfStatsInDiscards; 4493173664eSapersson /* # delivered to upper layer protocols { ipIfStatsEntry 18 } */ 4503173664eSapersson Counter ipIfStatsInDelivers; 4513173664eSapersson /* # forwarded out interface { ipIfStatsEntry 23 } */ 4523173664eSapersson Counter ipIfStatsOutForwDatagrams; 4533173664eSapersson /* # originated out interface { ipIfStatsEntry 20 } */ 4543173664eSapersson Counter ipIfStatsOutRequests; 4553173664eSapersson /* # discarded e.g. due to no buffers { ipIfStatsEntry 25 } */ 4563173664eSapersson Counter ipIfStatsOutDiscards; 4573173664eSapersson /* # sucessfully fragmented packets { ipIfStatsEntry 27 } */ 4583173664eSapersson Counter ipIfStatsOutFragOKs; 4593173664eSapersson /* # fragmentation failed { ipIfStatsEntry 28 } */ 4603173664eSapersson Counter ipIfStatsOutFragFails; 4613173664eSapersson /* # fragments created { ipIfStatsEntry 29 } */ 4623173664eSapersson Counter ipIfStatsOutFragCreates; 4633173664eSapersson /* # fragments to reassemble { ipIfStatsEntry 14 } */ 4643173664eSapersson Counter ipIfStatsReasmReqds; 4653173664eSapersson /* # packets after reassembly { ipIfStatsEntry 15 } */ 4663173664eSapersson Counter ipIfStatsReasmOKs; 4673173664eSapersson /* # reassembly failed { ipIfStatsEntry 16 } */ 4683173664eSapersson Counter ipIfStatsReasmFails; 4693173664eSapersson /* # received multicast packets { ipIfStatsEntry 34 } */ 4703173664eSapersson Counter ipIfStatsInMcastPkts; 4713173664eSapersson /* # transmitted multicast packets { ipIfStatsEntry 38 } */ 4723173664eSapersson Counter ipIfStatsOutMcastPkts; 4733173664eSapersson 4743173664eSapersson /* 4753173664eSapersson * In addition to defined MIBs 4763173664eSapersson */ 4773173664eSapersson 4783173664eSapersson /* # discarded due to no route to dest { ipSystemStatsEntry 22 } */ 4793173664eSapersson Counter ipIfStatsOutNoRoutes; 4803173664eSapersson /* # of complete duplicates in reassembly */ 4813173664eSapersson Counter ipIfStatsReasmDuplicates; 4823173664eSapersson /* # of partial duplicates in reassembly */ 4833173664eSapersson Counter ipIfStatsReasmPartDups; 4843173664eSapersson /* # of packets not forwarded due to adminstrative reasons */ 4853173664eSapersson Counter ipIfStatsForwProhibits; 4863173664eSapersson /* # of UDP packets with bad UDP checksums */ 4873173664eSapersson Counter udpInCksumErrs; 4883173664eSapersson #define udpIfStatsInCksumErrs udpInCksumErrs 4893173664eSapersson /* # of UDP packets droped due to queue overflow */ 4903173664eSapersson Counter udpInOverflows; 4913173664eSapersson #define udpIfStatsInOverflows udpInOverflows 4923173664eSapersson /* 4933173664eSapersson * # of RAW IP packets (all IP protocols except UDP, TCP 4943173664eSapersson * and ICMP) droped due to queue overflow 4953173664eSapersson */ 4963173664eSapersson Counter rawipInOverflows; 4973173664eSapersson #define rawipIfStatsInOverflows rawipInOverflows 4983173664eSapersson 4993173664eSapersson /* 5003173664eSapersson * # of IP packets received with the wrong version (i.e., not equal 5013173664eSapersson * to ipIfStatsIPVersion) and that were dropped. 5023173664eSapersson */ 5033173664eSapersson Counter ipIfStatsInWrongIPVersion; 5043173664eSapersson /* 505*bd670b35SErik Nordmark * This counter is no longer used 5063173664eSapersson */ 5073173664eSapersson Counter ipIfStatsOutWrongIPVersion; 5083173664eSapersson /* 509*bd670b35SErik Nordmark * This counter is no longer used 5103173664eSapersson */ 5113173664eSapersson Counter ipIfStatsOutSwitchIPVersion; 5123173664eSapersson 5133173664eSapersson /* 5143173664eSapersson * Fields defined in RFC 4293 5153173664eSapersson */ 5163173664eSapersson 5173173664eSapersson /* ip version { ipIfStatsEntry 1 } */ 5183173664eSapersson int ipIfStatsIPVersion; 5193173664eSapersson /* # input datagrams (incl errors) { ipIfStatsEntry 4 } */ 5203173664eSapersson Counter64 ipIfStatsHCInReceives; 5213173664eSapersson /* # input octets (incl errors) { ipIfStatsEntry 6 } */ 5223173664eSapersson Counter64 ipIfStatsHCInOctets; 5233173664eSapersson /* 5243173664eSapersson * { ipIfStatsEntry 13 } 5253173664eSapersson * # input datagrams for which a forwarding attempt was made 5263173664eSapersson */ 5273173664eSapersson Counter64 ipIfStatsHCInForwDatagrams; 5283173664eSapersson /* # delivered to upper layer protocols { ipIfStatsEntry 19 } */ 5293173664eSapersson Counter64 ipIfStatsHCInDelivers; 5303173664eSapersson /* # originated out interface { ipIfStatsEntry 21 } */ 5313173664eSapersson Counter64 ipIfStatsHCOutRequests; 5323173664eSapersson /* # forwarded out interface { ipIfStatsEntry 23 } */ 5333173664eSapersson Counter64 ipIfStatsHCOutForwDatagrams; 5343173664eSapersson /* # dg's requiring fragmentation { ipIfStatsEntry 26 } */ 5353173664eSapersson Counter ipIfStatsOutFragReqds; 5363173664eSapersson /* # output datagrams { ipIfStatsEntry 31 } */ 5373173664eSapersson Counter64 ipIfStatsHCOutTransmits; 5383173664eSapersson /* # output octets { ipIfStatsEntry 33 } */ 5393173664eSapersson Counter64 ipIfStatsHCOutOctets; 5403173664eSapersson /* # received multicast datagrams { ipIfStatsEntry 35 } */ 5413173664eSapersson Counter64 ipIfStatsHCInMcastPkts; 5423173664eSapersson /* # received multicast octets { ipIfStatsEntry 37 } */ 5433173664eSapersson Counter64 ipIfStatsHCInMcastOctets; 5443173664eSapersson /* # transmitted multicast datagrams { ipIfStatsEntry 39 } */ 5453173664eSapersson Counter64 ipIfStatsHCOutMcastPkts; 5463173664eSapersson /* # transmitted multicast octets { ipIfStatsEntry 41 } */ 5473173664eSapersson Counter64 ipIfStatsHCOutMcastOctets; 5483173664eSapersson /* # received broadcast datagrams { ipIfStatsEntry 43 } */ 5493173664eSapersson Counter64 ipIfStatsHCInBcastPkts; 5503173664eSapersson /* # transmitted broadcast datagrams { ipIfStatsEntry 45 } */ 5513173664eSapersson Counter64 ipIfStatsHCOutBcastPkts; 5523173664eSapersson 5533173664eSapersson /* 5543173664eSapersson * Fields defined in mib2_ip_t 5553173664eSapersson */ 5563173664eSapersson 5573173664eSapersson /* # of incoming packets that succeeded policy checks */ 5583173664eSapersson Counter ipsecInSucceeded; 5593173664eSapersson #define ipsecIfStatsInSucceeded ipsecInSucceeded 5603173664eSapersson /* # of incoming packets that failed policy checks */ 5613173664eSapersson Counter ipsecInFailed; 5623173664eSapersson #define ipsecIfStatsInFailed ipsecInFailed 5633173664eSapersson /* # of bad IP header checksums */ 5643173664eSapersson Counter ipInCksumErrs; 5653173664eSapersson #define ipIfStatsInCksumErrs ipInCksumErrs 5663173664eSapersson /* total # of segments recv'd with error { tcp 14 } */ 5673173664eSapersson Counter tcpInErrs; 5683173664eSapersson #define tcpIfStatsInErrs tcpInErrs 5693173664eSapersson /* # of recv'd dg's not deliverable (no appl.) { udp 2 } */ 5703173664eSapersson Counter udpNoPorts; 5713173664eSapersson #define udpIfStatsNoPorts udpNoPorts 5723173664eSapersson } mib2_ipIfStatsEntry_t; 5733173664eSapersson 5743173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 5753173664eSapersson #pragma pack() 5763173664eSapersson #endif 5773173664eSapersson 5783173664eSapersson /* 5797c478bd9Sstevel@tonic-gate * The IP address table contains this entity's IP addressing information. 5807c478bd9Sstevel@tonic-gate * 5817c478bd9Sstevel@tonic-gate * ipAddrTable OBJECT-TYPE 5827c478bd9Sstevel@tonic-gate * SYNTAX SEQUENCE OF IpAddrEntry 5837c478bd9Sstevel@tonic-gate * ACCESS not-accessible 5847c478bd9Sstevel@tonic-gate * STATUS mandatory 5857c478bd9Sstevel@tonic-gate * DESCRIPTION 5867c478bd9Sstevel@tonic-gate * "The table of addressing information relevant to 5877c478bd9Sstevel@tonic-gate * this entity's IP addresses." 5887c478bd9Sstevel@tonic-gate * ::= { ip 20 } 5897c478bd9Sstevel@tonic-gate */ 5907c478bd9Sstevel@tonic-gate 5917c478bd9Sstevel@tonic-gate typedef struct mib2_ipAddrEntry { 5927c478bd9Sstevel@tonic-gate /* IP address of this entry {ipAddrEntry 1} */ 5937c478bd9Sstevel@tonic-gate IpAddress ipAdEntAddr; 5947c478bd9Sstevel@tonic-gate /* Unique interface index {ipAddrEntry 2} */ 5957c478bd9Sstevel@tonic-gate DeviceName ipAdEntIfIndex; 5967c478bd9Sstevel@tonic-gate /* Subnet mask for this IP addr {ipAddrEntry 3} */ 5977c478bd9Sstevel@tonic-gate IpAddress ipAdEntNetMask; 5987c478bd9Sstevel@tonic-gate /* 2^lsb of IP broadcast addr {ipAddrEntry 4} */ 5997c478bd9Sstevel@tonic-gate int ipAdEntBcastAddr; 6007c478bd9Sstevel@tonic-gate /* max size for dg reassembly {ipAddrEntry 5} */ 6017c478bd9Sstevel@tonic-gate int ipAdEntReasmMaxSize; 6027c478bd9Sstevel@tonic-gate /* additional ipif_t fields */ 6037c478bd9Sstevel@tonic-gate struct ipAdEntInfo_s { 6047c478bd9Sstevel@tonic-gate Gauge ae_mtu; 6057c478bd9Sstevel@tonic-gate /* BSD if metric */ 6067c478bd9Sstevel@tonic-gate int ae_metric; 6077c478bd9Sstevel@tonic-gate /* ipif broadcast addr. relation to above?? */ 6087c478bd9Sstevel@tonic-gate IpAddress ae_broadcast_addr; 6097c478bd9Sstevel@tonic-gate /* point-point dest addr */ 6107c478bd9Sstevel@tonic-gate IpAddress ae_pp_dst_addr; 6117c478bd9Sstevel@tonic-gate int ae_flags; /* IFF_* flags in if.h */ 6127c478bd9Sstevel@tonic-gate Counter ae_ibcnt; /* Inbound packets */ 6137c478bd9Sstevel@tonic-gate Counter ae_obcnt; /* Outbound packets */ 6147c478bd9Sstevel@tonic-gate Counter ae_focnt; /* Forwarded packets */ 6157c478bd9Sstevel@tonic-gate IpAddress ae_subnet; /* Subnet prefix */ 6167c478bd9Sstevel@tonic-gate int ae_subnet_len; /* Subnet prefix length */ 6177c478bd9Sstevel@tonic-gate IpAddress ae_src_addr; /* Source address */ 6187c478bd9Sstevel@tonic-gate } ipAdEntInfo; 6193173664eSapersson uint32_t ipAdEntRetransmitTime; /* ipInterfaceRetransmitTime */ 6207c478bd9Sstevel@tonic-gate } mib2_ipAddrEntry_t; 6217c478bd9Sstevel@tonic-gate 6227c478bd9Sstevel@tonic-gate /* 6237c478bd9Sstevel@tonic-gate * ipv6AddrTable OBJECT-TYPE 6247c478bd9Sstevel@tonic-gate * SYNTAX SEQUENCE OF Ipv6AddrEntry 6257c478bd9Sstevel@tonic-gate * MAX-ACCESS not-accessible 6267c478bd9Sstevel@tonic-gate * STATUS current 6277c478bd9Sstevel@tonic-gate * DESCRIPTION 6287c478bd9Sstevel@tonic-gate * "The table of addressing information relevant to 6297c478bd9Sstevel@tonic-gate * this node's interface addresses." 6307c478bd9Sstevel@tonic-gate * ::= { ipv6MIBObjects 8 } 6317c478bd9Sstevel@tonic-gate */ 6327c478bd9Sstevel@tonic-gate 6337c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6AddrEntry { 6347c478bd9Sstevel@tonic-gate /* Unique interface index { Part of INDEX } */ 6357c478bd9Sstevel@tonic-gate DeviceName ipv6AddrIfIndex; 6367c478bd9Sstevel@tonic-gate 6377c478bd9Sstevel@tonic-gate /* IPv6 address of this entry { ipv6AddrEntry 1 } */ 6387c478bd9Sstevel@tonic-gate Ip6Address ipv6AddrAddress; 6397c478bd9Sstevel@tonic-gate /* Prefix length { ipv6AddrEntry 2 } */ 6407c478bd9Sstevel@tonic-gate uint_t ipv6AddrPfxLength; 6417c478bd9Sstevel@tonic-gate /* Type: stateless(1), stateful(2), unknown(3) { ipv6AddrEntry 3 } */ 6427c478bd9Sstevel@tonic-gate uint_t ipv6AddrType; 6437c478bd9Sstevel@tonic-gate /* Anycast: true(1), false(2) { ipv6AddrEntry 4 } */ 6447c478bd9Sstevel@tonic-gate uint_t ipv6AddrAnycastFlag; 6457c478bd9Sstevel@tonic-gate /* 6467c478bd9Sstevel@tonic-gate * Address status: preferred(1), deprecated(2), invalid(3), 6477c478bd9Sstevel@tonic-gate * inaccessible(4), unknown(5) { ipv6AddrEntry 5 } 6487c478bd9Sstevel@tonic-gate */ 6497c478bd9Sstevel@tonic-gate uint_t ipv6AddrStatus; 6507c478bd9Sstevel@tonic-gate struct ipv6AddrInfo_s { 6517c478bd9Sstevel@tonic-gate Gauge ae_mtu; 6527c478bd9Sstevel@tonic-gate /* BSD if metric */ 6537c478bd9Sstevel@tonic-gate int ae_metric; 6547c478bd9Sstevel@tonic-gate /* point-point dest addr */ 6557c478bd9Sstevel@tonic-gate Ip6Address ae_pp_dst_addr; 6567c478bd9Sstevel@tonic-gate int ae_flags; /* IFF_* flags in if.h */ 6577c478bd9Sstevel@tonic-gate Counter ae_ibcnt; /* Inbound packets */ 6587c478bd9Sstevel@tonic-gate Counter ae_obcnt; /* Outbound packets */ 6597c478bd9Sstevel@tonic-gate Counter ae_focnt; /* Forwarded packets */ 6607c478bd9Sstevel@tonic-gate Ip6Address ae_subnet; /* Subnet prefix */ 6617c478bd9Sstevel@tonic-gate int ae_subnet_len; /* Subnet prefix length */ 6627c478bd9Sstevel@tonic-gate Ip6Address ae_src_addr; /* Source address */ 6637c478bd9Sstevel@tonic-gate } ipv6AddrInfo; 6643173664eSapersson uint32_t ipv6AddrReasmMaxSize; /* InterfaceReasmMaxSize */ 6653173664eSapersson Ip6Address ipv6AddrIdentifier; /* InterfaceIdentifier */ 6663173664eSapersson uint32_t ipv6AddrIdentifierLen; 6673173664eSapersson uint32_t ipv6AddrReachableTime; /* InterfaceReachableTime */ 6683173664eSapersson uint32_t ipv6AddrRetransmitTime; /* InterfaceRetransmitTime */ 6697c478bd9Sstevel@tonic-gate } mib2_ipv6AddrEntry_t; 6707c478bd9Sstevel@tonic-gate 6717c478bd9Sstevel@tonic-gate /* 6727c478bd9Sstevel@tonic-gate * The IP routing table contains an entry for each route presently known to 6737c478bd9Sstevel@tonic-gate * this entity. (for IPv4 routes) 6747c478bd9Sstevel@tonic-gate * 6757c478bd9Sstevel@tonic-gate * ipRouteTable OBJECT-TYPE 6767c478bd9Sstevel@tonic-gate * SYNTAX SEQUENCE OF IpRouteEntry 6777c478bd9Sstevel@tonic-gate * ACCESS not-accessible 6787c478bd9Sstevel@tonic-gate * STATUS mandatory 6797c478bd9Sstevel@tonic-gate * DESCRIPTION 6807c478bd9Sstevel@tonic-gate * "This entity's IP Routing table." 6817c478bd9Sstevel@tonic-gate * ::= { ip 21 } 6827c478bd9Sstevel@tonic-gate */ 6837c478bd9Sstevel@tonic-gate 6847c478bd9Sstevel@tonic-gate typedef struct mib2_ipRouteEntry { 6857c478bd9Sstevel@tonic-gate /* dest ip addr for this route {ipRouteEntry 1 } RW */ 6867c478bd9Sstevel@tonic-gate IpAddress ipRouteDest; 6877c478bd9Sstevel@tonic-gate /* unique interface index for this hop {ipRouteEntry 2 } RW */ 6887c478bd9Sstevel@tonic-gate DeviceName ipRouteIfIndex; 6897c478bd9Sstevel@tonic-gate /* primary route metric {ipRouteEntry 3 } RW */ 6907c478bd9Sstevel@tonic-gate int ipRouteMetric1; 6917c478bd9Sstevel@tonic-gate /* alternate route metric {ipRouteEntry 4 } RW */ 6927c478bd9Sstevel@tonic-gate int ipRouteMetric2; 6937c478bd9Sstevel@tonic-gate /* alternate route metric {ipRouteEntry 5 } RW */ 6947c478bd9Sstevel@tonic-gate int ipRouteMetric3; 6957c478bd9Sstevel@tonic-gate /* alternate route metric {ipRouteEntry 6 } RW */ 6967c478bd9Sstevel@tonic-gate int ipRouteMetric4; 6977c478bd9Sstevel@tonic-gate /* ip addr of next hop on this route {ipRouteEntry 7 } RW */ 6987c478bd9Sstevel@tonic-gate IpAddress ipRouteNextHop; 6997c478bd9Sstevel@tonic-gate /* other(1), inval(2), dir(3), indir(4) {ipRouteEntry 8 } RW */ 7007c478bd9Sstevel@tonic-gate int ipRouteType; 7017c478bd9Sstevel@tonic-gate /* mechanism by which route was learned {ipRouteEntry 9 } */ 7027c478bd9Sstevel@tonic-gate int ipRouteProto; 7037c478bd9Sstevel@tonic-gate /* sec's since last update of route {ipRouteEntry 10} RW */ 7047c478bd9Sstevel@tonic-gate int ipRouteAge; 7057c478bd9Sstevel@tonic-gate /* {ipRouteEntry 11} RW */ 7067c478bd9Sstevel@tonic-gate IpAddress ipRouteMask; 7077c478bd9Sstevel@tonic-gate /* alternate route metric {ipRouteEntry 12} RW */ 7087c478bd9Sstevel@tonic-gate int ipRouteMetric5; 7097c478bd9Sstevel@tonic-gate /* additional info from ire's {ipRouteEntry 13 } */ 7107c478bd9Sstevel@tonic-gate struct ipRouteInfo_s { 7117c478bd9Sstevel@tonic-gate Gauge re_max_frag; 7127c478bd9Sstevel@tonic-gate Gauge re_rtt; 7137c478bd9Sstevel@tonic-gate Counter re_ref; 7147c478bd9Sstevel@tonic-gate int re_frag_flag; 7157c478bd9Sstevel@tonic-gate IpAddress re_src_addr; 7167c478bd9Sstevel@tonic-gate int re_ire_type; 7177c478bd9Sstevel@tonic-gate Counter re_obpkt; 7187c478bd9Sstevel@tonic-gate Counter re_ibpkt; 7197c478bd9Sstevel@tonic-gate int re_flags; 7207c478bd9Sstevel@tonic-gate } ipRouteInfo; 7217c478bd9Sstevel@tonic-gate } mib2_ipRouteEntry_t; 7227c478bd9Sstevel@tonic-gate 7237c478bd9Sstevel@tonic-gate /* 7247c478bd9Sstevel@tonic-gate * The IPv6 routing table contains an entry for each route presently known to 7257c478bd9Sstevel@tonic-gate * this entity. 7267c478bd9Sstevel@tonic-gate * 7277c478bd9Sstevel@tonic-gate * ipv6RouteTable OBJECT-TYPE 7287c478bd9Sstevel@tonic-gate * SYNTAX SEQUENCE OF IpRouteEntry 7297c478bd9Sstevel@tonic-gate * ACCESS not-accessible 7307c478bd9Sstevel@tonic-gate * STATUS current 7317c478bd9Sstevel@tonic-gate * DESCRIPTION 7327c478bd9Sstevel@tonic-gate * "IPv6 Routing table. This table contains 7337c478bd9Sstevel@tonic-gate * an entry for each valid IPv6 unicast route 7347c478bd9Sstevel@tonic-gate * that can be used for packet forwarding 7357c478bd9Sstevel@tonic-gate * determination." 7367c478bd9Sstevel@tonic-gate * ::= { ipv6MIBObjects 11 } 7377c478bd9Sstevel@tonic-gate */ 7387c478bd9Sstevel@tonic-gate 7397c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6RouteEntry { 7407c478bd9Sstevel@tonic-gate /* dest ip addr for this route { ipv6RouteEntry 1 } */ 7417c478bd9Sstevel@tonic-gate Ip6Address ipv6RouteDest; 7427c478bd9Sstevel@tonic-gate /* prefix length { ipv6RouteEntry 2 } */ 7437c478bd9Sstevel@tonic-gate int ipv6RoutePfxLength; 7447c478bd9Sstevel@tonic-gate /* unique route index { ipv6RouteEntry 3 } */ 7457c478bd9Sstevel@tonic-gate unsigned ipv6RouteIndex; 7467c478bd9Sstevel@tonic-gate /* unique interface index for this hop { ipv6RouteEntry 4 } */ 7477c478bd9Sstevel@tonic-gate DeviceName ipv6RouteIfIndex; 7487c478bd9Sstevel@tonic-gate /* IPv6 addr of next hop on this route { ipv6RouteEntry 5 } */ 7497c478bd9Sstevel@tonic-gate Ip6Address ipv6RouteNextHop; 7507c478bd9Sstevel@tonic-gate /* other(1), discard(2), local(3), remote(4) */ 7517c478bd9Sstevel@tonic-gate /* { ipv6RouteEntry 6 } */ 7527c478bd9Sstevel@tonic-gate int ipv6RouteType; 7537c478bd9Sstevel@tonic-gate /* mechanism by which route was learned { ipv6RouteEntry 7 } */ 7547c478bd9Sstevel@tonic-gate /* 7557c478bd9Sstevel@tonic-gate * other(1), local(2), netmgmt(3), ndisc(4), rip(5), ospf(6), 7567c478bd9Sstevel@tonic-gate * bgp(7), idrp(8), igrp(9) 7577c478bd9Sstevel@tonic-gate */ 7587c478bd9Sstevel@tonic-gate int ipv6RouteProtocol; 7597c478bd9Sstevel@tonic-gate /* policy hook or traffic class { ipv6RouteEntry 8 } */ 7607c478bd9Sstevel@tonic-gate unsigned ipv6RoutePolicy; 7617c478bd9Sstevel@tonic-gate /* sec's since last update of route { ipv6RouteEntry 9} */ 7627c478bd9Sstevel@tonic-gate int ipv6RouteAge; 7637c478bd9Sstevel@tonic-gate /* Routing domain ID of the next hop { ipv6RouteEntry 10 } */ 7647c478bd9Sstevel@tonic-gate unsigned ipv6RouteNextHopRDI; 7657c478bd9Sstevel@tonic-gate /* route metric { ipv6RouteEntry 11 } */ 7667c478bd9Sstevel@tonic-gate unsigned ipv6RouteMetric; 7677c478bd9Sstevel@tonic-gate /* preference (impl specific) { ipv6RouteEntry 12 } */ 7687c478bd9Sstevel@tonic-gate unsigned ipv6RouteWeight; 7697c478bd9Sstevel@tonic-gate /* additional info from ire's { } */ 7707c478bd9Sstevel@tonic-gate struct ipv6RouteInfo_s { 7717c478bd9Sstevel@tonic-gate Gauge re_max_frag; 7727c478bd9Sstevel@tonic-gate Gauge re_rtt; 7737c478bd9Sstevel@tonic-gate Counter re_ref; 7747c478bd9Sstevel@tonic-gate int re_frag_flag; 7757c478bd9Sstevel@tonic-gate Ip6Address re_src_addr; 7767c478bd9Sstevel@tonic-gate int re_ire_type; 7777c478bd9Sstevel@tonic-gate Counter re_obpkt; 7787c478bd9Sstevel@tonic-gate Counter re_ibpkt; 7797c478bd9Sstevel@tonic-gate int re_flags; 7807c478bd9Sstevel@tonic-gate } ipv6RouteInfo; 7817c478bd9Sstevel@tonic-gate } mib2_ipv6RouteEntry_t; 7827c478bd9Sstevel@tonic-gate 78345916cd2Sjpk /* 78445916cd2Sjpk * The IPv4 and IPv6 routing table entries on a trusted system also have 78545916cd2Sjpk * security attributes in the form of label ranges. This experimental 78645916cd2Sjpk * interface provides information about these labels. 78745916cd2Sjpk * 78845916cd2Sjpk * Each entry in this table contains a label range and an index that refers 78945916cd2Sjpk * back to the entry in the routing table to which it applies. There may be 0, 79045916cd2Sjpk * 1, or many label ranges for each routing table entry. 79145916cd2Sjpk * 79245916cd2Sjpk * (opthdr.level is set to MIB2_IP for IPv4 entries and MIB2_IP6 for IPv6. 79345916cd2Sjpk * opthdr.name is set to EXPER_IP_GWATTR.) 79445916cd2Sjpk * 79545916cd2Sjpk * ipRouteAttributeTable OBJECT-TYPE 79645916cd2Sjpk * SYNTAX SEQUENCE OF IpAttributeEntry 79745916cd2Sjpk * ACCESS not-accessible 79845916cd2Sjpk * STATUS current 79945916cd2Sjpk * DESCRIPTION 80045916cd2Sjpk * "IPv4 routing attributes table. This table contains 80145916cd2Sjpk * an entry for each valid trusted label attached to a 80245916cd2Sjpk * route in the system." 80345916cd2Sjpk * ::= { ip 102 } 80445916cd2Sjpk * 80545916cd2Sjpk * ipv6RouteAttributeTable OBJECT-TYPE 80645916cd2Sjpk * SYNTAX SEQUENCE OF IpAttributeEntry 80745916cd2Sjpk * ACCESS not-accessible 80845916cd2Sjpk * STATUS current 80945916cd2Sjpk * DESCRIPTION 81045916cd2Sjpk * "IPv6 routing attributes table. This table contains 81145916cd2Sjpk * an entry for each valid trusted label attached to a 81245916cd2Sjpk * route in the system." 81345916cd2Sjpk * ::= { ip6 102 } 81445916cd2Sjpk */ 81545916cd2Sjpk 81645916cd2Sjpk typedef struct mib2_ipAttributeEntry { 81745916cd2Sjpk uint_t iae_routeidx; 81845916cd2Sjpk int iae_doi; 81945916cd2Sjpk brange_t iae_slrange; 82045916cd2Sjpk } mib2_ipAttributeEntry_t; 8217c478bd9Sstevel@tonic-gate 8227c478bd9Sstevel@tonic-gate /* 8237c478bd9Sstevel@tonic-gate * The IP address translation table contain the IpAddress to 8247c478bd9Sstevel@tonic-gate * `physical' address equivalences. Some interfaces do not 8257c478bd9Sstevel@tonic-gate * use translation tables for determining address 8267c478bd9Sstevel@tonic-gate * equivalences (e.g., DDN-X.25 has an algorithmic method); 8277c478bd9Sstevel@tonic-gate * if all interfaces are of this type, then the Address 8287c478bd9Sstevel@tonic-gate * Translation table is empty, i.e., has zero entries. 8297c478bd9Sstevel@tonic-gate * 8307c478bd9Sstevel@tonic-gate * ipNetToMediaTable OBJECT-TYPE 8317c478bd9Sstevel@tonic-gate * SYNTAX SEQUENCE OF IpNetToMediaEntry 8327c478bd9Sstevel@tonic-gate * ACCESS not-accessible 8337c478bd9Sstevel@tonic-gate * STATUS mandatory 8347c478bd9Sstevel@tonic-gate * DESCRIPTION 8357c478bd9Sstevel@tonic-gate * "The IP Address Translation table used for mapping 8367c478bd9Sstevel@tonic-gate * from IP addresses to physical addresses." 8377c478bd9Sstevel@tonic-gate * ::= { ip 22 } 8387c478bd9Sstevel@tonic-gate */ 8397c478bd9Sstevel@tonic-gate 8407c478bd9Sstevel@tonic-gate typedef struct mib2_ipNetToMediaEntry { 8417c478bd9Sstevel@tonic-gate /* Unique interface index { ipNetToMediaEntry 1 } RW */ 8427c478bd9Sstevel@tonic-gate DeviceName ipNetToMediaIfIndex; 8437c478bd9Sstevel@tonic-gate /* Media dependent physical addr { ipNetToMediaEntry 2 } RW */ 8447c478bd9Sstevel@tonic-gate PhysAddress ipNetToMediaPhysAddress; 8457c478bd9Sstevel@tonic-gate /* ip addr for this physical addr { ipNetToMediaEntry 3 } RW */ 8467c478bd9Sstevel@tonic-gate IpAddress ipNetToMediaNetAddress; 8477c478bd9Sstevel@tonic-gate /* other(1), inval(2), dyn(3), stat(4) { ipNetToMediaEntry 4 } RW */ 8487c478bd9Sstevel@tonic-gate int ipNetToMediaType; 8497c478bd9Sstevel@tonic-gate struct ipNetToMediaInfo_s { 8507c478bd9Sstevel@tonic-gate PhysAddress ntm_mask; /* subnet mask for entry */ 8517c478bd9Sstevel@tonic-gate int ntm_flags; /* ACE_F_* flags in arp.h */ 8527c478bd9Sstevel@tonic-gate } ipNetToMediaInfo; 8537c478bd9Sstevel@tonic-gate } mib2_ipNetToMediaEntry_t; 8547c478bd9Sstevel@tonic-gate 8557c478bd9Sstevel@tonic-gate /* 8567c478bd9Sstevel@tonic-gate * ipv6NetToMediaTable OBJECT-TYPE 8577c478bd9Sstevel@tonic-gate * SYNTAX SEQUENCE OF Ipv6NetToMediaEntry 8587c478bd9Sstevel@tonic-gate * MAX-ACCESS not-accessible 8597c478bd9Sstevel@tonic-gate * STATUS current 8607c478bd9Sstevel@tonic-gate * DESCRIPTION 8617c478bd9Sstevel@tonic-gate * "The IPv6 Address Translation table used for 8627c478bd9Sstevel@tonic-gate * mapping from IPv6 addresses to physical addresses. 8637c478bd9Sstevel@tonic-gate * 8647c478bd9Sstevel@tonic-gate * The IPv6 address translation table contain the 8657c478bd9Sstevel@tonic-gate * Ipv6Address to `physical' address equivalencies. 8667c478bd9Sstevel@tonic-gate * Some interfaces do not use translation tables 8677c478bd9Sstevel@tonic-gate * for determining address equivalencies; if all 8687c478bd9Sstevel@tonic-gate * interfaces are of this type, then the Address 8697c478bd9Sstevel@tonic-gate * Translation table is empty, i.e., has zero 8707c478bd9Sstevel@tonic-gate * entries." 8717c478bd9Sstevel@tonic-gate * ::= { ipv6MIBObjects 12 } 8727c478bd9Sstevel@tonic-gate */ 8737c478bd9Sstevel@tonic-gate 8747c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6NetToMediaEntry { 8757c478bd9Sstevel@tonic-gate /* Unique interface index { Part of INDEX } */ 8767c478bd9Sstevel@tonic-gate DeviceIndex ipv6NetToMediaIfIndex; 8777c478bd9Sstevel@tonic-gate 8787c478bd9Sstevel@tonic-gate /* ip addr for this physical addr { ipv6NetToMediaEntry 1 } */ 8797c478bd9Sstevel@tonic-gate Ip6Address ipv6NetToMediaNetAddress; 8807c478bd9Sstevel@tonic-gate /* Media dependent physical addr { ipv6NetToMediaEntry 2 } */ 8817c478bd9Sstevel@tonic-gate PhysAddress ipv6NetToMediaPhysAddress; 8827c478bd9Sstevel@tonic-gate /* 8837c478bd9Sstevel@tonic-gate * Type of mapping 8847c478bd9Sstevel@tonic-gate * other(1), dynamic(2), static(3), local(4) 8857c478bd9Sstevel@tonic-gate * { ipv6NetToMediaEntry 3 } 8867c478bd9Sstevel@tonic-gate */ 8877c478bd9Sstevel@tonic-gate int ipv6NetToMediaType; 8887c478bd9Sstevel@tonic-gate /* 8897c478bd9Sstevel@tonic-gate * NUD state 8907c478bd9Sstevel@tonic-gate * reachable(1), stale(2), delay(3), probe(4), invalid(5), unknown(6) 8917c478bd9Sstevel@tonic-gate * Note: The kernel returns ND_* states. 8927c478bd9Sstevel@tonic-gate * { ipv6NetToMediaEntry 4 } 8937c478bd9Sstevel@tonic-gate */ 8947c478bd9Sstevel@tonic-gate int ipv6NetToMediaState; 8957c478bd9Sstevel@tonic-gate /* sysUpTime last time entry was updated { ipv6NetToMediaEntry 5 } */ 8967c478bd9Sstevel@tonic-gate int ipv6NetToMediaLastUpdated; 8977c478bd9Sstevel@tonic-gate } mib2_ipv6NetToMediaEntry_t; 8987c478bd9Sstevel@tonic-gate 8997c478bd9Sstevel@tonic-gate 9007c478bd9Sstevel@tonic-gate /* 9017c478bd9Sstevel@tonic-gate * List of group members per interface 9027c478bd9Sstevel@tonic-gate */ 9037c478bd9Sstevel@tonic-gate typedef struct ip_member { 9047c478bd9Sstevel@tonic-gate /* Interface index */ 9057c478bd9Sstevel@tonic-gate DeviceName ipGroupMemberIfIndex; 9067c478bd9Sstevel@tonic-gate /* IP Multicast address */ 9077c478bd9Sstevel@tonic-gate IpAddress ipGroupMemberAddress; 9087c478bd9Sstevel@tonic-gate /* Number of member sockets */ 9097c478bd9Sstevel@tonic-gate Counter ipGroupMemberRefCnt; 9107c478bd9Sstevel@tonic-gate /* Filter mode: 1 => include, 2 => exclude */ 9117c478bd9Sstevel@tonic-gate int ipGroupMemberFilterMode; 9127c478bd9Sstevel@tonic-gate } ip_member_t; 9137c478bd9Sstevel@tonic-gate 9147c478bd9Sstevel@tonic-gate 9157c478bd9Sstevel@tonic-gate /* 9167c478bd9Sstevel@tonic-gate * List of IPv6 group members per interface 9177c478bd9Sstevel@tonic-gate */ 9187c478bd9Sstevel@tonic-gate typedef struct ipv6_member { 9197c478bd9Sstevel@tonic-gate /* Interface index */ 9207c478bd9Sstevel@tonic-gate DeviceIndex ipv6GroupMemberIfIndex; 9217c478bd9Sstevel@tonic-gate /* IP Multicast address */ 9227c478bd9Sstevel@tonic-gate Ip6Address ipv6GroupMemberAddress; 9237c478bd9Sstevel@tonic-gate /* Number of member sockets */ 9247c478bd9Sstevel@tonic-gate Counter ipv6GroupMemberRefCnt; 9257c478bd9Sstevel@tonic-gate /* Filter mode: 1 => include, 2 => exclude */ 9267c478bd9Sstevel@tonic-gate int ipv6GroupMemberFilterMode; 9277c478bd9Sstevel@tonic-gate } ipv6_member_t; 9287c478bd9Sstevel@tonic-gate 92945916cd2Sjpk /* 93045916cd2Sjpk * This is used to mark transport layer entities (e.g., TCP connections) that 93145916cd2Sjpk * are capable of receiving packets from a range of labels. 'level' is set to 93245916cd2Sjpk * the protocol of interest (e.g., MIB2_TCP), and 'name' is set to 93345916cd2Sjpk * EXPER_XPORT_MLP. The tme_connidx refers back to the entry in MIB2_TCP_CONN, 93445916cd2Sjpk * MIB2_TCP6_CONN, or MIB2_SCTP_CONN. 93545916cd2Sjpk * 93645916cd2Sjpk * It is also used to report connections that receive packets at a single label 93745916cd2Sjpk * that's other than the zone's label. This is the case when a TCP connection 93845916cd2Sjpk * is accepted from a particular peer using an MLP listener. 93945916cd2Sjpk */ 94045916cd2Sjpk typedef struct mib2_transportMLPEntry { 94145916cd2Sjpk uint_t tme_connidx; 94245916cd2Sjpk uint_t tme_flags; 94345916cd2Sjpk int tme_doi; 94445916cd2Sjpk bslabel_t tme_label; 94545916cd2Sjpk } mib2_transportMLPEntry_t; 94645916cd2Sjpk 94745916cd2Sjpk #define MIB2_TMEF_PRIVATE 0x00000001 /* MLP on private addresses */ 94845916cd2Sjpk #define MIB2_TMEF_SHARED 0x00000002 /* MLP on shared addresses */ 9495f9878b0Sken Powell - Sun Microsystem #define MIB2_TMEF_ANONMLP 0x00000004 /* Anonymous MLP port */ 9505f9878b0Sken Powell - Sun Microsystem #define MIB2_TMEF_MACEXEMPT 0x00000008 /* MAC-Exempt port */ 9515f9878b0Sken Powell - Sun Microsystem #define MIB2_TMEF_IS_LABELED 0x00000010 /* tme_doi & tme_label exists */ 9525d3b8cb7SBill Sommerfeld #define MIB2_TMEF_MACIMPLICIT 0x00000020 /* MAC-Implicit */ 9537c478bd9Sstevel@tonic-gate /* 9547c478bd9Sstevel@tonic-gate * List of IPv4 source addresses being filtered per interface 9557c478bd9Sstevel@tonic-gate */ 9567c478bd9Sstevel@tonic-gate typedef struct ip_grpsrc { 9577c478bd9Sstevel@tonic-gate /* Interface index */ 9587c478bd9Sstevel@tonic-gate DeviceName ipGroupSourceIfIndex; 9597c478bd9Sstevel@tonic-gate /* IP Multicast address */ 9607c478bd9Sstevel@tonic-gate IpAddress ipGroupSourceGroup; 9617c478bd9Sstevel@tonic-gate /* IP Source address */ 9627c478bd9Sstevel@tonic-gate IpAddress ipGroupSourceAddress; 9637c478bd9Sstevel@tonic-gate } ip_grpsrc_t; 9647c478bd9Sstevel@tonic-gate 9657c478bd9Sstevel@tonic-gate 9667c478bd9Sstevel@tonic-gate /* 9677c478bd9Sstevel@tonic-gate * List of IPv6 source addresses being filtered per interface 9687c478bd9Sstevel@tonic-gate */ 9697c478bd9Sstevel@tonic-gate typedef struct ipv6_grpsrc { 9707c478bd9Sstevel@tonic-gate /* Interface index */ 9717c478bd9Sstevel@tonic-gate DeviceIndex ipv6GroupSourceIfIndex; 9727c478bd9Sstevel@tonic-gate /* IP Multicast address */ 9737c478bd9Sstevel@tonic-gate Ip6Address ipv6GroupSourceGroup; 9747c478bd9Sstevel@tonic-gate /* IP Source address */ 9757c478bd9Sstevel@tonic-gate Ip6Address ipv6GroupSourceAddress; 9767c478bd9Sstevel@tonic-gate } ipv6_grpsrc_t; 9777c478bd9Sstevel@tonic-gate 9787c478bd9Sstevel@tonic-gate 9797c478bd9Sstevel@tonic-gate /* 980*bd670b35SErik Nordmark * List of destination cache entries 981*bd670b35SErik Nordmark */ 982*bd670b35SErik Nordmark typedef struct dest_cache_entry { 983*bd670b35SErik Nordmark /* IP Multicast address */ 984*bd670b35SErik Nordmark IpAddress DestIpv4Address; 985*bd670b35SErik Nordmark Ip6Address DestIpv6Address; 986*bd670b35SErik Nordmark uint_t DestFlags; /* DCEF_* */ 987*bd670b35SErik Nordmark uint32_t DestPmtu; /* Path MTU if DCEF_PMTU */ 988*bd670b35SErik Nordmark uint32_t DestIdent; /* Per destination IP ident. */ 989*bd670b35SErik Nordmark DeviceIndex DestIfindex; /* For IPv6 link-locals */ 990*bd670b35SErik Nordmark uint32_t DestAge; /* Age of MTU info in seconds */ 991*bd670b35SErik Nordmark } dest_cache_entry_t; 992*bd670b35SErik Nordmark 993*bd670b35SErik Nordmark 994*bd670b35SErik Nordmark /* 9957c478bd9Sstevel@tonic-gate * ICMP Group 9967c478bd9Sstevel@tonic-gate */ 9977c478bd9Sstevel@tonic-gate typedef struct mib2_icmp { 9987c478bd9Sstevel@tonic-gate /* total # of recv'd ICMP msgs { icmp 1 } */ 9997c478bd9Sstevel@tonic-gate Counter icmpInMsgs; 10007c478bd9Sstevel@tonic-gate /* recv'd ICMP msgs with errors { icmp 2 } */ 10017c478bd9Sstevel@tonic-gate Counter icmpInErrors; 10027c478bd9Sstevel@tonic-gate /* recv'd "dest unreachable" msg's { icmp 3 } */ 10037c478bd9Sstevel@tonic-gate Counter icmpInDestUnreachs; 10047c478bd9Sstevel@tonic-gate /* recv'd "time exceeded" msg's { icmp 4 } */ 10057c478bd9Sstevel@tonic-gate Counter icmpInTimeExcds; 10067c478bd9Sstevel@tonic-gate /* recv'd "parameter problem" msg's { icmp 5 } */ 10077c478bd9Sstevel@tonic-gate Counter icmpInParmProbs; 10087c478bd9Sstevel@tonic-gate /* recv'd "source quench" msg's { icmp 6 } */ 10097c478bd9Sstevel@tonic-gate Counter icmpInSrcQuenchs; 10107c478bd9Sstevel@tonic-gate /* recv'd "ICMP redirect" msg's { icmp 7 } */ 10117c478bd9Sstevel@tonic-gate Counter icmpInRedirects; 10127c478bd9Sstevel@tonic-gate /* recv'd "echo request" msg's { icmp 8 } */ 10137c478bd9Sstevel@tonic-gate Counter icmpInEchos; 10147c478bd9Sstevel@tonic-gate /* recv'd "echo reply" msg's { icmp 9 } */ 10157c478bd9Sstevel@tonic-gate Counter icmpInEchoReps; 10167c478bd9Sstevel@tonic-gate /* recv'd "timestamp" msg's { icmp 10 } */ 10177c478bd9Sstevel@tonic-gate Counter icmpInTimestamps; 10187c478bd9Sstevel@tonic-gate /* recv'd "timestamp reply" msg's { icmp 11 } */ 10197c478bd9Sstevel@tonic-gate Counter icmpInTimestampReps; 10207c478bd9Sstevel@tonic-gate /* recv'd "address mask request" msg's { icmp 12 } */ 10217c478bd9Sstevel@tonic-gate Counter icmpInAddrMasks; 10227c478bd9Sstevel@tonic-gate /* recv'd "address mask reply" msg's { icmp 13 } */ 10237c478bd9Sstevel@tonic-gate Counter icmpInAddrMaskReps; 10247c478bd9Sstevel@tonic-gate /* total # of sent ICMP msg's { icmp 14 } */ 10257c478bd9Sstevel@tonic-gate Counter icmpOutMsgs; 10267c478bd9Sstevel@tonic-gate /* # of msg's not sent for internal icmp errors { icmp 15 } */ 10277c478bd9Sstevel@tonic-gate Counter icmpOutErrors; 10287c478bd9Sstevel@tonic-gate /* # of "dest unreachable" msg's sent { icmp 16 } */ 10297c478bd9Sstevel@tonic-gate Counter icmpOutDestUnreachs; 10307c478bd9Sstevel@tonic-gate /* # of "time exceeded" msg's sent { icmp 17 } */ 10317c478bd9Sstevel@tonic-gate Counter icmpOutTimeExcds; 10327c478bd9Sstevel@tonic-gate /* # of "parameter problme" msg's sent { icmp 18 } */ 10337c478bd9Sstevel@tonic-gate Counter icmpOutParmProbs; 10347c478bd9Sstevel@tonic-gate /* # of "source quench" msg's sent { icmp 19 } */ 10357c478bd9Sstevel@tonic-gate Counter icmpOutSrcQuenchs; 10367c478bd9Sstevel@tonic-gate /* # of "ICMP redirect" msg's sent { icmp 20 } */ 10377c478bd9Sstevel@tonic-gate Counter icmpOutRedirects; 10387c478bd9Sstevel@tonic-gate /* # of "Echo request" msg's sent { icmp 21 } */ 10397c478bd9Sstevel@tonic-gate Counter icmpOutEchos; 10407c478bd9Sstevel@tonic-gate /* # of "Echo reply" msg's sent { icmp 22 } */ 10417c478bd9Sstevel@tonic-gate Counter icmpOutEchoReps; 10427c478bd9Sstevel@tonic-gate /* # of "timestamp request" msg's sent { icmp 23 } */ 10437c478bd9Sstevel@tonic-gate Counter icmpOutTimestamps; 10447c478bd9Sstevel@tonic-gate /* # of "timestamp reply" msg's sent { icmp 24 } */ 10457c478bd9Sstevel@tonic-gate Counter icmpOutTimestampReps; 10467c478bd9Sstevel@tonic-gate /* # of "address mask request" msg's sent { icmp 25 } */ 10477c478bd9Sstevel@tonic-gate Counter icmpOutAddrMasks; 10487c478bd9Sstevel@tonic-gate /* # of "address mask reply" msg's sent { icmp 26 } */ 10497c478bd9Sstevel@tonic-gate Counter icmpOutAddrMaskReps; 10507c478bd9Sstevel@tonic-gate /* 10517c478bd9Sstevel@tonic-gate * In addition to MIB-II 10527c478bd9Sstevel@tonic-gate */ 10537c478bd9Sstevel@tonic-gate /* # of received packets with checksum errors */ 10547c478bd9Sstevel@tonic-gate Counter icmpInCksumErrs; 10557c478bd9Sstevel@tonic-gate /* # of received packets with unknow codes */ 10567c478bd9Sstevel@tonic-gate Counter icmpInUnknowns; 10577c478bd9Sstevel@tonic-gate /* # of received unreachables with "fragmentation needed" */ 10587c478bd9Sstevel@tonic-gate Counter icmpInFragNeeded; 10597c478bd9Sstevel@tonic-gate /* # of sent unreachables with "fragmentation needed" */ 10607c478bd9Sstevel@tonic-gate Counter icmpOutFragNeeded; 10617c478bd9Sstevel@tonic-gate /* 10627c478bd9Sstevel@tonic-gate * # of msg's not sent since original packet was broadcast/multicast 10637c478bd9Sstevel@tonic-gate * or an ICMP error packet 10647c478bd9Sstevel@tonic-gate */ 10657c478bd9Sstevel@tonic-gate Counter icmpOutDrops; 10667c478bd9Sstevel@tonic-gate /* # of ICMP packets droped due to queue overflow */ 10677c478bd9Sstevel@tonic-gate Counter icmpInOverflows; 10687c478bd9Sstevel@tonic-gate /* recv'd "ICMP redirect" msg's that are bad thus ignored */ 10697c478bd9Sstevel@tonic-gate Counter icmpInBadRedirects; 10707c478bd9Sstevel@tonic-gate } mib2_icmp_t; 10717c478bd9Sstevel@tonic-gate 10727c478bd9Sstevel@tonic-gate 10737c478bd9Sstevel@tonic-gate /* 10747c478bd9Sstevel@tonic-gate * ipv6IfIcmpEntry OBJECT-TYPE 10757c478bd9Sstevel@tonic-gate * SYNTAX Ipv6IfIcmpEntry 10767c478bd9Sstevel@tonic-gate * MAX-ACCESS not-accessible 10777c478bd9Sstevel@tonic-gate * STATUS current 10787c478bd9Sstevel@tonic-gate * DESCRIPTION 10797c478bd9Sstevel@tonic-gate * "An ICMPv6 statistics entry containing 10807c478bd9Sstevel@tonic-gate * objects at a particular IPv6 interface. 10817c478bd9Sstevel@tonic-gate * 10827c478bd9Sstevel@tonic-gate * Note that a receiving interface is 10837c478bd9Sstevel@tonic-gate * the interface to which a given ICMPv6 message 10847c478bd9Sstevel@tonic-gate * is addressed which may not be necessarily 10857c478bd9Sstevel@tonic-gate * the input interface for the message. 10867c478bd9Sstevel@tonic-gate * 10877c478bd9Sstevel@tonic-gate * Similarly, the sending interface is 10887c478bd9Sstevel@tonic-gate * the interface that sources a given 10897c478bd9Sstevel@tonic-gate * ICMP message which is usually but not 10907c478bd9Sstevel@tonic-gate * necessarily the output interface for the message." 10917c478bd9Sstevel@tonic-gate * AUGMENTS { ipv6IfEntry } 10927c478bd9Sstevel@tonic-gate * ::= { ipv6IfIcmpTable 1 } 10937c478bd9Sstevel@tonic-gate * 10947c478bd9Sstevel@tonic-gate * Per-interface ICMPv6 statistics table 10957c478bd9Sstevel@tonic-gate */ 10967c478bd9Sstevel@tonic-gate 10977c478bd9Sstevel@tonic-gate typedef struct mib2_ipv6IfIcmpEntry { 10987c478bd9Sstevel@tonic-gate /* Local ifindex to identify the interface */ 10997c478bd9Sstevel@tonic-gate DeviceIndex ipv6IfIcmpIfIndex; 11007c478bd9Sstevel@tonic-gate 11017c478bd9Sstevel@tonic-gate int ipv6IfIcmpEntrySize; /* Size of ipv6IfIcmpEntry */ 11027c478bd9Sstevel@tonic-gate 11037c478bd9Sstevel@tonic-gate /* The total # ICMP msgs rcvd includes ipv6IfIcmpInErrors */ 11047c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInMsgs; 11057c478bd9Sstevel@tonic-gate /* # ICMP with ICMP-specific errors (bad checkum, length, etc) */ 11067c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInErrors; 11077c478bd9Sstevel@tonic-gate /* # ICMP Destination Unreachable */ 11087c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInDestUnreachs; 11097c478bd9Sstevel@tonic-gate /* # ICMP destination unreachable/communication admin prohibited */ 11107c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInAdminProhibs; 11117c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInTimeExcds; 11127c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInParmProblems; 11137c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInPktTooBigs; 11147c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInEchos; 11157c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInEchoReplies; 11167c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInRouterSolicits; 11177c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInRouterAdvertisements; 11187c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInNeighborSolicits; 11197c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInNeighborAdvertisements; 11207c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInRedirects; 11217c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembQueries; 11227c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembResponses; 11237c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembReductions; 11247c478bd9Sstevel@tonic-gate /* Total # ICMP messages attempted to send (includes OutErrors) */ 11257c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutMsgs; 11267c478bd9Sstevel@tonic-gate /* # ICMP messages not sent due to ICMP problems (e.g. no buffers) */ 11277c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutErrors; 11287c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutDestUnreachs; 11297c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutAdminProhibs; 11307c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutTimeExcds; 11317c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutParmProblems; 11327c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutPktTooBigs; 11337c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutEchos; 11347c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutEchoReplies; 11357c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutRouterSolicits; 11367c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutRouterAdvertisements; 11377c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutNeighborSolicits; 11387c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutNeighborAdvertisements; 11397c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutRedirects; 11407c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutGroupMembQueries; 11417c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutGroupMembResponses; 11427c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpOutGroupMembReductions; 11437c478bd9Sstevel@tonic-gate /* Additions beyond the MIB */ 11447c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInOverflows; 11457c478bd9Sstevel@tonic-gate /* recv'd "ICMPv6 redirect" msg's that are bad thus ignored */ 11467c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpBadHoplimit; 11477c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInBadNeighborAdvertisements; 11487c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInBadNeighborSolicitations; 11497c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInBadRedirects; 11507c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembTotal; 11517c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembBadQueries; 11527c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembBadReports; 11537c478bd9Sstevel@tonic-gate Counter32 ipv6IfIcmpInGroupMembOurReports; 11547c478bd9Sstevel@tonic-gate } mib2_ipv6IfIcmpEntry_t; 11557c478bd9Sstevel@tonic-gate 11567c478bd9Sstevel@tonic-gate /* 11577c478bd9Sstevel@tonic-gate * the TCP group 11587c478bd9Sstevel@tonic-gate * 11597c478bd9Sstevel@tonic-gate * Note that instances of object types that represent 11607c478bd9Sstevel@tonic-gate * information about a particular TCP connection are 11617c478bd9Sstevel@tonic-gate * transient; they persist only as long as the connection 11627c478bd9Sstevel@tonic-gate * in question. 11637c478bd9Sstevel@tonic-gate */ 11647c478bd9Sstevel@tonic-gate #define MIB2_TCP_CONN 13 /* tcpConnEntry */ 11657c478bd9Sstevel@tonic-gate #define MIB2_TCP6_CONN 14 /* tcp6ConnEntry */ 11667c478bd9Sstevel@tonic-gate 11677c478bd9Sstevel@tonic-gate /* Old name retained for compatibility */ 11687c478bd9Sstevel@tonic-gate #define MIB2_TCP_13 MIB2_TCP_CONN 11697c478bd9Sstevel@tonic-gate 11703173664eSapersson /* Pack data in mib2_tcp to make struct size the same for 32- and 64-bits */ 11713173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 11723173664eSapersson #pragma pack(4) 11733173664eSapersson #endif 11747c478bd9Sstevel@tonic-gate typedef struct mib2_tcp { 11757c478bd9Sstevel@tonic-gate /* algorithm used for transmit timeout value { tcp 1 } */ 11767c478bd9Sstevel@tonic-gate int tcpRtoAlgorithm; 11777c478bd9Sstevel@tonic-gate /* minimum retransmit timeout (ms) { tcp 2 } */ 11787c478bd9Sstevel@tonic-gate int tcpRtoMin; 11797c478bd9Sstevel@tonic-gate /* maximum retransmit timeout (ms) { tcp 3 } */ 11807c478bd9Sstevel@tonic-gate int tcpRtoMax; 11817c478bd9Sstevel@tonic-gate /* maximum # of connections supported { tcp 4 } */ 11827c478bd9Sstevel@tonic-gate int tcpMaxConn; 11837c478bd9Sstevel@tonic-gate /* # of direct transitions CLOSED -> SYN-SENT { tcp 5 } */ 11847c478bd9Sstevel@tonic-gate Counter tcpActiveOpens; 11857c478bd9Sstevel@tonic-gate /* # of direct transitions LISTEN -> SYN-RCVD { tcp 6 } */ 11867c478bd9Sstevel@tonic-gate Counter tcpPassiveOpens; 11877c478bd9Sstevel@tonic-gate /* # of direct SIN-SENT/RCVD -> CLOSED/LISTEN { tcp 7 } */ 11887c478bd9Sstevel@tonic-gate Counter tcpAttemptFails; 11897c478bd9Sstevel@tonic-gate /* # of direct ESTABLISHED/CLOSE-WAIT -> CLOSED { tcp 8 } */ 11907c478bd9Sstevel@tonic-gate Counter tcpEstabResets; 11917c478bd9Sstevel@tonic-gate /* # of connections ESTABLISHED or CLOSE-WAIT { tcp 9 } */ 11927c478bd9Sstevel@tonic-gate Gauge tcpCurrEstab; 11937c478bd9Sstevel@tonic-gate /* total # of segments recv'd { tcp 10 } */ 11947c478bd9Sstevel@tonic-gate Counter tcpInSegs; 11957c478bd9Sstevel@tonic-gate /* total # of segments sent { tcp 11 } */ 11967c478bd9Sstevel@tonic-gate Counter tcpOutSegs; 11977c478bd9Sstevel@tonic-gate /* total # of segments retransmitted { tcp 12 } */ 11987c478bd9Sstevel@tonic-gate Counter tcpRetransSegs; 11997c478bd9Sstevel@tonic-gate /* {tcp 13} */ 12007c478bd9Sstevel@tonic-gate int tcpConnTableSize; /* Size of tcpConnEntry_t */ 12017c478bd9Sstevel@tonic-gate /* in ip {tcp 14} */ 12027c478bd9Sstevel@tonic-gate /* # of segments sent with RST flag { tcp 15 } */ 12037c478bd9Sstevel@tonic-gate Counter tcpOutRsts; 12047c478bd9Sstevel@tonic-gate /* In addition to MIB-II */ 12057c478bd9Sstevel@tonic-gate /* Sender */ 12067c478bd9Sstevel@tonic-gate /* total # of data segments sent */ 12077c478bd9Sstevel@tonic-gate Counter tcpOutDataSegs; 12087c478bd9Sstevel@tonic-gate /* total # of bytes in data segments sent */ 12097c478bd9Sstevel@tonic-gate Counter tcpOutDataBytes; 12107c478bd9Sstevel@tonic-gate /* total # of bytes in segments retransmitted */ 12117c478bd9Sstevel@tonic-gate Counter tcpRetransBytes; 12127c478bd9Sstevel@tonic-gate /* total # of acks sent */ 12137c478bd9Sstevel@tonic-gate Counter tcpOutAck; 12147c478bd9Sstevel@tonic-gate /* total # of delayed acks sent */ 12157c478bd9Sstevel@tonic-gate Counter tcpOutAckDelayed; 12167c478bd9Sstevel@tonic-gate /* total # of segments sent with the urg flag on */ 12177c478bd9Sstevel@tonic-gate Counter tcpOutUrg; 12187c478bd9Sstevel@tonic-gate /* total # of window updates sent */ 12197c478bd9Sstevel@tonic-gate Counter tcpOutWinUpdate; 12207c478bd9Sstevel@tonic-gate /* total # of zero window probes sent */ 12217c478bd9Sstevel@tonic-gate Counter tcpOutWinProbe; 12227c478bd9Sstevel@tonic-gate /* total # of control segments sent (syn, fin, rst) */ 12237c478bd9Sstevel@tonic-gate Counter tcpOutControl; 12247c478bd9Sstevel@tonic-gate /* total # of segments sent due to "fast retransmit" */ 12257c478bd9Sstevel@tonic-gate Counter tcpOutFastRetrans; 12267c478bd9Sstevel@tonic-gate /* Receiver */ 12277c478bd9Sstevel@tonic-gate /* total # of ack segments received */ 12287c478bd9Sstevel@tonic-gate Counter tcpInAckSegs; 12297c478bd9Sstevel@tonic-gate /* total # of bytes acked */ 12307c478bd9Sstevel@tonic-gate Counter tcpInAckBytes; 12317c478bd9Sstevel@tonic-gate /* total # of duplicate acks */ 12327c478bd9Sstevel@tonic-gate Counter tcpInDupAck; 12337c478bd9Sstevel@tonic-gate /* total # of acks acking unsent data */ 12347c478bd9Sstevel@tonic-gate Counter tcpInAckUnsent; 12357c478bd9Sstevel@tonic-gate /* total # of data segments received in order */ 12367c478bd9Sstevel@tonic-gate Counter tcpInDataInorderSegs; 12377c478bd9Sstevel@tonic-gate /* total # of data bytes received in order */ 12387c478bd9Sstevel@tonic-gate Counter tcpInDataInorderBytes; 12397c478bd9Sstevel@tonic-gate /* total # of data segments received out of order */ 12407c478bd9Sstevel@tonic-gate Counter tcpInDataUnorderSegs; 12417c478bd9Sstevel@tonic-gate /* total # of data bytes received out of order */ 12427c478bd9Sstevel@tonic-gate Counter tcpInDataUnorderBytes; 12437c478bd9Sstevel@tonic-gate /* total # of complete duplicate data segments received */ 12447c478bd9Sstevel@tonic-gate Counter tcpInDataDupSegs; 12457c478bd9Sstevel@tonic-gate /* total # of bytes in the complete duplicate data segments received */ 12467c478bd9Sstevel@tonic-gate Counter tcpInDataDupBytes; 12477c478bd9Sstevel@tonic-gate /* total # of partial duplicate data segments received */ 12487c478bd9Sstevel@tonic-gate Counter tcpInDataPartDupSegs; 12497c478bd9Sstevel@tonic-gate /* total # of bytes in the partial duplicate data segments received */ 12507c478bd9Sstevel@tonic-gate Counter tcpInDataPartDupBytes; 12517c478bd9Sstevel@tonic-gate /* total # of data segments received past the window */ 12527c478bd9Sstevel@tonic-gate Counter tcpInDataPastWinSegs; 12537c478bd9Sstevel@tonic-gate /* total # of data bytes received part the window */ 12547c478bd9Sstevel@tonic-gate Counter tcpInDataPastWinBytes; 12557c478bd9Sstevel@tonic-gate /* total # of zero window probes received */ 12567c478bd9Sstevel@tonic-gate Counter tcpInWinProbe; 12577c478bd9Sstevel@tonic-gate /* total # of window updates received */ 12587c478bd9Sstevel@tonic-gate Counter tcpInWinUpdate; 12597c478bd9Sstevel@tonic-gate /* total # of data segments received after the connection has closed */ 12607c478bd9Sstevel@tonic-gate Counter tcpInClosed; 12617c478bd9Sstevel@tonic-gate /* Others */ 12627c478bd9Sstevel@tonic-gate /* total # of failed attempts to update the rtt estimate */ 12637c478bd9Sstevel@tonic-gate Counter tcpRttNoUpdate; 12647c478bd9Sstevel@tonic-gate /* total # of successful attempts to update the rtt estimate */ 12657c478bd9Sstevel@tonic-gate Counter tcpRttUpdate; 12667c478bd9Sstevel@tonic-gate /* total # of retransmit timeouts */ 12677c478bd9Sstevel@tonic-gate Counter tcpTimRetrans; 12687c478bd9Sstevel@tonic-gate /* total # of retransmit timeouts dropping the connection */ 12697c478bd9Sstevel@tonic-gate Counter tcpTimRetransDrop; 12707c478bd9Sstevel@tonic-gate /* total # of keepalive timeouts */ 12717c478bd9Sstevel@tonic-gate Counter tcpTimKeepalive; 12727c478bd9Sstevel@tonic-gate /* total # of keepalive timeouts sending a probe */ 12737c478bd9Sstevel@tonic-gate Counter tcpTimKeepaliveProbe; 12747c478bd9Sstevel@tonic-gate /* total # of keepalive timeouts dropping the connection */ 12757c478bd9Sstevel@tonic-gate Counter tcpTimKeepaliveDrop; 12767c478bd9Sstevel@tonic-gate /* total # of connections refused due to backlog full on listen */ 12777c478bd9Sstevel@tonic-gate Counter tcpListenDrop; 12787c478bd9Sstevel@tonic-gate /* total # of connections refused due to half-open queue (q0) full */ 12797c478bd9Sstevel@tonic-gate Counter tcpListenDropQ0; 12807c478bd9Sstevel@tonic-gate /* total # of connections dropped from a full half-open queue (q0) */ 12817c478bd9Sstevel@tonic-gate Counter tcpHalfOpenDrop; 12827c478bd9Sstevel@tonic-gate /* total # of retransmitted segments by SACK retransmission */ 12837c478bd9Sstevel@tonic-gate Counter tcpOutSackRetransSegs; 12847c478bd9Sstevel@tonic-gate 12857c478bd9Sstevel@tonic-gate int tcp6ConnTableSize; /* Size of tcp6ConnEntry_t */ 12863173664eSapersson 12873173664eSapersson /* 12883173664eSapersson * fields from RFC 4022 12893173664eSapersson */ 12903173664eSapersson 12913173664eSapersson /* total # of segments recv'd { tcp 17 } */ 12923173664eSapersson Counter64 tcpHCInSegs; 12933173664eSapersson /* total # of segments sent { tcp 18 } */ 12943173664eSapersson Counter64 tcpHCOutSegs; 12957c478bd9Sstevel@tonic-gate } mib2_tcp_t; 12967c478bd9Sstevel@tonic-gate 12973173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 12983173664eSapersson #pragma pack() 12993173664eSapersson #endif 13003173664eSapersson 13017c478bd9Sstevel@tonic-gate /* 13027c478bd9Sstevel@tonic-gate * The TCP/IPv4 connection table {tcp 13} contains information about this 13037c478bd9Sstevel@tonic-gate * entity's existing TCP connections over IPv4. 13047c478bd9Sstevel@tonic-gate */ 13057c478bd9Sstevel@tonic-gate /* For tcpConnState and tcp6ConnState */ 13067c478bd9Sstevel@tonic-gate #define MIB2_TCP_closed 1 13077c478bd9Sstevel@tonic-gate #define MIB2_TCP_listen 2 13087c478bd9Sstevel@tonic-gate #define MIB2_TCP_synSent 3 13097c478bd9Sstevel@tonic-gate #define MIB2_TCP_synReceived 4 13107c478bd9Sstevel@tonic-gate #define MIB2_TCP_established 5 13117c478bd9Sstevel@tonic-gate #define MIB2_TCP_finWait1 6 13127c478bd9Sstevel@tonic-gate #define MIB2_TCP_finWait2 7 13137c478bd9Sstevel@tonic-gate #define MIB2_TCP_closeWait 8 13147c478bd9Sstevel@tonic-gate #define MIB2_TCP_lastAck 9 13157c478bd9Sstevel@tonic-gate #define MIB2_TCP_closing 10 13167c478bd9Sstevel@tonic-gate #define MIB2_TCP_timeWait 11 13177c478bd9Sstevel@tonic-gate #define MIB2_TCP_deleteTCB 12 /* only writeable value */ 13187c478bd9Sstevel@tonic-gate 13193173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */ 13203173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 13213173664eSapersson #pragma pack(4) 13223173664eSapersson #endif 13237c478bd9Sstevel@tonic-gate typedef struct mib2_tcpConnEntry { 13247c478bd9Sstevel@tonic-gate /* state of tcp connection { tcpConnEntry 1} RW */ 13257c478bd9Sstevel@tonic-gate int tcpConnState; 13267c478bd9Sstevel@tonic-gate /* local ip addr for this connection { tcpConnEntry 2 } */ 13277c478bd9Sstevel@tonic-gate IpAddress tcpConnLocalAddress; 13287c478bd9Sstevel@tonic-gate /* local port for this connection { tcpConnEntry 3 } */ 13297c478bd9Sstevel@tonic-gate int tcpConnLocalPort; /* In host byte order */ 13307c478bd9Sstevel@tonic-gate /* remote ip addr for this connection { tcpConnEntry 4 } */ 13317c478bd9Sstevel@tonic-gate IpAddress tcpConnRemAddress; 13327c478bd9Sstevel@tonic-gate /* remote port for this connection { tcpConnEntry 5 } */ 13337c478bd9Sstevel@tonic-gate int tcpConnRemPort; /* In host byte order */ 13347c478bd9Sstevel@tonic-gate struct tcpConnEntryInfo_s { 13357c478bd9Sstevel@tonic-gate /* seq # of next segment to send */ 13367c478bd9Sstevel@tonic-gate Gauge ce_snxt; 13377c478bd9Sstevel@tonic-gate /* seq # of of last segment unacknowledged */ 13387c478bd9Sstevel@tonic-gate Gauge ce_suna; 13397c478bd9Sstevel@tonic-gate /* currect send window size */ 13407c478bd9Sstevel@tonic-gate Gauge ce_swnd; 13417c478bd9Sstevel@tonic-gate /* seq # of next expected segment */ 13427c478bd9Sstevel@tonic-gate Gauge ce_rnxt; 13437c478bd9Sstevel@tonic-gate /* seq # of last ack'd segment */ 13447c478bd9Sstevel@tonic-gate Gauge ce_rack; 13457c478bd9Sstevel@tonic-gate /* currenct receive window size */ 13467c478bd9Sstevel@tonic-gate Gauge ce_rwnd; 13477c478bd9Sstevel@tonic-gate /* current rto (retransmit timeout) */ 13487c478bd9Sstevel@tonic-gate Gauge ce_rto; 13497c478bd9Sstevel@tonic-gate /* current max segment size */ 13507c478bd9Sstevel@tonic-gate Gauge ce_mss; 13517c478bd9Sstevel@tonic-gate /* actual internal state */ 13527c478bd9Sstevel@tonic-gate int ce_state; 13537c478bd9Sstevel@tonic-gate } tcpConnEntryInfo; 13543173664eSapersson 13553173664eSapersson /* pid of the processes that created this connection */ 13563173664eSapersson uint32_t tcpConnCreationProcess; 13573173664eSapersson /* system uptime when the connection was created */ 13583173664eSapersson uint64_t tcpConnCreationTime; 13597c478bd9Sstevel@tonic-gate } mib2_tcpConnEntry_t; 13603173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 13613173664eSapersson #pragma pack() 13623173664eSapersson #endif 13637c478bd9Sstevel@tonic-gate 13647c478bd9Sstevel@tonic-gate 13657c478bd9Sstevel@tonic-gate /* 13667c478bd9Sstevel@tonic-gate * The TCP/IPv6 connection table {tcp 14} contains information about this 13677c478bd9Sstevel@tonic-gate * entity's existing TCP connections over IPv6. 13687c478bd9Sstevel@tonic-gate */ 13697c478bd9Sstevel@tonic-gate 13703173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */ 13713173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 13723173664eSapersson #pragma pack(4) 13733173664eSapersson #endif 13747c478bd9Sstevel@tonic-gate typedef struct mib2_tcp6ConnEntry { 13757c478bd9Sstevel@tonic-gate /* local ip addr for this connection { ipv6TcpConnEntry 1 } */ 13767c478bd9Sstevel@tonic-gate Ip6Address tcp6ConnLocalAddress; 13777c478bd9Sstevel@tonic-gate /* local port for this connection { ipv6TcpConnEntry 2 } */ 13787c478bd9Sstevel@tonic-gate int tcp6ConnLocalPort; 13797c478bd9Sstevel@tonic-gate /* remote ip addr for this connection { ipv6TcpConnEntry 3 } */ 13807c478bd9Sstevel@tonic-gate Ip6Address tcp6ConnRemAddress; 13817c478bd9Sstevel@tonic-gate /* remote port for this connection { ipv6TcpConnEntry 4 } */ 13827c478bd9Sstevel@tonic-gate int tcp6ConnRemPort; 13837c478bd9Sstevel@tonic-gate /* interface index or zero { ipv6TcpConnEntry 5 } */ 13847c478bd9Sstevel@tonic-gate DeviceIndex tcp6ConnIfIndex; 13857c478bd9Sstevel@tonic-gate /* state of tcp6 connection { ipv6TcpConnEntry 6 } RW */ 13867c478bd9Sstevel@tonic-gate int tcp6ConnState; 13877c478bd9Sstevel@tonic-gate struct tcp6ConnEntryInfo_s { 13887c478bd9Sstevel@tonic-gate /* seq # of next segment to send */ 13897c478bd9Sstevel@tonic-gate Gauge ce_snxt; 13907c478bd9Sstevel@tonic-gate /* seq # of of last segment unacknowledged */ 13917c478bd9Sstevel@tonic-gate Gauge ce_suna; 13927c478bd9Sstevel@tonic-gate /* currect send window size */ 13937c478bd9Sstevel@tonic-gate Gauge ce_swnd; 13947c478bd9Sstevel@tonic-gate /* seq # of next expected segment */ 13957c478bd9Sstevel@tonic-gate Gauge ce_rnxt; 13967c478bd9Sstevel@tonic-gate /* seq # of last ack'd segment */ 13977c478bd9Sstevel@tonic-gate Gauge ce_rack; 13987c478bd9Sstevel@tonic-gate /* currenct receive window size */ 13997c478bd9Sstevel@tonic-gate Gauge ce_rwnd; 14007c478bd9Sstevel@tonic-gate /* current rto (retransmit timeout) */ 14017c478bd9Sstevel@tonic-gate Gauge ce_rto; 14027c478bd9Sstevel@tonic-gate /* current max segment size */ 14037c478bd9Sstevel@tonic-gate Gauge ce_mss; 14047c478bd9Sstevel@tonic-gate /* actual internal state */ 14057c478bd9Sstevel@tonic-gate int ce_state; 14067c478bd9Sstevel@tonic-gate } tcp6ConnEntryInfo; 14073173664eSapersson 14083173664eSapersson /* pid of the processes that created this connection */ 14093173664eSapersson uint32_t tcp6ConnCreationProcess; 14103173664eSapersson /* system uptime when the connection was created */ 14113173664eSapersson uint64_t tcp6ConnCreationTime; 14127c478bd9Sstevel@tonic-gate } mib2_tcp6ConnEntry_t; 14133173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 14143173664eSapersson #pragma pack() 14153173664eSapersson #endif 14167c478bd9Sstevel@tonic-gate 14177c478bd9Sstevel@tonic-gate /* 14187c478bd9Sstevel@tonic-gate * the UDP group 14197c478bd9Sstevel@tonic-gate */ 14207c478bd9Sstevel@tonic-gate #define MIB2_UDP_ENTRY 5 /* udpEntry */ 14217c478bd9Sstevel@tonic-gate #define MIB2_UDP6_ENTRY 6 /* udp6Entry */ 14227c478bd9Sstevel@tonic-gate 14237c478bd9Sstevel@tonic-gate /* Old name retained for compatibility */ 14247c478bd9Sstevel@tonic-gate #define MIB2_UDP_5 MIB2_UDP_ENTRY 14257c478bd9Sstevel@tonic-gate 14263173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */ 14273173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 14283173664eSapersson #pragma pack(4) 14293173664eSapersson #endif 14307c478bd9Sstevel@tonic-gate typedef struct mib2_udp { 14317c478bd9Sstevel@tonic-gate /* total # of UDP datagrams sent upstream { udp 1 } */ 14327c478bd9Sstevel@tonic-gate Counter udpInDatagrams; 14337c478bd9Sstevel@tonic-gate /* in ip { udp 2 } */ 14347c478bd9Sstevel@tonic-gate /* # of recv'd dg's not deliverable (other) { udp 3 } */ 14357c478bd9Sstevel@tonic-gate Counter udpInErrors; 14367c478bd9Sstevel@tonic-gate /* total # of dg's sent { udp 4 } */ 14377c478bd9Sstevel@tonic-gate Counter udpOutDatagrams; 14387c478bd9Sstevel@tonic-gate /* { udp 5 } */ 14397c478bd9Sstevel@tonic-gate int udpEntrySize; /* Size of udpEntry_t */ 14407c478bd9Sstevel@tonic-gate int udp6EntrySize; /* Size of udp6Entry_t */ 14417c478bd9Sstevel@tonic-gate Counter udpOutErrors; 14423173664eSapersson 14433173664eSapersson /* 14443173664eSapersson * fields from RFC 4113 14453173664eSapersson */ 14463173664eSapersson 14473173664eSapersson /* total # of UDP datagrams sent upstream { udp 8 } */ 14483173664eSapersson Counter64 udpHCInDatagrams; 14493173664eSapersson /* total # of dg's sent { udp 9 } */ 14503173664eSapersson Counter64 udpHCOutDatagrams; 14517c478bd9Sstevel@tonic-gate } mib2_udp_t; 14523173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 14533173664eSapersson #pragma pack() 14543173664eSapersson #endif 14557c478bd9Sstevel@tonic-gate 14567c478bd9Sstevel@tonic-gate /* 14577c478bd9Sstevel@tonic-gate * The UDP listener table contains information about this entity's UDP 14587c478bd9Sstevel@tonic-gate * end-points on which a local application is currently accepting datagrams. 14597c478bd9Sstevel@tonic-gate */ 14607c478bd9Sstevel@tonic-gate 14617c478bd9Sstevel@tonic-gate /* For both IPv4 and IPv6 ue_state: */ 14627c478bd9Sstevel@tonic-gate #define MIB2_UDP_unbound 1 14637c478bd9Sstevel@tonic-gate #define MIB2_UDP_idle 2 14647c478bd9Sstevel@tonic-gate #define MIB2_UDP_connected 3 14657c478bd9Sstevel@tonic-gate #define MIB2_UDP_unknown 4 14667c478bd9Sstevel@tonic-gate 14673173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */ 14683173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 14693173664eSapersson #pragma pack(4) 14703173664eSapersson #endif 14717c478bd9Sstevel@tonic-gate typedef struct mib2_udpEntry { 14727c478bd9Sstevel@tonic-gate /* local ip addr of listener { udpEntry 1 } */ 14737c478bd9Sstevel@tonic-gate IpAddress udpLocalAddress; 14747c478bd9Sstevel@tonic-gate /* local port of listener { udpEntry 2 } */ 14757c478bd9Sstevel@tonic-gate int udpLocalPort; /* In host byte order */ 14767c478bd9Sstevel@tonic-gate struct udpEntryInfo_s { 14777c478bd9Sstevel@tonic-gate int ue_state; 14787c478bd9Sstevel@tonic-gate IpAddress ue_RemoteAddress; 14797c478bd9Sstevel@tonic-gate int ue_RemotePort; /* In host byte order */ 14807c478bd9Sstevel@tonic-gate } udpEntryInfo; 14813173664eSapersson 14823173664eSapersson /* 14833173664eSapersson * RFC 4113 14843173664eSapersson */ 14853173664eSapersson 14863173664eSapersson /* Unique id for this 4-tuple { udpEndpointEntry 7 } */ 14873173664eSapersson uint32_t udpInstance; 14883173664eSapersson /* pid of the processes that created this endpoint */ 14893173664eSapersson uint32_t udpCreationProcess; 14903173664eSapersson /* system uptime when the endpoint was created */ 14913173664eSapersson uint64_t udpCreationTime; 14927c478bd9Sstevel@tonic-gate } mib2_udpEntry_t; 14933173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 14943173664eSapersson #pragma pack() 14953173664eSapersson #endif 14967c478bd9Sstevel@tonic-gate 14977c478bd9Sstevel@tonic-gate /* 14987c478bd9Sstevel@tonic-gate * The UDP (for IPv6) listener table contains information about this 14997c478bd9Sstevel@tonic-gate * entity's UDP end-points on which a local application is 15007c478bd9Sstevel@tonic-gate * currently accepting datagrams. 15017c478bd9Sstevel@tonic-gate */ 15027c478bd9Sstevel@tonic-gate 15033173664eSapersson /* Pack data to make struct size the same for 32- and 64-bits */ 15043173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 15053173664eSapersson #pragma pack(4) 15063173664eSapersson #endif 15077c478bd9Sstevel@tonic-gate typedef struct mib2_udp6Entry { 15087c478bd9Sstevel@tonic-gate /* local ip addr of listener { ipv6UdpEntry 1 } */ 15097c478bd9Sstevel@tonic-gate Ip6Address udp6LocalAddress; 15107c478bd9Sstevel@tonic-gate /* local port of listener { ipv6UdpEntry 2 } */ 15117c478bd9Sstevel@tonic-gate int udp6LocalPort; /* In host byte order */ 15127c478bd9Sstevel@tonic-gate /* interface index or zero { ipv6UdpEntry 3 } */ 15137c478bd9Sstevel@tonic-gate DeviceIndex udp6IfIndex; 15147c478bd9Sstevel@tonic-gate struct udp6EntryInfo_s { 15157c478bd9Sstevel@tonic-gate int ue_state; 15167c478bd9Sstevel@tonic-gate Ip6Address ue_RemoteAddress; 15177c478bd9Sstevel@tonic-gate int ue_RemotePort; /* In host byte order */ 15187c478bd9Sstevel@tonic-gate } udp6EntryInfo; 15193173664eSapersson 15203173664eSapersson /* 15213173664eSapersson * RFC 4113 15223173664eSapersson */ 15233173664eSapersson 15243173664eSapersson /* Unique id for this 4-tuple { udpEndpointEntry 7 } */ 15253173664eSapersson uint32_t udp6Instance; 15263173664eSapersson /* pid of the processes that created this endpoint */ 15273173664eSapersson uint32_t udp6CreationProcess; 15283173664eSapersson /* system uptime when the endpoint was created */ 15293173664eSapersson uint64_t udp6CreationTime; 15307c478bd9Sstevel@tonic-gate } mib2_udp6Entry_t; 15313173664eSapersson #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 15323173664eSapersson #pragma pack() 15333173664eSapersson #endif 15347c478bd9Sstevel@tonic-gate 15357c478bd9Sstevel@tonic-gate /* 15367c478bd9Sstevel@tonic-gate * the RAWIP group 15377c478bd9Sstevel@tonic-gate */ 15387c478bd9Sstevel@tonic-gate typedef struct mib2_rawip { 15397c478bd9Sstevel@tonic-gate /* total # of RAWIP datagrams sent upstream */ 15407c478bd9Sstevel@tonic-gate Counter rawipInDatagrams; 15417c478bd9Sstevel@tonic-gate /* # of RAWIP packets with bad IPV6_CHECKSUM checksums */ 15427c478bd9Sstevel@tonic-gate Counter rawipInCksumErrs; 15437c478bd9Sstevel@tonic-gate /* # of recv'd dg's not deliverable (other) */ 15447c478bd9Sstevel@tonic-gate Counter rawipInErrors; 15457c478bd9Sstevel@tonic-gate /* total # of dg's sent */ 15467c478bd9Sstevel@tonic-gate Counter rawipOutDatagrams; 15477c478bd9Sstevel@tonic-gate /* total # of dg's not sent (e.g. no memory) */ 15487c478bd9Sstevel@tonic-gate Counter rawipOutErrors; 15497c478bd9Sstevel@tonic-gate } mib2_rawip_t; 15507c478bd9Sstevel@tonic-gate 15517c478bd9Sstevel@tonic-gate /* DVMRP group */ 15527c478bd9Sstevel@tonic-gate #define EXPER_DVMRP_VIF 1 15537c478bd9Sstevel@tonic-gate #define EXPER_DVMRP_MRT 2 15547c478bd9Sstevel@tonic-gate 15557c478bd9Sstevel@tonic-gate 15567c478bd9Sstevel@tonic-gate /* 15577c478bd9Sstevel@tonic-gate * The SCTP group 15587c478bd9Sstevel@tonic-gate */ 15597c478bd9Sstevel@tonic-gate #define MIB2_SCTP_CONN 15 15607c478bd9Sstevel@tonic-gate #define MIB2_SCTP_CONN_LOCAL 16 15617c478bd9Sstevel@tonic-gate #define MIB2_SCTP_CONN_REMOTE 17 15627c478bd9Sstevel@tonic-gate 15637c478bd9Sstevel@tonic-gate #define MIB2_SCTP_closed 1 15647c478bd9Sstevel@tonic-gate #define MIB2_SCTP_cookieWait 2 15657c478bd9Sstevel@tonic-gate #define MIB2_SCTP_cookieEchoed 3 15667c478bd9Sstevel@tonic-gate #define MIB2_SCTP_established 4 15677c478bd9Sstevel@tonic-gate #define MIB2_SCTP_shutdownPending 5 15687c478bd9Sstevel@tonic-gate #define MIB2_SCTP_shutdownSent 6 15697c478bd9Sstevel@tonic-gate #define MIB2_SCTP_shutdownReceived 7 15707c478bd9Sstevel@tonic-gate #define MIB2_SCTP_shutdownAckSent 8 15717c478bd9Sstevel@tonic-gate #define MIB2_SCTP_deleteTCB 9 15727c478bd9Sstevel@tonic-gate #define MIB2_SCTP_listen 10 /* Not in the MIB */ 15737c478bd9Sstevel@tonic-gate 15747c478bd9Sstevel@tonic-gate #define MIB2_SCTP_ACTIVE 1 15757c478bd9Sstevel@tonic-gate #define MIB2_SCTP_INACTIVE 2 15767c478bd9Sstevel@tonic-gate 15777c478bd9Sstevel@tonic-gate #define MIB2_SCTP_ADDR_V4 1 15787c478bd9Sstevel@tonic-gate #define MIB2_SCTP_ADDR_V6 2 15797c478bd9Sstevel@tonic-gate 15807c478bd9Sstevel@tonic-gate #define MIB2_SCTP_RTOALGO_OTHER 1 15817c478bd9Sstevel@tonic-gate #define MIB2_SCTP_RTOALGO_VANJ 2 15827c478bd9Sstevel@tonic-gate 15837c478bd9Sstevel@tonic-gate typedef struct mib2_sctpConnEntry { 15847c478bd9Sstevel@tonic-gate /* connection identifier { sctpAssocEntry 1 } */ 15857c478bd9Sstevel@tonic-gate uint32_t sctpAssocId; 15867c478bd9Sstevel@tonic-gate /* remote hostname (not used) { sctpAssocEntry 2 } */ 15877c478bd9Sstevel@tonic-gate Octet_t sctpAssocRemHostName; 15887c478bd9Sstevel@tonic-gate /* local port number { sctpAssocEntry 3 } */ 15897c478bd9Sstevel@tonic-gate uint32_t sctpAssocLocalPort; 15907c478bd9Sstevel@tonic-gate /* remote port number { sctpAssocEntry 4 } */ 15917c478bd9Sstevel@tonic-gate uint32_t sctpAssocRemPort; 15927c478bd9Sstevel@tonic-gate /* type of primary remote addr { sctpAssocEntry 5 } */ 15937c478bd9Sstevel@tonic-gate int sctpAssocRemPrimAddrType; 15947c478bd9Sstevel@tonic-gate /* primary remote address { sctpAssocEntry 6 } */ 15957c478bd9Sstevel@tonic-gate Ip6Address sctpAssocRemPrimAddr; 15967c478bd9Sstevel@tonic-gate /* local address */ 15977c478bd9Sstevel@tonic-gate Ip6Address sctpAssocLocPrimAddr; 15987c478bd9Sstevel@tonic-gate /* current heartbeat interval { sctpAssocEntry 7 } */ 15997c478bd9Sstevel@tonic-gate uint32_t sctpAssocHeartBeatInterval; 16007c478bd9Sstevel@tonic-gate /* state of this association { sctpAssocEntry 8 } */ 16017c478bd9Sstevel@tonic-gate int sctpAssocState; 16027c478bd9Sstevel@tonic-gate /* # of inbound streams { sctpAssocEntry 9 } */ 16037c478bd9Sstevel@tonic-gate uint32_t sctpAssocInStreams; 16047c478bd9Sstevel@tonic-gate /* # of outbound streams { sctpAssocEntry 10 } */ 16057c478bd9Sstevel@tonic-gate uint32_t sctpAssocOutStreams; 16067c478bd9Sstevel@tonic-gate /* max # of data retans { sctpAssocEntry 11 } */ 16077c478bd9Sstevel@tonic-gate uint32_t sctpAssocMaxRetr; 16087c478bd9Sstevel@tonic-gate /* sysId for assoc owner { sctpAssocEntry 12 } */ 16097c478bd9Sstevel@tonic-gate uint32_t sctpAssocPrimProcess; 16107c478bd9Sstevel@tonic-gate /* # of rxmit timeouts during hanshake */ 16117c478bd9Sstevel@tonic-gate Counter32 sctpAssocT1expired; /* { sctpAssocEntry 13 } */ 16127c478bd9Sstevel@tonic-gate /* # of rxmit timeouts during shutdown */ 16137c478bd9Sstevel@tonic-gate Counter32 sctpAssocT2expired; /* { sctpAssocEntry 14 } */ 16147c478bd9Sstevel@tonic-gate /* # of rxmit timeouts during data transfer */ 16157c478bd9Sstevel@tonic-gate Counter32 sctpAssocRtxChunks; /* { sctpAssocEntry 15 } */ 16167c478bd9Sstevel@tonic-gate /* assoc start-up time { sctpAssocEntry 16 } */ 16177c478bd9Sstevel@tonic-gate uint32_t sctpAssocStartTime; 16187c478bd9Sstevel@tonic-gate struct sctpConnEntryInfo_s { 16197c478bd9Sstevel@tonic-gate /* amount of data in send Q */ 16207c478bd9Sstevel@tonic-gate Gauge ce_sendq; 16217c478bd9Sstevel@tonic-gate /* amount of data in recv Q */ 16227c478bd9Sstevel@tonic-gate Gauge ce_recvq; 16237c478bd9Sstevel@tonic-gate /* currect send window size */ 16247c478bd9Sstevel@tonic-gate Gauge ce_swnd; 16257c478bd9Sstevel@tonic-gate /* currenct receive window size */ 16267c478bd9Sstevel@tonic-gate Gauge ce_rwnd; 16277c478bd9Sstevel@tonic-gate /* current max segment size */ 16287c478bd9Sstevel@tonic-gate Gauge ce_mss; 16297c478bd9Sstevel@tonic-gate } sctpConnEntryInfo; 16307c478bd9Sstevel@tonic-gate } mib2_sctpConnEntry_t; 16317c478bd9Sstevel@tonic-gate 16327c478bd9Sstevel@tonic-gate typedef struct mib2_sctpConnLocalAddrEntry { 16337c478bd9Sstevel@tonic-gate /* connection identifier */ 16347c478bd9Sstevel@tonic-gate uint32_t sctpAssocId; 16357c478bd9Sstevel@tonic-gate /* type of local addr { sctpAssocLocalEntry 1 } */ 16367c478bd9Sstevel@tonic-gate int sctpAssocLocalAddrType; 16377c478bd9Sstevel@tonic-gate /* local address { sctpAssocLocalEntry 2 } */ 16387c478bd9Sstevel@tonic-gate Ip6Address sctpAssocLocalAddr; 16397c478bd9Sstevel@tonic-gate } mib2_sctpConnLocalEntry_t; 16407c478bd9Sstevel@tonic-gate 16417c478bd9Sstevel@tonic-gate typedef struct mib2_sctpConnRemoteAddrEntry { 16427c478bd9Sstevel@tonic-gate /* connection identier */ 16437c478bd9Sstevel@tonic-gate uint32_t sctpAssocId; 16447c478bd9Sstevel@tonic-gate /* remote addr type { sctpAssocRemEntry 1 } */ 16457c478bd9Sstevel@tonic-gate int sctpAssocRemAddrType; 16467c478bd9Sstevel@tonic-gate /* remote address { sctpAssocRemEntry 2 } */ 16477c478bd9Sstevel@tonic-gate Ip6Address sctpAssocRemAddr; 16487c478bd9Sstevel@tonic-gate /* is the address active { sctpAssocRemEntry 3 } */ 16497c478bd9Sstevel@tonic-gate int sctpAssocRemAddrActive; 16507c478bd9Sstevel@tonic-gate /* whether hearbeat is active { sctpAssocRemEntry 4 } */ 16517c478bd9Sstevel@tonic-gate int sctpAssocRemAddrHBActive; 16527c478bd9Sstevel@tonic-gate /* current RTO { sctpAssocRemEntry 5 } */ 16537c478bd9Sstevel@tonic-gate uint32_t sctpAssocRemAddrRTO; 16547c478bd9Sstevel@tonic-gate /* max # of rexmits before becoming inactive */ 16557c478bd9Sstevel@tonic-gate uint32_t sctpAssocRemAddrMaxPathRtx; /* {sctpAssocRemEntry 6} */ 16567c478bd9Sstevel@tonic-gate /* # of rexmits to this dest { sctpAssocRemEntry 7 } */ 16577c478bd9Sstevel@tonic-gate uint32_t sctpAssocRemAddrRtx; 16587c478bd9Sstevel@tonic-gate } mib2_sctpConnRemoteEntry_t; 16597c478bd9Sstevel@tonic-gate 16607c478bd9Sstevel@tonic-gate 16617c478bd9Sstevel@tonic-gate 16627c478bd9Sstevel@tonic-gate /* Pack data in mib2_sctp to make struct size the same for 32- and 64-bits */ 16637c478bd9Sstevel@tonic-gate #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 16647c478bd9Sstevel@tonic-gate #pragma pack(4) 16657c478bd9Sstevel@tonic-gate #endif 16667c478bd9Sstevel@tonic-gate 16677c478bd9Sstevel@tonic-gate typedef struct mib2_sctp { 16687c478bd9Sstevel@tonic-gate /* algorithm used to determine rto { sctpParams 1 } */ 16697c478bd9Sstevel@tonic-gate int sctpRtoAlgorithm; 16707c478bd9Sstevel@tonic-gate /* min RTO in msecs { sctpParams 2 } */ 16717c478bd9Sstevel@tonic-gate uint32_t sctpRtoMin; 16727c478bd9Sstevel@tonic-gate /* max RTO in msecs { sctpParams 3 } */ 16737c478bd9Sstevel@tonic-gate uint32_t sctpRtoMax; 16747c478bd9Sstevel@tonic-gate /* initial RTO in msecs { sctpParams 4 } */ 16757c478bd9Sstevel@tonic-gate uint32_t sctpRtoInitial; 16767c478bd9Sstevel@tonic-gate /* max # of assocs { sctpParams 5 } */ 16777c478bd9Sstevel@tonic-gate int32_t sctpMaxAssocs; 16787c478bd9Sstevel@tonic-gate /* cookie lifetime in msecs { sctpParams 6 } */ 16797c478bd9Sstevel@tonic-gate uint32_t sctpValCookieLife; 16807c478bd9Sstevel@tonic-gate /* max # of retrans in startup { sctpParams 7 } */ 16817c478bd9Sstevel@tonic-gate uint32_t sctpMaxInitRetr; 16827c478bd9Sstevel@tonic-gate /* # of conns ESTABLISHED, SHUTDOWN-RECEIVED or SHUTDOWN-PENDING */ 16837c478bd9Sstevel@tonic-gate Counter32 sctpCurrEstab; /* { sctpStats 1 } */ 16847c478bd9Sstevel@tonic-gate /* # of active opens { sctpStats 2 } */ 16857c478bd9Sstevel@tonic-gate Counter32 sctpActiveEstab; 16867c478bd9Sstevel@tonic-gate /* # of passive opens { sctpStats 3 } */ 16877c478bd9Sstevel@tonic-gate Counter32 sctpPassiveEstab; 16887c478bd9Sstevel@tonic-gate /* # of aborted conns { sctpStats 4 } */ 16897c478bd9Sstevel@tonic-gate Counter32 sctpAborted; 16907c478bd9Sstevel@tonic-gate /* # of graceful shutdowns { sctpStats 5 } */ 16917c478bd9Sstevel@tonic-gate Counter32 sctpShutdowns; 16927c478bd9Sstevel@tonic-gate /* # of OOB packets { sctpStats 6 } */ 16937c478bd9Sstevel@tonic-gate Counter32 sctpOutOfBlue; 16947c478bd9Sstevel@tonic-gate /* # of packets discarded due to cksum { sctpStats 7 } */ 16957c478bd9Sstevel@tonic-gate Counter32 sctpChecksumError; 16967c478bd9Sstevel@tonic-gate /* # of control chunks sent { sctpStats 8 } */ 16977c478bd9Sstevel@tonic-gate Counter64 sctpOutCtrlChunks; 16987c478bd9Sstevel@tonic-gate /* # of ordered data chunks sent { sctpStats 9 } */ 16997c478bd9Sstevel@tonic-gate Counter64 sctpOutOrderChunks; 17007c478bd9Sstevel@tonic-gate /* # of unordered data chunks sent { sctpStats 10 } */ 17017c478bd9Sstevel@tonic-gate Counter64 sctpOutUnorderChunks; 17027c478bd9Sstevel@tonic-gate /* # of retransmitted data chunks */ 17037c478bd9Sstevel@tonic-gate Counter64 sctpRetransChunks; 17047c478bd9Sstevel@tonic-gate /* # of SACK chunks sent */ 17057c478bd9Sstevel@tonic-gate Counter sctpOutAck; 17067c478bd9Sstevel@tonic-gate /* # of delayed ACK timeouts */ 17077c478bd9Sstevel@tonic-gate Counter sctpOutAckDelayed; 17087c478bd9Sstevel@tonic-gate /* # of SACK chunks sent to update window */ 17097c478bd9Sstevel@tonic-gate Counter sctpOutWinUpdate; 17107c478bd9Sstevel@tonic-gate /* # of fast retransmits */ 17117c478bd9Sstevel@tonic-gate Counter sctpOutFastRetrans; 17127c478bd9Sstevel@tonic-gate /* # of window probes sent */ 17137c478bd9Sstevel@tonic-gate Counter sctpOutWinProbe; 17147c478bd9Sstevel@tonic-gate /* # of control chunks received { sctpStats 11 } */ 17157c478bd9Sstevel@tonic-gate Counter64 sctpInCtrlChunks; 17167c478bd9Sstevel@tonic-gate /* # of ordered data chunks rcvd { sctpStats 12 } */ 17177c478bd9Sstevel@tonic-gate Counter64 sctpInOrderChunks; 17187c478bd9Sstevel@tonic-gate /* # of unord data chunks rcvd { sctpStats 13 } */ 17197c478bd9Sstevel@tonic-gate Counter64 sctpInUnorderChunks; 17207c478bd9Sstevel@tonic-gate /* # of received SACK chunks */ 17217c478bd9Sstevel@tonic-gate Counter sctpInAck; 17227c478bd9Sstevel@tonic-gate /* # of received SACK chunks with duplicate TSN */ 17237c478bd9Sstevel@tonic-gate Counter sctpInDupAck; 17247c478bd9Sstevel@tonic-gate /* # of SACK chunks acking unsent data */ 17257c478bd9Sstevel@tonic-gate Counter sctpInAckUnsent; 17267c478bd9Sstevel@tonic-gate /* # of Fragmented User Messages { sctpStats 14 } */ 17277c478bd9Sstevel@tonic-gate Counter64 sctpFragUsrMsgs; 17287c478bd9Sstevel@tonic-gate /* # of Reassembled User Messages { sctpStats 15 } */ 17297c478bd9Sstevel@tonic-gate Counter64 sctpReasmUsrMsgs; 17307c478bd9Sstevel@tonic-gate /* # of Sent SCTP Packets { sctpStats 16 } */ 17317c478bd9Sstevel@tonic-gate Counter64 sctpOutSCTPPkts; 17327c478bd9Sstevel@tonic-gate /* # of Received SCTP Packets { sctpStats 17 } */ 17337c478bd9Sstevel@tonic-gate Counter64 sctpInSCTPPkts; 17347c478bd9Sstevel@tonic-gate /* # of invalid cookies received */ 17357c478bd9Sstevel@tonic-gate Counter sctpInInvalidCookie; 17367c478bd9Sstevel@tonic-gate /* total # of retransmit timeouts */ 17377c478bd9Sstevel@tonic-gate Counter sctpTimRetrans; 17387c478bd9Sstevel@tonic-gate /* total # of retransmit timeouts dropping the connection */ 17397c478bd9Sstevel@tonic-gate Counter sctpTimRetransDrop; 17407c478bd9Sstevel@tonic-gate /* total # of heartbeat probes */ 17417c478bd9Sstevel@tonic-gate Counter sctpTimHeartBeatProbe; 17427c478bd9Sstevel@tonic-gate /* total # of heartbeat timeouts dropping the connection */ 17437c478bd9Sstevel@tonic-gate Counter sctpTimHeartBeatDrop; 17447c478bd9Sstevel@tonic-gate /* total # of conns refused due to backlog full on listen */ 17457c478bd9Sstevel@tonic-gate Counter sctpListenDrop; 17467c478bd9Sstevel@tonic-gate /* total # of pkts received after the association has closed */ 17477c478bd9Sstevel@tonic-gate Counter sctpInClosed; 17487c478bd9Sstevel@tonic-gate int sctpEntrySize; 17497c478bd9Sstevel@tonic-gate int sctpLocalEntrySize; 17507c478bd9Sstevel@tonic-gate int sctpRemoteEntrySize; 17517c478bd9Sstevel@tonic-gate } mib2_sctp_t; 17527c478bd9Sstevel@tonic-gate 17537c478bd9Sstevel@tonic-gate #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4 17547c478bd9Sstevel@tonic-gate #pragma pack() 17557c478bd9Sstevel@tonic-gate #endif 17567c478bd9Sstevel@tonic-gate 17577c478bd9Sstevel@tonic-gate 17587c478bd9Sstevel@tonic-gate #ifdef __cplusplus 17597c478bd9Sstevel@tonic-gate } 17607c478bd9Sstevel@tonic-gate #endif 17617c478bd9Sstevel@tonic-gate 17627c478bd9Sstevel@tonic-gate #endif /* _INET_MIB2_H */ 1763