⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 inetcidrroutetable.c

📁 snmp的源代码,已经在我的ubuntu下编译通过
💻 C
📖 第 1 页 / 共 5 页
字号:
 * OID: .1.3.6.1.2.1.4.24.7.1.7 * Description:The ifIndex value which identifies the local interface                 through which the next hop of this route should be                  reached.  A value of 0 is valid and represents the                 scenario where no interface is specified. * * Attributes: *   accessible 1     isscalar 0     enums  0      hasdefval 0 *   readable   1     iscolumn 1     ranges 1      hashint   1 *   settable   1 *   hint: d * * Ranges:  0 - 2147483647; * * Its syntax is InterfaceIndexOrZero (based on perltype INTEGER32) * The net-snmp type is ASN_INTEGER. The C type decl is long (long) *//** * Extract the current value of the inetCidrRouteIfIndex data. * * Set a value using the data context for the row. * * @param rowreq_ctx *        Pointer to the row request context. * @param inetCidrRouteIfIndex_val_ptr *        Pointer to storage for a long variable * * @retval MFD_SUCCESS         : success * @retval MFD_SKIP            : skip this node (no value for now) * @retval MFD_ERROR           : Any other error */intinetCidrRouteIfIndex_get(inetCidrRouteTable_rowreq_ctx * rowreq_ctx,                         long *inetCidrRouteIfIndex_val_ptr){   /** we should have a non-NULL pointer */    netsnmp_assert(NULL != inetCidrRouteIfIndex_val_ptr);    DEBUGMSGTL(("verbose:inetCidrRouteTable:inetCidrRouteIfIndex_get",                "called\n"));    netsnmp_assert(NULL != rowreq_ctx);    /*     * TODO:231:o: |-> Extract the current value of the inetCidrRouteIfIndex data.     * set (* inetCidrRouteIfIndex_val_ptr ) from rowreq_ctx->data     */    (*inetCidrRouteIfIndex_val_ptr) = rowreq_ctx->data->if_index;    return MFD_SUCCESS;}                               /* inetCidrRouteIfIndex_get *//*--------------------------------------------------------------------- * IP-FORWARD-MIB::inetCidrRouteEntry.inetCidrRouteType * inetCidrRouteType is subid 8 of inetCidrRouteEntry. * Its status is Current, and its access level is Create. * OID: .1.3.6.1.2.1.4.24.7.1.8 * Description:The type of route.  Note that local(3) refers to a                  route for which the next hop is the final destination;                  remote(4)refers to a route for which the next hop is                  not the final destination.                 Routes which do not result in traffic forwarding or                 rejection should not be displayed even if the                  implementation keeps them stored internally.                 reject(2) refers to a route which, if matched, discards                  the message as unreachable and returns a notification                  (e.g. ICMP error) to the message sender.  This is used                  in some protocols as a means of correctly aggregating                  routes.                 blackhole(5) refers to a route which, if matched,                  discards the message silently. * * Attributes: *   accessible 1     isscalar 0     enums  1      hasdefval 0 *   readable   1     iscolumn 1     ranges 0      hashint   0 *   settable   1 * * Enum range: 3/8. Values:  other(1), reject(2), local(3), remote(4), blackhole(5) * * Its syntax is INTEGER (based on perltype INTEGER) * The net-snmp type is ASN_INTEGER. The C type decl is long (u_long) *//** * Extract the current value of the inetCidrRouteType data. * * Set a value using the data context for the row. * * @param rowreq_ctx *        Pointer to the row request context. * @param inetCidrRouteType_val_ptr *        Pointer to storage for a long variable * * @retval MFD_SUCCESS         : success * @retval MFD_SKIP            : skip this node (no value for now) * @retval MFD_ERROR           : Any other error */intinetCidrRouteType_get(inetCidrRouteTable_rowreq_ctx * rowreq_ctx,                      u_long * inetCidrRouteType_val_ptr){   /** we should have a non-NULL pointer */    netsnmp_assert(NULL != inetCidrRouteType_val_ptr);    DEBUGMSGTL(("verbose:inetCidrRouteTable:inetCidrRouteType_get",                "called\n"));    netsnmp_assert(NULL != rowreq_ctx);    /*     * TODO:231:o: |-> Extract the current value of the inetCidrRouteType data.     * set (* inetCidrRouteType_val_ptr ) from rowreq_ctx->data     */    (*inetCidrRouteType_val_ptr) = rowreq_ctx->data->rt_type;    return MFD_SUCCESS;}                               /* inetCidrRouteType_get *//*--------------------------------------------------------------------- * IP-FORWARD-MIB::inetCidrRouteEntry.inetCidrRouteProto * inetCidrRouteProto is subid 9 of inetCidrRouteEntry. * Its status is Current, and its access level is ReadOnly. * OID: .1.3.6.1.2.1.4.24.7.1.9 * Description:The routing mechanism via which this route was learned.                 Inclusion of values for gateway routing protocols is                  not intended to imply that hosts should support those                 protocols. * * Attributes: *   accessible 1     isscalar 0     enums  1      hasdefval 0 *   readable   1     iscolumn 1     ranges 0      hashint   0 *   settable   0 * * Enum range: 13/32. Values:  other(1), local(2), netmgmt(3), icmp(4), egp(5), ggp(6), hello(7), rip(8), isIs(9), esIs(10), ciscoIgrp(11), bbnSpfIgp(12), ospf(13), bgp(14), idpr(15), ciscoEigrp(16), dvmrp(17) * * Its syntax is IANAipRouteProtocol (based on perltype INTEGER) * The net-snmp type is ASN_INTEGER. The C type decl is long (u_long) *//** * Extract the current value of the inetCidrRouteProto data. * * Set a value using the data context for the row. * * @param rowreq_ctx *        Pointer to the row request context. * @param inetCidrRouteProto_val_ptr *        Pointer to storage for a long variable * * @retval MFD_SUCCESS         : success * @retval MFD_SKIP            : skip this node (no value for now) * @retval MFD_ERROR           : Any other error */intinetCidrRouteProto_get(inetCidrRouteTable_rowreq_ctx * rowreq_ctx,                       u_long * inetCidrRouteProto_val_ptr){   /** we should have a non-NULL pointer */    netsnmp_assert(NULL != inetCidrRouteProto_val_ptr);    DEBUGMSGTL(("verbose:inetCidrRouteTable:inetCidrRouteProto_get",                "called\n"));    netsnmp_assert(NULL != rowreq_ctx);    /*     * TODO:231:o: |-> Extract the current value of the inetCidrRouteProto data.     * set (* inetCidrRouteProto_val_ptr ) from rowreq_ctx->data     */    (*inetCidrRouteProto_val_ptr) = rowreq_ctx->data->rt_proto;    return MFD_SUCCESS;}                               /* inetCidrRouteProto_get *//*--------------------------------------------------------------------- * IP-FORWARD-MIB::inetCidrRouteEntry.inetCidrRouteAge * inetCidrRouteAge is subid 10 of inetCidrRouteEntry. * Its status is Current, and its access level is ReadOnly. * OID: .1.3.6.1.2.1.4.24.7.1.10 * Description:The number of seconds since this route was last updated                  or otherwise determined to be correct.  Note that no                  semantics of 'too old' can be implied except through                  knowledge of the routing protocol by which the route                  was learned. * * Attributes: *   accessible 1     isscalar 0     enums  0      hasdefval 0 *   readable   1     iscolumn 1     ranges 0      hashint   0 *   settable   0 * * * Its syntax is GAUGE (based on perltype GAUGE) * The net-snmp type is ASN_GAUGE. The C type decl is u_long (u_long) *//** * Extract the current value of the inetCidrRouteAge data. * * Set a value using the data context for the row. * * @param rowreq_ctx *        Pointer to the row request context. * @param inetCidrRouteAge_val_ptr *        Pointer to storage for a u_long variable * * @retval MFD_SUCCESS         : success * @retval MFD_SKIP            : skip this node (no value for now) * @retval MFD_ERROR           : Any other error */intinetCidrRouteAge_get(inetCidrRouteTable_rowreq_ctx * rowreq_ctx,                     u_long * inetCidrRouteAge_val_ptr){   /** we should have a non-NULL pointer */    netsnmp_assert(NULL != inetCidrRouteAge_val_ptr);    DEBUGMSGTL(("verbose:inetCidrRouteTable:inetCidrRouteAge_get",                "called\n"));    netsnmp_assert(NULL != rowreq_ctx);    /*     * TODO:231:o: |-> Extract the current value of the inetCidrRouteAge data.     * set (* inetCidrRouteAge_val_ptr ) from rowreq_ctx->data     */    (*inetCidrRouteAge_val_ptr) = rowreq_ctx->data->rt_age;    return MFD_SUCCESS;}                               /* inetCidrRouteAge_get *//*--------------------------------------------------------------------- * IP-FORWARD-MIB::inetCidrRouteEntry.inetCidrRouteNextHopAS * inetCidrRouteNextHopAS is subid 11 of inetCidrRouteEntry. * Its status is Current, and its access level is Create. * OID: .1.3.6.1.2.1.4.24.7.1.11 * Description:The Autonomous System Number of the Next Hop.  The                  semantics of this object are determined by the routing-                 protocol specified in the route's inetCidrRouteProto                  value. When this object is unknown or not relevant its                  value should be set to zero. * * Attributes: *   accessible 1     isscalar 0     enums  0      hasdefval 1 *   readable   1     iscolumn 1     ranges 0      hashint   1 *   settable   1 *   defval: 0 *   hint: d * * * Its syntax is InetAutonomousSystemNumber (based on perltype UNSIGNED32) * The net-snmp type is ASN_UNSIGNED. The C type decl is u_long (u_long) *//** * Extract the current value of the inetCidrRouteNextHopAS data. * * Set a value using the data context for the row. * * @param rowreq_ctx *        Pointer to the row request context. * @param inetCidrRouteNextHopAS_val_ptr *        Pointer to storage for a u_long variable * * @retval MFD_SUCCESS         : success * @retval MFD_SKIP            : skip this node (no value for now) * @retval MFD_ERROR           : Any other error */intinetCidrRouteNextHopAS_get(inetCidrRouteTable_rowreq_ctx * rowreq_ctx,                           u_long * inetCidrRouteNextHopAS_val_ptr){   /** we should have a non-NULL pointer */    netsnmp_assert(NULL != inetCidrRouteNextHopAS_val_ptr);    DEBUGMSGTL(("verbose:inetCidrRouteTable:inetCidrRouteNextHopAS_get",                "called\n"));    netsnmp_assert(NULL != rowreq_ctx);    /*     * TODO:231:o: |-> Extract the current value of the inetCidrRouteNextHopAS data.     * set (* inetCidrRouteNextHopAS_val_ptr ) from rowreq_ctx->data     */    (*inetCidrRouteNextHopAS_val_ptr) = rowreq_ctx->data->rt_nexthop_as;    return MFD_SUCCESS;}                               /* inetCidrRouteNextHopAS_get *//*--------------------------------------------------------------------- * IP-FORWARD-MIB::inetCidrRouteEntry.inetCidrRouteMetric1 * inetCidrRouteMetric1 is subid 12 of inetCidrRouteEntry. * Its status is Current, and its access level is Create. * OID: .1.3.6.1.2.1.4.24.7.1.12 * Description:The primary routing metric for this route.  The                  semantics of this metric are determined by the routing-                 protocol specified in the route's inetCidrRouteProto                  value.  If this metric is not used, its value should be                  set to -1. * * Attributes: *   accessible 1     isscalar 0     enums  0      hasdefval 1 *   readable   1     iscolumn 1     ranges 0      hashint   0 *   settable   1 *   defval: -1 * * * Its syntax is INTEGER32 (based on perltype INTEGER32) * The net-snmp type is ASN_INTEGER. The C type decl is long (long) *//** * Extract the current value of the inetCidrRouteMetric1 data. * * Set a value using the data context for the row. * * @param rowreq_ctx *        Pointer to the row request context. * @param inetCidrRouteMetric1_val_ptr *        Pointer to storage for a long variable * * @retval MFD_SUCCESS         : success * @retval MFD_SKIP            : skip this node (no value for now) * @retval MFD_ERROR           : Any other error */intinetCidrRouteMetric1_get(inetCidrRouteTable_rowreq_ctx * rowreq_ctx,                         long *inetCidrRouteMetric1_val_ptr){   /** we should have a non-NULL pointer */    netsnmp_assert(NULL != inetCidrRouteMetric1_val_ptr);    DEBUGMSGTL(("verbose:inetCidrRouteTable:inetCidrRouteMetric1_get",                "called\n"));    netsnmp_assert(NULL != rowreq_ctx);    /*     * TODO:231:o: |-> Extract the current value of the inetCidrRouteMetric1 data.     * set (* inetCidrRouteMetric1_val_ptr ) from rowreq_ctx->data     */    (*inetCidrRouteMetric1_val_ptr) = rowreq_ctx->data->rt_metric1;    return MFD_SUCCESS;}                               /* inetCidrRouteMetric1_get *//*--------------------------------------------------------------------- * IP-FORWARD-MIB::inetCidrRouteEntry.inetCidrRouteMetric2 * inetCidrRouteMetric2 is subid 13 of inetCidrRouteEntry. * Its status is Current, and its access level is Create. * OID: .1.3.6.1.2.1.4.24.7.1.13 * Description:An alternate routing metric for this route.  The                  semantics of this metric are determined by the routing-                 protocol specified in the route's inetCidrRouteProto                  value.  If this metric is not used, its value should be  

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -