Commit Graph

59 Commits

Author SHA1 Message Date
brooks
62ebe3a4fd MFC rev 1.5: Mention the -b flag in the SYNOPSIS. 2006-01-24 06:03:16 +00:00
brooks
38fe71cbe9 MFC rev 1.11:
When we give up on an interface, use the arp(8) command to remove all
  entries from the interface rather than using ifconfig's delete command.
  This preserves non-dhclient configured addresses (though they are wiped
  out when dhclient is restarted).
2006-01-24 06:01:59 +00:00
brooks
afb310880a MFC rev 1.13: Allow users to add aliases to the interface.
PR:		bin/87465
2006-01-24 05:59:27 +00:00
brooks
964ba286a9 MFC 1.5: we now support BPF write filters unconditionally. 2005-12-20 21:11:16 +00:00
brooks
a2aee2ad8e MFC 1.12:
When we get a bogus hostname in an option, drop the option
	rather than refusing the lease.  This allow obtaining leases
	on misadministered networks that use host names with
	underscores in them.

Reminded by:	avatar
2005-12-20 21:02:22 +00:00
brooks
95d5cce419 Sync dhclient with HEAD with exception of bpf.c:1.5.
sbin/dhclient/*.c:
 - add __FBSDID
sbin/dhclient/conflex.c: 1.3-1.4
 - fix a minor buffer overflow in config parsing
 - actually support backslash escaping in config files
bin/dhclient/dhclient-script: 1.6-1.10
 - don't create or remove routes to our address through 127.0.0.1
 - improved detection of the interface of the default route
 - support quotes in the medium string
 - clear interface state more effectively on failure
 - don't update resolv.conf when unchanged
bin/dhclient/dhclient.c: 1.10-1.11
 - validate domain-name (used as resolv.conf search string)
 - handle superseded subnet-mask correctly

Approved by:	re (scottl)
2005-09-10 17:01:16 +00:00
brooks
7b1f88bc8a Sync dhclient with HEAD:
- Don't complain when debouncing dhclient startup.
 - Fix buffer handling in reveive_packet().  This fixes infinite cpu
   eating loops and probably some crashes.
 - Spell if_defaultroute route correctly in dhclient-script so we
   are allowed to change the default route.
 - Document dhclient -b.
 - Treat reassociation like association.
 - Do not force server-name to be a valid domain name.
 - Handle servers that send NUL-terminated host-name options.

Approved by:	re (scottl)
2005-07-29 23:36:28 +00:00
brooks
fd1962d203 Don't complain when we receive smtp, pop, nntp, www, finger, and irc
server options.

Reported by:	Max Boyarov <max_b at tut dot by>
Approved by:	re (dhclient blanket)
2005-06-30 05:50:52 +00:00
brooks
b862e39773 People like to do RFC violating things with the domain-name option and
include a space seperated list of domains instead of the domain of the
host.  This is supported on too many platforms to break for now so,
remove validation of this option for the moment.

The correct solution longer term is to implement RFC 3397 support and
then treat domain-name options containing space seperated lists of
domains as domain-search options for backwards compatability.

Approved by:	re (dhclient blanket)
2005-06-30 05:32:42 +00:00
ru
f185aed84f Install the dhcp-options.5 manpage.
Timeout from:	brooks
Approved by:	re (blanket manpages)
2005-06-25 11:03:06 +00:00
ru
557bdadf66 Line up the markup.
Approved by:	re (blanket)
2005-06-22 14:55:59 +00:00
brooks
d6e60e9b86 Avoid a null pointer dereference by not expiring our lease if we don't
have an active one.

Submitted by:	sam
Reported by:	James Snow <snow at teardrop dot org>
Approved by:	re (dhclient blanket)
2005-06-13 23:43:08 +00:00
brooks
a3df0b2237 Add support for /etc/dhclient-enter-hooks to match /etc/dhclient-exit-hooks. 2005-06-10 03:41:18 +00:00
brooks
dbc80a24b5 Add support for /etc/dhclient-exit-hooks file.
Tested by:	Max Boyarov <max_b at tut dot by>
2005-06-08 18:21:56 +00:00
brooks
8ab6a79677 Fix build on 64-bit platforms where time_t is 64 bit. Since where
talking about time related to leases, it should be OK to cast these to
(int)s rather than using intmax_t.

Submitted by:	ru
Pointy hat:	brooks
2005-06-07 14:47:54 +00:00
ru
f1edfd67ca - Remove OpenBSD'ism (bsd.own.mk).
- Remove redundant and harmful -Wall from CFLAGS.
2005-06-07 09:32:23 +00:00
brooks
9a851b1b81 Use SCRIPTS to install dhclient-script instead of rolling our own. 2005-06-07 04:35:48 +00:00
brooks
f5d3bb73c0 FreeBSDize the dhclient-script.
Submitted by:	sam
2005-06-07 04:32:29 +00:00
brooks
26a535f115 Define _PATH_VAREMPTY.
Add a -b option to background immediatly.

Add support for 802.11 routing messages to "instantly" renegotiate
at lease when we associate with a new network.

Submitted by:	sam
2005-06-07 04:26:14 +00:00
brooks
c93fbf7bf1 NULL is not a valid time_t.
Submitted by:	sam
2005-06-07 04:14:54 +00:00
brooks
bfb49a1939 We don't support BPF write filters at this time.
Submitted by:	sam
2005-06-07 04:13:52 +00:00
brooks
df346bd933 Take the OpenBSD version of the Makefile to resolve conflicts as the old
one is irrelevent.  Add $FreeBSD.
2005-06-07 04:08:50 +00:00
brooks
95219de6ac This commit was generated by cvs2svn to compensate for changes in r147072,
which included commits to RCS files with non-trunk default branches.
2005-06-07 04:05:09 +00:00
brooks
9066b3f834 Import the OpenBSD dhclient as shipped with OpenBSD-3.7 (the tag
OPENBSD_3_7).
2005-06-07 04:05:09 +00:00
brooks
490c515d02 Remove the bits to build the isc-dhclient. 2005-06-07 04:02:10 +00:00
ru
e68efdc747 Let bsd.prog.mk set SRCS and MAN to their default values. 2005-01-28 16:08:11 +00:00
ru
cec60429bb Start the dreaded NOFOO -> NO_FOO conversion.
OK'ed by:	core
2004-12-21 08:47:35 +00:00
ru
5db2b9d5b3 For variables that are only checked with defined(), don't provide
any fake value.
2004-10-24 15:33:08 +00:00
johan
31854a224a style.Makefile(5):
Use WARNS?= instead of WARNS=.
2004-02-23 20:25:27 +00:00
murray
f9be70e213 Update maintainer line. mbr has been maintainer for at least the last
6 months.

Approved by:	re (murray)
2003-11-30 21:09:58 +00:00
mbr
28b45f597c Turn the annoying and long error message off. It was so
long that it was even hard to find the real error cause.

Requested by:	rwatson
2003-08-09 20:36:06 +00:00
mbr
6416064bd6 Enable dhclient to poll the interface state and send only
requests if the interface has an active link. This is a
great benefit if you often change networks with your laptop
and you do not like to kill/restart dhclient all the time.
Changes are automatically detected and the link is refreshed.

The change allows us to start dhclient in background mode
Enable dhclient to poll the interface state and send only
requests if the interface has an active link. This is a
great benefit if you often change networks with your laptop
and you do not like to kill/restart dhclient all the time.
Changes are automatically detected and the link is refreshed.

The change allows us to start dhclient in background mode
while the network cable is not plugged in.

To control the polling interval, the option -i has been
introduced. It takes seconds as parameter, the minimum is
one second, the default is five seconds.

Polling is done in seconds, not microseconds, because dhclient
does internally work with timeouts in seconds.

This change will be part of the next major ISC-dhcpd release.

Tested by:	bms, imp, and many many others.
Reviewed by:	murray, eivind, dhclient folks
2003-07-28 08:30:11 +00:00
gordon
6b7019d5ed Tweak a couple of utilities so they compile cleanly for /rescue. Mostly
path fixes.

Submitted by:	Tim Kientzle <kientzle@acm.org>
2003-06-29 18:46:18 +00:00
mdodd
f74cd6a71b Hook omshell(1) up to the build. 2003-03-25 03:16:53 +00:00
mdodd
27882ca963 Building crunched things by hand (regenerating boot floppies for example)
without a full make release cycle fails as the correct include path
isn't setup.
2003-03-25 03:13:57 +00:00
ru
bc2e1305d8 Removed now unused INTERNALSTATICLIB.
INTERNALLIB now implies NOPIC and NOPROFILE.
Removed gratuitous NOMAN.
2002-05-13 11:09:07 +00:00
obrien
d22011437e Do not use perl where sed is more than adequate. 2002-04-13 23:53:36 +00:00
matusita
b60aca7d4b Fix "make release.4" breakage.
src/contrib/isc-dhcp/includes/minires/resolv.h has a 'extern' definition
but it makes an error when linking crunched binary just like this:

	dhclient.lo: In function `MRres_nquery':
	dhclient.lo(.text+0x2dcce): undefined reference to `__h_errno_set'
	dhclient.lo(.text+0x2dd5b): undefined reference to `__h_errno_set'
	dhclient.lo: In function `MRres_nquerydomain':
	dhclient.lo(.text+0x2de53): undefined reference to `__h_errno_set'

The author understands this will be a problem (see comments in resolv.h).
Murray said that the author will fix this, but as a temporary solution,
modifying the source code and not to use __h_errno_set.

BTW, I'm sorry that previous commitlog in src/sbin/dhclient/Makefile should
read "Found by:" instead of "Confirmed by"; I just found that rev 1.15
has a typo so fixed.

Tested on: ushi.jp.FreeBSD.org with today's 5-current source code.
           (belive me, "make release.4" works fine now)
2002-02-28 16:17:18 +00:00
matusita
ef2430cf70 For unbraking "make release": s/client/common/g
(these files are sitting in src/contrib/isc-dhcp/common, not .../client.)

Confirmed by: 5.0-CURRENT-20020228-JPSNAP at snapshots.jp.FreeBSD.org
2002-02-28 00:02:33 +00:00
murray
4de8d802ca Add some ifdef(RELEASE_CRUNCH) goo to explicitly list the requisite
object files for crunchgen.  Without this patch, release.4 will fail
to build the crunched binaries for the release floppies.
2002-02-26 15:12:54 +00:00
obrien
00825f7188 Neutralize bits of ns_parse.c with bad juju. 2002-02-20 05:45:59 +00:00
obrien
872134cfe5 Style cleanup.
Approved by:	Murray
2002-02-19 22:23:49 +00:00
murray
91492d0f97 Makefile glue for DHCP v3 import. 2002-02-19 12:57:18 +00:00
alfred
60c95d7951 If the dhcpd server doesn't provide a domain name or dns servers then
don't clobber /etc/resolv.conf

Add $FreeBSD.

Submitted by: an j. peterson" <rbw@myplace.org>
Verified fix in: dhcp-3.0.1rc6
PR: misc/34455
2002-02-01 18:46:58 +00:00
obrien
9baf2f1b03 Default to WARNS=2.
Binary builds that cannot handle this must explicitly set WARNS=0.

Reviewed by:	mike
2001-12-04 02:19:58 +00:00
ru
ef2dbc1fb0 beforeinstall -> SCRIPTS. 2001-04-07 11:21:35 +00:00
ru
86642a4ab4 - Backout botched attempt to introduce MANSECT feature.
- MAN[1-9] -> MAN.
2001-03-26 14:33:27 +00:00
nectar
748554442d Add nsswitch support. By creating an /etc/nsswitch.conf file, you can
configure FreeBSD so that various databases such as passwd and group can be
looked up using flat files, NIS, or Hesiod.

= Hesiod has been added to libc (see hesiod(3)).

= A library routine for parsing nsswitch.conf and invoking callback
  functions as specified has been added to libc (see nsdispatch(3)).

= The following C library functions have been modified to use nsdispatch:
    . getgrent, getgrnam, getgrgid
    . getpwent, getpwnam, getpwuid
    . getusershell
    . getaddrinfo
    . gethostbyname, gethostbyname2, gethostbyaddr
    . getnetbyname, getnetbyaddr
    . getipnodebyname, getipnodebyaddr, getnodebyname, getnodebyaddr

= host.conf has been removed from src/etc.  rc.network has been modified
  to warn that host.conf is no longer used at boot time.  In addition, if
  there is a host.conf but no nsswitch.conf, the latter is created at boot
  time from the former.

Obtained from:	NetBSD
2000-09-06 18:16:48 +00:00
obrien
fbf25b131f This commit was generated by cvs2svn to compensate for changes in r63925,
which included commits to RCS files with non-trunk default branches.
2000-07-27 20:49:27 +00:00
obrien
2a5b7e4303 Alternate script for dhclient to use in setting the received configuration
on the host.

PR:		15342
Submitted by:	Patrick Bihan-Faou <patrick@mindstep.com>
2000-07-27 20:49:27 +00:00