]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
6 years agoRPM spec dependencies for RHEL8 (#3384)
Terry Burton [Fri, 17 Apr 2020 18:19:18 +0000 (19:19 +0100)] 
RPM spec dependencies for RHEL8 (#3384)

Co-authored-by: Matthew Newton <matthew-git@newtoncomputing.co.uk>
6 years agotrunk: Use lookup table for trigger names
Arran Cudbard-Bell [Fri, 17 Apr 2020 17:20:25 +0000 (12:20 -0500)] 
trunk: Use lookup table for trigger names

6 years agomisc: Better docs for fr_high_bit_pos_uint64 and strip uint64_t.
Arran Cudbard-Bell [Fri, 17 Apr 2020 17:20:07 +0000 (12:20 -0500)] 
misc: Better docs for fr_high_bit_pos_uint64 and strip uint64_t.

We can just use the same function for all unsigned integers

6 years agotable: Add O(1) lookups for bitfield flag to string identifiers
Arran Cudbard-Bell [Fri, 17 Apr 2020 17:19:00 +0000 (12:19 -0500)] 
table: Add O(1) lookups for bitfield flag to string identifiers

6 years agoHowto for ODBC (#3381)
Terry Burton [Fri, 17 Apr 2020 16:43:29 +0000 (17:43 +0100)] 
Howto for ODBC (#3381)

* Howto for ODBC

6 years agodlist: reorder checks
Arran Cudbard-Bell [Fri, 17 Apr 2020 14:39:03 +0000 (09:39 -0500)] 
dlist: reorder checks

6 years agodlist: Try and prevent erroneous removals from a dlist
Arran Cudbard-Bell [Fri, 17 Apr 2020 14:10:27 +0000 (09:10 -0500)] 
dlist: Try and prevent erroneous removals from a dlist

6 years agotrunk: Fix bad INIT->INIT transition on init failure.
Arran Cudbard-Bell [Fri, 17 Apr 2020 02:56:23 +0000 (21:56 -0500)] 
trunk: Fix bad INIT->INIT transition on init failure.

6 years agosbuff: Simplify
Arran Cudbard-Bell [Fri, 17 Apr 2020 02:20:33 +0000 (21:20 -0500)] 
sbuff: Simplify

6 years agosbuff: Another copy function
Arran Cudbard-Bell [Fri, 17 Apr 2020 01:53:39 +0000 (20:53 -0500)] 
sbuff: Another copy function

Should be enough to be useful now...

6 years agotrigger: Fix wrong return (#3382)
Jorge Pereira [Fri, 17 Apr 2020 01:33:22 +0000 (22:33 -0300)] 
trigger: Fix wrong return (#3382)

6 years agotrunk: We can hit the trunk_request_check_enqueue limit or the alloc one depending...
Arran Cudbard-Bell [Thu, 16 Apr 2020 22:11:41 +0000 (17:11 -0500)] 
trunk: We can hit the trunk_request_check_enqueue limit or the alloc one depending on how the trunk is used

6 years agotrunk: Enforce max requests at alloc time
Arran Cudbard-Bell [Thu, 16 Apr 2020 21:56:27 +0000 (16:56 -0500)] 
trunk: Enforce max requests at alloc time

6 years agorlm_radius: Remove no_connection_fail
Arran Cudbard-Bell [Thu, 16 Apr 2020 21:55:46 +0000 (16:55 -0500)] 
rlm_radius: Remove no_connection_fail

This is already implemented by the trunk

6 years agotrunk: Update copyrights
Arran Cudbard-Bell [Thu, 16 Apr 2020 19:02:57 +0000 (14:02 -0500)] 
trunk: Update copyrights

6 years agotrunk: Add a hard limit on the number of state entries per request
Arran Cudbard-Bell [Thu, 16 Apr 2020 18:47:49 +0000 (13:47 -0500)] 
trunk: Add a hard limit on the number of state entries per request

6 years agosbuff: Quiet gcc
Arran Cudbard-Bell [Thu, 16 Apr 2020 16:29:03 +0000 (11:29 -0500)] 
sbuff: Quiet gcc

6 years agotrunk: Add asserts to ensure log entries are freed
Arran Cudbard-Bell [Thu, 16 Apr 2020 16:14:27 +0000 (11:14 -0500)] 
trunk: Add asserts to ensure log entries are freed

6 years agoassert: Add fr_assert_msg
Arran Cudbard-Bell [Thu, 16 Apr 2020 16:13:58 +0000 (11:13 -0500)] 
assert: Add fr_assert_msg

6 years agoring_buffer: Fix memory leak (#3378)
Jorge Pereira [Thu, 16 Apr 2020 14:48:18 +0000 (11:48 -0300)] 
ring_buffer: Fix memory leak (#3378)

6 years agowhoops, need this, too
Alan T. DeKok [Thu, 16 Apr 2020 14:43:55 +0000 (10:43 -0400)] 
whoops, need this, too

6 years agoadd triggers for the trunk code
Alan T. DeKok [Thu, 16 Apr 2020 14:23:53 +0000 (10:23 -0400)] 
add triggers for the trunk code

6 years agoFix memory leak in rlm_exec
Jorge Pereira [Wed, 15 Apr 2020 22:32:57 +0000 (19:32 -0300)] 
Fix memory leak in rlm_exec

6 years agoremove one more PRE
Alan T. DeKok [Wed, 15 Apr 2020 23:57:13 +0000 (19:57 -0400)] 
remove one more PRE

6 years agoAdd start of new tokenization API
Arran Cudbard-Bell [Wed, 15 Apr 2020 22:50:01 +0000 (17:50 -0500)] 
Add start of new tokenization API

6 years agoFix other stupidity...
Arran Cudbard-Bell [Wed, 15 Apr 2020 22:40:34 +0000 (17:40 -0500)] 
Fix other stupidity...

6 years agoTypo
Arran Cudbard-Bell [Wed, 15 Apr 2020 21:46:20 +0000 (16:46 -0500)] 
Typo

6 years agoadd provisions for running triggers
Alan T. DeKok [Wed, 15 Apr 2020 21:00:44 +0000 (17:00 -0400)] 
add provisions for running triggers

6 years agoprint: Fix fr_utf8_strchr to take a length
Arran Cudbard-Bell [Wed, 15 Apr 2020 21:43:31 +0000 (16:43 -0500)] 
print: Fix fr_utf8_strchr to take a length

6 years agoUse the token not the char
Arran Cudbard-Bell [Wed, 15 Apr 2020 19:50:04 +0000 (14:50 -0500)] 
Use the token not the char

6 years agonothing uses this.
Alan T. DeKok [Wed, 15 Apr 2020 19:45:39 +0000 (15:45 -0400)] 
nothing uses this.

all of the dynamic client code is handled in src/lib/io/master.c

6 years agoCan't have non-null for REQUEST *
Arran Cudbard-Bell [Wed, 15 Apr 2020 19:41:42 +0000 (14:41 -0500)] 
Can't have non-null for REQUEST *

6 years agorest: Use common functions for parsing TLS options
Arran Cudbard-Bell [Wed, 15 Apr 2020 19:31:29 +0000 (14:31 -0500)] 
rest: Use common functions for parsing TLS options

6 years agocurl: Minor fixes for common functions
Arran Cudbard-Bell [Wed, 15 Apr 2020 19:29:25 +0000 (14:29 -0500)] 
curl: Minor fixes for common functions

6 years agoreturn only for non-debug builds...
Arran Cudbard-Bell [Wed, 15 Apr 2020 19:25:30 +0000 (14:25 -0500)] 
return only for non-debug builds...

6 years agomake exec no-wait fully async
Alan T. DeKok [Wed, 15 Apr 2020 18:22:37 +0000 (14:22 -0400)] 
make exec no-wait fully async

6 years agofinalize async exec
Alan T. DeKok [Wed, 15 Apr 2020 18:06:29 +0000 (14:06 -0400)] 
finalize async exec

this is really just for tests, but it may be useful to have for now.
Once the whole module is async, this method should be deleted.

6 years agoshow that we're running the test
Alan T. DeKok [Wed, 15 Apr 2020 18:05:13 +0000 (14:05 -0400)] 
show that we're running the test

6 years agoremove things which are no longer rleevant
Alan T. DeKok [Wed, 15 Apr 2020 16:26:34 +0000 (12:26 -0400)] 
remove things which are no longer rleevant

6 years agorest: Move more calls to the libfreeradius-curl library
Arran Cudbard-Bell [Wed, 15 Apr 2020 19:10:06 +0000 (14:10 -0500)] 
rest: Move more calls to the libfreeradius-curl library

6 years agoFormatting
Arran Cudbard-Bell [Wed, 15 Apr 2020 18:59:16 +0000 (13:59 -0500)] 
Formatting

6 years agoradsniff: Remove pktap interfaces from the default interface list. Closes #3364
Arran Cudbard-Bell [Wed, 15 Apr 2020 18:59:07 +0000 (13:59 -0500)] 
radsniff: Remove pktap interfaces from the default interface list.  Closes #3364

6 years agoadd missing "return"
Alan T. DeKok [Wed, 15 Apr 2020 12:52:56 +0000 (08:52 -0400)] 
add missing "return"

to avoid messages being printed twice.

6 years agoAdded tls functionality to curl and a SET_OPTION macro (#3376)
Stephen Blackwell [Wed, 15 Apr 2020 01:36:30 +0000 (21:36 -0400)] 
Added tls functionality to curl and a SET_OPTION macro (#3376)

* Added fr_curl_easy_tls_init and fr_curl_response_certinfo to src/lib/curl/base.c and FR_CURL_SET_OPTION and fr_curl_tls_config to src/lib/curl/base.h

* Fix whitespace

Co-authored-by: Arran Cudbard-Bell <a.cudbardb@freeradius.org>
6 years agomore "fix stupid analyzer" changes
Alan T. DeKok [Wed, 15 Apr 2020 00:22:07 +0000 (20:22 -0400)] 
more "fix stupid analyzer" changes

6 years agoasserts for static analyzer
Alan T. DeKok [Wed, 15 Apr 2020 00:09:25 +0000 (20:09 -0400)] 
asserts for static analyzer

6 years agoglue triggers to workers at run time
Alan T. DeKok [Tue, 14 Apr 2020 23:40:08 +0000 (19:40 -0400)] 
glue triggers to workers at run time

and only if we have workers.  This is a bit of a hack for now,
until such time as we have a better solution.

6 years agoUpdate misc test to use the test's API
Jorge Pereira [Tue, 14 Apr 2020 21:47:07 +0000 (18:47 -0300)] 
Update misc test to use the test's API

6 years agoFix misc tests
Jorge Pereira [Tue, 14 Apr 2020 21:14:24 +0000 (18:14 -0300)] 
Fix misc tests

6 years agoFix typo
Jorge Pereira [Tue, 14 Apr 2020 20:26:00 +0000 (17:26 -0300)] 
Fix typo

6 years agoFix minor memory leak
Jorge Pereira [Tue, 14 Apr 2020 19:58:55 +0000 (16:58 -0300)] 
Fix minor memory leak

6 years agolet's run the interpreter in order to expand the xlat string...
Alan T. DeKok [Tue, 14 Apr 2020 18:55:29 +0000 (14:55 -0400)] 
let's run the interpreter in order to expand the xlat string...

6 years agodebug argv for fr_exec_nowait(), too
Alan T. DeKok [Tue, 14 Apr 2020 18:41:09 +0000 (14:41 -0400)] 
debug argv for fr_exec_nowait(), too

6 years agomake asynchronous triggers which run exec no-wait
Alan T. DeKok [Tue, 14 Apr 2020 18:32:28 +0000 (14:32 -0400)] 
make asynchronous triggers which run exec no-wait

6 years agovarious fixes to get fake requests to work better
Alan T. DeKok [Tue, 14 Apr 2020 18:17:55 +0000 (14:17 -0400)] 
various fixes to get fake requests to work better

6 years agodon't touch request->async->listen for fake requests
Alan T. DeKok [Tue, 14 Apr 2020 17:51:37 +0000 (13:51 -0400)] 
don't touch request->async->listen for fake requests

6 years agoadd API to asynchronously schedule a REQUEST
Alan T. DeKok [Tue, 14 Apr 2020 15:43:39 +0000 (11:43 -0400)] 
add API to asynchronously schedule a REQUEST

using thread-local storage

6 years agorearrange code in preparation for asynchronously adding REQUESTs
Alan T. DeKok [Tue, 14 Apr 2020 15:35:42 +0000 (11:35 -0400)] 
rearrange code in preparation for asynchronously adding REQUESTs

6 years agoremove ev from request_data in talloc destructor
Alan T. DeKok [Tue, 14 Apr 2020 14:51:18 +0000 (10:51 -0400)] 
remove ev from request_data in talloc destructor

6 years agomake TMPL_TYPE_EXEC us pass2_fixup_tmpl()
Alan T. DeKok [Tue, 14 Apr 2020 14:26:24 +0000 (10:26 -0400)] 
make TMPL_TYPE_EXEC us pass2_fixup_tmpl()

instead of pass2_fixup_xlat(), which was only a temporary hack

6 years agocorrectly compile TMPL_TYPE_EXEC in pass2_fixup_tmpl()
Alan T. DeKok [Tue, 14 Apr 2020 14:24:25 +0000 (10:24 -0400)] 
correctly compile TMPL_TYPE_EXEC in pass2_fixup_tmpl()

6 years agocall tokenize_argv, not tokenize
Alan T. DeKok [Tue, 14 Apr 2020 13:41:44 +0000 (09:41 -0400)] 
call tokenize_argv, not tokenize

so that the individual arguments are split into groups

6 years agoremove trailing CR / LF from output buffer
Alan T. DeKok [Tue, 14 Apr 2020 13:39:34 +0000 (09:39 -0400)] 
remove trailing CR / LF from output buffer

If there are intermediate ones, well, too bad.

6 years agoprint out actual exit status
Alan T. DeKok [Tue, 14 Apr 2020 13:39:14 +0000 (09:39 -0400)] 
print out actual exit status

6 years agoprint out arguments we are using for exec
Alan T. DeKok [Tue, 14 Apr 2020 13:26:50 +0000 (09:26 -0400)] 
print out arguments we are using for exec

6 years ago_fr_exit_now removed
Arran Cudbard-Bell [Tue, 14 Apr 2020 02:28:17 +0000 (21:28 -0500)] 
_fr_exit_now removed

6 years ago*sigh*
Arran Cudbard-Bell [Tue, 14 Apr 2020 01:53:20 +0000 (20:53 -0500)] 
*sigh*

6 years agoradius: Don't need file/line for fr_assert_fail anymore
Arran Cudbard-Bell [Tue, 14 Apr 2020 01:34:42 +0000 (20:34 -0500)] 
radius: Don't need file/line for fr_assert_fail anymore

6 years agoDon't need fake expr
Arran Cudbard-Bell [Tue, 14 Apr 2020 01:11:27 +0000 (20:11 -0500)] 
Don't need fake expr

6 years agoevent: Better to make it an assert
Arran Cudbard-Bell [Tue, 14 Apr 2020 01:04:33 +0000 (20:04 -0500)] 
event: Better to make it an assert

6 years agoMissing header
Arran Cudbard-Bell [Tue, 14 Apr 2020 01:03:48 +0000 (20:03 -0500)] 
Missing header

6 years agoMore compiler issues
Arran Cudbard-Bell [Tue, 14 Apr 2020 00:57:59 +0000 (19:57 -0500)] 
More compiler issues

6 years agoDefine macros for NDEBUG
Arran Cudbard-Bell [Tue, 14 Apr 2020 00:48:00 +0000 (19:48 -0500)] 
Define macros for NDEBUG

6 years agoQuiet compiler
Arran Cudbard-Bell [Tue, 14 Apr 2020 00:45:30 +0000 (19:45 -0500)] 
Quiet compiler

6 years agoRemove all calls to exit() and _Exit() except where hey're absolutely necessary
Arran Cudbard-Bell [Mon, 13 Apr 2020 22:57:27 +0000 (17:57 -0500)] 
Remove all calls to exit() and _Exit() except where hey're absolutely necessary

6 years agoFixup assert macros
Arran Cudbard-Bell [Mon, 13 Apr 2020 21:57:58 +0000 (16:57 -0500)] 
Fixup assert macros

# Conflicts:
# src/lib/unlang/tmpl.c

6 years agominor clean ups and bug fixes so that it works
Alan T. DeKok [Mon, 13 Apr 2020 21:52:49 +0000 (17:52 -0400)] 
minor clean ups and bug fixes so that it works

6 years agokevent() will return an error if the process has already exited
Alan T. DeKok [Mon, 13 Apr 2020 21:50:08 +0000 (17:50 -0400)] 
kevent() will return an error if the process has already exited

so we just call waitpid() to reap its status

6 years agoreturn the child_fd to the caller
Alan T. DeKok [Mon, 13 Apr 2020 21:32:29 +0000 (17:32 -0400)] 
return the child_fd to the caller

because fr_exec_child() doesn't do it

6 years agoit helps to wait for the child...
Alan T. DeKok [Mon, 13 Apr 2020 21:32:13 +0000 (17:32 -0400)] 
it helps to wait for the child...

6 years agoadd unlang_module_yield_to_tmpl()
Alan T. DeKok [Mon, 13 Apr 2020 20:38:05 +0000 (16:38 -0400)] 
add unlang_module_yield_to_tmpl()

6 years agocleanups and simplifications
Alan T. DeKok [Mon, 13 Apr 2020 15:15:57 +0000 (11:15 -0400)] 
cleanups and simplifications

6 years agoturn the output buffer into an output value box
Alan T. DeKok [Mon, 13 Apr 2020 14:43:36 +0000 (10:43 -0400)] 
turn the output buffer into an output value box

and allow exec-wait without an output FD

6 years agoFix rlm_cache_ sanity check for crazy people (#3370)
Disconnect3d [Mon, 13 Apr 2020 14:45:14 +0000 (16:45 +0200)] 
Fix rlm_cache_ sanity check for crazy people (#3370)

This PR fixes an incorrect size argument passed to `strncmp` which resulted in smaller prefix matching than intended.

6 years agouse kevent to wait for the PID
Alan T. DeKok [Mon, 13 Apr 2020 13:11:25 +0000 (09:11 -0400)] 
use kevent to wait for the PID

it should all be working.  Next is to add tests

6 years agomore framework for exec-wait
Alan T. DeKok [Mon, 13 Apr 2020 12:09:29 +0000 (08:09 -0400)] 
more framework for exec-wait

we still need to use kqueue to wait for the child PID.  But the
basic parts of the framework are now here.

6 years agoadd fr_exec_waitpid()
Alan T. DeKok [Mon, 13 Apr 2020 11:51:47 +0000 (07:51 -0400)] 
add fr_exec_waitpid()

so that child processes will be cleaned up if we do exec-wait,
but there's an error.

6 years agostart of framework for exec-wait
Alan T. DeKok [Mon, 13 Apr 2020 00:16:28 +0000 (20:16 -0400)] 
start of framework for exec-wait

with reading the output.

And some "todo" notes for the future.

6 years agoexec-wait API using new methods
Alan T. DeKok [Mon, 13 Apr 2020 00:12:25 +0000 (20:12 -0400)] 
exec-wait API using new methods

6 years agofix typo
Alan T. DeKok [Sun, 12 Apr 2020 23:22:02 +0000 (19:22 -0400)] 
fix typo

6 years agostupid OSX leaks memory on fork(). Let's ignore it.
Alan T. DeKok [Sun, 12 Apr 2020 22:11:28 +0000 (18:11 -0400)] 
stupid OSX leaks memory on fork().  Let's ignore it.

6 years agocheck for tainted flag on first argument
Alan T. DeKok [Sun, 12 Apr 2020 22:09:12 +0000 (18:09 -0400)] 
check for tainted flag on first argument

6 years agoprecompile TMPL_TYPE_EXEC in unlang
Alan T. DeKok [Sun, 12 Apr 2020 21:51:58 +0000 (17:51 -0400)] 
precompile TMPL_TYPE_EXEC in unlang

into vpt->tmpl_xlat
Update tmpl_verify to allow this.

In preparation for having precompiled xlat's everywhere.

6 years agopreparation for signal handlers
Alan T. DeKok [Sun, 12 Apr 2020 19:55:57 +0000 (15:55 -0400)] 
preparation for signal handlers

6 years agominor cleanups
Alan T. DeKok [Sun, 12 Apr 2020 18:06:40 +0000 (14:06 -0400)] 
minor cleanups

6 years agoallow modules to push async calls onto the stack
Alan T. DeKok [Sun, 12 Apr 2020 12:49:37 +0000 (08:49 -0400)] 
allow modules to push async calls onto the stack

i.e. triggers.  Which are fire and forget, but which also need
to do async expansions.

6 years agodon't exit on full stack
Alan T. DeKok [Sun, 12 Apr 2020 12:27:08 +0000 (08:27 -0400)] 
don't exit on full stack

instead just cancel the request

6 years agorlm_radius: Fail the first message not the last message
Arran Cudbard-Bell [Sat, 11 Apr 2020 17:18:35 +0000 (12:18 -0500)] 
rlm_radius: Fail the first message not the last message

6 years agorlm_radius - Remove function names, not needed anymore
Arran Cudbard-Bell [Sat, 11 Apr 2020 17:11:29 +0000 (12:11 -0500)] 
rlm_radius - Remove function names, not needed anymore

There's a logging mode which prints log lines that'd be better to use

6 years agoAlways reset repetitions counter
Arran Cudbard-Bell [Sat, 11 Apr 2020 05:22:58 +0000 (00:22 -0500)] 
Always reset repetitions counter