]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
19 months agono, it's the pending queue.
Alan T. DeKok [Sat, 28 Dec 2024 17:19:49 +0000 (12:19 -0500)] 
no, it's the pending queue.

CI passes, but CI static analyzer doesn't pass, likely due to
different timings.

19 months agorequests can be in the backlog when the trunk is initially connected
Alan T. DeKok [Sat, 28 Dec 2024 16:20:32 +0000 (11:20 -0500)] 
requests can be in the backlog when the trunk is initially connected

this behavior is needed by rlm_radius, which opens trunks to new
destinations, and then immediately enqueues requests onto them.

19 months agoit helps to set the eof flag
Alan T. DeKok [Sat, 28 Dec 2024 16:16:08 +0000 (11:16 -0500)] 
it helps to set the eof flag

19 months agohandle more corner cases of blocking IO
Alan T. DeKok [Sat, 28 Dec 2024 12:43:36 +0000 (07:43 -0500)] 
handle more corner cases of blocking IO

19 months agoa failed xlat is a "false" condition
Alan T. DeKok [Sat, 28 Dec 2024 12:48:11 +0000 (07:48 -0500)] 
a failed xlat is a "false" condition

19 months agohoist proxy loop checks to one location
Alan T. DeKok [Fri, 27 Dec 2024 21:20:46 +0000 (16:20 -0500)] 
hoist proxy loop checks to one location

and apply the CHAP-Challenge etc. fixups to %proxy.sendto.ipaddr()

19 months agostart of stats cleanups
Alan T. DeKok [Fri, 27 Dec 2024 19:59:19 +0000 (14:59 -0500)] 
start of stats cleanups

19 months agomove SNMP declarations to their own header
Alan T. DeKok [Fri, 27 Dec 2024 19:48:46 +0000 (14:48 -0500)] 
move SNMP declarations to their own header

19 months agomove to new unlang_xlat_yield_to_retry() API
Alan T. DeKok [Fri, 27 Dec 2024 18:36:51 +0000 (13:36 -0500)] 
move to new unlang_xlat_yield_to_retry() API

19 months agoadd unlang_xlat_yield_to_retry()
Alan T. DeKok [Fri, 27 Dec 2024 18:35:49 +0000 (13:35 -0500)] 
add unlang_xlat_yield_to_retry()

which mirrors the functionality of unlang_module_yield_to_retry()

19 months agonu_events can't be <0 if it's checked earlier
Alan T. DeKok [Fri, 27 Dec 2024 15:03:44 +0000 (10:03 -0500)] 
nu_events can't be <0 if it's checked earlier

19 months agomake our own Proxy-State 64-bit
Alan T. DeKok [Fri, 27 Dec 2024 14:18:26 +0000 (09:18 -0500)] 
make our own Proxy-State 64-bit

which means that collisions are essentially impossible.

19 months agocomplain about proxy loops
Alan T. DeKok [Fri, 27 Dec 2024 13:53:22 +0000 (08:53 -0500)] 
complain about proxy loops

19 months agoset attr_packet_type
Alan T. DeKok [Fri, 27 Dec 2024 13:35:21 +0000 (08:35 -0500)] 
set attr_packet_type

so that we get names out of the packet codes

19 months agoadd test for %proxy.sendto.ipaddr(...)
Alan T. DeKok [Fri, 27 Dec 2024 13:27:25 +0000 (08:27 -0500)] 
add test for %proxy.sendto.ipaddr(...)

which checks that proxying is a success

19 months agomove common code to function
Alan T. DeKok [Thu, 26 Dec 2024 23:52:03 +0000 (18:52 -0500)] 
move common code to function

19 months agosave a copy of the packet only if we're going to resend it
Alan T. DeKok [Thu, 26 Dec 2024 23:51:45 +0000 (18:51 -0500)] 
save a copy of the packet only if we're going to resend it

19 months agominor cleanups
Alan T. DeKok [Thu, 26 Dec 2024 23:36:38 +0000 (18:36 -0500)] 
minor cleanups

19 months agoregenerate from module configuration
Alan T. DeKok [Thu, 26 Dec 2024 22:32:33 +0000 (17:32 -0500)] 
regenerate from module configuration

19 months agoquiet compiler
Alan T. DeKok [Thu, 26 Dec 2024 21:01:29 +0000 (16:01 -0500)] 
quiet compiler

19 months agomore docs
Alan T. DeKok [Thu, 26 Dec 2024 20:56:33 +0000 (15:56 -0500)] 
more docs

19 months agominor tweaks to the example
Alan T. DeKok [Thu, 26 Dec 2024 20:53:55 +0000 (15:53 -0500)] 
minor tweaks to the example

