]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
6 years agorlm_radius_udp: Move common decode logic into its own function in preparation for...
Arran Cudbard-Bell [Tue, 3 Mar 2020 00:30:10 +0000 (18:30 -0600)] 
rlm_radius_udp: Move common decode logic into its own function in preparation for adding connection based status checks

6 years agorlm_radius_udp: Move allowed replies array
Arran Cudbard-Bell [Tue, 3 Mar 2020 00:28:51 +0000 (18:28 -0600)] 
rlm_radius_udp: Move allowed replies array

6 years agorlm_radius_udp: Produce log messages on write errors
Arran Cudbard-Bell [Tue, 3 Mar 2020 00:28:24 +0000 (18:28 -0600)] 
rlm_radius_udp: Produce log messages on write errors

Ooops, don't know how these were removed

6 years agoradius: More decode error codes
Arran Cudbard-Bell [Tue, 3 Mar 2020 00:26:19 +0000 (18:26 -0600)] 
radius: More decode error codes

6 years agorlm_radius_udp: Move conn_init
Arran Cudbard-Bell [Mon, 2 Mar 2020 21:19:29 +0000 (15:19 -0600)] 
rlm_radius_udp: Move conn_init

6 years agotrunk: Add last_read_success
Arran Cudbard-Bell [Mon, 2 Mar 2020 21:14:10 +0000 (15:14 -0600)] 
trunk: Add last_read_success

6 years agotrunk: Unused field
Arran Cudbard-Bell [Mon, 2 Mar 2020 15:26:53 +0000 (09:26 -0600)] 
trunk: Unused field

6 years agotrunk: Formatting
Arran Cudbard-Bell [Mon, 2 Mar 2020 15:23:20 +0000 (09:23 -0600)] 
trunk: Formatting

6 years agotrunk: Split FULL and INACTIVE states
Arran Cudbard-Bell [Mon, 2 Mar 2020 15:18:33 +0000 (09:18 -0600)] 
trunk: Split FULL and INACTIVE states

6 years agotrunk: Add back previous functionality to allow requests to be assigned to the backlo...
Arran Cudbard-Bell [Mon, 2 Mar 2020 15:17:17 +0000 (09:17 -0600)] 
trunk: Add back previous functionality to allow requests to be assigned to the backlog if the last event was a connection failure

6 years agotrunk: Prevent assert when req_cleanup_delay == 0
Arran Cudbard-Bell [Mon, 2 Mar 2020 15:05:32 +0000 (09:05 -0600)] 
trunk: Prevent assert when req_cleanup_delay == 0

6 years agorlm_radius: Test plan zombie state
Arran Cudbard-Bell [Mon, 2 Mar 2020 14:28:33 +0000 (08:28 -0600)] 
rlm_radius: Test plan zombie state

6 years agorlm_radius: Start of test plan for rlm_radius (incomplete)
Arran Cudbard-Bell [Mon, 2 Mar 2020 00:52:11 +0000 (18:52 -0600)] 
rlm_radius: Start of test plan for rlm_radius (incomplete)

6 years agorlm_radius_udp: Update comments
Arran Cudbard-Bell [Sun, 1 Mar 2020 20:08:42 +0000 (14:08 -0600)] 
rlm_radius_udp: Update comments

6 years agorlm_radius: status_check singular not plural
Arran Cudbard-Bell [Sun, 1 Mar 2020 19:44:01 +0000 (13:44 -0600)] 
rlm_radius: status_check singular not plural

6 years agorlm_radius_udp: Handle more error codes on failed write
Arran Cudbard-Bell [Sun, 1 Mar 2020 19:42:59 +0000 (13:42 -0600)] 
rlm_radius_udp: Handle more error codes on failed write

6 years agorlm_radius: Fix sanity check order
Arran Cudbard-Bell [Sun, 1 Mar 2020 15:22:25 +0000 (09:22 -0600)] 
rlm_radius: Fix sanity check order

6 years agorlm_chap: Add tests for rlm_chap
Arran Cudbard-Bell [Sat, 29 Feb 2020 21:44:25 +0000 (15:44 -0600)] 
rlm_chap: Add tests for rlm_chap

6 years agorlm_chap: Remove duplicate message detailing the password source
Arran Cudbard-Bell [Sat, 29 Feb 2020 21:43:23 +0000 (15:43 -0600)] 
rlm_chap: Remove duplicate message detailing the password source

