hostapd/radius_example
Johannes Berg 87098d3324 build: Put archive files into build/ folder too
This is something I hadn't previously done, but there are
cases where it's needed, e.g., building 'wlantest' and then
one of the tests/fuzzing/*/ projects, they use a different
configuration (fuzzing vs. not fuzzing).

Perhaps more importantly, this gets rid of the last thing
that was dumped into the source directories, apart from
the binaries themselves.

Note that due to the use of thin archives, this required
building with absolute paths.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2020-10-11 11:16:00 +03:00
..
.gitignore Re-initialize hostapd/wpa_supplicant git repository based on 0.6.3 release 2008-02-27 17:34:43 -08:00
Makefile build: Put archive files into build/ folder too 2020-10-11 11:16:00 +03:00
radius_example.c RADIUS: Redesign Request Authenticator generation 2016-02-06 17:19:35 +02:00
README Remove the GPL notification from files contributed by Jouni Malinen 2012-02-11 19:39:36 +02:00

Example application using RADIUS client as a library
Copyright (c) 2007, Jouni Malinen <j@w1.fi>

This software may be distributed under the terms of the BSD license.
See the parent directory README for more details.


This directory contains an example showing how the RADIUS client
functionality from hostapd can be used as a library in another
program. The example program initializes the RADIUS client and send a
Access-Request using User-Name and User-Password attributes. A reply
from the RADIUS authentication server will be processed and it is used
as a trigger to terminate the example program.

The RADIUS library links in couple of helper functions from src/utils and
src/crypto directories. Most of these are suitable as-is, but it may
be desirable to replace the debug output code in src/utils/wpa_debug.c
by dropping this file from the library and re-implementing the
functions there in a way that better fits in with the main
application.

RADIUS client implementation takes care of receiving messages,
timeouts, and retransmissions of packets. Consequently, it requires
functionality for registering timeouts and received packet
notifications. This is implemented using the generic event loop
implementation (see src/utils/eloop.h).

The main application may either use the included event loop
implementation or alternatively, implement eloop_* wrapper functions
to use whatever event loop design is used in the main program. This
would involve removing src/utils/eloop.o from the library and
implementing following functions defines in src/utils/eloop.h:
eloop_register_timeout(), eloop_cancel_timeout(),
eloop_register_read_sock(), eloop_unregister_read_sock(), and
eloop_terminated().