19 months agoadd and use idle_timeout configuration
Alan T. DeKok [Wed, 25 Dec 2024 17:54:54 +0000 (12:54 -0500)] 
add and use idle_timeout configuration

19 months agotrack more per-connection stats
Alan T. DeKok [Wed, 25 Dec 2024 17:54:22 +0000 (12:54 -0500)] 
track more per-connection stats

19 months agoquiet analyzer
Alan T. DeKok [Thu, 26 Dec 2024 19:35:31 +0000 (14:35 -0500)] 
quiet analyzer

19 months agoquiet analyzer
Alan T. DeKok [Thu, 26 Dec 2024 19:35:20 +0000 (14:35 -0500)] 
quiet analyzer

19 months agodirfd() is a C library function, and not a variable name
Alan T. DeKok [Thu, 26 Dec 2024 19:34:05 +0000 (14:34 -0500)] 
dirfd() is a C library function, and not a variable name

19 months agoexpire old home servers, on a fixed 60s timer
Alan T. DeKok [Thu, 26 Dec 2024 19:21:49 +0000 (14:21 -0500)] 
expire old home servers, on a fixed 60s timer

19 months agoallow modules to be commented out trivially
Alan T. DeKok [Thu, 26 Dec 2024 17:09:05 +0000 (12:09 -0500)] 
allow modules to be commented out trivially

19 months agoadd support for dynamic proxying
Alan T. DeKok [Thu, 26 Dec 2024 16:56:22 +0000 (11:56 -0500)] 
add support for dynamic proxying

The home servers are never cleaned up or timed out.  The home
servers also can't have their secrets changed.

19 months agoadd API for RB trees with expiry timers
Alan T. DeKok [Thu, 26 Dec 2024 17:07:33 +0000 (12:07 -0500)] 
add API for RB trees with expiry timers

19 months agomove common elements to one data structure
Alan T. DeKok [Thu, 26 Dec 2024 16:37:32 +0000 (11:37 -0500)] 
move common elements to one data structure

in preparation for adding trunked home servers

19 months agodon't complain about limit_proxy_state if we have Message-Authenticator
Alan T. DeKok [Thu, 26 Dec 2024 14:02:38 +0000 (09:02 -0500)] 
don't complain about limit_proxy_state if we have Message-Authenticator

if we set "require_message_authenticator = yes", then we don't need
to set (or complain about) limit_proxy_state

19 months agoget rid of bio_result_t
Alan T. DeKok [Thu, 26 Dec 2024 12:07:44 +0000 (07:07 -0500)] 
get rid of bio_result_t

now that we have them unified, they don't need to be two different
data structures and variables.  We can just always use one.

19 months agorename functions for clarity
Alan T. DeKok [Wed, 25 Dec 2024 22:25:08 +0000 (17:25 -0500)] 
rename functions for clarity

we're sending initial negotiation packets, so let's not name the
functions "status_check".  This makes it clearer that later "ping"
packets are different from the initial negotiation / setup

19 months agounify bio_result_t and bio_request_t
Alan T. DeKok [Wed, 25 Dec 2024 22:08:18 +0000 (17:08 -0500)] 
unify bio_result_t and bio_request_t

they have the same lifetime, so there is no need for them to be
separate data structures.

19 months agowe don't need to include <talloc.h>
Alan T. DeKok [Wed, 25 Dec 2024 15:04:20 +0000 (10:04 -0500)] 
we don't need to include <talloc.h>

19 months agoremove last bits of rlm_radius_udp
Alan T. DeKok [Tue, 24 Dec 2024 13:27:11 +0000 (08:27 -0500)] 
remove last bits of rlm_radius_udp

19 months agoonly complain if the user sets "interface = foo"
Alan T. DeKok [Tue, 24 Dec 2024 12:42:01 +0000 (07:42 -0500)] 
only complain if the user sets "interface = foo"

19 months agominor tweaks and clarifications
Alan T. DeKok [Tue, 24 Dec 2024 12:39:09 +0000 (07:39 -0500)] 
minor tweaks and clarifications

OSX has IP_BOUND_IF.

*BSD has IP_RECVIF, but no IP_SENDIF.  And IP_RECVIF is a socket
option which is set, and then causes any _subsequent_ recvmsg()
call to have another cmsg structure added, with the sockaddr_dl
containing the interface.  The application is then responsible
for comparing the interface IDs, and discarding packets which
don't match.

19 months agoAnother cbor negative limit fix
Nick Porter [Tue, 24 Dec 2024 10:31:15 +0000 (10:31 +0000)] 
Another cbor negative limit fix

