Bug 70332 - pump doesn't reset gateway and dns to new lease values
Summary: pump doesn't reset gateway and dns to new lease values
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: pump
Version: 7.1
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Eido Inoue
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-07-31 17:06 UTC by Mike Iglesias
Modified: 2007-04-18 16:45 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-08-23 20:45:58 UTC
Embargoed:


Attachments (Terms of Use)

Description Mike Iglesias 2002-07-31 17:06:09 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.77 [en] (X11; U; Linux 2.4.9-21smp i686)

Description of problem:
If pump cannot renew a lease and tries to get a new one, it does not reset the
gateway and dns server with information from the new lease.

Consider the following scenario:

You have a switch that blocks access until you have authenticated.  pump asks
for an IP address, and the switch hands out a private address (192.168.1.x) with
a very short renewal time (3 secs).  The user opens a web browser and the switch
gives out a web page with a login and password box.  The user types in a login
and password, and the switch validates them, unblocks the port and stops
replying to the dhcp lease renewals.

pump notices that the lease renewals are being ignored, and logs that
fact.  It now tries to get a new lease, and since the switch port is unblocked,
the dhcp requests go to the real server which responds with correct information
for the network the system is on.  This includes the real gateway and dns server
information.  Pump doesn't call the routines to set the default gateway or
update /etc/resolv.conf in this case, but does update the interface's IP address
to the correct value. This leaves the system in a state where it can't talk to
other systems.


Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. see above
2.
3.
	

Actual Results:  The gateway and dns servers are not updated correctly.

Expected Results:  The gateway and dns servers should be updated as per the
lease info.


Additional info:

This patch fixes the problem.

--- pump.c.dist	Wed Feb 28 23:15:22 2001
+++ pump.c	Wed Jul 31 09:36:00 2002
@@ -427,6 +427,13 @@
 				intf[i] = intf[numInterfaces - 1];
 				numInterfaces--;
 			    } else {
+			        if ((intf[closest].set & PUMP_NETINFO_HAS_GATEWAY) &&
+			 		!(o->flags & OVERRIDE_FLAG_NOGATEWAY))
+					pumpSetupDefaultGateway(&intf[closest].gateway);
+
+			        setupDns(intf + closest, o);
+		    		setupDomain(intf + closest, o);
+
 				callScript(o->script, PUMP_SCRIPT_NEWLEASE,
 					   &intf[closest]);
                             }

Comment 1 Eido Inoue 2004-08-23 20:45:58 UTC
in cvs, not pkg


Note You need to log in before you can comment on or make changes to this bug.