6 years agoAdd %{chap_password:} for producing values for CHAP-Password
Arran Cudbard-Bell [Sat, 29 Feb 2020 21:00:25 +0000 (15:00 -0600)] 
Add %{chap_password:} for producing values for CHAP-Password

This is mostly for testing rlm_radius

6 years agoradius: Simplify fr_radius_encode_chap_password and have it accept an input buffer...
Arran Cudbard-Bell [Sat, 29 Feb 2020 20:59:42 +0000 (14:59 -0600)] 
radius: Simplify fr_radius_encode_chap_password and have it accept an input buffer for the password instead of the VP

6 years agoglobal: Use assert not error in MEM()
Arran Cudbard-Bell [Sat, 29 Feb 2020 20:58:21 +0000 (14:58 -0600)] 
global: Use assert not error in MEM()

Means we don't have to provide argumets used by FR_LOG_PREFIX whenever MEM() is used

6 years agothere's no User-Name in a fake packet we just created
Alan T. DeKok [Sat, 29 Feb 2020 15:29:40 +0000 (10:29 -0500)] 
there's no User-Name in a fake packet we just created

6 years agoadd API / wrapper fro fr_pair_group_...() functions
Alan T. DeKok [Sat, 29 Feb 2020 15:24:24 +0000 (10:24 -0500)] 
add API / wrapper fro fr_pair_group_...() functions

so that we can do bulk conversions of the callers *without*
breaking anything.

i.e. convert the callers to use the new API, which (for now)
is just a macro wrapper around the old API.  Then, once the callers
use the new API format, we can delete the macros, and actually use
the real new API functionality.

6 years agofix use of fake / request to be consistent
Alan T. DeKok [Sat, 29 Feb 2020 15:07:51 +0000 (10:07 -0500)] 
fix use of fake / request to be consistent

6 years agouse vp_group for groups
Alan T. DeKok [Fri, 28 Feb 2020 17:49:44 +0000 (12:49 -0500)] 
use vp_group for groups

6 years agouse vp_group for group access
Alan T. DeKok [Fri, 28 Feb 2020 17:48:16 +0000 (12:48 -0500)] 
use vp_group for group access

6 years agoremove unnecessary whitespace
Alan T. DeKok [Fri, 28 Feb 2020 16:07:34 +0000 (11:07 -0500)] 
remove unnecessary whitespace

6 years agoMerge pull request #3298 from jirutka/cui-pgsql
Matthew Newton [Fri, 28 Feb 2020 14:51:55 +0000 (14:51 +0000)] 
Merge pull request #3298 from jirutka/cui-pgsql

Fix and improve cui/postgresql

6 years agospecify name for pkey constraint and use it in query for cui postgresql 3298/head
Jakub Jirutka [Thu, 20 Feb 2020 11:12:09 +0000 (12:12 +0100)] 
specify name for pkey constraint and use it in query for cui postgresql

6 years agouse real upsert (ON CONFLICT) instead of workaround in postgresql cui
Jakub Jirutka [Thu, 20 Feb 2020 00:30:04 +0000 (01:30 +0100)] 
use real upsert (ON CONFLICT) instead of workaround in postgresql cui

Clause ON CONFLICT performs better than the RULE workaround and it's
guaranted to be atomic (the workaround is not).

It requires PostgreSQL 9.5 or newer; this version was released in 2016
and the previous versions are already unsupported, so it shouldn't be
a problem for anyone using latest FreeRADIUS versions.

There's a problem with backward compatibility because ON CONFLICT
doesn't work when there's a RULE ON INSERT defined on the table. It
results in the following error in radius.log:

    Error: rlm_sql_postgresql: 0A000: FEATURE NOT SUPPORTED

6 years agofix postgresql schema for cui
Jakub Jirutka [Thu, 20 Feb 2020 00:12:18 +0000 (01:12 +0100)] 
fix postgresql schema for cui

I'm getting the following error with the current schema:

    rlm_sql_postgresql: 22001: STRING DATA RIGHT TRUNCATION

Moreover, in PostgreSQL the text type is highly preferred above
varchar. Schema for radacct already uses it, so it seems that schema
for cui is just outdated.

I also remove quotes around `now()`, it was probably some archaism.

6 years agofix formatting in cui postgresql schema to be consistent
Jakub Jirutka [Thu, 20 Feb 2020 09:30:50 +0000 (10:30 +0100)] 
fix formatting in cui postgresql schema to be consistent

6 years agouse usec since current second, not usec since epoch
Alan T. DeKok [Fri, 28 Feb 2020 13:10:33 +0000 (08:10 -0500)] 
use usec since current second, not usec since epoch