19 months agoThe new radius module doesn't create rlm_radius_udp.so
Nick Porter [Tue, 24 Dec 2024 09:14:58 +0000 (09:14 +0000)] 
The new radius module doesn't create rlm_radius_udp.so

19 months agoenable the new radius module
Alan T. DeKok [Mon, 23 Dec 2024 14:32:11 +0000 (09:32 -0500)] 
enable the new radius module

19 months agominor tweaks
Alan T. DeKok [Mon, 23 Dec 2024 12:40:54 +0000 (07:40 -0500)] 
minor tweaks

19 months agouse unconnected-proxy and unconnected-replicate
Alan T. DeKok [Sun, 22 Dec 2024 14:12:33 +0000 (09:12 -0500)] 
use unconnected-proxy and unconnected-replicate

19 months agoactually set SO_RCVBUF to zero
Alan T. DeKok [Fri, 20 Dec 2024 23:08:35 +0000 (18:08 -0500)] 
actually set SO_RCVBUF to zero

19 months agoCorrect limit on negative cbor decode
Nick Porter [Mon, 23 Dec 2024 12:35:22 +0000 (12:35 +0000)] 
Correct limit on negative cbor decode

19 months agoBetter Coverity hint (CID #1619299)
Nick Porter [Mon, 23 Dec 2024 09:43:46 +0000 (09:43 +0000)] 
Better Coverity hint (CID #1619299)

In normal use, fr_nbo_from_uint64v will return 1 to 8 - telling Coverity
it can return 0 then leads to another false positive.

19 months agoPacify Coverity (CID #1634622)
Nick Porter [Mon, 23 Dec 2024 08:50:08 +0000 (08:50 +0000)] 
Pacify Coverity (CID #1634622)

Coverity doesn't see that buffer is being used as an output for
fr_pair_print, so complains about uninitialised use.

19 months agoMove pointer check before first use (CID #1635782)
Nick Porter [Mon, 23 Dec 2024 08:34:38 +0000 (08:34 +0000)] 
Move pointer check before first use (CID #1635782)

19 months agoCheck return of fr_pair_list_copy (CID #1636884)
Nick Porter [Sun, 22 Dec 2024 20:27:31 +0000 (20:27 +0000)] 
Check return of fr_pair_list_copy (CID #1636884)

19 months agoUse an attribute to record the type of TLS session resumption used
Nick Porter [Tue, 10 Dec 2024 17:29:39 +0000 (17:29 +0000)] 
Use an attribute to record the type of TLS session resumption used

19 months agoAdd placeholder establish session section
Nick Porter [Tue, 10 Dec 2024 12:04:34 +0000 (12:04 +0000)] 
Add placeholder establish session section

19 months agoAdd an optional "establish session" session
Nick Porter [Tue, 10 Dec 2024 11:55:52 +0000 (11:55 +0000)] 
Add an optional "establish session" session

Called after a TLS session is established, primarily intended for
logging.

19 months agoDon't duplicate TLS session info attributes
Nick Porter [Tue, 10 Dec 2024 11:41:06 +0000 (11:41 +0000)] 
Don't duplicate TLS session info attributes

They may already exist if the session is being resumed.

19 months agoAdd sample "new session" section
Nick Porter [Mon, 2 Dec 2024 13:25:45 +0000 (13:25 +0000)] 
Add sample "new session" section

19 months agoUse control attributes to set TLS min/max version
Nick Porter [Mon, 2 Dec 2024 13:24:00 +0000 (13:24 +0000)] 
Use control attributes to set TLS min/max version

19 months agoDefine attributes for setting TLS min/max versions
Nick Porter [Mon, 2 Dec 2024 12:07:59 +0000 (12:07 +0000)] 
Define attributes for setting TLS min/max versions

19 months agoIf a "new session" section exists run that before creating TLS session
Nick Porter [Mon, 2 Dec 2024 12:07:13 +0000 (12:07 +0000)] 
If a "new session" section exists run that before creating TLS session

19 months agoDetect if "new session" section exists
Nick Porter [Wed, 11 Dec 2024 12:30:13 +0000 (12:30 +0000)] 
Detect if "new session" section exists

19 months agoAdd fr_tls_new_session_push
Nick Porter [Wed, 11 Dec 2024 12:15:05 +0000 (12:15 +0000)] 
Add fr_tls_new_session_push

To run a subrequest though "new session"

19 months agoAdd "new session" to TLS process sections
Nick Porter [Mon, 2 Dec 2024 11:28:50 +0000 (11:28 +0000)] 
Add "new session" to TLS process sections

19 months agoset SO_RCVBUF to zero for unconnected sockets, too
Alan T. DeKok [Fri, 20 Dec 2024 22:10:09 +0000 (17:10 -0500)] 
set SO_RCVBUF to zero for unconnected sockets, too

but only when the socket is being marked read-only

19 months agoadd "mode = unconnected" and xlat function for replication
Alan T. DeKok [Fri, 20 Dec 2024 22:06:19 +0000 (17:06 -0500)] 
add "mode = unconnected" and xlat function for replication

%replicate.sendto.ipaddr(ip, port, secret)

19 months agomake it clear that Message-Authenticator is auto-added
Alan T. DeKok [Fri, 20 Dec 2024 22:05:28 +0000 (17:05 -0500)] 
make it clear that Message-Authenticator is auto-added

manual port of 04b4c655fd

19 months agoAdd Blast RADIUS checks to radclient.
Alan T. DeKok [Fri, 20 Dec 2024 21:41:26 +0000 (16:41 -0500)] 
Add Blast RADIUS checks to radclient.

Manual port of 47eb7ee365abc66a

19 months agodon't print out results if there are no results
Alan T. DeKok [Fri, 20 Dec 2024 15:55:39 +0000 (10:55 -0500)] 
don't print out results if there are no results

19 months agoset src_port if it's zero, too
Alan T. DeKok [Fri, 20 Dec 2024 15:41:03 +0000 (10:41 -0500)] 
set src_port if it's zero, too

19 months agoget cmsg after setting controllen
Alan T. DeKok [Fri, 20 Dec 2024 15:20:17 +0000 (10:20 -0500)] 
get cmsg after setting controllen

19 months agomake decode_fail_t radius specific.
Alan T. DeKok [Wed, 18 Dec 2024 16:03:39 +0000 (17:03 +0100)] 
make decode_fail_t radius specific.

nothing else needs it, and it's full of RADIUS things

19 months agoadd verify callback for stream sockets.
Alan T. DeKok [Wed, 18 Dec 2024 15:50:41 +0000 (16:50 +0100)] 
add verify callback for stream sockets.

so we only return complete packets to the reader

19 months agoadd memory BIO for stream sockets
Alan T. DeKok [Wed, 18 Dec 2024 15:20:43 +0000 (16:20 +0100)] 
add memory BIO for stream sockets

so that the BIOs are sending only complete packets to the module

19 months agomore sanity checks for unconnected sockets
Alan T. DeKok [Wed, 18 Dec 2024 14:20:05 +0000 (15:20 +0100)] 
more sanity checks for unconnected sockets

19 months agoadd configuration for unconnected sockets
Alan T. DeKok [Wed, 18 Dec 2024 14:17:44 +0000 (15:17 +0100)] 
add configuration for unconnected sockets

19 months agoremove old "use_authenticator" flag
Alan T. DeKok [Wed, 18 Dec 2024 06:46:24 +0000 (07:46 +0100)] 
remove old "use_authenticator" flag

we no longer use the Request Authenticator as a unique ID

19 months agoReturn CACHE_RECONNECT if memcached returned a fatal result code
Nick Porter [Wed, 18 Dec 2024 15:59:23 +0000 (15:59 +0000)] 
Return CACHE_RECONNECT if memcached returned a fatal result code

19 months agoAdd memcached to CI tests
Nick Porter [Wed, 18 Dec 2024 13:48:03 +0000 (13:48 +0000)] 
Add memcached to CI tests

19 months agoAdd tests for memcached cache driver
Nick Porter [Wed, 18 Dec 2024 13:45:56 +0000 (13:45 +0000)] 
Add tests for memcached cache driver

19 months agoExpected output is data, not unresolved data
Nick Porter [Wed, 18 Dec 2024 11:46:04 +0000 (11:46 +0000)] 
Expected output is data, not unresolved data

19 months agoInitialise map list
Nick Porter [Wed, 18 Dec 2024 11:45:34 +0000 (11:45 +0000)] 
Initialise map list

19 months agoRun-time tmpls need an event list
Nick Porter [Wed, 18 Dec 2024 11:45:22 +0000 (11:45 +0000)] 
Run-time tmpls need an event list

19 months agoUse fr_asprintf to access custom format specifiers
Nick Porter [Wed, 18 Dec 2024 11:43:53 +0000 (11:43 +0000)] 
Use fr_asprintf to access custom format specifiers

19 months agoNo need to populate buffer with driver name
Nick Porter [Tue, 17 Dec 2024 21:28:10 +0000 (21:28 +0000)] 
No need to populate buffer with driver name

Was being used in pool initialisation, now buffer is just for error
messages.

19 months agoNo need to initialise buffer which is about to be printed to
Nick Porter [Tue, 17 Dec 2024 21:21:57 +0000 (21:21 +0000)] 
No need to initialise buffer which is about to be printed to

19 months agoDriver config is auto parsed when module is loaded
Nick Porter [Tue, 17 Dec 2024 21:21:11 +0000 (21:21 +0000)] 
Driver config is auto parsed when module is loaded

19 months agoBetter comments
Nick Porter [Tue, 17 Dec 2024 17:21:42 +0000 (17:21 +0000)] 
Better comments

19 months agoCorrect reference to cache config
Nick Porter [Tue, 17 Dec 2024 17:20:48 +0000 (17:20 +0000)] 
Correct reference to cache config

19 months agoConvert rlm_cache memcached driver to use slab allocator
Nick Porter [Tue, 17 Dec 2024 14:04:35 +0000 (14:04 +0000)] 
Convert rlm_cache memcached driver to use slab allocator

19 months agoWS
Nick Porter [Tue, 17 Dec 2024 14:00:05 +0000 (14:00 +0000)] 
WS

19 months agofix: Return -1 on error instead of 1 (01) - typo.
ethan-thompson [Tue, 17 Dec 2024 19:33:02 +0000 (14:33 -0500)] 
fix: Return -1 on error instead of 1 (01) - typo.

Signed-off-by: ethan-thompson <ethan.thompson@networkradius.com>
19 months agofix: When using a dictionary that first defines a protocol with "PROTOCOL" the dctx...
ethan-thompson [Tue, 17 Dec 2024 18:37:06 +0000 (13:37 -0500)] 
fix: When using a dictionary that first defines a protocol with "PROTOCOL" the dctx stack da is updated, but not the filename, causing it to be lost as the stack grows, since all future items on the stack inherit the filename. Fixed by also setting the filename when updating the da.

Signed-off-by: ethan-thompson <ethan.thompson@networkradius.com>
19 months agoadd INVALID type, and auto-set from configuration
Alan T. DeKok [Mon, 16 Dec 2024 08:23:04 +0000 (09:23 +0100)] 
add INVALID type, and auto-set from configuration

19 months agoupdate docs
Alan T. DeKok [Mon, 16 Dec 2024 08:22:44 +0000 (09:22 +0100)] 
update docs

19 months agoallow module to retransmit even if set to proxy mode
Alan T. DeKok [Sun, 15 Dec 2024 17:10:03 +0000 (18:10 +0100)] 
allow module to retransmit even if set to proxy mode

for packets which change protocols, OR change packet code, OR
are read from the detail file.

19 months agouse "mode" instead of replicate / synchronous / originate
Alan T. DeKok [Sun, 15 Dec 2024 16:43:03 +0000 (17:43 +0100)] 
use "mode" instead of replicate / synchronous / originate

as it is more descriptive.  The other configuration flags also
can be configured in contradictory or conflicting ways.

Perhaps we could add a non-synchronous proxy, but that is likely
a good idea only if there's no Proxy-State in the packet.
i.e. we received the packet from a NAS, which has it's own retransmission
timers, and those timers are almost always garbage.

19 months agoadd optional CONF_SECTION parsers, and use in rlm_radius
Alan T. DeKok [Sat, 14 Dec 2024 16:54:44 +0000 (17:54 +0100)] 
add optional CONF_SECTION parsers, and use in rlm_radius

this lets the RADIUS module put more things into a "udp" section,
but only if the "udp" section ends up being used by the transport
configuration.

The RADIUS module can also push rules for "tcp", but those rules
don't show up in the debug output (and are ignored by the parser)
if a corresponding "tcp" section is defined

19 months agoIPv6 addresses should have a 128 prefix, too
Alan T. DeKok [Fri, 13 Dec 2024 15:17:53 +0000 (10:17 -0500)] 
IPv6 addresses should have a 128 prefix, too

19 months agoFreeRADIUS IPv4 addresses must have prefix len 32
Nick Porter [Fri, 13 Dec 2024 14:06:21 +0000 (14:06 +0000)] 
FreeRADIUS IPv4 addresses must have prefix len 32

19 months agoMake request subsection required
Nick Porter [Fri, 13 Dec 2024 11:49:26 +0000 (11:49 +0000)] 
Make request subsection required

Without this, the check for mandatory URI doesn't happen.

19 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/cbor.tar
github-actions[bot] [Fri, 13 Dec 2024 04:16:59 +0000 (04:16 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/cbor.tar