OpenBSD CVS

CVS log for src/usr.sbin/arp/arp.c


[BACK] Up to [local] / src / usr.sbin / arp

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.89 / (download) - annotate - [select for diffs], Tue Apr 4 21:18:04 2023 UTC (14 months ago) by bluhm
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, HEAD
Changes since 1.88: +10 -10 lines
Diff to previous 1.88 (colored)

Remove stylistic differences between arp(8) and ndp(8) delete()
function.  This makes it easier to spot real changes in behavior.
OK kn@

Revision 1.88 / (download) - annotate - [select for diffs], Mon Sep 16 20:49:28 2019 UTC (4 years, 8 months ago) by kn
Branch: MAIN
CVS Tags: 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, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6
Changes since 1.87: +1 -3 lines
Diff to previous 1.87 (colored)

Zap unused h_errno

Revision 1.84 removed the last user;  no object change.

Revision 1.87 / (download) - annotate - [select for diffs], Mon Sep 16 19:39:47 2019 UTC (4 years, 8 months ago) by kn
Branch: MAIN
Changes since 1.86: +9 -31 lines
Diff to previous 1.86 (colored)

Simplify function detection

To determine which "function" (get, set, ...) is requested, use getopt(3)'s
result directly as ndp(8) does instead of translating everyting into
internal F_* defines and back again.

Avoids one level of indirection, chops 22 lines of code and brings both
tools closer together.

OK bluhm

Revision 1.86 / (download) - annotate - [select for diffs], Sat Aug 31 13:46:14 2019 UTC (4 years, 9 months ago) by bluhm
Branch: MAIN
Changes since 1.85: +3 -4 lines
Diff to previous 1.85 (colored)

The algorithm creating the routing addresses in route(8) and arp(6)
were still not correct.  While the values written to the kernel are
fine, the bytes for padding were taken from memory after the sockaddr
structs.
In route(8) the union of sockaddrs can be made larger, so that the
padding is taken from there.
In arp(8) the size of the struct is known.  Copy only the struct
and advance over the padding.  The memory has been zeroed before.
Merge all address size fixes from arp(8) into ndp(8).
OK claudio@

Revision 1.85 / (download) - annotate - [select for diffs], Thu Aug 29 19:11:15 2019 UTC (4 years, 9 months ago) by bluhm
Branch: MAIN
Changes since 1.84: +10 -8 lines
Diff to previous 1.84 (colored)

The IFP address in arp(8) used some bytes from a location depending
on sizeof(long) as sockaddr_dl.  We were lucky and it worked.  Use
the correct size and the algorithm from route(8) for arp(8).
OK mpi@

Revision 1.84 / (download) - annotate - [select for diffs], Tue Aug 27 20:50:36 2019 UTC (4 years, 9 months ago) by kn
Branch: MAIN
Changes since 1.83: +32 -23 lines
Diff to previous 1.83 (colored)

Honour -n when deleting entries, sync parse_host() from ndp(8)

arp(8) already has a common getinetaddr() but it ignores -n for delete() and
uses gethostbyname(3), so simply replace it with parse_host() from ndp.c
instead of changing behaviour around the old API.

In set(), make host[] and eaddr[] const since all functions receiving those
variables as parameters expect const anyway.

OK bluhm

