]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
2 years agopyfr: Add Python binding for libfreeradius API. v4/pyfr 4849/head
Jorge Pereira [Mon, 2 Jan 2023 22:28:09 +0000 (19:28 -0300)] 
pyfr: Add Python binding for libfreeradius API.

The first version of our new Python "pyfr" module
exporting some API behaviors.

2 years agouse TLS_method()
Alan T. DeKok [Fri, 14 Apr 2023 14:56:11 +0000 (10:56 -0400)] 
use TLS_method()

as per https://www.openssl.org/docs/man3.1/man3/TLS_method.html

2 years agoadd test for editing session-state, too
Alan T. DeKok [Wed, 5 Apr 2023 19:50:30 +0000 (15:50 -0400)] 
add test for editing session-state, too

2 years agoNot an error
Nick Porter [Fri, 14 Apr 2023 07:43:53 +0000 (08:43 +0100)] 
Not an error

2 years agoFree on both read/write and read only paths
Nick Porter [Fri, 14 Apr 2023 07:43:32 +0000 (08:43 +0100)] 
Free on both read/write and read only paths

2 years agocustomer: *stab* *stab* *stab*
Arran Cudbard-Bell [Thu, 13 Apr 2023 22:52:02 +0000 (08:52 +1000)] 
customer: *stab* *stab* *stab*

2 years agoFix talloc foreach so it doesn't have issues with NULL input arrays
Arran Cudbard-Bell [Thu, 13 Apr 2023 21:48:20 +0000 (07:48 +1000)] 
Fix talloc foreach so it doesn't have issues with NULL input arrays

2 years agoOnly need trunk for lookups if we don't have a cached DN
Nick Porter [Thu, 13 Apr 2023 15:43:25 +0000 (16:43 +0100)] 
Only need trunk for lookups if we don't have a cached DN

If the cached DN is already in the control list, then there is no need
to perform any lookup queries - just the auth bind will be done, which
is not on the trunk used for queries.

2 years agoAdd missing net_timeout option to sample ldap config
Nick Porter [Tue, 11 Apr 2023 10:27:03 +0000 (11:27 +0100)] 
Add missing net_timeout option to sample ldap config

2 years agoUpdate sample ldap module to reflect trunk parameters
Nick Porter [Fri, 7 Apr 2023 15:25:46 +0000 (16:25 +0100)] 
Update sample ldap module to reflect trunk parameters

Aligned with fr_trunk_config CONF_PARSER

2 years agoAvoid NULL pointer error
Nick Porter [Thu, 13 Apr 2023 17:23:42 +0000 (18:23 +0100)] 
Avoid NULL pointer error

2 years agoFree redis result on failure paths
Nick Porter [Thu, 13 Apr 2023 16:19:14 +0000 (17:19 +0100)] 
Free redis result on failure paths

2 years agoFree previous redis result before retrieving another
Nick Porter [Thu, 13 Apr 2023 16:18:33 +0000 (17:18 +0100)] 
Free previous redis result before retrieving another

2 years agoredis: Don't allocate a default section
Arran Cudbard-Bell [Thu, 13 Apr 2023 11:41:10 +0000 (21:41 +1000)] 
redis: Don't allocate a default section

2 years agoredis ippool: Need the delay module here too
Arran Cudbard-Bell [Thu, 13 Apr 2023 11:06:12 +0000 (21:06 +1000)] 
redis ippool: Need the delay module here too

2 years agoredis: If remap fails because the connection is bad, don't leave the stale connection...
Arran Cudbard-Bell [Thu, 13 Apr 2023 10:57:07 +0000 (20:57 +1000)] 
redis: If remap fails because the connection is bad, don't leave the stale connection open

2 years agoredis: Fix remap rate limit
Arran Cudbard-Bell [Thu, 13 Apr 2023 10:55:43 +0000 (20:55 +1000)] 
redis: Fix remap rate limit

2 years agoredis: Fix const issue
Arran Cudbard-Bell [Thu, 13 Apr 2023 10:22:15 +0000 (20:22 +1000)] 
redis: Fix const issue

