]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
fix up snmp_{incoming,outgoing}_addr code
authorwessels <>
Fri, 14 Aug 1998 22:42:02 +0000 (22:42 +0000)
committerwessels <>
Fri, 14 Aug 1998 22:42:02 +0000 (22:42 +0000)
src/cf.data.pre
src/snmp_core.cc
src/structs.h

index 1689f62de3b1613dfcd5490c47195e85079f62a6..b0d871efb8d7f55bbb4b955dea3f28c4834942b6 100644 (file)
@@ -1,6 +1,6 @@
 
 #
-# $Id: cf.data.pre,v 1.94 1998/08/03 19:30:26 wessels Exp $
+# $Id: cf.data.pre,v 1.95 1998/08/14 16:42:02 wessels Exp $
 #
 #
 # SQUID Internet Object Cache  http://squid.nlanr.net/Squid/
@@ -156,7 +156,7 @@ DOC_START
        udp_outgoing_address    is used for ICP packets sent out to other
                                caches.
 
-       The defaults behaviour is to not bind to any specific address.
+       The default behaviour is to not bind to any specific address.
 
        NOTE, udp_incoming_address and udp_outgoing_address can not have
        the same value since they both use port 3130.
@@ -2237,6 +2237,33 @@ DOC_START
                snmp_acl public deny all
 DOC_END
 
+NAME: snmp_incoming_address
+TYPE: address
+LOC: Config.Addrs.snmp_outgoing
+DEFAULT: 0.0.0.0
+IFDEF: SQUID_SNMP
+DOC_NONE
+NAME: snmp_outgoing_address
+TYPE: address
+LOC: Config.Addrs.snmp_outgoing
+DEFAULT: 255.255.255.255
+IFDEF: SQUID_SNMP
+DOC_START
+       Just like 'udp_incoming_address' above, but for the SNMP port.
+
+       snmp_incoming_address   is used for the SNMP socket receiving
+                               messages from SNMP agents.
+       snmp_outgoing_address   is used for SNMP packets returned to SNMP
+                               agents.
+
+       The default behaviour is to not bind to any specific address.
+
+       NOTE, snmp_incoming_address and snmp_outgoing_address can not have
+       the same value since they both use port 3130.
+
+snmp_incoming_address 0.0.0.0
+snmp_outgoing_address 0.0.0.0
+DOC_END
 
 NAME: as_whois_server
 TYPE: string
index edecfb9360967b3372714c412cb1e5875e17ef4a..188b63a2203aa8480a4c0c6da35fdef4349ddf81 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: snmp_core.cc,v 1.7 1998/07/22 20:37:49 wessels Exp $
+ * $Id: snmp_core.cc,v 1.8 1998/08/14 16:42:03 wessels Exp $
  *
  * DEBUG: section 49    SNMP support
  * AUTHOR: Kostas Anagnostakis
@@ -327,7 +327,7 @@ snmpConnectionOpen(void)
        commSetSelect(theInSnmpConnection, COMM_SELECT_READ, snmpHandleUdp, NULL, 0);
        debug(1, 1) ("Accepting SNMP messages on port %d, FD %d.\n",
            (int) port, theInSnmpConnection);
-       if ((addr = Config.Addrs.udp_outgoing).s_addr != no_addr.s_addr) {
+       if ((addr = Config.Addrs.snmp_outgoing).s_addr != no_addr.s_addr) {
            enter_suid();
            theOutSnmpConnection = comm_open(SOCK_DGRAM,
                0,
index defff3eb370bf487db55aedc29523ad2c9265349..f246283e3f5656b311f055123faab45b9656e970 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: structs.h,v 1.196 1998/08/14 09:22:41 wessels Exp $
+ * $Id: structs.h,v 1.197 1998/08/14 16:42:04 wessels Exp $
  *
  *
  * SQUID Internet Object Cache  http://squid.nlanr.net/Squid/
@@ -307,8 +307,10 @@ struct _SquidConfig {
        struct in_addr tcp_outgoing;
        struct in_addr udp_incoming;
        struct in_addr udp_outgoing;
+#if SQUID_SNMP
        struct in_addr snmp_incoming;
        struct in_addr snmp_outgoing;
+#endif
        struct in_addr client_netmask;
     } Addrs;
     size_t tcpRcvBufsz;