6 years agofix crash when no previous regex seen
Matthew Newton [Thu, 27 Feb 2020 13:54:59 +0000 (13:54 +0000)] 
fix crash when no previous regex seen

6 years agodoxygen
Matthew Newton [Thu, 27 Feb 2020 13:54:46 +0000 (13:54 +0000)] 
doxygen

6 years agoRemove vp_cursor_t from rlm_radius_udp.c
Arran Cudbard-Bell [Thu, 27 Feb 2020 22:12:39 +0000 (16:12 -0600)] 
Remove vp_cursor_t from rlm_radius_udp.c

6 years agos/pair_cursor/fr_cursor/ in rlm_isc_dhcp.c
Arran Cudbard-Bell [Thu, 27 Feb 2020 22:10:29 +0000 (16:10 -0600)] 
s/pair_cursor/fr_cursor/ in rlm_isc_dhcp.c

6 years agoMore reasonable default
Arran Cudbard-Bell [Thu, 27 Feb 2020 22:06:18 +0000 (16:06 -0600)] 
More reasonable default

6 years agoAdd more log prefixes. Switch some statements to debug/info.
Arran Cudbard-Bell [Thu, 27 Feb 2020 20:42:03 +0000 (14:42 -0600)] 
Add more log prefixes.  Switch some statements to debug/info.

We really do want to see rechability messages in the main server log.

6 years agoTypo
Arran Cudbard-Bell [Thu, 27 Feb 2020 20:25:22 +0000 (14:25 -0600)] 
Typo

6 years agoRemove duplicate track delete call
Arran Cudbard-Bell [Thu, 27 Feb 2020 20:25:15 +0000 (14:25 -0600)] 
Remove duplicate track delete call

6 years agoAssert treq is still assigned to a connection on timeout
Arran Cudbard-Bell [Thu, 27 Feb 2020 20:23:04 +0000 (14:23 -0600)] 
Assert treq is still assigned to a connection on timeout

6 years agoPass in tconn to status_check_next
Arran Cudbard-Bell [Thu, 27 Feb 2020 20:11:24 +0000 (14:11 -0600)] 
Pass in tconn to status_check_next

The timer is now parented of h, so this should all be ok...

6 years agoSignalling request is complete frees everything parented by treq, so probably want...
Arran Cudbard-Bell [Thu, 27 Feb 2020 19:48:30 +0000 (13:48 -0600)] 
Signalling request is complete frees everything parented by treq, so probably want to do it after we're done messing around with it

6 years agoRemove udp_connection_t;
Arran Cudbard-Bell [Thu, 27 Feb 2020 19:36:28 +0000 (13:36 -0600)] 
Remove udp_connection_t;

6 years agouse more standard names "packet" and "reply"
Alan T. DeKok [Thu, 27 Feb 2020 18:43:00 +0000 (13:43 -0500)] 
use more standard names "packet" and "reply"

6 years agouse more standard name "packet"
Alan T. DeKok [Thu, 27 Feb 2020 16:55:58 +0000 (11:55 -0500)] 
use more standard name "packet"

6 years agouse more standard name "packet" and "reply"
Alan T. DeKok [Thu, 27 Feb 2020 16:46:42 +0000 (11:46 -0500)] 
use more standard name "packet" and "reply"

in preparation for moving to type "group" for lists.

6 years agouse more standard name "packet"
Alan T. DeKok [Thu, 27 Feb 2020 16:46:19 +0000 (11:46 -0500)] 
use more standard name "packet"

in preparation for moving to type "group" for lists.

6 years agouse more standard name "packet" instead of "current"
Alan T. DeKok [Thu, 27 Feb 2020 16:45:18 +0000 (11:45 -0500)] 
use more standard name "packet" instead of "current"

in preparation for moving to type "group" for lists.

6 years agofix crash on invalid attribute
Matthew Newton [Thu, 27 Feb 2020 12:38:50 +0000 (12:38 +0000)] 
fix crash on invalid attribute

6 years agouse path count
Alan T. DeKok [Wed, 26 Feb 2020 21:26:25 +0000 (16:26 -0500)] 
use path count

6 years agoremove "set fd handlers" hack now that status checks are in the trunk
Alan T. DeKok [Wed, 26 Feb 2020 21:24:36 +0000 (16:24 -0500)] 
remove "set fd handlers" hack now that status checks are in the trunk