2 years agoredis: Version specific fixes in redis-setup.sh
Arran Cudbard-Bell [Thu, 13 Apr 2023 10:13:52 +0000 (20:13 +1000)] 
redis: Version specific fixes in redis-setup.sh

2 years agoredis: Add the ability to add xlat wrappers which allow lua functions to be called...
Arran Cudbard-Bell [Thu, 13 Apr 2023 05:55:59 +0000 (15:55 +1000)] 
redis: Add the ability to add xlat wrappers which allow lua functions to be called on the redis cluster

2 years agoredis: Fix node fail test to be more reliable
Arran Cudbard-Bell [Thu, 13 Apr 2023 07:43:41 +0000 (17:43 +1000)] 
redis: Fix node fail test to be more reliable

2 years agoredis: Fixup redis setup script to enable debug commands
Arran Cudbard-Bell [Thu, 13 Apr 2023 07:39:41 +0000 (17:39 +1000)] 
redis: Fixup redis setup script to enable debug commands

2 years agoredis: Fix timing issues in cluster reset
Arran Cudbard-Bell [Thu, 13 Apr 2023 07:11:06 +0000 (17:11 +1000)] 
redis: Fix timing issues in cluster reset

It takes 5-6 seconds for replicas to appear in the output of cluster slots

2 years agoredis: No need to mangle this for other platforms
Arran Cudbard-Bell [Thu, 13 Apr 2023 06:49:31 +0000 (16:49 +1000)] 
redis: No need to mangle this for other platforms

2 years agobuild: Document RELEASE=1 and RELEASE=0
Arran Cudbard-Bell [Wed, 12 Apr 2023 01:16:14 +0000 (11:16 +1000)] 
build: Document RELEASE=1 and RELEASE=0

2 years agoworkflow: Install a more recent version of Git for centos 7
Arran Cudbard-Bell [Wed, 12 Apr 2023 00:14:25 +0000 (10:14 +1000)] 
workflow: Install a more recent version of Git for centos 7

2 years agoCorrect state machine for SASL bind auth
Nick Porter [Tue, 11 Apr 2023 09:15:12 +0000 (10:15 +0100)] 
Correct state machine for SASL bind auth

There needs to be one more call to ldap_sasl_interactive_bind after
ldap_result returns success to complete the SASL bind.

It is the return code of ldap_sasl_interactive_bind which indicates
whether a further call is required or not.

2 years agoUse correct type for bind_auth_ctx->ret
Nick Porter [Tue, 11 Apr 2023 09:07:36 +0000 (10:07 +0100)] 
Use correct type for bind_auth_ctx->ret

2 years agoPartially revert change in version.sh
Arran Cudbard-Bell [Mon, 10 Apr 2023 17:09:17 +0000 (10:09 -0700)] 
Partially revert change in version.sh

2 years agobuild: Use --add-file not --add-virtual-file
Arran Cudbard-Bell [Mon, 10 Apr 2023 17:08:00 +0000 (10:08 -0700)] 
build:  Use --add-file not --add-virtual-file

2 years agobuild: Improve versioning support
Arran Cudbard-Bell [Mon, 10 Apr 2023 04:36:22 +0000 (21:36 -0700)] 
build: Improve versioning support

RELEASE=0 or RELEASE=1 can now be used to influence the default state of enable-developer when making archives, running configure, and building packages.

All versioning values are now produced by version.sh instead of being spread between our Makefile and configure.

Commit and commit depth are inserted into into tar/gz files so that developer builds are automatically enabled for non-release builds, and the commit is embedded in version strings for all builds.

