Home | History | Annotate | Download | only in rarpd
History log of /src/usr.sbin/rarpd/rarpd.c
RevisionDateAuthorComments
 1.61  26-Mar-2023  andvar fix various typos in documentation, comments and sysctl device description.
mainly aion -> ation and inlude -> include.
 1.60  13-Feb-2018  martin Adapt to ar_tha() changes in if_arp.h rev1.31.
 1.59  30-Aug-2011  joerg static + __printflike + __dead
 1.58  18-Apr-2009  lukem Fix WARNS=4 issues (-Wshadow -Wsign-compare -Wextra)
 1.57  21-Jul-2008  lukem branches: 1.57.6;
Remove the \n and tabs from the __COPYRIGHT() strings.
Tweak to use a consistent format.
 1.56  21-Jul-2008  martin UBC license does not require an advertizing clause any more - this files
where probably missed in the initial sweep due to strange formatting
(last clause not explicitly numbered).

FreeBSD converted them (rev. 1.21 pf rarpd.8 and rev 1.41 of rarpd.c
in their repository), nearly four years ago.
 1.55  12-May-2006  mrg branches: 1.55.20;
since ar_tha() can return NULL, don't pass it directly to functions
that expect real addresses. explicitly KASSERT() that it is not
NULL in the kernel and just avoid using it userland.

(the kernel could be more defensive about this, but, until now it
would have just crashed anyway.)
 1.54  01-Dec-2004  christos remove backwards compatibility with non-cloning bpf.
 1.53  01-Dec-2004  christos Use /dev/bpf, if _PATH_BPF is defined.
 1.52  07-Sep-2004  jrf Replaced strncpy with strlcpy. Thanks to Peter Postma who
pointed them our in PR #25762. Approved by christos@NetBSD.org.
 1.51  12-May-2004  tron Fix handling of interface aliases if "rarpd" is not invoked with "-a".
 1.50  10-Apr-2004  darrenr With recent changes to BPF, pushing the default buffer size to 1MB, running
a bunch of small daemons that seem small packet flows can easily chew up
significant kernel memory (each BPF device opened takes 2*buffersize of
wired memory.) In each of these applications, add code to set the buffer
size to 32k before setting the interface.
 1.49  13-Jul-2003  itojun branches: 1.49.2;
use bounded string op
 1.48  15-May-2003  itojun assume presense of getifaddrs(3).
 1.47  21-Oct-2002  lukem tweak usage now that multiple interfaces are supported...
 1.46  17-Oct-2002  thorpej Allow more than one interface to be specified on the command line.
 1.45  14-Jul-2002  wiz ANSIfy. Remove ifndef __STDC__. Remove __P(). Remove register.
 1.44  11-Jan-2002  itojun branches: 1.44.2;
daemon(3) has to be called prior to file descriptor initialization.
 1.43  24-Sep-2001  wiz va_{start,end} audit:
Make sure that each va_start has one and only one matching va_end,
especially in error cases.
If the va_list is used multiple times, do multiple va_starts/va_ends.
If a function gets va_list as argument, don't let it use va_end (since
it's the callers responsibility).

Improved by comments from enami and christos -- thanks!

Heimdal/krb4/KAME changes already fed back, rest to follow.

Inspired by, but not not based on, OpenBSD.
 1.42  11-Jan-2001  enami Kill no longer used variable decl.
 1.41  11-Jan-2001  lukem use explicit name rather than __progname in openlog
 1.40  20-Nov-2000  is With RARP, MAC asks, and IP answers. Fixes PR 11330 by Thilo Manske, who
also provided the fix (modulo formatting).
 1.39  11-Oct-2000  is More format string cleanups by sommerfeld.
 1.38  30-Aug-2000  abs Include the fact we're making replies in the debug() output.
 1.37  13-Apr-2000  itojun branches: 1.37.4;
