]>
git.ipfire.org Git - thirdparty/freeradius-server.git/log
Arran Cudbard-Bell [Sun, 5 Feb 2023 03:37:12 +0000 (21:37 -0600)]
rpm: List each .so individually as this appears to be the only way to fix the duplicates
We were seeing the SQL and LDAP .so files being included in both the main package and SQL/LDAP packages, which was adding incorrect dependencies for MySQL/openldap to the main FreeRADIUS RPM
Arran Cudbard-Bell [Sun, 5 Feb 2023 03:33:17 +0000 (21:33 -0600)]
rpm: Use defattr to specify default dir permissions so we don't need to manually set permissions on each %dir
The vast majority of config files have the same permissions (640) so just set that as the default
Arran Cudbard-Bell [Sun, 5 Feb 2023 01:19:19 +0000 (19:19 -0600)]
rpm: Add support back for symas flavoured openldap
Arran Cudbard-Bell [Sun, 5 Feb 2023 01:16:11 +0000 (19:16 -0600)]
rpm: Just use the standard with/without macros
Alan T. DeKok [Fri, 3 Feb 2023 13:11:10 +0000 (08:11 -0500)]
free the filter on error path. Fixes #4881
Alan T. DeKok [Fri, 3 Feb 2023 13:00:05 +0000 (08:00 -0500)]
remove unnecessary restriction
Mark Donnelly [Thu, 2 Feb 2023 15:07:31 +0000 (10:07 -0500)]
Index the headers starting with 1, just like all the data. (#4880)
Nick Porter [Wed, 1 Feb 2023 20:54:02 +0000 (20:54 +0000)]
Allow redis cluster time to propagate changes after failover
Alan T. DeKok [Wed, 1 Feb 2023 21:40:16 +0000 (16:40 -0500)]
allow a debugger via FR_DEBUGGER="lldb --" or similar
James Jones [Wed, 1 Feb 2023 20:57:03 +0000 (14:57 -0600)]
Annotate remaining tainted data issues (CID #
1519002 , #
1503896 ) (#4879)
Nick Porter [Wed, 1 Feb 2023 19:50:31 +0000 (19:50 +0000)]
Sequence ldap tests that update the directory to avoid conflicts
Nick Porter [Wed, 1 Feb 2023 19:24:52 +0000 (19:24 +0000)]
Use different keys in each cache test
Allows for parallel runs of cache tests that use redis without the tests
interfering with each other.
Nick Porter [Wed, 1 Feb 2023 09:54:22 +0000 (09:54 +0000)]
SQL driver needs to be instantiated before starting connections
Nick Porter [Tue, 31 Jan 2023 17:53:24 +0000 (17:53 +0000)]
CI: Correct REST port env variables
Nick Porter [Wed, 1 Feb 2023 13:39:37 +0000 (13:39 +0000)]
Very short cache ttl can cause issues with CI
When running under memory sanitizers, tests can be slow enough for the
cache entry to expire
Nick Porter [Wed, 1 Feb 2023 12:06:11 +0000 (12:06 +0000)]
Ensure cache resources are freed before returning
Nick Porter [Tue, 31 Jan 2023 17:02:13 +0000 (17:02 +0000)]
Tidy and fix up redis clust_node_fail test
Nick Porter [Tue, 31 Jan 2023 16:25:39 +0000 (16:25 +0000)]
Resequence tests so redis ones run sequentially
Redis tests all call scripts to reset the same cluster - so cannot run
in parallel
Nick Porter [Tue, 31 Jan 2023 15:47:24 +0000 (15:47 +0000)]
Tidy and correct redis_ippool test
Nick Porter [Mon, 30 Jan 2023 17:26:00 +0000 (17:26 +0000)]
CI: Tests need a redis-cluster, created with cluster-create script
The script creates nodes on the local host and is not designed to
operate on a remote host
Nick Porter [Wed, 1 Feb 2023 11:04:39 +0000 (11:04 +0000)]
CI: Check that redis nodes are up before creating the cluster
The create-cluster script starts redis-server with the --daemonize
option and on slow CI hosts, this may not be fully ready if `start` is
immediately followed by `create`
Nick Porter [Mon, 30 Jan 2023 16:37:16 +0000 (16:37 +0000)]
CI: Fix up redis create-cluster script for version on Ubuntu 20.04
Nick Porter [Tue, 31 Jan 2023 13:12:47 +0000 (13:12 +0000)]
Allow for \1f style escape strings inside single quotes
Nick Porter [Tue, 31 Jan 2023 13:11:46 +0000 (13:11 +0000)]
Fixup ldap tests - missing dn doesn't actually return an LDAP error
Nick Porter [Tue, 31 Jan 2023 13:10:06 +0000 (13:10 +0000)]
Replace != with !( == ) in ldap module tests
Nick Porter [Tue, 31 Jan 2023 13:04:42 +0000 (13:04 +0000)]
CI: Correct test ldap data
- Enums now need to be quoted strings
- Test looks for &control.Reply-Message to be set
Nick Porter [Mon, 30 Jan 2023 17:50:26 +0000 (17:50 +0000)]
post-auth is now send
Nick Porter [Mon, 30 Jan 2023 15:36:37 +0000 (15:36 +0000)]
uc is a GNU Make Standard Library function, not builtin
Nick Porter [Wed, 1 Feb 2023 16:46:24 +0000 (16:46 +0000)]
Don't call xlat_process_return() with node->call.func == NULL
Alan T. DeKok [Wed, 1 Feb 2023 14:04:49 +0000 (09:04 -0500)]
just return
Alan T. DeKok [Wed, 1 Feb 2023 13:48:05 +0000 (08:48 -0500)]
let's not go to "next" on pushed child or pushed unlang
Alan T. DeKok [Wed, 1 Feb 2023 13:47:07 +0000 (08:47 -0500)]
not all failed expansions will produce fr_strerror()
so print them as warnings
Alan T. DeKok [Wed, 1 Feb 2023 13:34:52 +0000 (08:34 -0500)]
this should now pass
It should have been commited with "go to "next" xlat node on RESUME"
Alan T. DeKok [Wed, 1 Feb 2023 13:34:07 +0000 (08:34 -0500)]
let's not use vpt after it's been freed
and clean up some of the other code to avoid leaks on error
Alan T. DeKok [Wed, 1 Feb 2023 02:56:08 +0000 (21:56 -0500)]
fix "success" policy to use new edit sections
we don't need to do "if" checks for parent, we can just use
the "=" operator, and let that fail-safe.
We also revert the "subrequest" test to the previous version.
The next step is to figure out why changing the xlat expansions
broke the "success" policy. But we can check that tomorrow,
once the CI tests pass again.
Alan T. DeKok [Wed, 1 Feb 2023 00:57:30 +0000 (19:57 -0500)]
go to "next" xlat node on RESUME
previously, if an intermediate xlat node yielded, it would resume
and _not_ go to process the next sibling. So make xlat_frame_eval_resume()
call xlat_frame_eval() when it's done, to resume.
Then fix up the xlat indentation, through the simple expedient
of saving the indent level, indenting, and restoring the indent
level on success/failure. This is easier than trying to figure out
the proper indent/exdent macros for every possible code path.
Then also fix up the keywords.subrequest test, which returns an
extra Packet-Type attribute from inside of the subrequest.
Alan T. DeKok [Tue, 31 Jan 2023 21:45:23 +0000 (16:45 -0500)]
don't lose casts when they're explicitly given
(foo)%{xlat..}
was being set to just
%{xlat...}
and that's wrong. :(
Alan T. DeKok [Tue, 31 Jan 2023 15:29:37 +0000 (10:29 -0500)]
expanding the expression may fail
Alan T. DeKok [Tue, 31 Jan 2023 15:11:02 +0000 (10:11 -0500)]
send reply if the reply is set
which can be set in a policy or in a module
James Jones [Tue, 31 Jan 2023 22:11:35 +0000 (16:11 -0600)]
Add -p to mkdir coverity_tool/config. (#4877)
James Jones [Tue, 31 Jan 2023 15:03:55 +0000 (09:03 -0600)]
Handle unchecked returns in src/protocols/dhcpv4/encode.c (CIDs below) (#4874)
CID
1503896 : change fr_dbuff_in() to FR_DBUFF_IN_RETURN()
CID
1504021 : annnotate; a preceding FR_DBUFF_REMAINING_RETURN() assures
that there's enough space for the PEN and data-len1.
James Jones [Tue, 31 Jan 2023 15:03:30 +0000 (09:03 -0600)]
Start using modeling for Coverity (#4853)
This involves
* making the coverity workflow build the model
* adding model source file(s)
Nick Porter [Mon, 30 Jan 2023 14:50:24 +0000 (14:50 +0000)]
Use found terminal character to determine how many URI parts to advance
not the character found after skipping `extra_skip`
Nick Porter [Mon, 30 Jan 2023 13:52:15 +0000 (13:52 +0000)]
Correct module config for rest module test
Nick Porter [Mon, 30 Jan 2023 13:51:53 +0000 (13:51 +0000)]
Replace != with !( == ) in rest module tests
Alan T. DeKok [Mon, 30 Jan 2023 21:06:57 +0000 (16:06 -0500)]
cleanups and fixes
Alan T. DeKok [Mon, 30 Jan 2023 20:27:34 +0000 (15:27 -0500)]
re-initialize the iterator for every module we delete
because deleting one module may cause it to delete child modules
in the tree, which confuses the iterator and makes it sad.
Alan T. DeKok [Mon, 30 Jan 2023 19:51:09 +0000 (14:51 -0500)]
skip the '/'
Alan T. DeKok [Mon, 30 Jan 2023 16:34:30 +0000 (11:34 -0500)]
automatically set DEBUGGER_ATTACHED when executing gdb or lldb
because the debugger detection on some OS's is broken and doesn't
work.
Alan T. DeKok [Mon, 30 Jan 2023 16:18:28 +0000 (11:18 -0500)]
typo
Alan T. DeKok [Mon, 30 Jan 2023 12:51:44 +0000 (07:51 -0500)]
more checking for corner cases
Alan T. DeKok [Mon, 30 Jan 2023 00:27:49 +0000 (19:27 -0500)]
it helps to set the value for State
Alan T. DeKok [Sun, 29 Jan 2023 22:07:57 +0000 (17:07 -0500)]
use VALID macro
Alan T. DeKok [Sat, 28 Jan 2023 01:45:11 +0000 (20:45 -0500)]
rename TACACS+ packet types
for increased clarity, now that we're actually using it.
and do a number of other cleanups. Fix the state machine to match
the new packet types. Fix the state machine to track state based
on synthesized information. Add authentication logging ala RADIUS
Alan T. DeKok [Fri, 27 Jan 2023 19:11:36 +0000 (14:11 -0500)]
fix up macros to be sure there's no possibility of error
Nick Porter [Fri, 27 Jan 2023 16:10:20 +0000 (16:10 +0000)]
Resequence to avoid potential double free. Fixes #4863
Nick Porter [Fri, 27 Jan 2023 15:49:12 +0000 (15:49 +0000)]
Ensure LDAPMessage is freed on errors. Fixes #4864
Alan T. DeKok [Fri, 27 Jan 2023 00:17:46 +0000 (19:17 -0500)]
there should have been no reply yet
Alan T. DeKok [Thu, 26 Jan 2023 23:50:52 +0000 (18:50 -0500)]
force reject if there's no auth-type
and don't set default accept if "recv Access-Request" returns "ok"
Alan T. DeKok [Thu, 26 Jan 2023 20:48:57 +0000 (15:48 -0500)]
typo and cleanups
Alan T. DeKok [Thu, 26 Jan 2023 18:20:23 +0000 (13:20 -0500)]
not needed
Alan T. DeKok [Thu, 26 Jan 2023 15:16:57 +0000 (10:16 -0500)]
update docs
James Jones [Thu, 26 Jan 2023 15:04:57 +0000 (09:04 -0600)]
Remove dead code (CID #
1519001 ) (#4854)
_event_build_indexes() always returns 0, so fr_atexit_global_once_ret()
will always set ret to zero, and hence ret won't be negative.
Terry Burton [Thu, 26 Jan 2023 14:05:46 +0000 (14:05 +0000)]
pap: Hoist &control:User-Password check so that it can be found (#4866)
Since loop is rooted at &Password.
Alan T. DeKok [Thu, 26 Jan 2023 13:59:23 +0000 (08:59 -0500)]
fix unlock and return code. Fixes #4862
Don't override an error return code with a successful one.
Instead, set the success code first, and then override it if
there's an error.
Now that that's cleaned up, always unlock the mutex
Alan T. DeKok [Wed, 25 Jan 2023 01:33:27 +0000 (20:33 -0500)]
use FR_TACACS_PACKET_CODE_VALID
Nick Porter [Wed, 25 Jan 2023 19:19:44 +0000 (19:19 +0000)]
Only leaf vps have the data object
Nick Porter [Wed, 18 Jan 2023 10:53:17 +0000 (10:53 +0000)]
Add unit tests launcher to launch.json
Arran Cudbard-Bell [Thu, 26 Jan 2023 06:42:07 +0000 (01:42 -0500)]
Don't set the path in the spec file
James Jones [Wed, 25 Jan 2023 01:06:03 +0000 (19:06 -0600)]
Placate coverity about day-to-second calculation (CID #
1520503 , #
1520502 ) (#4859)
Coverity doesn't realize that day of week or month is constrained
such that multiplying by seconds per day won't overflow int32_t.
Alan T. DeKok [Tue, 24 Jan 2023 19:27:42 +0000 (14:27 -0500)]
install libtalloc && libpcap, too
Stephen Blackwell [Tue, 24 Jan 2023 19:15:48 +0000 (13:15 -0600)]
Clean up versioning for libtalloc and libkqueue, add rule to install libpcap (#4858)
Signed-off-by: Stephen Blackwell <sblackwell@networkradius.com>
Signed-off-by: Stephen Blackwell <sblackwell@networkradius.com>
Alan T. DeKok [Tue, 24 Jan 2023 17:27:40 +0000 (12:27 -0500)]
change assert to run-time warning
until we track down why it occurs in CI but not locally
Alan T. DeKok [Tue, 24 Jan 2023 17:16:49 +0000 (12:16 -0500)]
script to build (hopefully) prerequisites on RH
Alan T. DeKok [Tue, 24 Jan 2023 17:03:04 +0000 (12:03 -0500)]
wrapper scripts to run local binaries
Alan T. DeKok [Tue, 24 Jan 2023 16:41:17 +0000 (11:41 -0500)]
tell people about "xcrun foo" on OSX
Alan T. DeKok [Tue, 24 Jan 2023 14:49:56 +0000 (09:49 -0500)]
assert that we don't leak memory on each packet
Alan T. DeKok [Tue, 24 Jan 2023 12:12:37 +0000 (07:12 -0500)]
change name from SARL to SAS
Alan T. DeKok [Tue, 24 Jan 2023 12:08:16 +0000 (07:08 -0500)]
whitespace
Alan T. DeKok [Tue, 24 Jan 2023 01:43:23 +0000 (20:43 -0500)]
it's a day for typos
Alan T. DeKok [Tue, 24 Jan 2023 01:21:58 +0000 (20:21 -0500)]
clean up and regularize names
perl -p -i -e 's/fr_vmps_codes/fr_vmps_packet_names/g' $(git grep -l fr_vmps_codes)
Alan T. DeKok [Tue, 24 Jan 2023 01:16:42 +0000 (20:16 -0500)]
clean up and regularize names
perl -p -i -e 's/fr_dns_packet_codes/fr_dns_packet_names/g' $(git grep -l fr_dns_packet_codes)
Alan T. DeKok [Tue, 24 Jan 2023 01:14:47 +0000 (20:14 -0500)]
Clean up and regularize names
perl -p -i -e 's/fr_dhcpv6_packet_types/fr_dhcpv6_packet_names/g' $(git grep -l fr_dhcpv6_packet_types)
Alan T. DeKok [Tue, 24 Jan 2023 01:12:08 +0000 (20:12 -0500)]
clean up and standardize names
perl -p -i -e 's/fr_request_types/fr_radius_request_name_table/g' $(git grep -l fr_request_types)
Alan T. DeKok [Tue, 24 Jan 2023 01:07:37 +0000 (20:07 -0500)]
clean up and dedup FR_RADIUS_PACKET_CODE_VALID
perl -p -i -e 's/is_radius_code/FR_RADIUS_PACKET_CODE_VALID/g' $(find . -name "*.[ch]" -print)
Alan T. DeKok [Tue, 24 Jan 2023 01:05:09 +0000 (20:05 -0500)]
clean up RADIUS names
perl -p -i -e 's/fr_packet_codes/fr_radius_packet_names/g' $(find . -name "*.[ch]" -print)
Alan T. DeKok [Tue, 24 Jan 2023 01:04:07 +0000 (20:04 -0500)]
clean up names
perl -p -i -e 's/fr_tacacs_packet_codes/fr_tacacs_packet_names/g' $(find . -name "*.[ch]" -print)
Alan T. DeKok [Tue, 24 Jan 2023 00:58:19 +0000 (19:58 -0500)]
clean up definition of FR_TACACS_CODE_MAX. Fixes #4856
The CODE_MAX definition should be one more than the last valid
packet code.
The DO_NOT_RESPOND value should be a value which will never show
up in a real packet.
The PACKET_CODE_VALID macro should be used instead of relying on
manual checks of CODE_MAX
Alan T. DeKok [Mon, 23 Jan 2023 22:18:11 +0000 (17:18 -0500)]
typo
Alan T. DeKok [Mon, 23 Jan 2023 22:10:04 +0000 (17:10 -0500)]
typo to rearrange code
Alan T. DeKok [Mon, 23 Jan 2023 21:30:31 +0000 (16:30 -0500)]
don't call frame_pop() if we have REQUEST_STOP_PROCESSING
Alan T. DeKok [Mon, 23 Jan 2023 20:25:25 +0000 (15:25 -0500)]
clean up descriptions and names
so that the names and functions are descriptive and correct.
Alan T. DeKok [Mon, 23 Jan 2023 19:35:07 +0000 (14:35 -0500)]
use CLOCK_MONOTONIC_RAW if it exists
otherwise use CLOCK_MONOTONIC. The RAW version is unaffected
by frequency or time adjustments
Alan T. DeKok [Mon, 23 Jan 2023 19:31:41 +0000 (14:31 -0500)]
remove mach functions.
OSX now (and for a long time) has had clock_gettime(). The old
code using the mach functions didn't even compile when we tried
to not use clock_gettime(). So... nuke the old / broken / unused
code.
Alan T. DeKok [Mon, 23 Jan 2023 21:34:24 +0000 (16:34 -0500)]
clarifications and typo fixes
Alan T. DeKok [Sun, 22 Jan 2023 13:51:30 +0000 (08:51 -0500)]
add functions to get gmt offset and daylight savings flag
we should note that the server tracks times in UTC, so
(date) foo % (time_delta) 1d
will return the offset from the UTC day, not from the local time.
This could perhaps be more prominent. But tracking times internally
in UTC is the only way to make sure we're not screwed up by time
zone and DST changes.
Alan T. DeKok [Sun, 22 Jan 2023 12:56:50 +0000 (07:56 -0500)]
update for expressions terminating before EOL
the admin must manually add backslashes for continuation
Alan T. DeKok [Sun, 22 Jan 2023 11:33:06 +0000 (06:33 -0500)]
add week / month / year time resolution
which are vaguely correct for months, and correct to the second
for years. The main purpose here is to allow for at least rough
parsing of years / months
James Jones [Sun, 22 Jan 2023 15:52:11 +0000 (09:52 -0600)]
Get rid of double unlock in fr_atexit_global_once_ret() (CID #
1518999 ) (#4855)
Alan T. DeKok [Sat, 21 Jan 2023 21:48:40 +0000 (16:48 -0500)]
add Tmp-Time-Delta-*
we really need local variables :(