]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
17 months agoSwitch Coverity-only code to assert (CID #1619299) (#5441)
James Jones [Sun, 12 Jan 2025 20:48:01 +0000 (14:48 -0600)] 
Switch Coverity-only code to assert (CID #1619299) (#5441)

fr_nbo_from_uint64v() does not have an error return--it doesn't
need one. The buffers are big enough, the "| 0x80" means it will
always use as least one byte, so fr_high_bit_pos() won't return 0
even if num == 0. So adding a bogus error return check for Coverity
actually misleads Coverity about any call to fr_nbo_from_uint64v(),
making it the probable cause of the CID.

Co-authored-by: Arran Cudbard-Bell <a.cudbardb@freeradius.org>
17 months agoquiet a number of coverity issues
Alan T. DeKok [Sun, 12 Jan 2025 14:50:27 +0000 (09:50 -0500)] 
quiet a number of coverity issues

17 months agocopy is_set fields, too
Alan T. DeKok [Sun, 12 Jan 2025 14:25:29 +0000 (09:25 -0500)] 
copy is_set fields, too

17 months agoshut up coverity. CID #1604620
Alan T. DeKok [Sat, 11 Jan 2025 15:11:38 +0000 (10:11 -0500)] 
shut up coverity.  CID #1604620

17 months agotweak code to satisfy coverity #1633838
Alan T. DeKok [Sat, 11 Jan 2025 15:04:01 +0000 (10:04 -0500)] 
tweak code to satisfy coverity #1633838

17 months agoPacify Coverity (#CID 1638651)
Nick Porter [Sun, 12 Jan 2025 14:24:14 +0000 (14:24 +0000)] 
Pacify Coverity (#CID 1638651)

Coverity doesn't understand that the limit on the number of parsed
digits prevents an overflow.

17 months agoAdd DR_TACACS_CODE_DO_NOT_RESPOND to TACACS process_state (#CID 1638274)
Nick Porter [Sun, 12 Jan 2025 14:02:39 +0000 (14:02 +0000)] 
Add DR_TACACS_CODE_DO_NOT_RESPOND to TACACS process_state (#CID 1638274)

17 months agobetter handle dynamic clients for connected sockets
Alan T. DeKok [Sat, 11 Jan 2025 14:27:15 +0000 (09:27 -0500)] 
better handle dynamic clients for connected sockets

don't run "new client" on every connection

17 months agono need for destructor
Alan T. DeKok [Sat, 11 Jan 2025 13:40:05 +0000 (08:40 -0500)] 
no need for destructor

alive clients are talloc'd from the thread, so freeing the thread
will free the clients

17 months agoclean up messages for BlastRADIUS issues
Alan T. DeKok [Sat, 11 Jan 2025 01:44:43 +0000 (20:44 -0500)] 
clean up messages for BlastRADIUS issues

17 months agoset "yes" to "1" and "auto" to "2"
Alan T. DeKok [Fri, 10 Jan 2025 21:44:23 +0000 (16:44 -0500)] 
set "yes" to "1" and "auto" to "2"

The configuration file parsing code parses things before it knows
their data types. Which means that "yes" gets parsed as data type
"bool", with value "1".  It then gets cast to "uint8_t" when
processing the require-ma attribute.  Which just happens to have
"auto" as "1", and "yes" as "2".

Rather than redoing all of the parsing code, we just set "yes"
to "1", which is much safer.

17 months agocorrect check
Alan T. DeKok [Fri, 10 Jan 2025 20:42:02 +0000 (15:42 -0500)] 
correct check

17 months agowe shouldn't need to require "add client" or "deny client"
Alan T. DeKok [Fri, 10 Jan 2025 20:34:02 +0000 (15:34 -0500)] 
we shouldn't need to require "add client" or "deny client"

but at least print out what we're doing

17 months agocorrect checks in dict_attr_allow_dup()
Alan T. DeKok [Fri, 10 Jan 2025 14:30:55 +0000 (09:30 -0500)] 
correct checks in dict_attr_allow_dup()

so that it actually checks for dups.

17 months agoclearer errors
Alan T. DeKok [Fri, 10 Jan 2025 14:10:46 +0000 (09:10 -0500)] 
clearer errors

17 months agocall SSL_set_connect_state() when starting client context
Alan T. DeKok [Thu, 9 Jan 2025 21:40:58 +0000 (16:40 -0500)] 
call SSL_set_connect_state() when starting client context

17 months agoadded missing dictionaries
Alan T. DeKok [Thu, 9 Jan 2025 19:36:53 +0000 (14:36 -0500)] 
added missing dictionaries

17 months agoupdate as per recent feature additions
Alan T. DeKok [Thu, 9 Jan 2025 19:01:29 +0000 (14:01 -0500)] 
update as per recent feature additions

17 months agoAdd dynamic client processing to TACACS state machine
Nick Porter [Fri, 10 Jan 2025 11:35:34 +0000 (11:35 +0000)] 
Add dynamic client processing to TACACS state machine

17 months agoNo need to re-write attributes for TACACS dynamic clients
Nick Porter [Fri, 10 Jan 2025 11:34:53 +0000 (11:34 +0000)] 
No need to re-write attributes for TACACS dynamic clients

As we haven't done a packet decode, the request pair list will be empty.

17 months agoInitial packets from TACACS+ dynamic clients can't be decoded
Nick Porter [Fri, 10 Jan 2025 11:33:14 +0000 (11:33 +0000)] 
Initial packets from TACACS+ dynamic clients can't be decoded

As we don't know the shared secret yet - so just set a sensible packet
code and skip the decode.

17 months agoBump PostgreSQL version for FreeBSD tests
Nick Porter [Fri, 10 Jan 2025 09:48:39 +0000 (09:48 +0000)] 
Bump PostgreSQL version for FreeBSD tests

17 months agoPop box from list before manipulation
Nick Porter [Fri, 10 Jan 2025 09:33:03 +0000 (09:33 +0000)] 
Pop box from list before manipulation

fr_value_box_strdup re-initialises the box, which clears the list
pointers, meaning list_remove won't work.

17 months agoupdate docs for OSX
Alan T. DeKok [Wed, 8 Jan 2025 20:15:07 +0000 (15:15 -0500)] 
update docs for OSX

17 months agoport from v3.2.x
Alan T. DeKok [Wed, 8 Jan 2025 20:09:11 +0000 (15:09 -0500)] 
port from v3.2.x

17 months agosort help text
Alan T. DeKok [Wed, 8 Jan 2025 16:25:10 +0000 (11:25 -0500)] 
sort help text

17 months agorename to --show-config. Fixes #5442
Alan T. DeKok [Sun, 5 Jan 2025 13:59:40 +0000 (08:59 -0500)] 
rename to --show-config.  Fixes #5442

This avoids conflict with clang's --config option.

We should probably instead have a special "--" option which
signifies "end of jlibtool options.

Arguably jlibtool should have

17 months agoAdd libfreeradius-bio-config.so to Debian packaging
Nick Porter [Wed, 8 Jan 2025 16:13:02 +0000 (16:13 +0000)] 
Add libfreeradius-bio-config.so to Debian packaging

17 months agoadd examples as per Juniper documentation
Alan T. DeKok [Wed, 8 Jan 2025 13:58:37 +0000 (08:58 -0500)] 
add examples as per Juniper documentation

17 months agoadd write_pause API
Alan T. DeKok [Tue, 7 Jan 2025 20:01:56 +0000 (15:01 -0500)] 
add write_pause API

so that we can pause / buffer / resume writes for possible
performance improvements

17 months agoAdd test of += operator in LDAP update
Nick Porter [Wed, 8 Jan 2025 09:54:00 +0000 (09:54 +0000)] 
Add test of += operator in LDAP update

17 months agoAdd test of LDAP binary data update
Nick Porter [Wed, 8 Jan 2025 09:48:12 +0000 (09:48 +0000)] 
Add test of LDAP binary data update

And validation that empty / missing expansions don't produce updates

17 months agoSkip LDAP updates when tmpl produces zero length output
Nick Porter [Wed, 8 Jan 2025 09:16:21 +0000 (09:16 +0000)] 
Skip LDAP updates when tmpl produces zero length output

17 months agoSkip LDAP updates when tmpl produces no boxes
Nick Porter [Wed, 8 Jan 2025 09:11:15 +0000 (09:11 +0000)] 
Skip LDAP updates when tmpl produces no boxes

17 months agoLDAPMod arrays can be dynamically created
Nick Porter [Tue, 7 Jan 2025 15:16:50 +0000 (15:16 +0000)] 
LDAPMod arrays can be dynamically created

Removing the arbitrary limit

17 months agoUpdate LDAP accounting / send module calls in tests
Nick Porter [Tue, 7 Jan 2025 15:12:43 +0000 (15:12 +0000)] 
Update LDAP accounting / send module calls in tests

These now need to be ldap.accounting.<acct status type> or
ldap.send.<packet type>

17 months agoAmend LDAP test config to match new update section layout
Nick Porter [Tue, 7 Jan 2025 15:03:36 +0000 (15:03 +0000)] 
Amend LDAP test config to match new update section layout

17 months agoUse call_env
Nick Porter [Tue, 7 Jan 2025 14:47:39 +0000 (14:47 +0000)] 
Use call_env

17 months agoUse call_env
Nick Porter [Tue, 7 Jan 2025 14:42:16 +0000 (14:42 +0000)] 
Use call_env

17 months agoUpdate sample LDAP module config with new structure
Nick Porter [Tue, 7 Jan 2025 14:29:40 +0000 (14:29 +0000)] 
Update sample LDAP module config with new structure

17 months agoRemove old LDAP accounting section handling
Nick Porter [Tue, 7 Jan 2025 14:28:10 +0000 (14:28 +0000)] 
Remove old LDAP accounting section handling

17 months agoUse call_env to populate LDAP modification maps
Nick Porter [Tue, 7 Jan 2025 14:19:32 +0000 (14:19 +0000)] 
Use call_env to populate LDAP modification maps

17 months agoAdd return values to doxygen comments
Nick Porter [Tue, 7 Jan 2025 14:06:40 +0000 (14:06 +0000)] 
Add return values to doxygen comments

17 months agoLDAP modifies do have a result which can be checked for errors
Nick Porter [Tue, 7 Jan 2025 13:30:22 +0000 (13:30 +0000)] 
LDAP modifies do have a result which can be checked for errors

17 months agoAdd call_env parsing of LDAP mods
Nick Porter [Mon, 6 Jan 2025 19:57:00 +0000 (19:57 +0000)] 
Add call_env parsing of LDAP mods

Mods are parsed from

<name 1> {
  <name 2> {
    update {
      ...
    }
  }
}

17 months agoComment corrections
Nick Porter [Mon, 6 Jan 2025 12:08:22 +0000 (12:08 +0000)] 
Comment corrections

17 months agoBetter error reporting for missing queries
Nick Porter [Mon, 6 Jan 2025 11:50:06 +0000 (11:50 +0000)] 
Better error reporting for missing queries

17 months agoCorrect comment
Nick Porter [Mon, 6 Jan 2025 10:31:18 +0000 (10:31 +0000)] 
Correct comment

17 months agoadd callback to parse protocol-specific data types
Alan T. DeKok [Mon, 6 Jan 2025 23:44:47 +0000 (18:44 -0500)] 
add callback to parse protocol-specific data types

17 months agounify error path
Alan T. DeKok [Mon, 30 Dec 2024 16:12:53 +0000 (11:12 -0500)] 
unify error path

17 months agoMove to a single Python script that implements dd (#5444)
James Jones [Mon, 6 Jan 2025 16:30:01 +0000 (10:30 -0600)] 
Move to a single Python script that implements dd (#5444)

This will pro9bably be the schema for any future commands added to
gdb and lldb.

17 months agoDon't directly use buffer set in sbuff (CID #1634622) (#5460)
James Jones [Mon, 6 Jan 2025 16:29:38 +0000 (10:29 -0600)] 
Don't directly use buffer set in sbuff (CID #1634622) (#5460)

Another case of an uninitialized local buffer used in an sbuff but
referenced by name to print out. Coverity complains about it, not
recognizing the the sbuff operation puts a value there. Referencing
the start of the sbuff gets the same effect without complaint.

17 months agoadoc typo
James Jones [Wed, 2 Oct 2024 18:28:45 +0000 (13:28 -0500)] 
adoc typo

17 months agoAnother typo
James Jones [Thu, 3 Oct 2024 12:28:41 +0000 (07:28 -0500)] 
Another typo

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/dhcpv6.tar
github-actions[bot] [Sun, 5 Jan 2025 09:35:07 +0000 (09:35 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/dhcpv6.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/radius.tar
github-actions[bot] [Sun, 5 Jan 2025 09:35:01 +0000 (09:35 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/radius.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/tacacs.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:44 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/tacacs.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/dns.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:40 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/dns.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/dhcpv4.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:35 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/dhcpv4.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/bfd.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:25 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/bfd.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/util.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:22 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/util.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/tftp.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:19 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/tftp.tar

17 months agoScheduled fuzzing: Update src/tests/fuzzer-corpus/vmps.tar
github-actions[bot] [Sun, 5 Jan 2025 09:34:16 +0000 (09:34 +0000)] 
Scheduled fuzzing: Update src/tests/fuzzer-corpus/vmps.tar

17 months agoRework extraction of pairs from Subject Alternate Name
Nick Porter [Fri, 3 Jan 2025 18:15:35 +0000 (18:15 +0000)] 
Rework extraction of pairs from Subject Alternate Name

Some valid certificates have been seen where X509_get_ext_by_NID() fails
to find the SAN extension even though it is present.

The extension is then found when walking the list of extensions.

17 months agoAttempt to parse unknown extensions when extracting
Nick Porter [Thu, 2 Jan 2025 19:23:33 +0000 (19:23 +0000)] 
Attempt to parse unknown extensions when extracting

17 months agoReport when certificate extensions fail to be extracted
Nick Porter [Thu, 2 Jan 2025 19:22:18 +0000 (19:22 +0000)] 
Report when certificate extensions fail to be extracted

17 months agoPass nested attributes to Python functions (fixes #5456)
Nick Porter [Thu, 2 Jan 2025 13:04:38 +0000 (13:04 +0000)] 
Pass nested attributes to Python functions (fixes #5456)

17 months agoAdd test for list reference in exec output parsing
Nick Porter [Tue, 31 Dec 2024 11:32:32 +0000 (11:32 +0000)] 
Add test for list reference in exec output parsing

17 months agoSimplify libcurl certificate parsing
Nick Porter [Tue, 31 Dec 2024 09:39:15 +0000 (09:39 +0000)] 
Simplify libcurl certificate parsing

17 months agorequire_cert is a long not a pointer
Nick Porter [Tue, 31 Dec 2024 09:05:56 +0000 (09:05 +0000)] 
require_cert is a long not a pointer

17 months agoSet correct curl option for TLS SRP auth
Nick Porter [Tue, 31 Dec 2024 08:57:15 +0000 (08:57 +0000)] 
Set correct curl option for TLS SRP auth

17 months agoAttempt to pacify Coverity (CID #1604608)
Nick Porter [Mon, 30 Dec 2024 18:06:11 +0000 (18:06 +0000)] 
Attempt to pacify Coverity (CID #1604608)

17 months agoCorrect coverity annotation syntax
Nick Porter [Mon, 30 Dec 2024 17:54:55 +0000 (17:54 +0000)] 
Correct coverity annotation syntax

17 months agoAlways populate h_out when a connection is initialised
Nick Porter [Mon, 30 Dec 2024 17:35:18 +0000 (17:35 +0000)] 
Always populate h_out when a connection is initialised

17 months agofr_dlist takes real objects in the list, not the `entry` pointer
Nick Porter [Mon, 30 Dec 2024 17:01:37 +0000 (17:01 +0000)] 
fr_dlist takes real objects in the list, not the `entry` pointer

17 months agoUse .asc extension for ASCII gpg keys
Nick Porter [Mon, 30 Dec 2024 12:02:32 +0000 (12:02 +0000)] 
Use .asc extension for ASCII gpg keys

17 months agoAnother -1 error indicator (CID #1604616)
Nick Porter [Mon, 30 Dec 2024 09:21:13 +0000 (09:21 +0000)] 
Another -1 error indicator (CID #1604616)

17 months agoWe only need -1 as an error indicator (CID #1604605)
Nick Porter [Mon, 30 Dec 2024 09:09:32 +0000 (09:09 +0000)] 
We only need -1 as an error indicator (CID #1604605)

17 months agoNo need for intermediate variable
Nick Porter [Mon, 30 Dec 2024 08:59:40 +0000 (08:59 +0000)] 
No need for intermediate variable

Also pacifies Coverity (CID #1604602)

17 months agoapt-key add is long deprecated
Nick Porter [Mon, 30 Dec 2024 08:51:06 +0000 (08:51 +0000)] 
apt-key add is long deprecated

17 months agotrunk can have pending connections on open.
Alan T. DeKok [Sat, 28 Dec 2024 18:42:01 +0000 (13:42 -0500)] 
trunk can have pending connections on open.

see previous commits for details

17 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.

17 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.

17 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

17 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

17 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

17 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()

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

17 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

17 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

17 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()

17 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

17 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.

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

17 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

17 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

17 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

17 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

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

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