OpenBSD CVS

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


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

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.42 / (download) - annotate - [select for diffs], Wed Mar 8 04:43:13 2023 UTC (15 months ago) by guenther
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, HEAD
Changes since 1.41: +1 -2 lines
Diff to previous 1.41 (colored)

Delete obsolete /* ARGSUSED */ lint comments.

ok miod@ millert@

Revision 1.41 / (download) - annotate - [select for diffs], Wed Jul 3 03:24:03 2019 UTC (4 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: 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.40: +2 -2 lines
Diff to previous 1.40 (colored)

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

Revision 1.40 / (download) - annotate - [select for diffs], Fri Jun 28 13:32:47 2019 UTC (4 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.39: +2 -2 lines
Diff to previous 1.39 (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.39 / (download) - annotate - [select for diffs], Fri May 10 01:29:31 2019 UTC (5 years, 1 month ago) by guenther
Branch: MAIN
Changes since 1.38: +1 -2 lines
Diff to previous 1.38 (colored)

Delete superfluous #includes of <ifaddrs.h>, <net/if_dl.h>, and <net/if_enc.h>

ok krw@, jsg@

Revision 1.38 / (download) - annotate - [select for diffs], Wed Apr 19 05:36:13 2017 UTC (7 years, 1 month ago) by natano
Branch: MAIN
CVS Tags: OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.37: +2 -2 lines
Diff to previous 1.37 (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.37 / (download) - annotate - [select for diffs], Sat May 28 07:00:18 2016 UTC (8 years ago) by natano
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0
Changes since 1.36: +4 -19 lines
Diff to previous 1.36 (colored)

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

Revision 1.36 / (download) - annotate - [select for diffs], Tue Dec 22 19:45:09 2015 UTC (8 years, 5 months ago) by mmcc
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.35: +2 -3 lines
Diff to previous 1.35 (colored)

remove a NULL-check before free()

Revision 1.35 / (download) - annotate - [select for diffs], Fri Jan 16 06:40:17 2015 UTC (9 years, 4 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.34: +3 -2 lines
Diff to previous 1.34 (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.34 / (download) - annotate - [select for diffs], Mon May 12 23:49:28 2008 UTC (16 years, 1 month ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6, OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, 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, OPENBSD_4_8_BASE, OPENBSD_4_8, OPENBSD_4_7_BASE, OPENBSD_4_7, OPENBSD_4_6_BASE, OPENBSD_4_6, OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.33: +2 -2 lines
Diff to previous 1.33 (colored)

Fix cut and pasto; Steven Roberts

Revision 1.33 / (download) - annotate - [select for diffs], Mon May 12 19:15:02 2008 UTC (16 years, 1 month ago) by pyr
Branch: MAIN
Changes since 1.32: +6 -1 lines
Diff to previous 1.32 (colored)

Error out with usage line if additional arguments are given after the
option parsing. Found out the hard way by jdixon on ifstated.

ok sobrado@, jdixon@, millert@

Revision 1.32 / (download) - annotate - [select for diffs], Wed May 2 09:09:29 2007 UTC (17 years, 1 month ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3, OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.31: +17 -13 lines
Diff to previous 1.31 (colored)

Use event(3) provided signal functions -- this decouples the event
handling and so the signal handlers are safe to call whatever they want.
This solves PR5463. OK reyk@

Revision 1.31 / (download) - annotate - [select for diffs], Thu Feb 8 11:15:55 2007 UTC (17 years, 4 months ago) by reyk
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.30: +22 -13 lines
Diff to previous 1.30 (colored)

carefully check some return values and make lint happy. check for
truncation before feeding strings into the kernel.

Revision 1.30 / (download) - annotate - [select for diffs], Thu Sep 28 17:43:42 2006 UTC (17 years, 8 months ago) by reyk
Branch: MAIN
Changes since 1.29: +4 -2 lines
Diff to previous 1.29 (colored)

hostapd tree search speedup via inlined compare function

suggested by Mike Belopuhov (mkb at crypt dot org dot ru)

Revision 1.29 / (download) - annotate - [select for diffs], Thu Jun 1 22:09:09 2006 UTC (18 years ago) by reyk
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.28: +22 -15 lines
Diff to previous 1.28 (colored)

don't use the newline character in hostapd_log() calls

Revision 1.28 / (download) - annotate - [select for diffs], Sat May 13 18:25:12 2006 UTC (18 years, 1 month ago) by reyk
Branch: MAIN
Changes since 1.27: +2 -1 lines
Diff to previous 1.27 (colored)

set the correct timezone using tzset() before before writing to syslog.

thanks to Bruno Carnazzi

Revision 1.27 / (download) - annotate - [select for diffs], Sat Feb 25 13:38:25 2006 UTC (18 years, 3 months ago) by reyk
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.26: +14 -10 lines
Diff to previous 1.26 (colored)

fix for hostapd_printf() from Andrey Matveev:
---snip---
We allocate some memory with va_start() for storage variable arguments
in dynamic mode. va_end() takes care about clearing this memory.
Therefore we should be sure, that to each va_start() there corresponds
va_end() call. And on error path too.
---snap---

Revision 1.26 / (download) - annotate - [select for diffs], Sun Dec 18 17:54:12 2005 UTC (18 years, 5 months ago) by reyk
Branch: MAIN
Changes since 1.25: +2 -2 lines
Diff to previous 1.25 (colored)

Update my e-mail address in the copyright statement, no binary changes.

Revision 1.25 / (download) - annotate - [select for diffs], Sat Dec 10 13:42:37 2005 UTC (18 years, 6 months ago) by reyk
Branch: MAIN
Changes since 1.24: +13 -7 lines
Diff to previous 1.24 (colored)

add an option to increase the multicast ttl which is currently limited
to 1 hop. by using a higher multicast ttl, you could use inter-network
multicast forwarding of hostapd messages (i.e. with mrouted(8) or
multicast-capable routing switches); "set iapp mode multicast ttl 2".

Revision 1.24 / (download) - annotate - [select for diffs], Thu Dec 1 01:11:30 2005 UTC (18 years, 6 months ago) by reyk
Branch: MAIN
Changes since 1.23: +34 -29 lines
Diff to previous 1.23 (colored)

move iapp configuration in a separate data structure

Revision 1.23 / (download) - annotate - [select for diffs], Sun Nov 20 12:02:04 2005 UTC (18 years, 6 months ago) by reyk
Branch: MAIN
Changes since 1.22: +28 -28 lines
Diff to previous 1.22 (colored)

add support for multiple hostap (wireless) interfaces.

for example, if you run one hostapd with two ath(4) devices. you have
to specify "set hostap interface { ath0, ath1 }" in hostapd.conf(5).

man page bits by jmc@, tested by others

Revision 1.22 / (download) - annotate - [select for diffs], Wed Nov 16 00:01:19 2005 UTC (18 years, 6 months ago) by reyk
Branch: MAIN
Changes since 1.21: +12 -10 lines
Diff to previous 1.21 (colored)

add a configuration option for specifying a non-standard port and multicast
address for the IAPP messages. this is an initial approach to run multiple
hostapds on one machine, further work will be done later.

Revision 1.21 / (download) - annotate - [select for diffs], Fri Oct 7 22:32:52 2005 UTC (18 years, 8 months ago) by reyk
Branch: MAIN
Changes since 1.20: +2 -1 lines
Diff to previous 1.20 (colored)

move IAPP definitions to separate header file

Revision 1.20 / (download) - annotate - [select for diffs], Fri Oct 7 21:52:40 2005 UTC (18 years, 8 months ago) by reyk
Branch: MAIN
Changes since 1.19: +2 -2 lines
Diff to previous 1.19 (colored)

spacing

Revision 1.19 / (download) - annotate - [select for diffs], Tue Sep 13 09:22:42 2005 UTC (18 years, 9 months ago) by reyk
Branch: MAIN
Changes since 1.18: +2 -2 lines
Diff to previous 1.18 (colored)

use memcmp instead of bcmp to compare tree nodes.

Revision 1.18 / (download) - annotate - [select for diffs], Fri Sep 9 13:21:13 2005 UTC (18 years, 9 months ago) by reyk
Branch: MAIN
Changes since 1.17: +22 -29 lines
Diff to previous 1.17 (colored)

replace hasch tables with red-black trees used by the node tables.

ok mcbride@

Revision 1.17 / (download) - annotate - [select for diffs], Wed Aug 17 13:18:33 2005 UTC (18 years, 9 months ago) by reyk
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.16: +4 -4 lines
Diff to previous 1.16 (colored)

add newlines in hostapd_fatal() calls, fix some typos.
thanks to Brian Poole.

Revision 1.16 / (download) - annotate - [select for diffs], Sat Jul 30 17:16:09 2005 UTC (18 years, 10 months ago) by reyk
Branch: MAIN
Changes since 1.15: +4 -1 lines
Diff to previous 1.15 (colored)

flush print buffer on empty newlines

Revision 1.15 / (download) - annotate - [select for diffs], Mon Jul 4 18:48:05 2005 UTC (18 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.14: +2 -2 lines
Diff to previous 1.14 (colored)

nicer text

Revision 1.14 / (download) - annotate - [select for diffs], Mon Jul 4 17:51:44 2005 UTC (18 years, 11 months ago) by reyk
Branch: MAIN
Changes since 1.13: +5 -16 lines
Diff to previous 1.13 (colored)

remove command line options -i, -a and -b (iapp interface, hostap interface
and broadcast mode). please use the configuration file hostapd.conf(5)
instead, it is now mandatory to run hostapd with it.

Revision 1.13 / (download) - annotate - [select for diffs], Mon Jul 4 17:13:39 2005 UTC (18 years, 11 months ago) by reyk
Branch: MAIN
Changes since 1.12: +16 -8 lines
Diff to previous 1.12 (colored)

print error messages to stderr instead of syslog on startup.
suggested by deraadt@

Revision 1.12 / (download) - annotate - [select for diffs], Mon Jul 4 16:48:55 2005 UTC (18 years, 11 months ago) by reyk
Branch: MAIN
Changes since 1.11: +15 -1 lines
Diff to previous 1.11 (colored)

add 'random' action address and auth open request/response

Revision 1.11 / (download) - annotate - [select for diffs], Fri Jun 17 19:13:35 2005 UTC (18 years, 11 months ago) by reyk
Branch: MAIN
Changes since 1.10: +147 -3 lines
Diff to previous 1.10 (colored)

first step to implement a proactive wireless monitoring system using
hostapd(8). it's a very simple but powerful approach using highly
flexible and stateless event and action rules for IEEE 802.11 traffic.
you can monitor a wireless network by watching frames with types and
addresses (with support for tables and masks) and you can trigger
actions like writing log messages, sending pcap/radiotap dumps to the
IAPP network, removing nodes from the hostap, resending received
frames and sending contructed 802.11 frames in reply to traffic
received from any rogue nodes.

it's based on some initial work from the c2k5 which has been tested
and improved during the last weeks. some missing documentation for
hostapd.conf(5) will be written as soon as possible.

ok deraadt@

Revision 1.10 / (download) - annotate - [select for diffs], Sat May 21 19:18:51 2005 UTC (19 years ago) by msf
Branch: MAIN
Changes since 1.9: +4 -1 lines
Diff to previous 1.9 (colored)

hostapd doesn't really do much without root privileges, so check for that early

ok reyk@

Revision 1.9 / (download) - annotate - [select for diffs], Thu Apr 14 10:59:56 2005 UTC (19 years, 2 months ago) by reyk
Branch: MAIN
Changes since 1.8: +5 -7 lines
Diff to previous 1.8 (colored)

fix possible double free(), thans to Andrey Matveev

Revision 1.8 / (download) - annotate - [select for diffs], Wed Apr 13 21:15:36 2005 UTC (19 years, 2 months ago) by reyk
Branch: MAIN
Changes since 1.7: +7 -6 lines
Diff to previous 1.7 (colored)

un-hack, use event_loopexit()

ok henning@ brad@

Revision 1.7 / (download) - annotate - [select for diffs], Wed Apr 13 19:59:08 2005 UTC (19 years, 2 months ago) by jmc
Branch: MAIN
Changes since 1.6: +2 -2 lines
Diff to previous 1.6 (colored)

sync usage()

Revision 1.6 / (download) - annotate - [select for diffs], Wed Apr 13 19:26:05 2005 UTC (19 years, 2 months ago) by henning
Branch: MAIN
Changes since 1.5: +8 -9 lines
Diff to previous 1.5 (colored)

only fflush STDERR when we actually log to STDERR, reyk ok

Revision 1.5 / (download) - annotate - [select for diffs], Wed Apr 13 19:16:08 2005 UTC (19 years, 2 months ago) by henning
Branch: MAIN
Changes since 1.4: +2 -1 lines
Diff to previous 1.4 (colored)

missing copyrights here as well
it is more than fine to re-use our code (please do!), but do not forget our
copyright!

Revision 1.4 / (download) - annotate - [select for diffs], Wed Apr 13 19:08:18 2005 UTC (19 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.3: +2 -10 lines
Diff to previous 1.3 (colored)

do not close descriptors before exit

Revision 1.3 / (download) - annotate - [select for diffs], Wed Apr 13 18:55:00 2005 UTC (19 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.2: +1 -3 lines
Diff to previous 1.2 (colored)

bzero of bss not needed

Revision 1.2 / (download) - annotate - [select for diffs], Wed Apr 13 18:25:28 2005 UTC (19 years, 2 months ago) by henning
Branch: MAIN
Changes since 1.1: +7 -8 lines
Diff to previous 1.1 (colored)

KNF

Revision 1.1 / (download) - annotate - [select for diffs], Wed Apr 13 18:12:23 2005 UTC (19 years, 2 months ago) by reyk
Branch: MAIN

add the initial version of the OpenBSD hostapd daemon

ok deraadt@

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.