use getifaddrs to avoid alignment constraints in SIOCGIFCONF.
(do you have PR # for this? >lukem)
 1.36  11-Feb-2000  abs Indicate on which interface a packet has been received when debugging
 1.35  07-Feb-2000  nathanw Copy struct ifreq returned by SIOGIFCONF to ensure correct alignment.
 1.34  26-Sep-1999  kleink Need <sys/param.h> for MAXHOSTNAMELEN.
 1.33  06-Jun-1999  thorpej branches: 1.33.2;
Use pidfile(3).
 1.32  13-Feb-1999  thorpej branches: 1.32.2;
Fix a logic error which would have caused a NULL pointer dereference
if the client's IP address wasn't found on the interface's network.
 1.31  11-Jan-1999  kleink In userland, pull in <errno.h> instead of <sys/errno.h> for the declaration
of errno.
 1.30  06-Oct-1998  fvdl Shut up gcc.
 1.29  06-Oct-1998  matt Teach rarpd about interface aliases.
 1.28  29-Sep-1998  mrg use daemon(). remove spurious \n from rarperr() call
 1.27  29-Jul-1998  fair usage & comment string patch, per PR#5859
 1.26  13-Jul-1998  mrg KNF. be safe with buffers. use setsid().
 1.25  23-Apr-1998  mrg support /var/run/rarpd.pid
 1.24  15-Apr-1998  mrg add a -l (logging) switch.
 1.23  23-Mar-1998  fair These changes from PR#3190 (second set of diffs) deal with rarpd
refusing to work in "-a" mode on a host with more than one Ethernet,
and at least one non-ethernet device. Frankly, the interface
initialization loop is badly structured and should be rewritten,
and these changes do nothing to fix that. However, they oughta do
the requested job, quick & dirty.
 1.22  24-Nov-1997  is If we answer a RARP request, also add the mapping to the local arp cache.
[This was broken when the 4.4BSD ARP table changes were done, and never
repaired.]
Inspired by Jarle Greipsland, PR 4531; code stolen from arp.a and cleaned
up (mostly removing global variables).
XXX As pointed out in the PR, this should be in some library (libutil?),
to be usable by other servers like bootpd and dhcpd.
 1.21  18-Oct-1997  lukem branches: 1.21.2;
use memcmp/memset/memmove instead of bcmp/bzero/bcopy
 1.20  17-Oct-1997  lukem getopt returns -1 not EOF
 1.19  17-Oct-1997  lukem WARNSify
 1.18  21-Jun-1997  lukem * use MAXHOSTNAMELEN+1 instead of 256
* don't use LOG_CONS - it's unnecessary and spams the console if syslogd
fails (a bad thing, really)

From [misc/873] by Giles Lean <giles@nemeton.com.au>:
* explain why the name lookup failed
* always send debug() via syslog(3) (unlike the PR, which added a -s flag)
* enhance the man page a bit (even in the commented out section which
is only relevant to the -DREQUIRE_TFTPBOOT case
 1.17  23-Mar-1997  cgd fix some u_long vs. u_int32_t bogons in uses of nameserver lookup results.
 1.16  15-Mar-1997  is New ARP system, supports IPv4 over any hardware link.

Some of the stuff (e.g., rarpd, bootpd, dhcpd etc., libsa) still will
only support Ethernet. Tcpdump itself should be ok, but libpcap needs
lot of work.

For the detailed change history, look at the commit log entries for
the is-newarp branch.
 1.15  10-Mar-1997  is branches: 1.15.2;
back out previoius commit---wasn't intended for The Trunk
 1.14  10-Mar-1997  is adapt to new ARP code. still needs work for non-Ethernet.
 1.13  18-Jan-1997  mikel cast ether_ntohost() argument to proper type;
from Klaus Klein <kleink@layla.inka.de>
 1.12  21-Mar-1996  jtc Be pedantic, main() returns int in C.
 1.11  01-Feb-1996  mycroft If __FreeBSD__, don't swap the type field in the Ethernet II header.
 1.10  31-Jan-1996  hpeyerl interface aliases don't count as individual interfaces and hence don't
need a seperate bpf. Someone should decide whether to tell netstat
about this.
 1.9  17-Nov-1995  thorpej New-style RCS id.
 1.8  01-Sep-1995  thorpej branches: 1.8.2;
Make the "/tftpboot/<client-ip-address>" requirement conditional on
-DREQUIRE_TFTPBOOT and disable it by default.
 1.7  25-May-1994  mycroft Look up the ether addresses of interfaces *correctly*, and just ditch
SIOCSARP altogether.
 1.6  14-May-1994  cgd rename constants
 1.5  30-Mar-1994  cgd kill bad casts
 1.4  01-Mar-1994  cgd put ar_hrd in network byte order. from
Christos Zoulas <christos@deshaw.com>
 1.3  24-Jan-1994  deraadt bpf writes for ethernet take a network byte order ether_type
 1.2  12-Jan-1994  deraadt remove the faster replacement for inet_ntoa because the stupid thing
is byte order dependent.
 1.1  16-Dec-1993  deraadt original from LBL (part of the tcpdump distrib)
SIOCGIFCONF fixup by Roland McGrath <roland@frob.com>
 1.8.2.1  23-Feb-1996  hpeyerl interface aliases don't count as individual interfaces and hence don't
need a seperate bpf. Someone should decide whether to tell netstat
about this.
 1.15.2.2  10-Mar-1997  is Convert this to use the new ARP code (mostly header files/structure
definitions). Needs still work for non-Ethernet.
 1.15.2.1  10-Mar-1997  is file rarpd.c was added on branch is-newarp on 1997-03-10 20:00:55 +0000
 1.21.2.3  29-Jul-1998  mellon Pull up 1.24-1.27 (fair) (PR#5859)
 1.21.2.2  08-May-1998  mycroft Pull up 1.23, per request of mycroft.
 1.21.2.1  24-Nov-1997  mellon Pull rev 1.22 up from trunk (is)
 1.32.2.2  19-Oct-2000  he Pull up revision 1.39 (requested by he):
Format string cleanup.
 1.32.2.1  12-Feb-2000  he Pull up revision 1.36 (requested by abs):
Stop rarpd from hanging if too many routing updates come in
between requests, also improve debug output slightly. Fixes
PR#7508.
 1.33.2.1  27-Dec-1999  wrstuden Pull up to last week's -current.
 1.37.4.3  03-Feb-2001  he Pull up revision 1.40 (requested by is):
Diagnostic message was the wrong way round. Fixes PR#11330.
 1.37.4.2  17-Oct-2000  tv Pullup usr.sbin string format fixes [is].
See "cvs log" for explicit revision numbers per file, from sommerfeld.
 1.37.4.1  30-Aug-2000  abs Include the fact we're making replies in debug() output.
Pullup revision 1.38, approved by thorpej
 1.44.2.1  21-Oct-2002  lukem Pull up revision 1.46 (requested by thorpej in ticket #920):
Allow more than one interface to be specified on the command line.
 1.49.2.2  22-May-2004  he Pull up revision 1.51 (requested by tron in ticket #323):
Fix handling of interface aliases if "rarpd" is not invoked with "-a".
 1.49.2.1  21-Apr-2004  jmc Pullup rev 1.50 (requested by darrenr in ticket #167)

Reduce bpf buffer to 32k from 1M to reduce kernel memory usage from userland
binaries.
Fix bpf so that select will return for a timeout.
Fix the behaviour of BIOCIMMEDIATE.
In bpf_mtap(), optimise the calling of bpf_filter() and catchpacket()
based on whether or not the entire packet is in one mbuf.
Various other bpf fixes, including PR#8674, PR#12170
 1.55.20.1  18-Sep-2008  wrstuden Sync with wrstuden-revivesa-base-2.
 1.57.6.1  13-May-2009  jym Sync with HEAD.

Third (and last) commit. See http://mail-index.netbsd.org/source-changes/2009/05/13/msg221222.html

RSS XML Feed