6 years agoPast tense as it's after sendmmsg
Arran Cudbard-Bell [Wed, 26 Feb 2020 21:31:31 +0000 (16:31 -0500)] 
Past tense as it's after sendmmsg

6 years agoNot needed, already NULL
Arran Cudbard-Bell [Wed, 26 Feb 2020 21:21:42 +0000 (16:21 -0500)] 
Not needed, already NULL

6 years agoUse sendmmsg in rlm_radius_udp.c
Arran Cudbard-Bell [Wed, 26 Feb 2020 20:52:37 +0000 (15:52 -0500)] 
Use sendmmsg in rlm_radius_udp.c

6 years agoFail requests which can't be requeued
Arran Cudbard-Bell [Wed, 26 Feb 2020 20:52:21 +0000 (15:52 -0500)] 
Fail requests which can't be requeued

6 years agoadd support for glob. Fixes #1018
Alan T. DeKok [Wed, 26 Feb 2020 19:51:13 +0000 (14:51 -0500)] 
add support for glob.  Fixes #1018

This needs documentation added, too.

6 years agomove FAILED to timeout function
Alan T. DeKok [Wed, 26 Feb 2020 18:18:05 +0000 (13:18 -0500)] 
move FAILED to timeout function

6 years agodoxygen (xlat functions)
Matthew Newton [Wed, 26 Feb 2020 16:12:43 +0000 (16:12 +0000)] 
doxygen (xlat functions)

6 years agomove status checks to using the trunk API
Alan T. DeKok [Wed, 26 Feb 2020 16:21:50 +0000 (11:21 -0500)] 
move status checks to using the trunk API

6 years agoprioritize status checks
Alan T. DeKok [Tue, 25 Feb 2020 14:19:55 +0000 (09:19 -0500)] 
prioritize status checks

in preparation for making them part of the trunk

6 years agoFunction names and param order
Matthew Newton [Wed, 26 Feb 2020 01:48:03 +0000 (01:48 +0000)] 
Function names and param order

6 years agoxlat doxygen
Matthew Newton [Wed, 26 Feb 2020 01:38:55 +0000 (01:38 +0000)] 
xlat doxygen

6 years agoRe-order xlat_builtin functions, whitespace
Matthew Newton [Sun, 23 Feb 2020 23:16:54 +0000 (23:16 +0000)] 
Re-order xlat_builtin functions, whitespace

6 years agoRemove invalid assert
Arran Cudbard-Bell [Tue, 25 Feb 2020 22:25:31 +0000 (17:25 -0500)] 
Remove invalid assert

6 years agoMove closefrom into missing
Arran Cudbard-Bell [Tue, 25 Feb 2020 22:03:31 +0000 (17:03 -0500)] 
Move closefrom into missing

6 years agoAdd crappy userland sendmmsg implementation
Arran Cudbard-Bell [Tue, 25 Feb 2020 22:03:15 +0000 (17:03 -0500)] 
Add crappy userland sendmmsg implementation

6 years agoExplicitly free rctx on cancel
Arran Cudbard-Bell [Tue, 25 Feb 2020 04:39:29 +0000 (23:39 -0500)] 
Explicitly free rctx on cancel

6 years agoRe-order more functions, and explicitly clean up more things
Arran Cudbard-Bell [Tue, 25 Feb 2020 04:34:48 +0000 (23:34 -0500)] 
Re-order more functions, and explicitly clean up more things

6 years agoRe-order functions
Arran Cudbard-Bell [Tue, 25 Feb 2020 03:27:23 +0000 (22:27 -0500)] 
Re-order functions

6 years agoAllow laziness on the part of the API client, and free any treq children
Arran Cudbard-Bell [Tue, 25 Feb 2020 03:27:15 +0000 (22:27 -0500)] 
Allow laziness on the part of the API client, and free any treq children

6 years agoset treq
Arran Cudbard-Bell [Tue, 25 Feb 2020 02:59:18 +0000 (21:59 -0500)] 
set treq

6 years agoAlways populate preq and rctx
Arran Cudbard-Bell [Tue, 25 Feb 2020 02:52:56 +0000 (21:52 -0500)] 
Always populate preq and rctx

6 years agoMore asserts
Arran Cudbard-Bell [Tue, 25 Feb 2020 02:41:34 +0000 (21:41 -0500)] 
More asserts

6 years agoReturn the treq to the free list
Arran Cudbard-Bell [Tue, 25 Feb 2020 02:37:06 +0000 (21:37 -0500)] 
Return the treq to the free list