2 years agoFix build-essential package name (#4971)
Max Khon [Fri, 7 Apr 2023 12:13:45 +0000 (13:13 +0100)] 
Fix build-essential package name (#4971)

2 years agovalue: Add value box acopy function
Arran Cudbard-Bell [Fri, 7 Apr 2023 07:16:11 +0000 (00:16 -0700)] 
value: Add value box acopy function

2 years agofix comment
Arran Cudbard-Bell [Fri, 7 Apr 2023 07:15:05 +0000 (00:15 -0700)] 
fix comment

2 years agodeb: Remove hack in debian/rules, it should not be necessary
Arran Cudbard-Bell [Fri, 7 Apr 2023 03:29:24 +0000 (20:29 -0700)] 
deb: Remove hack in debian/rules, it should not be necessary

2 years agogit: Fix check for whether we're in a git repo
Arran Cudbard-Bell [Fri, 7 Apr 2023 03:11:34 +0000 (20:11 -0700)] 
git: Fix check for whether we're in a git repo

2 years agoforce RHS of edits to use full paths when referencing an attribute
Alan T. DeKok [Wed, 5 Apr 2023 19:08:30 +0000 (15:08 -0400)] 
force RHS of edits to use full paths when referencing an attribute

because it's crazy to do

&reply += {
&User-Name = &User-Name
}

2 years agoadd tests for nested groups
Alan T. DeKok [Wed, 5 Apr 2023 19:07:59 +0000 (15:07 -0400)] 
add tests for nested groups

and update parsing rules to not leave namespace as internal

2 years agomove copy of attrs file to make rules
Alan T. DeKok [Wed, 5 Apr 2023 02:11:42 +0000 (22:11 -0400)] 
move copy of attrs file to make rules

so that we don't do the copy every time

2 years agoFormatting
Arran Cudbard-Bell [Wed, 5 Apr 2023 13:48:41 +0000 (07:48 -0600)] 
Formatting

2 years agoclang scan fixes
Arran Cudbard-Bell [Wed, 5 Apr 2023 01:31:06 +0000 (19:31 -0600)] 
clang scan fixes

2 years agoexec: Create two distinct interfaces for the exec code
Arran Cudbard-Bell [Wed, 5 Apr 2023 01:20:53 +0000 (19:20 -0600)] 
exec: Create two distinct interfaces for the exec code

- Low level interface is used for spawning global processes used in pool.
- High level interface is for oneshot requests use for backticks and rlm_exec.

2 years agoevent-waitid: When waitid returns 0, info isn't initialised so we can't check it
Arran Cudbard-Bell [Wed, 5 Apr 2023 01:16:36 +0000 (19:16 -0600)] 
event-waitid: When waitid returns 0, info isn't initialised so we can't check it

2 years agoIgnore doxygen src
Arran Cudbard-Bell [Wed, 5 Apr 2023 00:12:42 +0000 (18:12 -0600)] 
Ignore doxygen src

2 years agoThe RADIUS module can only use RADIUS attributes for status-server
Alan T. DeKok [Tue, 4 Apr 2023 19:15:49 +0000 (15:15 -0400)] 
The RADIUS module can only use RADIUS attributes for status-server

2 years agoupdate for WITH_SASL build
Alan T. DeKok [Tue, 4 Apr 2023 19:08:30 +0000 (15:08 -0400)] 
update for WITH_SASL build

2 years agoRemove unused connection pool
Nick Porter [Tue, 4 Apr 2023 17:20:00 +0000 (18:20 +0100)] 
Remove unused connection pool

2 years agoUse correct debug level
Nick Porter [Tue, 4 Apr 2023 16:16:02 +0000 (17:16 +0100)] 
Use correct debug level

2 years agorename to "PROTO.encode"
Alan T. DeKok [Mon, 3 Apr 2023 20:53:07 +0000 (16:53 -0400)] 
rename to "PROTO.encode"

as most everything else is hiearchical based on protocol name

2 years agoNo need for non-async LDAP modify now
Nick Porter [Fri, 31 Mar 2023 17:17:46 +0000 (18:17 +0100)] 
No need for non-async LDAP modify now

2 years agoRework LDAP user_modify to use async queries
Nick Porter [Fri, 31 Mar 2023 12:13:10 +0000 (13:13 +0100)] 
Rework LDAP user_modify to use async queries

2 years agoRework mod_authorize_resume to use state, group and profile async lookups
Nick Porter [Tue, 28 Mar 2023 13:51:27 +0000 (14:51 +0100)] 
Rework mod_authorize_resume to use state, group and profile async lookups

2 years agoRework LDAP profile lookup to use async queries
Nick Porter [Thu, 30 Mar 2023 18:41:19 +0000 (19:41 +0100)] 
Rework LDAP profile lookup to use async queries

2 years agoRework rlm_ldap_cacheable_groupobj() to use async queries
Nick Porter [Tue, 28 Mar 2023 13:40:56 +0000 (14:40 +0100)] 
Rework rlm_ldap_cacheable_groupobj() to use async queries

2 years agoRework rlm_ldap_cacheable_userobj() to use async lookups
Nick Porter [Tue, 28 Mar 2023 13:33:56 +0000 (14:33 +0100)] 
Rework rlm_ldap_cacheable_userobj() to use async lookups

2 years agoCreate async functions to convert group DNs to names
Nick Porter [Tue, 28 Mar 2023 13:16:38 +0000 (14:16 +0100)] 
Create async functions to convert group DNs to names

The sync version is still needed for LDAP-Group pair cmp magic at
present.

2 years agoRe-work group name to DN lookup to be async
Nick Porter [Tue, 28 Mar 2023 13:06:15 +0000 (14:06 +0100)] 
Re-work group name to DN lookup to be async

2 years agoAdd context for resolving group membership from user object
Nick Porter [Tue, 28 Mar 2023 13:06:43 +0000 (14:06 +0100)] 
Add context for resolving group membership from user object

2 years agoSet a valid LOG_PREFIX
Nick Porter [Tue, 28 Mar 2023 11:31:59 +0000 (12:31 +0100)] 
Set a valid LOG_PREFIX

2 years agoRemove tmpl expansions now done by module environment
Nick Porter [Wed, 22 Mar 2023 19:41:01 +0000 (19:41 +0000)] 
Remove tmpl expansions now done by module environment

2 years agoUse module environment in rlm_ldap_map_profile
Nick Porter [Tue, 28 Mar 2023 13:52:17 +0000 (14:52 +0100)] 
Use module environment in rlm_ldap_map_profile

2 years agoMake SASL binds work again for user auth
Nick Porter [Wed, 22 Mar 2023 19:39:55 +0000 (19:39 +0000)] 
Make SASL binds work again for user auth

2 years agoAdd fr_ldap_sasl_bind_auth_async and supporting functions
Nick Porter [Wed, 22 Mar 2023 19:37:03 +0000 (19:37 +0000)] 
Add fr_ldap_sasl_bind_auth_async and supporting functions

2 years agoAllow for SASL bind ctx in LDAP auth bind ctx
Nick Porter [Wed, 22 Mar 2023 14:52:19 +0000 (14:52 +0000)] 
Allow for SASL bind ctx in LDAP auth bind ctx

2 years agoAdd state to LDAP authorization ctx
Nick Porter [Tue, 28 Mar 2023 11:19:04 +0000 (12:19 +0100)] 
Add state to LDAP authorization ctx

To track progress through multiple async LDAP queries

2 years agoUse async lookup of user DN in rlm_ldap mod_authorize
Nick Porter [Wed, 21 Sep 2022 09:36:00 +0000 (10:36 +0100)] 
Use async lookup of user DN in rlm_ldap mod_authorize

2 years agoUse async user DN lookup in LDAP authentication
Nick Porter [Tue, 20 Sep 2022 16:47:20 +0000 (17:47 +0100)] 
Use async user DN lookup in LDAP authentication

2 years agoModule environment for rlm_ldap
Nick Porter [Wed, 22 Mar 2023 18:54:25 +0000 (18:54 +0000)] 
Module environment for rlm_ldap

2 years agoAdd macro for module env subsections
Nick Porter [Wed, 15 Mar 2023 14:54:15 +0000 (14:54 +0000)] 
Add macro for module env subsections

2 years agoMove include - function.h will be needed by most LDAP source
Nick Porter [Tue, 20 Sep 2022 16:38:23 +0000 (17:38 +0100)] 
Move include - function.h will be needed by most LDAP source

2 years agoAdd rlm_ldap_find_user_async() and supporting functions
Nick Porter [Tue, 20 Sep 2022 16:37:21 +0000 (17:37 +0100)] 
Add rlm_ldap_find_user_async() and supporting functions

2 years agoAdd rlm_find_user_dn_cached()
Nick Porter [Tue, 20 Sep 2022 16:35:43 +0000 (17:35 +0100)] 
Add rlm_find_user_dn_cached()

2 years agoCorrect return of fr_ldap_trunk_search and fr_ldap_trunk_modify
Nick Porter [Wed, 29 Mar 2023 18:19:33 +0000 (19:19 +0100)] 
Correct return of fr_ldap_trunk_search and fr_ldap_trunk_modify

It is the child function which yields (until everything becomes async at
which point this will get simplified)

2 years agoslab: Style guide says alloc functions should return the newly allocated structure...
Arran Cudbard-Bell [Tue, 4 Apr 2023 00:34:36 +0000 (18:34 -0600)] 
slab: Style guide says alloc functions should return the newly allocated structure unless they have complex failure conditions which slabs don't

https://wiki.freeradius.org/contributing/coding-standards#return-types_pointer

2 years agojlibtool: Fix minor warnings
Arran Cudbard-Bell [Mon, 3 Apr 2023 23:31:35 +0000 (17:31 -0600)] 
jlibtool: Fix minor warnings

2 years agoclangd: Ignore osmocom code in submodules
Arran Cudbard-Bell [Mon, 3 Apr 2023 23:09:00 +0000 (17:09 -0600)] 
clangd: Ignore osmocom code in submodules

2 years agoslab: Remove implicit fr_ prefix
Arran Cudbard-Bell [Mon, 3 Apr 2023 22:40:09 +0000 (16:40 -0600)] 
slab: Remove implicit fr_ prefix

Yes, the framework for creating slabs is in the util library, but the functions and types it produces may not be so should not have an implicit fr_ prefix.

2 years agocf_util: Add cf_log_perr_by_child
Arran Cudbard-Bell [Mon, 3 Apr 2023 22:19:55 +0000 (16:19 -0600)] 
cf_util: Add cf_log_perr_by_child

2 years agocf_util: Pass in copy of va_list not original va_list
Arran Cudbard-Bell [Mon, 3 Apr 2023 22:19:23 +0000 (16:19 -0600)] 
cf_util: Pass in copy of va_list not original va_list

2 years agorlm_exec: Various cleanups
Arran Cudbard-Bell [Mon, 3 Apr 2023 02:18:08 +0000 (20:18 -0600)] 
rlm_exec: Various cleanups

2 years agoAdd CONF_PARSER snippet for slabs
Arran Cudbard-Bell [Mon, 3 Apr 2023 02:11:43 +0000 (20:11 -0600)] 
Add CONF_PARSER snippet for slabs

2 years agoSimplify and document conf parser macros
Arran Cudbard-Bell [Mon, 3 Apr 2023 00:07:50 +0000 (18:07 -0600)] 
Simplify and document conf parser macros

2 years agoupdate code and add tests to allow a group on the RHS of edits
Alan T. DeKok [Mon, 3 Apr 2023 17:00:53 +0000 (13:00 -0400)] 
update code and add tests to allow a group on the RHS of edits

2 years agoexec: Fixup another config file
Arran Cudbard-Bell [Sun, 2 Apr 2023 19:49:55 +0000 (13:49 -0600)] 
exec: Fixup another config file

2 years agomodules: Bubble up errors so the server will refuse to start if there's a module...
Arran Cudbard-Bell [Sun, 2 Apr 2023 19:10:23 +0000 (13:10 -0600)] 
modules: Bubble up errors so the server will refuse to start if there's a module error

Decorate all the functions with "warn_unused_result" so this doesn't happen again.

2 years agoexec: Use conf parser to deal with input and output tmpl parsing
Arran Cudbard-Bell [Sun, 2 Apr 2023 18:19:33 +0000 (12:19 -0600)] 
exec: Use conf parser to deal with input and output tmpl parsing

2 years agoAnnotate intentional writes of const-qualified data (CID #1508484, #1517674) (#4872)
James Jones [Fri, 31 Mar 2023 22:03:53 +0000 (17:03 -0500)] 
Annotate intentional writes of const-qualified data (CID #1508484, #1517674) (#4872)

Certain members of fr_value_box_t and hence of fr_pair_t have
const-qualified type, so pair_init_from_da() and fr_value_box_init(),
which modify some of those members, coverity points them out.
(UNCONST() placates the compiler, but not coverity.)

The coverity primitives that one might think would apply here,
__coverity_write_buffer_{bytes, elements}__(), are said to relate
mostly to checkers unrelated to writes to const-qualified fields,
so we annotate.

2 years agoLGTM no longer used
Arran Cudbard-Bell [Fri, 31 Mar 2023 22:02:35 +0000 (16:02 -0600)] 
LGTM no longer used

2 years agofr_sbuff_out_bstrncpy_until(): call fr_sbuff_extend_lowat() with proper sbuff (#4873)
Max Khon [Fri, 31 Mar 2023 21:03:27 +0000 (04:03 +0700)] 
fr_sbuff_out_bstrncpy_until(): call fr_sbuff_extend_lowat() with proper sbuff (#4873)

2 years agoUse correct attribute type
Arran Cudbard-Bell [Thu, 30 Mar 2023 21:21:05 +0000 (15:21 -0600)] 
Use correct attribute type

2 years agoxlat: Always check registration rcode to keep coverity quiet
Arran Cudbard-Bell [Thu, 30 Mar 2023 20:43:31 +0000 (14:43 -0600)] 
xlat: Always check registration rcode to keep coverity quiet

2 years agoRemove what we believe to be unnecessary alloc_strlen annotations (#4949)
James Jones [Thu, 30 Mar 2023 15:52:16 +0000 (10:52 -0500)] 
Remove what we believe to be unnecessary alloc_strlen annotations (#4949)

1. Either coverity has changed or pen_buffer_as_file() has,
   because an essentially identical use of it isn't annotated
   and doesn't register a defect, so the annotaion can go.
2. The curl_escape() call now just passes 0 and lets the
   function itself call strlen(), so that annotation should
   be unneccessary.

2 years agoAdd IGNORE() macro to let us avoid some identical branch annotations (#4948)
James Jones [Thu, 30 Mar 2023 14:53:05 +0000 (09:53 -0500)] 
Add IGNORE() macro to let us avoid some identical branch annotations (#4948)

If the unused-return warning is set, gcc will complain even in the
presence of an explicit cast to void. This lets us avoid that warning
in an error handling case that would otherwise be written

if (cleanup() < 0) goto error;
goto error;

about which Coverity complains.

2 years agoclean up error messages for consistency
Alan T. DeKok [Tue, 28 Mar 2023 07:36:46 +0000 (16:36 +0900)] 
clean up error messages for consistency

2 years agoxlat: Move function setting overrides into xlat_func.c
Arran Cudbard-Bell [Thu, 30 Mar 2023 03:31:06 +0000 (21:31 -0600)] 
xlat: Move function setting overrides into xlat_func.c

2 years agoxlat: Add an internal flag for marking xlats as internal
Arran Cudbard-Bell [Thu, 30 Mar 2023 03:14:58 +0000 (21:14 -0600)] 
xlat: Add an internal flag for marking xlats as internal

2 years agoFix setting xlat flags in redundant
Arran Cudbard-Bell [Thu, 30 Mar 2023 00:31:45 +0000 (18:31 -0600)] 
Fix setting xlat flags in redundant

2 years agoAdd sigmask to xlat/module/func signal handler registration
Arran Cudbard-Bell [Thu, 30 Mar 2023 00:26:40 +0000 (18:26 -0600)] 
Add sigmask to xlat/module/func signal handler registration

2 years agoxlat: Rename xlat_register to xlat_func and give all functions a common prefix
Arran Cudbard-Bell [Wed, 29 Mar 2023 23:20:28 +0000 (17:20 -0600)] 
xlat: Rename xlat_register to xlat_func and give all functions a common prefix

2 years agoredundant xlat: Move to a separate source file
Arran Cudbard-Bell [Wed, 29 Mar 2023 22:56:01 +0000 (16:56 -0600)] 
redundant xlat: Move to a separate source file