OpenBSD CVS

CVS log for src/sbin/dhclient/options.c


[BACK] Up to [local] / src / sbin / dhclient

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.123 / (download) - annotate - [select for diffs], Tue Jul 7 19:48:31 2020 UTC (3 years, 11 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, HEAD
Changes since 1.122: +28 -29 lines
Diff to previous 1.122 (colored)

Revert r1.121 and rewrite merge_option_data() to achieve same effect
w/o using string functions on data that *MIGHT NOT* be NUL
terminated. Fiddle parse_domain_name_list() to avoid string functions
for the same reason.

Problem encountered by Jesper Wallin when running with
vm.malloc_conf=CFGJUR, although he later proved 'J' (more junking) was
the actual trouble maker.

Revision 1.122 / (download) - annotate - [select for diffs], Thu May 21 01:07:52 2020 UTC (4 years ago) by krw
Branch: MAIN
Changes since 1.121: +3 -3 lines
Diff to previous 1.121 (colored)

extract_classless_route() -> extract_route() as there is only the one route
extraction function.

Revision 1.121 / (download) - annotate - [select for diffs], Thu May 14 13:57:13 2020 UTC (4 years ago) by krw
Branch: MAIN
Changes since 1.120: +32 -7 lines
Diff to previous 1.120 (colored)

Massage merge_option_data() to be more careful when dealing with 'D'
(domain search) and 't' (text) options. Enables append/prepend for the
domain-search option by inserting blanks between the domains and
ensures the presence of a terminating NUL when merging text.

Revision 1.120 / (download) - annotate - [select for diffs], Wed Jul 3 03:24:01 2019 UTC (4 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6
Changes since 1.119: +7 -7 lines
Diff to previous 1.119 (colored)

snprintf/vsnprintf return < 0 on error, rather than -1.

Revision 1.119 / (download) - annotate - [select for diffs], Sat Jun 22 19:47:12 2019 UTC (4 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.118: +4 -4 lines
Diff to previous 1.118 (colored)

Swap (opcount >= opleft || opcount == -1) to (opcount == -1 || opcount >= opleft) like
the rest of tree.

Spotted by deraadt@

Revision 1.118 / (download) - annotate - [select for diffs], Tue Apr 2 02:59:43 2019 UTC (5 years, 2 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.117: +54 -117 lines
Diff to previous 1.117 (colored)

Add human readable parsing/display of RFC1035 data in domain-search
option. Replace handrolled dn_expand() with the system
version. Existing hex octet versions still accepted. New format is

option domain-search "my.domain.org", "fw.my.domain.org";

It is now possible to append and prepend domains to the list provided
by the server.

Documention update to dhcp-options(5) in the pipeline!

Inspired by dhcpd(8) domain-search diff from William Ahern.

Code peered at by florian@ and kn@.

Revision 1.117 / (download) - annotate - [select for diffs], Fri Mar 22 16:45:48 2019 UTC (5 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.116: +7 -14 lines
Diff to previous 1.116 (colored)

Revert parts of recent changes to pretty_print_domain_search(). Parts
of WIP escaped into the wild and broke parsing of domain-search.

Reported by Greg Steuck and Raf Czlonka. Fix tested by Greg.

Revision 1.116 / (download) - annotate - [select for diffs], Thu Mar 21 00:45:46 2019 UTC (5 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.115: +3 -3 lines
Diff to previous 1.115 (colored)

Simplify merge_option_data() with strpbrk().

Zap insidious trailing space.

Revision 1.115 / (download) - annotate - [select for diffs], Wed Mar 20 20:10:00 2019 UTC (5 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.114: +51 -1 lines
Diff to previous 1.114 (colored)

Do not accept dhclient.conf(5) "prepend" or "append" statements when
the option data cannot be prepended or appended to. Instead, treat
"prepend" as "supersede" and "append" as "default". This preserves the
safe aspects of current behaviour. Issue a parsing warning when
appropriate to encourage people to fix their configuration files.

Eliminate egregious repeated code by abstracting merge_option_data().

Revision 1.114 / (download) - annotate - [select for diffs], Mon Mar 18 22:26:56 2019 UTC (5 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.113: +18 -10 lines
Diff to previous 1.113 (colored)

Use same idiom for pretty_print_domain_search() and
pretty_print_classless_routes(), making both of them local to
options.c.

Avoids a double pretty print of DHO_DOMAIN_SEARCH, eliminates an
unneeded 1024 byte static array.

Shrinks size of upcoming diff to implement parsing of domain search
option in leases and dhclient.conf.

Revision 1.113 / (download) - annotate - [select for diffs], Sun Jul 22 21:32:04 2018 UTC (5 years, 10 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4
Changes since 1.112: +15 -31 lines
Diff to previous 1.112 (colored)

No need to re-implement realloc(). Just use it
the way the man page says.

ok tb@

Revision 1.112 / (download) - annotate - [select for diffs], Sun Jul 22 08:59:56 2018 UTC (5 years, 10 months ago) by krw
Branch: MAIN
Changes since 1.111: +2 -3 lines
Diff to previous 1.111 (colored)

Tweak comment about truncating NULs to reflect new
reality.

Revision 1.111 / (download) - annotate - [select for diffs], Sun Jul 22 08:43:01 2018 UTC (5 years, 10 months ago) by krw
Branch: MAIN
Changes since 1.110: +2 -2 lines
Diff to previous 1.110 (colored)

When finished pulling an option out of a buffer, skip directly to the
next option. Don't rely on truncated NULs being ignored because
NUL == DHO_PAD.

ok tb@

Revision 1.110 / (download) - annotate - [select for diffs], Sat Jul 21 15:24:55 2018 UTC (5 years, 10 months ago) by krw
Branch: MAIN
Changes since 1.109: +9 -3 lines
Diff to previous 1.109 (colored)

Reading past the end of a buffer is bad, Even if the
extra byte is always there. Even if the byte contains
innocuous data that isn't used. Eeven if a particular
level of optimization of a particular compiler avoids
it by processing things backwards. Bad.

So simplify and correct logic. Perhaps even proof the
code against future generations of clever compilers.

Pointed out by Brandon Falk. Thanks!

ok millert@ tb@

Revision 1.109 / (download) - annotate - [select for diffs], Wed Oct 11 00:09:32 2017 UTC (6 years, 7 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE, OPENBSD_6_3
Changes since 1.108: +11 -4 lines
Diff to previous 1.108 (colored)

Repair printing of classless-static-routes to leases
file. Broken due to incorrect translation from a netmask
to the count of leading 1's. Use brute force counting
until something better is found.

Issue discovered and diffs tested by Anthony Coulter via
bugs@. Thanks!

Revision 1.108 / (download) - annotate - [select for diffs], Wed Sep 20 16:09:42 2017 UTC (6 years, 8 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.107: +8 -5 lines
Diff to previous 1.107 (colored)

Wrong captilization, long lines.

Revision 1.107 / (download) - annotate - [select for diffs], Sun Sep 17 21:20:23 2017 UTC (6 years, 8 months ago) by krw
Branch: MAIN
Changes since 1.106: +31 -27 lines
Diff to previous 1.106 (colored)

Create global 'log_procname' and set it to '<ifname>' or
'<ifname> [priv]' as appropriate for the process doing the
setting. Use it as the prefix in all log_*() output. Makes
tracking messages for an interface or a process much easier.

Revision 1.106 / (download) - annotate - [select for diffs], Thu Sep 14 00:10:17 2017 UTC (6 years, 8 months ago) by krw
Branch: MAIN
Changes since 1.105: +3 -5 lines
Diff to previous 1.105 (colored)

Strive to rationalize fatal[x]() usage and
verbiage.

Revision 1.105 / (download) - annotate - [select for diffs], Sat Sep 9 15:07:59 2017 UTC (6 years, 9 months ago) by krw
Branch: MAIN
Changes since 1.104: +4 -4 lines
Diff to previous 1.104 (colored)

Tweak extract_classless_route() to return unsigned int
and accept NULL pointers for unwanted components of
the route.

Revision 1.104 / (download) - annotate - [select for diffs], Fri Sep 1 19:23:50 2017 UTC (6 years, 9 months ago) by krw
Branch: MAIN
Changes since 1.103: +2 -2 lines
Diff to previous 1.103 (colored)

Two stray "if (p)" -> "if (p != NULL)" and
a stray "if (char)" -> "if (char != '\0').

Revision 1.103 / (download) - annotate - [select for diffs], Tue Aug 29 13:21:30 2017 UTC (6 years, 9 months ago) by krw
Branch: MAIN
Changes since 1.102: +19 -28 lines
Diff to previous 1.102 (colored)

Add a utility function extract_classless_route() and
use it to simplify logic at both places that process
RFC 3442 data.

Revision 1.102 / (download) - annotate - [select for diffs], Mon Aug 28 17:33:42 2017 UTC (6 years, 9 months ago) by krw
Branch: MAIN
Changes since 1.101: +18 -20 lines
Diff to previous 1.101 (colored)

No need for pretty_print_classless() to use
an internal 8K static buffer whose contents
are simply copied into another 8K buffer in
the caller.

Just pass a pointer to and length of the
outer buffer.

Revision 1.101 / (download) - annotate - [select for diffs], Fri Jul 14 16:21:03 2017 UTC (6 years, 10 months ago) by krw
Branch: MAIN
Changes since 1.100: +14 -14 lines
Diff to previous 1.100 (colored)

Replace remaining "!var" expressions with
"<var> == 0", "!(<var> & FLAG)" with
"(<var> & FLAG) == 0", "!<func()>"
with "<func()> == 0" and "!<define>" with
"<define> == 0". And the positive cases
as well.

A few stray == NULL and != NULL as well.

Revision 1.100 / (download) - annotate - [select for diffs], Fri Jul 14 14:03:15 2017 UTC (6 years, 10 months ago) by krw
Branch: MAIN
Changes since 1.99: +7 -5 lines
Diff to previous 1.99 (colored)

Replace remaining "!<pointer>" expressions with
"<pointer> == NULL". And of course "<pointer>"
expressions with "<pointer> != NULL".

Revision 1.99 / (download) - annotate - [select for diffs], Mon Jul 10 00:47:47 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.98: +20 -20 lines
Diff to previous 1.98 (colored)

Use a modern spacious idiom on all function local variable
declarations.

Revision 1.98 / (download) - annotate - [select for diffs], Sun Jul 9 19:19:58 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.97: +24 -24 lines
Diff to previous 1.97 (colored)

Be consistent. "return (e);" -> "return e;"

Revision 1.97 / (download) - annotate - [select for diffs], Sat Jul 8 20:38:31 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.96: +361 -27 lines
Diff to previous 1.96 (colored)

Fold tables.c into options.c and stop exporting the one
table (dhcp_options) involved. Provide functions
code_to_name(), name_to_code(), code_to_format() and
replace direct access to dhcp_options with them. Eliminate
unneeded 'struct option'.

Unhook tables.c from Makefile.

Revision 1.96 / (download) - annotate - [select for diffs], Sat Jul 8 00:36:10 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.95: +15 -14 lines
Diff to previous 1.95 (colored)

Always use uintNN_t instead of sometimes u_intNN_t
and sometimes uintNN_t.

Revision 1.95 / (download) - annotate - [select for diffs], Fri Jul 7 16:58:45 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.94: +3 -3 lines
Diff to previous 1.94 (colored)

Replace the many occurances of '256' with a new #define
DHO_COUNT.

Revision 1.94 / (download) - annotate - [select for diffs], Fri Jul 7 14:53:07 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.93: +20 -84 lines
Diff to previous 1.93 (colored)

Rename cons_options() to pack_options(), and do_packet() to
unpack_options(). Store the unpacked options in a static
variable. Move remaining raw packet processing from unpack_options()
to packethandler().

No more struct interface_info knowledge in options.c

Revision 1.93 / (download) - annotate - [select for diffs], Thu Jul 6 16:56:52 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.92: +2 -38 lines
Diff to previous 1.92 (colored)

cons_options() only needs to know a buffer and a length to
pack options into. Not all the gory details of interface_info.

Move some of the raw packet processing out of options.c's
do_packet() and into the more obvious dispatch.c's
packethandler().

Mention that RFC791 is why we use 576-byte UDP packets.

Revision 1.92 / (download) - annotate - [select for diffs], Thu Jun 15 17:06:17 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.91: +3 -4 lines
Diff to previous 1.91 (colored)

Nuke unused parameter 'client_addr' from the 'handlers', i.e.
dhcpoffer(), dhcpack(), dhcpnak().

Revision 1.91 / (download) - annotate - [select for diffs], Wed Jun 14 16:09:42 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.90: +3 -4 lines
Diff to previous 1.90 (colored)

Move xid, secs, first_sending, startup_time fields from
client_state to interface_info.

No intentional functional change.

Revision 1.90 / (download) - annotate - [select for diffs], Wed Jun 14 15:57:25 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.89: +3 -4 lines
Diff to previous 1.89 (colored)

Start consolidating client_state into interface_info. First
fields to move: recv_packet, sent_packet and sent_packet_length.

No intentional functional change.

Revision 1.89 / (download) - annotate - [select for diffs], Tue Jun 13 15:49:32 2017 UTC (6 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.88: +5 -5 lines
Diff to previous 1.88 (colored)

Rename 'packet' field to 'recv_packet' and 'bootrequest_packet'
field to 'sent_packet'. Also 'bootrequest_packet_length' to
'sent_packet_length'.

Adopt consistent idiom of a local variable 'packet' to point at
packet being manipulated.

No intentional functional change.

Revision 1.88 / (download) - annotate - [select for diffs], Sun Apr 9 20:44:13 2017 UTC (7 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.87: +4 -4 lines
Diff to previous 1.87 (colored)

Seven casts, a couple of tweaks and CFLAGS+=-Wsign-compare for the
win.

No intentional functional change.

Revision 1.87 / (download) - annotate - [select for diffs], Sat Apr 8 20:16:04 2017 UTC (7 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.86: +7 -4 lines
Diff to previous 1.86 (colored)

Reduce the overburden of signed vs unsigned comparisons by sprinkling
'int' -> 'unsigned int' (and visa versa) where obvious.

Steal a couple of 'unsigned' -> u_int32_t from reyk@'s dhcrelay
tweaks.

No intentional functional change.

Revision 1.86 / (download) - annotate - [select for diffs], Sat Apr 8 18:54:52 2017 UTC (7 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.85: +33 -28 lines
Diff to previous 1.85 (colored)

Replace another snprintf() dance with easier to read code using
strlcat(). Shorter, clearer, fewer signed vs unsigned questions.

Use an 8K static buffer for pretty_print_classless() and use it
rather scribbling intermediate values into the final destination.

No intentional functional change.

Revision 1.85 / (download) - annotate - [select for diffs], Sat Apr 8 17:00:10 2017 UTC (7 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.84: +24 -39 lines
Diff to previous 1.84 (colored)

Replace a mess of snprintf() dances with easier to read code using
strlcat(). Shorter, clearer, fewer signed vs unsigned questions.

Shrink static buffer for the string version of an option value from
32K to 8K. Since the string version of the entire lease is constructed
in a 8K buffer, bigger option values are pointless.

Use 8K of the saved space for a static buffer for pretty_print_string()
and use it rather scribbling intermediate values into the final
destination.

No intentional functional change.

Revision 1.84 / (download) - annotate - [select for diffs], Fri Apr 7 15:03:01 2017 UTC (7 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.83: +11 -20 lines
Diff to previous 1.83 (colored)

Simply decoding of domain search option. No intentional functional
change.

Revision 1.83 / (download) - annotate - [select for diffs], Sun Mar 26 21:33:36 2017 UTC (7 years, 2 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.82: +4 -5 lines
Diff to previous 1.82 (colored)

Fix dhclient vis/unvis of strings stored in the leases file.

Replaces incorrect manual emulation of vis() for single, double and
back quotes, dollar signs and back slashes. Just use vis() with
VIS_ALL for these characters.

Should fix problem reported by robert@ with ssid's containing back
slash.

Revision 1.82 / (download) - annotate - [select for diffs], Wed Mar 8 14:19:00 2017 UTC (7 years, 3 months ago) by krw
Branch: MAIN
Changes since 1.81: +8 -8 lines
Diff to previous 1.81 (colored)

Add comments to #endif's to allow easy differentiation between many
incoming #ifdef's.

Revision 1.81 / (download) - annotate - [select for diffs], Sun Feb 12 13:55:01 2017 UTC (7 years, 3 months ago) by krw
Branch: MAIN
Changes since 1.80: +13 -11 lines
Diff to previous 1.80 (colored)

Adjust lines that are too long.

Revision 1.80 / (download) - annotate - [select for diffs], Sun Feb 12 13:15:50 2017 UTC (7 years, 3 months ago) by krw
Branch: MAIN
Changes since 1.79: +28 -27 lines
Diff to previous 1.79 (colored)

Switch from 'legacy' errwarn.c to standard daemon logging functions.

No objections heard. Feedback from millert@ guenther@

Revision 1.79 / (download) - annotate - [select for diffs], Thu Oct 6 16:29:17 2016 UTC (7 years, 8 months ago) by krw
Branch: MAIN
Changes since 1.78: +18 -1 lines
Diff to previous 1.78 (colored)

Add support for RFC 6842, which says the client MUST drop packets when
the server provides a client-identifier value and it doesn't match
the value the client sent.

So stop suppressing client-identifer info in the leases file and when
reading the leases file stop discarding leases that don't have current
client-identifier info. Don't use them, but keep them around in case
the client-identifier info changes back next time.

Also construct the default client-identifier (if needed) before reading
the leases file.

Revision 1.78 / (download) - annotate - [select for diffs], Fri Sep 2 15:44:26 2016 UTC (7 years, 9 months ago) by mpi
Branch: MAIN
Changes since 1.77: +4 -3 lines
Diff to previous 1.77 (colored)

Kill 'ifi' global.

ok henning@, krw@

Revision 1.77 / (download) - annotate - [select for diffs], Wed Aug 31 12:57:31 2016 UTC (7 years, 9 months ago) by mpi
Branch: MAIN
Changes since 1.76: +4 -2 lines
Diff to previous 1.76 (colored)

Remove the 'client' global and make it per-ifp.

ok krw@

Revision 1.76 / (download) - annotate - [select for diffs], Tue Aug 23 09:26:02 2016 UTC (7 years, 9 months ago) by mpi
Branch: MAIN
Changes since 1.75: +3 -3 lines
Diff to previous 1.75 (colored)

Make the 'ifi' global local to dhclient.c and pass it as an argument to
functions needing it.

This is the first step to support multiple interfaces in one dhclient(8)
instance.

ok krw@

Revision 1.75 / (download) - annotate - [select for diffs], Sat Feb 6 19:30:52 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.74: +18 -2 lines
Diff to previous 1.74 (colored)

Eliminate #include inside *.h files and include only needed headers in
each *.c file.

Inspired by mention of header silliness by Edgar Pettijohn and mmcc@
on tech@.

Revision 1.74 / (download) - annotate - [select for diffs], Mon Oct 26 16:32:33 2015 UTC (8 years, 7 months ago) by krw
Branch: MAIN
Changes since 1.73: +125 -1 lines
Diff to previous 1.73 (colored)

Give dhclient(8) the ability to use option 119, a.k.a. "Domain
Search" if supplied by the server.

Requested by a few. Original diff from Ray Lai via tech@.

Tested & ok claudio@

Revision 1.73 / (download) - annotate - [select for diffs], Mon Oct 27 17:01:28 2014 UTC (9 years, 7 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.72: +16 -10 lines
Diff to previous 1.72 (colored)

Nuke getLong(), getShort(), getUShort(). Two line functions (memcpy();
ntoh[ls]()) obscure rather than simplify things. Especially when
they are used only once. Just use the expansion.

Revision 1.72 / (download) - annotate - [select for diffs], Mon Oct 27 14:17:01 2014 UTC (9 years, 7 months ago) by krw
Branch: MAIN
Changes since 1.71: +3 -3 lines
Diff to previous 1.71 (colored)

htonl(ntohl(memcpy'd buf)) seems like the long way around to copy
an IPv4 address. Just memcpy() it.

Revision 1.71 / (download) - annotate - [select for diffs], Mon Oct 27 13:36:21 2014 UTC (9 years, 7 months ago) by krw
Branch: MAIN
Changes since 1.70: +2 -3 lines
Diff to previous 1.70 (colored)

Zap extraneous whitespace and a stuttered extra 'break;'.

Revision 1.56.2.1 / (download) - annotate - [select for diffs], Tue Jul 29 18:23:07 2014 UTC (9 years, 10 months ago) by tobias
Branch: OPENBSD_5_4
Changes since 1.56: +2 -3 lines
Diff to previous 1.56 (colored) next main 1.57 (colored)

Fix memory exhaustion occurring on DHCP options with 0 length.

halex@ and krw@ pointed out that a NULL check before free can go, too.

ok deraadt@, halex@, krw@, jasper@

Revision 1.67.4.1 / (download) - annotate - [select for diffs], Tue Jul 29 18:21:30 2014 UTC (9 years, 10 months ago) by tobias
Branch: OPENBSD_5_5
Changes since 1.67: +2 -3 lines
Diff to previous 1.67 (colored) next main 1.68 (colored)

Fix memory exhaustion occurring on DHCP options with 0 length.

halex@ and krw@ pointed out that a NULL check before free can go, too.

ok deraadt@, halex@, krw@, jasper@

Revision 1.70 / (download) - annotate - [select for diffs], Mon Jul 28 16:45:35 2014 UTC (9 years, 10 months ago) by tobias
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.69: +2 -3 lines
Diff to previous 1.69 (colored)

Fix memory exhaustion occurring on DHCP options with 0 length.

halex@ and krw@ pointed out that a NULL check before free can go, too.

ok deraadt@, halex@, krw@

Revision 1.69 / (download) - annotate - [select for diffs], Wed Jul 9 12:55:31 2014 UTC (9 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.68: +57 -12 lines
Diff to previous 1.68 (colored)

Special case pretty printing of DHO_CLASSLESS_STATIC_ROUTES and
DHO_CLASSLESS_MS_STATIC_ROUTES. Remove 'C' (CIDR) pretty printing
outside of those special cases. Add a bunch of paranoia to protect
against confused/malicious dhcp servers.

Since 'C' is a variable size element it can't be handled by the
existing code, which is designed for fixed size elements.

Issue found by Someya Yuuichi, reported by yasuoka@ who also provided
the first diff.

ok yasuoka@

Revision 1.68 / (download) - annotate - [select for diffs], Mon May 5 18:02:49 2014 UTC (10 years, 1 month ago) by krw
Branch: MAIN
Changes since 1.67: +3 -3 lines
Diff to previous 1.67 (colored)

Zap trailing whitespace. Started by pointed comments from andre@.

Revision 1.67 / (download) - annotate - [select for diffs], Tue Jan 21 03:07:50 2014 UTC (10 years, 4 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE
Branch point for: OPENBSD_5_5
Changes since 1.66: +13 -1 lines
Diff to previous 1.66 (colored)

Add parsing for options 121 (classless-static-routes) and 249
(classless-ms-static-routes). dhcpd can now specify and serve
these options and dhclient can recognize and use supersede, etc.
statements on them.

Based on a diff from Stefan Rinke. Thanks!

Revision 1.66 / (download) - annotate - [select for diffs], Sun Jan 19 21:10:04 2014 UTC (10 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.65: +4 -16 lines
Diff to previous 1.65 (colored)

We don't have any (and I can't find elsewhere) signed 16 bit or
signed 8 bit dhcp option types. So nuke getShort() and all 's' and
'b' format support. While here use '%u'/'%lu' and not
'%d'/'%ld' to snprintf() unsigned values.

Revision 1.65 / (download) - annotate - [select for diffs], Mon Dec 30 03:36:17 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.64: +2 -2 lines
Diff to previous 1.64 (colored)

Replace yet another hand-rolled list with a TAILQ. reject_list this
time.

Revision 1.64 / (download) - annotate - [select for diffs], Sun Dec 22 04:47:57 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.63: +1 -2 lines
Diff to previous 1.63 (colored)

Setting format id to 't' when it's already 't' is a waste of
time.

Revision 1.63 / (download) - annotate - [select for diffs], Sun Dec 22 03:20:05 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.62: +2 -3 lines
Diff to previous 1.62 (colored)

No need to change format id 'X' (ascii or hex) to 'x' (hex) while
pretty printing, when 'X' is not used in the next switch statement.
Just keep 'X'. Makes the code a touch less mysterious.

Revision 1.62 / (download) - annotate - [select for diffs], Sat Dec 21 18:23:10 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.61: +59 -32 lines
Diff to previous 1.61 (colored)

Introduce pretty_print_string() and use for printing both text
valued options and previously snprintf()'d filename and servername
lease attributes.

Should fix "string constant too long" errors when reading back a
lease with filename or servername attributes with escaped characters.

Reported by Rivo Nurges.

Revision 1.61 / (download) - annotate - [select for diffs], Wed Dec 18 00:37:59 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.60: +9 -12 lines
Diff to previous 1.60 (colored)

Code existed to print non-printable characters in strings written
to the leases file. No code existed to correctly read back the
strings so written.

Redo both sides and use vis()/strnunvis() instead of handrolling
more parsing. As a side-effect allow embedded NUL characters rather
than skipping them.

Revision 1.60 / (download) - annotate - [select for diffs], Sat Dec 14 16:06:42 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.59: +42 -56 lines
Diff to previous 1.59 (colored)

Start cleanup/fixup of pretty printing of option data. Use snprintf()
exclusively and thus simplify error checking/overflow detection.
Bail out when unknown format character found. Don't ignore last
character if it's unprintable. Print embedded NULs rather than
ignoring them.

Revision 1.59 / (download) - annotate - [select for diffs], Thu Dec 12 13:22:37 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.58: +1 -2 lines
Diff to previous 1.58 (colored)

Delete spurious blank line.

Revision 1.58 / (download) - annotate - [select for diffs], Thu Dec 12 01:40:35 2013 UTC (10 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.57: +9 -14 lines
Diff to previous 1.57 (colored)

Eliminate (most) double decrements of remaining space in the pretty
print buffer. Use consistant idiom to increment pointer to data
being consumed, instead of hiding some increments.

Revision 1.57 / (download) - annotate - [select for diffs], Fri Dec 6 23:40:48 2013 UTC (10 years, 6 months ago) by krw
Branch: MAIN
Changes since 1.56: +7 -10 lines
Diff to previous 1.56 (colored)

Having stopped pretending we handle anything but ethernet packets,
replace the 'struct hardware' abstraction layer and use 'struct
ether_addr' where hardware addresses are of interest.

ok matthew@, confirmed by reyk@ not to impact DHCP-over-IPSec support.

Revision 1.56 / (download) - annotate - [select for diffs], Thu Jul 11 01:34:00 2013 UTC (10 years, 11 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE
Branch point for: OPENBSD_5_4
Changes since 1.55: +36 -22 lines
Diff to previous 1.55 (colored)

Put more debug verbiage under DEBUG. Add a few more debug messages.
Make packet discarding decisions before parsing the packet's possible
options. No intended functional change.

Revision 1.55 / (download) - annotate - [select for diffs], Sun Jul 7 00:04:58 2013 UTC (10 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.54: +1 -3 lines
Diff to previous 1.54 (colored)

Remove erroneous warnings -- we do not reject offers just because the
option buffer(s) end badly.

Revision 1.54 / (download) - annotate - [select for diffs], Sat Jul 6 03:03:23 2013 UTC (10 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.53: +3 -5 lines
Diff to previous 1.53 (colored)

Fix a lie in one comment and zap a pointless sentence in another.

Revision 1.53 / (download) - annotate - [select for diffs], Thu May 2 16:35:27 2013 UTC (11 years, 1 month ago) by krw
Branch: MAIN
Changes since 1.52: +4 -4 lines
Diff to previous 1.52 (colored)

Bunch of comment/whitespace cleanup. Eliminate some misleading or
pointless ones, make multiline comments readable, nuke '...' in
favour of '.', etc.

Revision 1.52 / (download) - annotate - [select for diffs], Fri Apr 5 19:19:05 2013 UTC (11 years, 2 months ago) by krw
Branch: MAIN
Changes since 1.51: +2 -2 lines
Diff to previous 1.51 (colored)

Nuke parameter to do_packet() not used since 2006. From dhill.

Revision 1.51 / (download) - annotate - [select for diffs], Thu Feb 14 20:39:46 2013 UTC (11 years, 3 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE, OPENBSD_5_3
Changes since 1.50: +2 -2 lines
Diff to previous 1.50 (colored)

Don't rely on the packet buffer (client->packet) being preserved between
attempts to send DISCOVER or REQUEST packets. Some DHCP servers might
NAK the DISCOVER, or other nefarious packets arrive, between attempts
and overwrite the packet being sent. Create and use another buffer
for packets being sent.

Problem encountered by fgsch@, who noticed that once the DISCOVER was
NAK'ed our dhclient sent a bunch of NAK's back to the server. Like it
thought they were DISCOVER messages.

ok beck@

Revision 1.50 / (download) - annotate - [select for diffs], Wed Jan 16 21:35:41 2013 UTC (11 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.49: +22 -14 lines
Diff to previous 1.49 (colored)

Unrevert last reversion. otto@ pointed out that it wasn't asprintf()
causing a problem, it was accessing uninitialized pointers.

Revision 1.49 / (download) - annotate - [select for diffs], Wed Jan 16 11:02:10 2013 UTC (11 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.48: +8 -14 lines
Diff to previous 1.48 (colored)

Revert last. asprintf() breaks something.

Revision 1.48 / (download) - annotate - [select for diffs], Wed Jan 16 06:11:21 2013 UTC (11 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.47: +14 -8 lines
Diff to previous 1.47 (colored)

Use the magic of asprintf() to produce more informative error
and log messages.

Revision 1.47 / (download) - annotate - [select for diffs], Sun Jan 13 22:50:33 2013 UTC (11 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.46: +3 -3 lines
Diff to previous 1.46 (colored)

More informative error message.

Revision 1.46 / (download) - annotate - [select for diffs], Sun Jan 13 22:09:38 2013 UTC (11 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.45: +25 -14 lines
Diff to previous 1.45 (colored)

Make pretty_print_option() return "" rather than "<fmt error>" when
the option fails validation tests. Make pretty_print_option() bail
on all bad format strings, and on all incorrect option data lengths.

Check pretty_print_option() return value rather than repeating
validation with check_option(). Do res_hnok() check on host name,
domain name, and nis domain while creating lease from packet info.

As a result, nuke ipv4addrs() and check_option().

Ignore options that do not validate rather than summarily rejecting
offered lease. Treat all options whose names start with "option-"
as unknown rather than relying on a big switch on DHO_ names.

Started when reading dhclient(8) -u verbiage.

Revision 1.45 / (download) - annotate - [select for diffs], Thu Nov 15 14:54:18 2012 UTC (11 years, 6 months ago) by krw
Branch: MAIN
Changes since 1.44: +1 -3 lines
Diff to previous 1.44 (colored)

Shuffle #include's to use the majority idiom everywhere - i.e. use
dhcpd.h to pull in most sys/net/netinet/etc. .h file. Eliminate
superfluous #include's.

Revision 1.44 / (download) - annotate - [select for diffs], Thu Nov 8 21:32:55 2012 UTC (11 years, 7 months ago) by krw
Branch: MAIN
Changes since 1.43: +8 -8 lines
Diff to previous 1.43 (colored)

Remove confusing extra address abstraction 'struct iaddr'. Just use
'in_addr'. Remove many double conversions and other perversions.
piaddr() replaced with inet_ntoa(). dhclient is extremely unlikely
to support anything but ipv4/dhcp without a complete rewrite.

Joint work with chris@.

Positive feedback from deraadt@ zinke@ phessler@.

Revision 1.43 / (download) - annotate - [select for diffs], Wed Nov 7 15:20:28 2012 UTC (11 years, 7 months ago) by krw
Branch: MAIN
Changes since 1.42: +2 -2 lines
Diff to previous 1.42 (colored)

Use memset() consistently rather than tossing in a few bzero()'s.

Revision 1.42 / (download) - annotate - [select for diffs], Sat Oct 27 23:08:53 2012 UTC (11 years, 7 months ago) by krw
Branch: MAIN
Changes since 1.41: +8 -6 lines
Diff to previous 1.41 (colored)

Change dhclient.conf directive 'ignore' to take a list of option names
rather than list of option declarations. e.g. 'ignore routers;'
instead of 'ignore routers 1.2.3.4;' The value in the declaration
was being ignored anyway.

While there clean up the related code a bit.

Revision 1.41 / (download) - annotate - [select for diffs], Tue Jun 26 14:46:42 2012 UTC (11 years, 11 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_2_BASE, OPENBSD_5_2
Changes since 1.40: +18 -16 lines
Diff to previous 1.40 (colored)

Add some more paranoia and make code clearer. Check that the required
length field for the option is present before using it. Reject lease
if no length field is present.

Revision 1.40 / (download) - annotate - [select for diffs], Tue Jun 26 14:36:11 2012 UTC (11 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.39: +14 -1 lines
Diff to previous 1.39 (colored)

RFC 2132 says "Options containing NVT ASCII data SHOULD NOT include
a trailing NULL; however, the receiver of such options MUST be
prepared to delete trailing nulls if they exist."

So delete (all) trailing NUL's when parsing NVT ASCII options.
Should fix odd results when 'append'ing info to such options via
dhclient.conf.

FreeBSD commit to fix 'append' logic in a different way pointed out
by brad.

Revision 1.39 / (download) - annotate - [select for diffs], Wed May 11 14:38:36 2011 UTC (13 years, 1 month ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.38: +12 -6 lines
Diff to previous 1.38 (colored)

Make dhclient more friendly to sequential option processing by
always starting DHCP packet options with DHO_DHCP_MESSAGE_TYPE. Now
DHCP-specific options always come after the option identifying the
packet as DHCP rather than BOOTP. Makes at least Nortel NetIP DHCP
server happier. Clean up some code and parameter passing.

Closes PR#6543, as confirmed by original submitter and patch
tester Len Zaifman. Thanks!

ok matthew@ (who hates the ISC-like code)

Revision 1.38 / (download) - annotate - [select for diffs], Sun Apr 17 19:57:23 2011 UTC (13 years, 1 month ago) by phessler
Branch: MAIN
Changes since 1.37: +8 -1 lines
Diff to previous 1.37 (colored)

fix a possible division by zero if a server sends us a broken option

hints for the proper fix, and OK claudio@
(this was lost in my tree for far too long)

Revision 1.37 / (download) - annotate - [select for diffs], Tue Mar 10 23:19:36 2009 UTC (15 years, 3 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9, OPENBSD_4_8_BASE, OPENBSD_4_8, OPENBSD_4_7_BASE, OPENBSD_4_7, OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.36: +10 -1 lines
Diff to previous 1.36 (colored)

Add 6-byte MAC address to the log entries for DHCP ACK/NAK/OFFER.
Log the packets before checking the client state. Makes it easy to
find MACs for 'surprise' DHCP servers.

Positive comments from mbalmer@, jasper@.

Revision 1.36 / (download) - annotate - [select for diffs], Sat Jun 2 01:29:11 2007 UTC (17 years ago) by pvalchev
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4, OPENBSD_4_3_BASE, OPENBSD_4_3, OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.35: +5 -3 lines
Diff to previous 1.35 (colored)

safer snprintf construct with more paranoid length calculation
ok millert

Revision 1.35 / (download) - annotate - [select for diffs], Thu May 31 23:24:15 2007 UTC (17 years ago) by pvalchev
Branch: MAIN
Changes since 1.34: +5 -3 lines
Diff to previous 1.34 (colored)

fix a funny memory miscalculation bug in options parsing
ok henning otto theo

Revision 1.34 / (download) - annotate - [select for diffs], Wed Feb 14 23:19:26 2007 UTC (17 years, 3 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.33: +3 -3 lines
Diff to previous 1.33 (colored)

spacing and a typo that fell out of the read

Revision 1.33 / (download) - annotate - [select for diffs], Thu Jan 25 01:21:04 2007 UTC (17 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.32: +75 -52 lines
Diff to previous 1.32 (colored)

Cleanup some more code. Eliminate dhcp(), bootp(), parse_options() by
moving the minimal code into do_packet(). Eliminate repeated code for
checking the client hardware address and the reject list by putting
those checks into do_packet as well.

No functional change, just much easier to read.

ok stevesk@

Revision 1.32 / (download) - annotate - [select for diffs], Tue Jan 16 20:22:20 2007 UTC (17 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.31: +37 -45 lines
Diff to previous 1.31 (colored)

More cleanup. Eliminate 'struct packet' by cleverly passing as
parameters just those things actually needed and using existing
structs and information. No functional change.

ok stevesk@

Revision 1.31 / (download) - annotate - [select for diffs], Sun Jan 14 01:35:46 2007 UTC (17 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.30: +7 -7 lines
Diff to previous 1.30 (colored)

Don't treat any packet with an invalid option buffer or an invalid
message type option of 0 as a BOOTP offer. Don't process any option
buffer after one is found to be corrupt. Don't process overflow
buffers in a BOOTP packet.  At least try to accept DHCP offers even if
a bad options buffer is encountered.

Brings code more into line with current ISC dhclient.

ok stevesk@

Revision 1.30 / (download) - annotate - [select for diffs], Thu Jan 11 00:04:48 2007 UTC (17 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.29: +13 -32 lines
Diff to previous 1.29 (colored)

Reject all packets with an option claiming to extend past the end of
an option buffer. No longer accept the 6th such packet. From ISC.

ok ckuethe@ stevesk@

Revision 1.29 / (download) - annotate - [select for diffs], Sat Jan 6 23:21:08 2007 UTC (17 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.28: +2 -2 lines
Diff to previous 1.28 (colored)

Fix options parsing. Last commit lost the proper length of the
incoming packet.  But since we bzero() the packet buffer before
copying the incoming data into it, and the options are at the end, and
we use a fixed sized buffer, and 0's are ignored as pad options, and
proper option lists end with 0xff, it's simplier to always try to scan
the whole buffer.

Problem found by, and patch tested by kettenis@.

Revision 1.28 / (download) - annotate - [select for diffs], Thu Jan 4 22:17:48 2007 UTC (17 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.27: +11 -15 lines
Diff to previous 1.27 (colored)

Another round of cleanup. There is only one instance of struct
dhcp_packet and it is contained in the global *client. So don't pass
around pointers to a struct that contains a pointer to the dhcp_packet
instance. Just use the global client->packet. Eliminate unused struct
packet members and parameter lists accordingly.

No functional change.

Suggestions by stevesk@. ok stevesk@

Revision 1.27 / (download) - annotate - [select for diffs], Tue Dec 26 21:19:52 2006 UTC (17 years, 5 months ago) by krw
Branch: MAIN
Changes since 1.26: +3 -4 lines
Diff to previous 1.26 (colored)

Our dhclient only handles one interface. Simplify code by using the
single, global, instance of 'struct interface_info' (ifi) rather than
passing around pointers to it.

"I agree" henning@

Testing moritz@ stevesk@, ok stevesk@

Revision 1.26 / (download) - annotate - [select for diffs], Fri Dec 15 14:09:13 2006 UTC (17 years, 5 months ago) by stevesk
Branch: MAIN
Changes since 1.25: +2 -2 lines
Diff to previous 1.25 (colored)

typo in comment

Revision 1.25 / (download) - annotate - [select for diffs], Mon Aug 22 20:30:52 2005 UTC (18 years, 9 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0, OPENBSD_3_9_BASE, OPENBSD_3_9, OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.24: +2 -2 lines
Diff to previous 1.24 (colored)

Fix problems with some Linksys DHCP servers (and probably others) by
not accidentally inserting two NULL characters after each option in
the DHCPREQUEST packet.

Thanks to Christian Jones for the problem report and tcpdump's, and to
Emmett Pate for finding a problematic Linksys model still in my local
stores.

ok deraadt@

Revision 1.24 / (download) - annotate - [select for diffs], Sat Jul 16 16:31:05 2005 UTC (18 years, 10 months ago) by henning
Branch: MAIN
Changes since 1.23: +1 -5 lines
Diff to previous 1.23 (colored)

back out last; breaks in cases where we want hex and the last byte is 0

Revision 1.23 / (download) - annotate - [select for diffs], Fri Jul 15 10:40:27 2005 UTC (18 years, 10 months ago) by henning
Branch: MAIN
Changes since 1.22: +6 -2 lines
Diff to previous 1.22 (colored)

let pretty_print_option() handle trailing nul bytes correctly (i. e. don't
let a trailing nul byte force hex printing)
FreeBSD PR 83468 by Sean Winn <sean@gothic.net.au>, via jmc@

Revision 1.22 / (download) - annotate - [select for diffs], Wed Jul 13 23:33:04 2005 UTC (18 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.21: +2 -2 lines
Diff to previous 1.21 (colored)

spacing

Revision 1.21 / (download) - annotate - [select for diffs], Wed Jul 13 23:25:55 2005 UTC (18 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.20: +25 -106 lines
Diff to previous 1.20 (colored)

Repair/rationalize option handling to ensure valid option section is
always sent. Fold store_options into cons_options. Eliminate priority
list of options.

ok deraadt@

Revision 1.20 / (download) - annotate - [select for diffs], Sat Jul 9 14:36:16 2005 UTC (18 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.19: +1 -2 lines
Diff to previous 1.19 (colored)

Clean out a few more unused/uninitialized variables.

ok henning@

Revision 1.19 / (download) - annotate - [select for diffs], Fri Jul 8 14:15:23 2005 UTC (18 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.18: +11 -40 lines
Diff to previous 1.18 (colored)

More dead and moribund code removal/cleanup. This time unused parameters
and associated code for store_options().

ok henning@

Revision 1.18 / (download) - annotate - [select for diffs], Fri Jul 8 00:57:36 2005 UTC (18 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.17: +13 -81 lines
Diff to previous 1.17 (colored)

Eliminate unused code and associated parameters.

ok deraadt@

Revision 1.17 / (download) - annotate - [select for diffs], Thu Jul 7 20:03:40 2005 UTC (18 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.16: +3 -31 lines
Diff to previous 1.16 (colored)

Eliminate unused code and associated parameter.

ok deraadt@ millert@.

Revision 1.16 / (download) - annotate - [select for diffs], Thu Jul 7 16:24:24 2005 UTC (18 years, 11 months ago) by krw
Branch: MAIN
Changes since 1.15: +8 -8 lines
Diff to previous 1.15 (colored)

Eliminate tree_cache structure in favour of option_data. Eliminate
redundant level of indirection in building and using option_data
arrays while constructing outgoing packets. Make option_data len field
unsigned.

ok henning@. 'cool!' deraadt@.

Revision 1.15 / (download) - annotate - [select for diffs], Sun Dec 26 03:17:07 2004 UTC (19 years, 5 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7
Changes since 1.14: +8 -8 lines
Diff to previous 1.14 (colored)

snprintf return value paranoia; henning ok

Revision 1.14 / (download) - annotate - [select for diffs], Tue Nov 2 01:18:45 2004 UTC (19 years, 7 months ago) by deraadt
Branch: MAIN
Changes since 1.13: +5 -5 lines
Diff to previous 1.13 (colored)

delint gunk approved by otto a while back

Revision 1.13 / (download) - annotate - [select for diffs], Tue Sep 21 04:07:04 2004 UTC (19 years, 8 months ago) by david
Branch: MAIN
Changes since 1.12: +2 -2 lines
Diff to previous 1.12 (colored)

spelling fixes; ok jmc@ henning@

Revision 1.12 / (download) - annotate - [select for diffs], Wed Sep 15 18:15:18 2004 UTC (19 years, 8 months ago) by henning
Branch: MAIN
Changes since 1.11: +2 -2 lines
Diff to previous 1.11 (colored)

no \n in error() calls and minor KNF, from Moritz Jodeit <moritz@jodeit.org>

Revision 1.11 / (download) - annotate - [select for diffs], Thu May 6 22:29:15 2004 UTC (20 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_6_BASE, OPENBSD_3_6
Changes since 1.10: +1 -5 lines
Diff to previous 1.10 (colored)

remove more unused code

Revision 1.10 / (download) - annotate - [select for diffs], Tue May 4 22:23:01 2004 UTC (20 years, 1 month ago) by mickey
Branch: MAIN
Changes since 1.9: +13 -13 lines
Diff to previous 1.9 (colored)

do not overload libc function names causing linker troubles

Revision 1.9 / (download) - annotate - [select for diffs], Tue May 4 20:28:40 2004 UTC (20 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.8: +10 -25 lines
Diff to previous 1.8 (colored)

remove things not used, spotted by lint mostly; ok henning

Revision 1.8 / (download) - annotate - [select for diffs], Wed Apr 14 20:22:27 2004 UTC (20 years, 1 month ago) by henning
Branch: MAIN
Changes since 1.7: +5 -7 lines
Diff to previous 1.7 (colored)

get rif of the few dmalloc/dfree occurances that were left

Revision 1.7 / (download) - annotate - [select for diffs], Tue Mar 2 18:49:21 2004 UTC (20 years, 3 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_5_BASE, OPENBSD_3_5
Changes since 1.6: +3 -2 lines
Diff to previous 1.6 (colored)

more pruning; henning ok

Revision 1.6 / (download) - annotate - [select for diffs], Tue Feb 24 17:02:40 2004 UTC (20 years, 3 months ago) by henning
Branch: MAIN
Changes since 1.5: +7 -1 lines
Diff to previous 1.5 (colored)

zap more unused crap

Revision 1.5 / (download) - annotate - [select for diffs], Sat Feb 7 13:59:45 2004 UTC (20 years, 4 months ago) by henning
Branch: MAIN
Changes since 1.4: +4 -4 lines
Diff to previous 1.4 (colored)

KNF

Revision 1.4 / (download) - annotate - [select for diffs], Sat Feb 7 13:26:35 2004 UTC (20 years, 4 months ago) by henning
Branch: MAIN
Changes since 1.3: +34 -36 lines
Diff to previous 1.3 (colored)

more KNF From: Emil Mikulic <emikulic@dmr.ath.cx>
great job.
no binary change.

Revision 1.3 / (download) - annotate - [select for diffs], Fri Feb 6 11:33:22 2004 UTC (20 years, 4 months ago) by henning
Branch: MAIN
Changes since 1.2: +329 -338 lines
Diff to previous 1.2 (colored)

more Knall & Rauch -> ANSI C, KNF and stuff that makes this a bit more
readable. no effect on the binary.
From: Emil Mikulic <emikulic@dmr.ath.cx>

Revision 1.2 / (download) - annotate - [select for diffs], Wed Feb 4 12:16:56 2004 UTC (20 years, 4 months ago) by henning
Branch: MAIN
Changes since 1.1: +2 -2 lines
Diff to previous 1.1 (colored)

$OpenBSD$, tedu

Revision 1.1 / (download) - annotate - [select for diffs], Sun Jan 18 01:26:20 2004 UTC (20 years, 4 months ago) by deraadt
Branch: MAIN

this is where dhclient will start surgery

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.