6 years agoSimplify populating treq_out
Arran Cudbard-Bell [Tue, 25 Feb 2020 02:30:11 +0000 (21:30 -0500)] 
Simplify populating treq_out

6 years agoHandle isn't available if the connection failed from the init state
Arran Cudbard-Bell [Tue, 25 Feb 2020 01:52:42 +0000 (20:52 -0500)] 
Handle isn't available if the connection failed from the init state

6 years agoAssert that the treq is a member of a trunk
Arran Cudbard-Bell [Tue, 25 Feb 2020 00:17:01 +0000 (19:17 -0500)] 
Assert that the treq is a member of a trunk

6 years agoAlways delete the request timeout
Arran Cudbard-Bell [Mon, 24 Feb 2020 23:40:52 +0000 (18:40 -0500)] 
Always delete the request timeout

6 years agoMore agressive defaults
Arran Cudbard-Bell [Mon, 24 Feb 2020 23:34:43 +0000 (18:34 -0500)] 
More agressive defaults

6 years agoCleanup failed requests...
Arran Cudbard-Bell [Mon, 24 Feb 2020 23:22:55 +0000 (18:22 -0500)] 
Cleanup failed requests...

6 years agoFix whitespace issues
Arran Cudbard-Bell [Mon, 24 Feb 2020 23:00:44 +0000 (18:00 -0500)] 
Fix whitespace issues

6 years agoNot an assert, a useful hint...
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:59:06 +0000 (17:59 -0500)] 
Not an assert, a useful hint...

6 years agoFix assert
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:56:22 +0000 (17:56 -0500)] 
Fix assert

6 years agoOnly apply last_above_target delay if we have at least one active connection
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:56:13 +0000 (17:56 -0500)] 
Only apply last_above_target delay if we have at least one active connection

6 years agoRecord reconnections (not due to expiry) as failures too
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:55:20 +0000 (17:55 -0500)] 
Record reconnections (not due to expiry) as failures too

6 years agoquotes around names...
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:17:40 +0000 (17:17 -0500)] 
quotes around names...

6 years agoOnly start the response timer if we manage to write out a packet
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:11:24 +0000 (17:11 -0500)] 
Only start the response timer if we manage to write out a packet

6 years agoAgressively reconnect connections on write errors
Arran Cudbard-Bell [Mon, 24 Feb 2020 22:02:43 +0000 (17:02 -0500)] 
Agressively reconnect connections on write errors

6 years agoRemove icky O(n) udata hack
Arran Cudbard-Bell [Mon, 24 Feb 2020 21:39:50 +0000 (16:39 -0500)] 
Remove icky O(n) udata hack

6 years agoUse 'noop' callback for unset function pointers. Fixes SEGV when filters are swapped...
Arran Cudbard-Bell [Mon, 24 Feb 2020 21:36:40 +0000 (16:36 -0500)] 
Use 'noop' callback for unset function pointers.  Fixes SEGV when filters are swapped out between corral and service.

6 years agoMinor cleanup in event.c
Arran Cudbard-Bell [Mon, 24 Feb 2020 21:01:57 +0000 (16:01 -0500)] 
Minor cleanup in event.c

6 years agoclean up status checks
Alan T. DeKok [Mon, 24 Feb 2020 21:31:46 +0000 (16:31 -0500)] 
clean up status checks

6 years agoset 'verify=lib' in test dictionary for RADIUS
Alan T. DeKok [Mon, 24 Feb 2020 21:10:00 +0000 (16:10 -0500)] 
set 'verify=lib' in test dictionary for RADIUS

and change check order for loading protocol libraries.
Try to load them, even if they're not required.  And error out
only if they fail to load AND they're required.

This change makes it a bit more forgiving.

6 years agofree module_name on error
Alan T. DeKok [Mon, 24 Feb 2020 21:09:36 +0000 (16:09 -0500)] 
free module_name on error

6 years agoreplicate now takes a different path
Alan T. DeKok [Mon, 24 Feb 2020 15:54:53 +0000 (10:54 -0500)] 
replicate now takes a different path

6 years agoAlways set te->tt
Arran Cudbard-Bell [Mon, 24 Feb 2020 19:25:59 +0000 (14:25 -0500)] 
Always set te->tt

6 years agoNot reading from the socket is an error...
Arran Cudbard-Bell [Mon, 24 Feb 2020 19:25:45 +0000 (14:25 -0500)] 
Not reading from the socket is an error...