Revision 1.83 / (download) - annotate - [select for diffs], Fri Jun 28 13:32:46 2019 UTC (4 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.82: +4 -4 lines
Diff to previous 1.82 (colored)

When system calls indicate an error they return -1, not some arbitrary
value < 0.  errno is only updated in this case.  Change all (most?)
callers of syscalls to follow this better, and let's see if this strictness
helps us in the future.

Revision 1.82 / (download) - annotate - [select for diffs], Tue Jan 22 09:25:29 2019 UTC (5 years, 4 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.81: +3 -3 lines
Diff to previous 1.81 (colored)

PF_ROUTE -> AF_ROUTE in the scattered sock()/setsockopt() calls
where the "wrong" #define was used.

ok dlg@

Revision 1.81 / (download) - annotate - [select for diffs], Thu Apr 26 12:42:51 2018 UTC (6 years, 1 month ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4
Changes since 1.80: +2 -3 lines
Diff to previous 1.80 (colored)

Use <fcntl.h> instead of <sys/file.h> for open() and friends.
Delete a bunch of unnecessary #includes and sort to match style(9)
while doing the above cleanup.

ok deraadt@ krw@

Revision 1.80 / (download) - annotate - [select for diffs], Sat Dec 23 20:53:07 2017 UTC (6 years, 5 months ago) by cheloha
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE, OPENBSD_6_3
Changes since 1.79: +7 -10 lines
Diff to previous 1.79 (colored)

As we only use the .tv_sec field, simplify gettimeofday(2) -> time(3).

ok tb@ jca@

Revision 1.79 / (download) - annotate - [select for diffs], Wed Apr 19 05:36:12 2017 UTC (7 years, 1 month ago) by natano
Branch: MAIN
CVS Tags: OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.78: +2 -2 lines
Diff to previous 1.78 (colored)

Switch base tools from /dev/bpf0 to /dev/bpf. Now that /dev/bpf has been
around for two releases, it should be safe to do so.

ok bluhm deraadt sthen tb yasuoka

Revision 1.78 / (download) - annotate - [select for diffs], Sat Apr 15 11:50:24 2017 UTC (7 years, 1 month ago) by bluhm
Branch: MAIN
Changes since 1.77: +9 -9 lines
Diff to previous 1.77 (colored)

Name global variable for routing socket rtsock like in ndp(8).
OK florian@

Revision 1.77 / (download) - annotate - [select for diffs], Tue Nov 29 08:55:06 2016 UTC (7 years, 6 months ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.76: +8 -8 lines
Diff to previous 1.76 (colored)

Tweak output to keep it aligned when interfaces with big names, like
vether0 are used.

ok jca@, deraadt@

Revision 1.76 / (download) - annotate - [select for diffs], Sat Aug 27 04:15:52 2016 UTC (7 years, 9 months ago) by guenther
Branch: MAIN
Changes since 1.75: +2 -1 lines
Diff to previous 1.75 (colored)

Pull in <sys/time.h> for gettimeofday()

ok deraadt@

Revision 1.75 / (download) - annotate - [select for diffs], Sat May 28 07:00:18 2016 UTC (8 years ago) by natano
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0
Changes since 1.74: +3 -28 lines
Diff to previous 1.74 (colored)

Replace the /dev/bpf* open loop with a plain open("/dev/bpf0", ...).
ok deraadt jca

Revision 1.74 / (download) - annotate - [select for diffs], Wed Mar 23 08:28:31 2016 UTC (8 years, 2 months ago) by mpi
Branch: MAIN
Changes since 1.73: +7 -9 lines
Diff to previous 1.73 (colored)

Kill undocumented "pro" command.  It's a no-op since the 90s!

Revision 1.73 / (download) - annotate - [select for diffs], Wed Mar 23 08:19:58 2016 UTC (8 years, 2 months ago) by mpi
Branch: MAIN
Changes since 1.72: +10 -11 lines
Diff to previous 1.72 (colored)

Rename 'rtn' to 'error' for coherency.

Revision 1.72 / (download) - annotate - [select for diffs], Wed Mar 23 08:17:35 2016 UTC (8 years, 2 months ago) by mpi
Branch: MAIN
Changes since 1.71: +1 -2 lines
Diff to previous 1.71 (colored)

Remove code to print the never set SIN_PROXY bit.  This flag is only used
to set the 33rd bit of a 32bit address in the routing table.

ok millert@

Revision 1.71 / (download) - annotate - [select for diffs], Tue Jan 26 18:26:19 2016 UTC (8 years, 4 months ago) by mmcc
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.70: +2 -2 lines
Diff to previous 1.70 (colored)

Use an unsigned int rather than an int when iterating through all 32
bits in the form:

for (i = 1; i; i <<= 1)

This avoids undefined operations when shifting into and out of the
highest-order bit.

ok millert@

Revision 1.70 / (download) - annotate - [select for diffs], Tue Dec 8 14:20:24 2015 UTC (8 years, 6 months ago) by tedu
Branch: MAIN
Changes since 1.69: +2 -4 lines
Diff to previous 1.69 (colored)

remove undocumented message about trailers

Revision 1.69 / (download) - annotate - [select for diffs], Wed Oct 14 04:03:01 2015 UTC (8 years, 7 months ago) by deraadt
Branch: MAIN
Changes since 1.68: +1 -4 lines
Diff to previous 1.68 (colored)

I messed up reading the call graph.  -d delete does use search, so a
late pledge is not possible in this way.

Revision 1.68 / (download) - annotate - [select for diffs], Fri Oct 9 01:37:09 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.67: +5 -5 lines
Diff to previous 1.67 (colored)

Change all tame callers to namechange to pledge(2).

Revision 1.67 / (download) - annotate - [select for diffs], Wed Oct 7 20:25:40 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.66: +9 -7 lines
Diff to previous 1.66 (colored)

use new tame "route" feature when possible

Revision 1.66 / (download) - annotate - [select for diffs], Mon Oct 5 14:58:37 2015 UTC (8 years, 8 months ago) by semarie
Branch: MAIN
Changes since 1.65: +2 -2 lines
Diff to previous 1.65 (colored)

correct a rtget() error check
this function could only return 0 or 1, and 1 on error.

avoid to deref an uninitialised variable if rtget() return an error.

ok millert@ benno@ deraadt@

Revision 1.65 / (download) - annotate - [select for diffs], Sat Oct 3 02:25:59 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.64: +7 -3 lines
Diff to previous 1.64 (colored)

arp uses a non-privileged sockraw to look at the kernel arp tables.
the function to do that is called a number of times, but as needed.
hoist it upwards into initization, then tame "stdio dns inet" is
possible in most code paths.  (there may be further work to do here here)
i believe florian helped me with this.

Revision 1.64 / (download) - annotate - [select for diffs], Wed Jun 3 08:10:53 2015 UTC (9 years ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.63: +52 -12 lines
Diff to previous 1.63 (colored)

Explicitly request the sockaddr_dl when doing a RTM_GET rather than
assuming that it will be in the gateway sa.

Fixes a regression introduced with the support of multiple connected
routes, found the hardway by deraadt@.

ok claudio@

Revision 1.63 / (download) - annotate - [select for diffs], Fri Jan 16 06:40:15 2015 UTC (9 years, 4 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.62: +3 -3 lines
Diff to previous 1.62 (colored)

Replace <sys/param.h> with <limits.h> and other less dirty headers where
possible.  Annotate <sys/param.h> lines with their current reasons.  Switch
to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc.  Change
MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where
sensible to avoid pulling in the pollution.  These are the files confirmed
through binary verification.
ok guenther, millert, doug (helped with the verification protocol)

Revision 1.62 / (download) - annotate - [select for diffs], Sun Sep 7 22:40:30 2014 UTC (9 years, 9 months ago) by bluhm
Branch: MAIN
Changes since 1.61: +2 -5 lines
Diff to previous 1.61 (colored)

Remove useless comment, snprintf and if/else.
OK mpi@

Revision 1.61 / (download) - annotate - [select for diffs], Wed Sep 3 10:39:41 2014 UTC (9 years, 9 months ago) by mpi
Branch: MAIN
Changes since 1.60: +6 -3 lines
Diff to previous 1.60 (colored)

Be coherent in the way arp(8) and ndp(8) display local entries and
use a new flag `l' to ditinguish them.

Also skip broadcast entries, they are not reall ARP entries and will
never be resolved to anything, requested by deraadt@.

ok bluhm@

Revision 1.60 / (download) - annotate - [select for diffs], Fri Aug 22 22:14:53 2014 UTC (9 years, 9 months ago) by sthen
Branch: MAIN
Changes since 1.59: +2 -2 lines
Diff to previous 1.59 (colored)

print leading 0's in MAC addresses again, ok deraadt

Revision 1.59 / (download) - annotate - [select for diffs], Thu Aug 21 10:23:47 2014 UTC (9 years, 9 months ago) by mpi
Branch: MAIN
Changes since 1.58: +121 -38 lines
Diff to previous 1.58 (colored)

Change the output of arp(8) to match what ndp(8) does and include the
expire timer.

This will makes it easier to add further information in a coherent way
between these tools for local and broadcast entries.

This new view displays either symbolic names (by default) or numerical
addresses (with "-n") for hosts but not both at the same time, just
like ndp(8), route(8) or netstat(1) do.

ok henning@

Revision 1.58 / (download) - annotate - [select for diffs], Tue Aug 19 12:39:36 2014 UTC (9 years, 9 months ago) by mpi
Branch: MAIN
Changes since 1.57: +2 -2 lines
Diff to previous 1.57 (colored)

Entries for broadcast addresses should also be ignored, just like local
entries.

ok florian@, mikeb@, henning@

Revision 1.57 / (download) - annotate - [select for diffs], Mon Aug 11 09:47:56 2014 UTC (9 years, 10 months ago) by mpi
Branch: MAIN
Changes since 1.56: +17 -14 lines
Diff to previous 1.56 (colored)

Do not try to delete RTF_LOCAL entries.  Such routes are automatically
created /deleted by the kernel when an IP address is added/removed
on/from an interface and should not be manipulated by userland tools.

ok henning@, jca@

Revision 1.56 / (download) - annotate - [select for diffs], Tue Mar 18 14:18:22 2014 UTC (10 years, 2 months ago) by mikeb
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.55: +5 -1 lines
Diff to previous 1.55 (colored)

Put AF_ROUTE socket that arp(8) operates on into the appropriate rdomain.

Previously "arp -V 1 -d 10.0.0.1" would hang forever since while the
target rdomain was passed in the rtm, the AF_ROUTE socket was always
created in the rdomain 0.  Due to the logic in route_input (rtsock.c)
route socket's rdomain is compared against the target rdomain of the
request and reply is generated only when they match.  In our case
rdomains were different which cased arp(8) to hang waiting for the
reply that would never be sent.

ok deraadt

Revision 1.55 / (download) - annotate - [select for diffs], Wed Feb 26 20:50:17 2014 UTC (10 years, 3 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5
Changes since 1.54: +2 -2 lines
Diff to previous 1.54 (colored)

There is no need to init a global to 0

Revision 1.54 / (download) - annotate - [select for diffs], Thu Aug 15 13:43:33 2013 UTC (10 years, 9 months ago) by bluhm
Branch: MAIN
Changes since 1.53: +4 -4 lines
Diff to previous 1.53 (colored)

Reduce the warnings when arp, rarp, ndp are compiled with WARNINGS=yes.
warning: declaration of 'time' shadows a global declaration
No binary change; OK lteo@ florian@ henning@ mikeb@ millert@

Revision 1.53 / (download) - annotate - [select for diffs], Sat Jul 20 18:21:11 2013 UTC (10 years, 10 months ago) by bluhm
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE, OPENBSD_5_4
Changes since 1.52: +5 -4 lines
Diff to previous 1.52 (colored)

arp and rarpd used an int expire_time for time calculation.  Convert
this into time_t.
OK benno@

Revision 1.52 / (download) - annotate - [select for diffs], Thu Mar 21 04:43:17 2013 UTC (11 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.51: +17 -11 lines
Diff to previous 1.51 (colored)

create realloc() loops around sysctl for array-based mibs, in programs
which want a "full" dump
ok dlg

Revision 1.51 / (download) - annotate - [select for diffs], Thu Nov 8 11:05:41 2012 UTC (11 years, 7 months ago) by phessler
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE, OPENBSD_5_3
Changes since 1.50: +2 -1 lines
Diff to previous 1.50 (colored)

When running route -Tx exec arp -an, arp would always use the default
routing domain.  Fix it so we use the process rdomain, but still allow
command line overrides.

noticed by, and OK, mikeb@

Revision 1.50 / (download) - annotate - [select for diffs], Tue Jan 11 16:34:20 2011 UTC (13 years, 5 months ago) by jasper
Branch: MAIN
CVS Tags: OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0, OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.49: +198 -4 lines
Diff to previous 1.49 (colored)

  Add Wake on Lan support to arp(8). This is partly based on the original
    wake(8) program. One can specify an interface to send on, or simply
      broadcast on all available interfaces.

	Initial input from stsp@, further help from claudio@ and deraadt@.
	  ok claudio@ deraadt@
	    manpage bits ok jmc@

Revision 1.49 / (download) - annotate - [select for diffs], Sun Sep 27 12:07:15 2009 UTC (14 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8, OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.48: +3 -3 lines
Diff to previous 1.48 (colored)

a usage line got too long; ok jmc

Revision 1.48 / (download) - annotate - [select for diffs], Thu Jun 25 15:43:18 2009 UTC (14 years, 11 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.47: +3 -2 lines
Diff to previous 1.47 (colored)

Same code as in route(8) same RTM_VERSION check missing.
Tested and OK sthen@, OK henning@

Revision 1.47 / (download) - annotate - [select for diffs], Fri Jun 5 03:54:42 2009 UTC (15 years ago) by chris
Branch: MAIN
Changes since 1.46: +2 -2 lines
Diff to previous 1.46 (colored)

more rtm->rtm_hdrlen conversion

ok claudio@

Revision 1.46 / (download) - annotate - [select for diffs], Fri Jun 5 00:13:35 2009 UTC (15 years ago) by claudio
Branch: MAIN
Changes since 1.45: +20 -8 lines
Diff to previous 1.45 (colored)

One more tool that knows about other domains via -V

Revision 1.45 / (download) - annotate - [select for diffs], Fri Dec 12 20:23:20 2008 UTC (15 years, 5 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5
Changes since 1.44: +4 -3 lines
Diff to previous 1.44 (colored)

Use rtm_hdrlen to jump over the message header and to the beginning of the
sockaddrs included in the message. This makes the code more robust when
kernel and userland are out of sync. put it in deraadt@

Revision 1.44 / (download) - annotate - [select for diffs], Wed Mar 12 23:18:59 2008 UTC (16 years, 3 months ago) by sobrado
Branch: MAIN
CVS Tags: OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.43: +2 -2 lines
Diff to previous 1.43 (colored)

"usage:" should precede the first statement only

ok jmc@

Revision 1.43 / (download) - annotate - [select for diffs], Thu Feb 14 09:28:02 2008 UTC (16 years, 3 months ago) by thib
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.42: +1 -4 lines
Diff to previous 1.42 (colored)

backout the change to make arp(8) default to -an;
Remove that blurp from the man page also.

requested by deraadt@;

Revision 1.42 / (download) - annotate - [select for diffs], Thu Feb 7 16:53:58 2008 UTC (16 years, 4 months ago) by thib
Branch: MAIN
Changes since 1.41: +4 -4 lines
Diff to previous 1.41 (colored)

Oops. Better diff to enable -an by default without breaking
the other options too badly;

ok millert@

Revision 1.41 / (download) - annotate - [select for diffs], Thu Feb 7 15:57:07 2008 UTC (16 years, 4 months ago) by thib
Branch: MAIN
Changes since 1.40: +4 -1 lines
Diff to previous 1.40 (colored)

make arp(8) default to -na when called with no arguments;

man page bit from jmc@

ok millert@, oga@, laurent@

Revision 1.40 / (download) - annotate - [select for diffs], Fri Aug 24 13:12:16 2007 UTC (16 years, 9 months ago) by claudio
Branch: MAIN
Changes since 1.39: +3 -1 lines
Diff to previous 1.39 (colored)

Yet another application that does not check if the RTM_VERSION is the expected
one. Luckily it seems that only show is affected. OK henning@

Revision 1.39 / (download) - annotate - [select for diffs], Sun Feb 18 23:50:47 2007 UTC (17 years, 3 months ago) by ray
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2, OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.38: +2 -2 lines
Diff to previous 1.38 (colored)

Use sizeof(buf) instead of hard coded numbers.

From Charles Longeau <chl at tuxfamily dot org> long ago.

OK moritz@.

Revision 1.38 / (download) - annotate - [select for diffs], Fri May 26 09:00:57 2006 UTC (18 years ago) by jmc
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.37: +3 -7 lines
Diff to previous 1.37 (colored)

simplify synopsis; ok deraadt

Revision 1.37 / (download) - annotate - [select for diffs], Tue Apr 18 22:11:49 2006 UTC (18 years, 1 month ago) by moritz
Branch: MAIN
Changes since 1.36: +2 -2 lines
Diff to previous 1.36 (colored)

Remove "S" from getopt(3) string, which was added in 1.32 by mistake.
From Steffen Wendzel. ok henning@

Revision 1.36 / (download) - annotate - [select for diffs], Mon Apr 4 16:14:45 2005 UTC (19 years, 2 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9, OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.35: +7 -13 lines
Diff to previous 1.35 (colored)

shrink

Revision 1.35 / (download) - annotate - [select for diffs], Mon Apr 4 09:03:07 2005 UTC (19 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.34: +1 -2 lines
Diff to previous 1.34 (colored)

nlist.h not needed

Revision 1.34 / (download) - annotate - [select for diffs], Tue Mar 29 23:55:18 2005 UTC (19 years, 2 months ago) by henning
Branch: MAIN
Changes since 1.33: +1 -12 lines
Diff to previous 1.33 (colored)


clean further, theo ok

Revision 1.33 / (download) - annotate - [select for diffs], Tue Mar 29 22:24:48 2005 UTC (19 years, 2 months ago) by henning
Branch: MAIN
Changes since 1.32: +71 -64 lines
Diff to previous 1.32 (colored)

make this a bit more readable

Revision 1.32 / (download) - annotate - [select for diffs], Tue Mar 29 21:59:59 2005 UTC (19 years, 2 months ago) by henning
Branch: MAIN
Changes since 1.31: +14 -6 lines
Diff to previous 1.31 (colored)

add -F to force replacement of entries with -s and -f
inspired by a diff from Mike Belopuhov <mkb@cvs.hnet.spb.ru>,
these semantics with theo, manpage jaredy jmc and bob, ok bob

Revision 1.31 / (download) - annotate - [select for diffs], Tue Jan 4 10:57:23 2005 UTC (19 years, 5 months ago) by pascoe
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7
Changes since 1.30: +4 -4 lines
Diff to previous 1.30 (colored)

Enable ARP table manipulation on CARP interfaces.

ok niklas@ mcbride@

Revision 1.30 / (download) - annotate - [select for diffs], Fri Jun 27 22:11:39 2003 UTC (20 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_6_BASE, OPENBSD_3_6, OPENBSD_3_5_BASE, OPENBSD_3_5, OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.29: +3 -2 lines
Diff to previous 1.29 (colored)

memory leak; andrushock@korovino.net

Revision 1.29 / (download) - annotate - [select for diffs], Fri Jun 27 22:11:22 2003 UTC (20 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.28: +5 -6 lines
Diff to previous 1.28 (colored)

remove unused variables

Revision 1.28 / (download) - annotate - [select for diffs], Wed Jun 11 23:33:25 2003 UTC (21 years ago) by deraadt
Branch: MAIN
Changes since 1.27: +17 -35 lines
Diff to previous 1.27 (colored)

some ansification, some de-register

Revision 1.27 / (download) - annotate - [select for diffs], Mon Jun 2 23:36:52 2003 UTC (21 years ago) by millert
Branch: MAIN
Changes since 1.26: +3 -7 lines
Diff to previous 1.26 (colored)

Remove the advertising clause in the UCB license which Berkeley
rescinded 22 July 1999.  Proofed by myself and Theo.

Revision 1.26 / (download) - annotate - [select for diffs], Mon Mar 17 23:26:21 2003 UTC (21 years, 2 months ago) by henric
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3
Changes since 1.25: +16 -9 lines
Diff to previous 1.25 (colored)

arp did not long-align sockaddrs in routing messages.  This led to
garbage being sent to the kernel on sparc64.

Problem reported and fix tested by Doug Winter (thanks).

ok jason@ and millert@

Revision 1.25 / (download) - annotate - [select for diffs], Tue Dec 3 22:33:50 2002 UTC (21 years, 6 months ago) by fgsch
Branch: MAIN
Changes since 1.24: +3 -0 lines
Diff to previous 1.24 (colored)

print the interface related to the arp entry; several ppl ok.

Revision 1.24 / (download) - annotate - [select for diffs], Fri Sep 6 18:33:16 2002 UTC (21 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_2_BASE, OPENBSD_3_2
Changes since 1.23: +7 -6 lines
Diff to previous 1.23 (colored)

undo signed vs unsigned confusion

Revision 1.23 / (download) - annotate - [select for diffs], Thu May 30 19:09:05 2002 UTC (22 years ago) by deraadt
Branch: MAIN
Changes since 1.22: +26 -22 lines
Diff to previous 1.22 (colored)

minor KNF

Revision 1.22 / (download) - annotate - [select for diffs], Sun May 26 09:25:21 2002 UTC (22 years ago) by deraadt
Branch: MAIN
Changes since 1.21: +3 -3 lines
Diff to previous 1.21 (colored)

pid_t cleanup

Revision 1.21 / (download) - annotate - [select for diffs], Thu Mar 14 16:44:24 2002 UTC (22 years, 3 months ago) by mpech
Branch: MAIN
CVS Tags: OPENBSD_3_1_BASE, OPENBSD_3_1
Changes since 1.20: +10 -10 lines
Diff to previous 1.20 (colored)

kill more registers.

millert@ ok

Revision 1.20 / (download) - annotate - [select for diffs], Thu Mar 14 06:51:42 2002 UTC (22 years, 3 months ago) by mpech
Branch: MAIN
Changes since 1.19: +3 -3 lines
Diff to previous 1.19 (colored)

Remove \n from err/errx/warn/warnx().

millert@ ok

Revision 1.19 / (download) - annotate - [select for diffs], Sat Feb 16 21:28:00 2002 UTC (22 years, 3 months ago) by millert
Branch: MAIN
Changes since 1.18: +11 -11 lines
Diff to previous 1.18 (colored)

Part one of userland __P removal.  Done with a simple regexp with some minor hand editing to make comments line up correctly.  Another pass is forthcoming that handles the cases that could not be done automatically.

Revision 1.18 / (download) - annotate - [select for diffs], Sun Jun 10 17:46:20 2001 UTC (23 years ago) by dugsong
Branch: MAIN
CVS Tags: OPENBSD_3_0_BASE, OPENBSD_3_0
Changes since 1.17: +148 -72 lines
Diff to previous 1.17 (colored)

implement arp -d -a, to delete all arp entries at once. mostly from FreeBSD. deraadt@ ok.

Revision 1.17 / (download) - annotate - [select for diffs], Wed Mar 7 19:31:58 2001 UTC (23 years, 3 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_9_BASE, OPENBSD_2_9
Changes since 1.16: +3 -3 lines
Diff to previous 1.16 (colored)

print ether_ntoa() compatible

Revision 1.16 / (download) - annotate - [select for diffs], Mon Oct 23 14:55:12 2000 UTC (23 years, 7 months ago) by aaron
Branch: MAIN
CVS Tags: OPENBSD_2_8_BASE, OPENBSD_2_8
Changes since 1.15: +2 -2 lines
Diff to previous 1.15 (colored)

Spelling: wierd -> weird

Revision 1.15 / (download) - annotate - [select for diffs], Sun Sep 24 22:12:25 2000 UTC (23 years, 8 months ago) by miod
Branch: MAIN
Changes since 1.14: +5 -4 lines
Diff to previous 1.14 (colored)

Correctly ignore -n flag with -d when both options are separate (i.e.
arp -n -d, not arp -nd), millert@ ok

Revision 1.14 / (download) - annotate - [select for diffs], Sun May 16 00:43:44 1999 UTC (25 years, 1 month ago) by ho
Branch: MAIN
CVS Tags: OPENBSD_2_7_BASE, OPENBSD_2_7, OPENBSD_2_6_BASE, OPENBSD_2_6
Changes since 1.13: +18 -3 lines
Diff to previous 1.13 (colored)

Added 'permanent' keyword for non-overwritable static ARP entries.

Revision 1.13 / (download) - annotate - [select for diffs], Tue Sep 29 02:22:14 1998 UTC (25 years, 8 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_2_5_BASE, OPENBSD_2_5, OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.12: +3 -1 lines
Diff to previous 1.12 (colored)

only spew 'illegal option' once  if they give an unsupported optino

Revision 1.12 / (download) - annotate - [select for diffs], Thu May 14 21:16:42 1998 UTC (26 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.11: +2 -2 lines
Diff to previous 1.11 (colored)

more careful scanf

Revision 1.11 / (download) - annotate - [select for diffs], Mon May 11 01:34:50 1998 UTC (26 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.10: +2 -2 lines
Diff to previous 1.10 (colored)

set max field width of %s correctly

Revision 1.10 / (download) - annotate - [select for diffs], Fri Nov 28 05:34:41 1997 UTC (26 years, 6 months ago) by art
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3
Changes since 1.9: +3 -1 lines
Diff to previous 1.9 (colored)

I'm amazed that noone has ever misspelled the ethernet address when
doing an arp -s. Well I was the first. ;)

Revision 1.9 / (download) - annotate - [select for diffs], Fri Nov 21 22:42:55 1997 UTC (26 years, 6 months ago) by deraadt
Branch: MAIN
Changes since 1.8: +3 -1 lines
Diff to previous 1.8 (colored)

bail if no arp entries

Revision 1.8 / (download) - annotate - [select for diffs], Fri Sep 12 04:07:16 1997 UTC (26 years, 9 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.7: +2 -1 lines
Diff to previous 1.7 (colored)

Kill extra newline in err()/warn().

Revision 1.7 / (download) - annotate - [select for diffs], Mon Jun 23 09:32:01 1997 UTC (26 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.6: +2 -2 lines
Diff to previous 1.6 (colored)

int vs in_addr_t

Revision 1.6 / (download) - annotate - [select for diffs], Mon Feb 3 00:12:57 1997 UTC (27 years, 4 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_1_BASE, OPENBSD_2_1
Changes since 1.5: +6 -1 lines
Diff to previous 1.5 (colored)

make "arp -na" and "arp -an" do the same thing; paul@wit387304.student.utwente.nl

Revision 1.5 / (download) - annotate - [select for diffs], Wed Jan 15 23:43:51 1997 UTC (27 years, 4 months ago) by millert
Branch: MAIN
Changes since 1.4: +1 -1 lines
Diff to previous 1.4 (colored)

getopt(3) returns -1 when out of args, not EOF, whee!

Revision 1.4 / (download) - annotate - [select for diffs], Tue Dec 10 15:15:39 1996 UTC (27 years, 6 months ago) by deraadt
Branch: MAIN
Changes since 1.3: +1 -3 lines
Diff to previous 1.3 (colored)

warnx, from netbsd

Revision 1.3 / (download) - annotate - [select for diffs], Thu Aug 29 03:32:41 1996 UTC (27 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.2: +1 -4 lines
Diff to previous 1.2 (colored)

fix warnings

Revision 1.2 / (download) - annotate - [select for diffs], Sat Jul 6 06:52:56 1996 UTC (27 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.1: +6 -24 lines
Diff to previous 1.1 (colored)

not very well tested ether_aton() cleanup

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:47:24 1995 UTC (28 years, 7 months ago) by deraadt
CVS Tags: netbsd_1_1
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of NetBSD tree

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 08:47:24 1995 UTC (28 years, 7 months ago) by deraadt
Branch: MAIN

Initial revision

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.