]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
5 years agos/vp_map_t/map_t/g
Arran Cudbard-Bell [Sun, 1 Nov 2020 00:03:31 +0000 (19:03 -0500)] 
s/vp_map_t/map_t/g

5 years agoSimplify debugging
Arran Cudbard-Bell [Sat, 31 Oct 2020 23:57:58 +0000 (18:57 -0500)] 
Simplify debugging

5 years agoWeaken the loop tests
Arran Cudbard-Bell [Sat, 31 Oct 2020 18:10:48 +0000 (13:10 -0500)] 
Weaken the loop tests

5 years agoOnly push the section if we have something to execute
Arran Cudbard-Bell [Sat, 31 Oct 2020 17:39:40 +0000 (12:39 -0500)] 
Only push the section if we have something to execute

5 years agoAllow call to run with no children
Arran Cudbard-Bell [Sat, 31 Oct 2020 17:24:47 +0000 (12:24 -0500)] 
Allow call to run with no children

5 years agoFormatting
Arran Cudbard-Bell [Sat, 31 Oct 2020 17:24:18 +0000 (12:24 -0500)] 
Formatting

5 years agoFormatting
Arran Cudbard-Bell [Sat, 31 Oct 2020 16:41:21 +0000 (11:41 -0500)] 
Formatting

5 years agosubrequest instruction needs to be talloced
Arran Cudbard-Bell [Sat, 31 Oct 2020 16:19:31 +0000 (11:19 -0500)] 
subrequest instruction needs to be talloced

5 years agoCorrect test_dbuff_no_advance() (#3718)
James Jones [Sat, 31 Oct 2020 13:26:11 +0000 (08:26 -0500)] 
Correct test_dbuff_no_advance() (#3718)

fr_dbuff_end() just returns the end pointer; actually moving to
the end requires fr_dbuff_set_to_end().

5 years agounlang: Use unlang keyword specialisation structs instead of separate allocations
Arran Cudbard-Bell [Sat, 31 Oct 2020 04:32:18 +0000 (23:32 -0500)] 
unlang: Use unlang keyword specialisation structs instead of separate allocations

5 years agoTest that operations on a dbuff created with FR_DBUFF_NO_ADVANCE() don't affect its...
James Jones [Fri, 30 Oct 2020 21:23:52 +0000 (16:23 -0500)] 
Test that operations on a dbuff created with FR_DBUFF_NO_ADVANCE() don't affect its parent's position. (#3714)

5 years agorlm_python: Add comments for -frecord-gcc-switches #3693 (#3702)
Jorge Pereira [Fri, 30 Oct 2020 21:23:20 +0000 (18:23 -0300)] 
rlm_python: Add comments for -frecord-gcc-switches #3693 (#3702)

5 years agoadd descriptive error messages
Alan T. DeKok [Fri, 30 Oct 2020 15:09:28 +0000 (11:09 -0400)] 
add descriptive error messages

5 years agoremove filter from value_box
Alan T. DeKok [Fri, 30 Oct 2020 12:52:32 +0000 (08:52 -0400)] 
remove filter from value_box

5 years agoremove 'abinary' data type.
Alan T. DeKok [Fri, 30 Oct 2020 12:49:14 +0000 (08:49 -0400)] 
remove 'abinary' data type.

Document the changes.  Update the RADIUS encode / decode tests.

Remove FR_TYPE_ABINARY from everything.

5 years agoremove / fixup abinary tests
Alan T. DeKok [Fri, 30 Oct 2020 12:35:18 +0000 (08:35 -0400)] 
remove / fixup abinary tests

in preparation for moving "abinary" data type to "string",
and making it radius-specific

5 years agoupdate comments to match functionality
Alan T. DeKok [Fri, 30 Oct 2020 12:30:54 +0000 (08:30 -0400)] 
update comments to match functionality

left over from changed behavior in commit 323f9c88a3

5 years agoremove debug stuff :(
Alan T. DeKok [Fri, 30 Oct 2020 11:04:27 +0000 (07:04 -0400)] 
remove debug stuff :(

5 years agoFix issues with errors when a length is passed to pton functions
Arran Cudbard-Bell [Fri, 30 Oct 2020 02:26:34 +0000 (21:26 -0500)] 
Fix issues with errors when a length is passed to pton functions

5 years agoset the async flag as appropriate
Alan T. DeKok [Thu, 29 Oct 2020 18:44:27 +0000 (14:44 -0400)] 
set the async flag as appropriate

5 years agofix for async. left over from changed behavior in commit 323f9c88a3
Alan T. DeKok [Thu, 29 Oct 2020 18:29:06 +0000 (14:29 -0400)] 
fix for async.  left over from changed behavior in commit 323f9c88a3

5 years agoprint the correct quotes around FR_TYPE_TMPL, too
Alan T. DeKok [Thu, 29 Oct 2020 18:04:02 +0000 (14:04 -0400)] 
print the correct quotes around FR_TYPE_TMPL, too

5 years agono need to use public functions for internal values
Alan T. DeKok [Thu, 29 Oct 2020 18:00:05 +0000 (14:00 -0400)] 
no need to use public functions for internal values

we're already using internal values everywhere else in the parser

5 years agoconvert "header" to using tmpl
Alan T. DeKok [Thu, 29 Oct 2020 17:54:01 +0000 (13:54 -0400)] 
convert "header" to using tmpl

which now lets the header be taken from an attribute, if the
user so desires

5 years agoadd FR_TYPE_NON_BLOCKING
Alan T. DeKok [Thu, 29 Oct 2020 17:51:34 +0000 (13:51 -0400)] 
add FR_TYPE_NON_BLOCKING

for use with tmpl_eval().  We can mark configuration items as
allowing tmpls / xlats, BUT also mark them up with a requirement
for non-blocking operation.

This lets us convert much of the code to using tmpl_eval() instead
of xlat_eval().  At the same time, the admin is prevented from
breaking the server by using asychronous operations in places
which do not support them.

Once all of the callers of foo_eval() have been converted to
async, we can remove the FR_TYPE_NON_BLOCKING flag.

5 years agocorrect documentation and behavior
Alan T. DeKok [Thu, 29 Oct 2020 17:50:21 +0000 (13:50 -0400)] 
correct documentation and behavior

to match the name of the variable, and how all of the code
uses the variable

5 years agonow that abinary is a pointer, treat it as such
Alan T. DeKok [Thu, 29 Oct 2020 14:55:31 +0000 (10:55 -0400)] 
now that abinary is a pointer, treat it as such

5 years agocomment out abinary tests until they're fixed
Alan T. DeKok [Thu, 29 Oct 2020 14:53:10 +0000 (10:53 -0400)] 
comment out abinary tests until they're fixed

5 years agoprint out string values with correct quotes and escaping
Alan T. DeKok [Thu, 29 Oct 2020 14:44:07 +0000 (10:44 -0400)] 
print out string values with correct quotes and escaping

so that the output is as close as possible to the input

5 years agono need to quote the string
Alan T. DeKok [Thu, 29 Oct 2020 14:27:38 +0000 (10:27 -0400)] 
no need to quote the string

5 years agouse cp->attr internally, instead of cf_pair_attr(cp)
Alan T. DeKok [Thu, 29 Oct 2020 14:16:50 +0000 (10:16 -0400)] 
use cp->attr internally, instead of cf_pair_attr(cp)

and clean up debug printing for FR_TYPE_STRING

5 years agowe cannot call fr_value_box_from_str() on any structural types
Alan T. DeKok [Thu, 29 Oct 2020 13:52:56 +0000 (09:52 -0400)] 
we cannot call fr_value_box_from_str() on any structural types

5 years agoWe cannot assign hex strings to attributes of type "vsa"
Alan T. DeKok [Thu, 29 Oct 2020 12:56:35 +0000 (08:56 -0400)] 
We cannot assign hex strings to attributes of type "vsa"

Fix the test so that it has the correct error message

5 years agoremove unused macros
Alan T. DeKok [Wed, 28 Oct 2020 14:13:32 +0000 (10:13 -0400)] 
remove unused macros

5 years agoFix pair type checks to allow all nested types not just FR_TYPE_GROUP
Arran Cudbard-Bell [Wed, 28 Oct 2020 15:28:58 +0000 (09:28 -0600)] 
Fix pair type checks to allow all nested types not just FR_TYPE_GROUP

5 years agosbuff: Set const depending on start pointer
Arran Cudbard-Bell [Wed, 28 Oct 2020 14:23:42 +0000 (08:23 -0600)] 
sbuff: Set const depending on start pointer

5 years agopass the value_box directly to print_abinary
Alan T. DeKok [Wed, 28 Oct 2020 14:01:13 +0000 (10:01 -0400)] 
pass the value_box directly to print_abinary

5 years agomove print_abinary() to use sbuff internally
Alan T. DeKok [Wed, 28 Oct 2020 13:45:21 +0000 (09:45 -0400)] 
move print_abinary() to use sbuff internally

5 years agocleanup ascend filters
Alan T. DeKok [Wed, 28 Oct 2020 12:22:56 +0000 (08:22 -0400)] 
cleanup ascend filters

make it a bit more forgiving with respect to input size, by
requiring only as much data as we need.  Instead of mandating it
is 32 octets.

Remove unused definitions.  Convert the union to anonymous.

5 years agoFix talloc ctx for group attributes
Arran Cudbard-Bell [Tue, 27 Oct 2020 20:10:45 +0000 (14:10 -0600)] 
Fix talloc ctx for group attributes

5 years agoAdd nested subrequest tests
Arran Cudbard-Bell [Tue, 27 Oct 2020 20:07:39 +0000 (14:07 -0600)] 
Add nested subrequest tests

5 years agoAdd functions and macros to read values and copy bytes from dbuffs (#3709)
James Jones [Tue, 27 Oct 2020 19:07:37 +0000 (14:07 -0500)] 
Add functions and macros to read values and copy bytes from dbuffs (#3709)

5 years agoparse Juniper filters with IPv6 addresses
Alan T. DeKok [Tue, 27 Oct 2020 16:55:36 +0000 (12:55 -0400)] 
parse Juniper filters with IPv6 addresses

5 years agomove ascend filters to pointer, and fix use of vb_length
Alan T. DeKok [Tue, 27 Oct 2020 15:46:19 +0000 (11:46 -0400)] 
move ascend filters to pointer, and fix use of vb_length

vb_length _was_ inside of the union for variable-sized types,
but the code also set it for fixed-size types.  Only the size
of the ascend filter prevented various over-writes.

changing ascend filter to pointer instead of an array highlighted
this issue, and causes us to move the "length" field out of the
union in order to stop the over-write

5 years agoabstract datum.length to vb_length
Alan T. DeKok [Tue, 27 Oct 2020 15:33:06 +0000 (11:33 -0400)] 
abstract datum.length to vb_length

5 years agoabstract datum.length
Alan T. DeKok [Tue, 27 Oct 2020 15:30:32 +0000 (11:30 -0400)] 
abstract datum.length

5 years agouse vb_length instead of mangling things manually
Alan T. DeKok [Tue, 27 Oct 2020 15:26:36 +0000 (11:26 -0400)] 
use vb_length instead of mangling things manually

5 years agoadd more tests for ascend data filters
Alan T. DeKok [Tue, 27 Oct 2020 15:11:28 +0000 (11:11 -0400)] 
add more tests for ascend data filters

5 years agoCorrect the fr_net_to_int*() functions
James Jones [Mon, 26 Oct 2020 21:54:39 +0000 (16:54 -0500)] 
Correct the fr_net_to_int*() functions

5 years agouse fr_cursor_tail() instead of vp->next
Alan T. DeKok [Tue, 27 Oct 2020 14:44:21 +0000 (10:44 -0400)] 
use fr_cursor_tail() instead of vp->next

5 years agomove VMPS to using cursors, instead of VALUE_PAIR**
Alan T. DeKok [Tue, 27 Oct 2020 13:30:00 +0000 (09:30 -0400)] 
move VMPS to using cursors, instead of VALUE_PAIR**

5 years agomore xlat tests
Alan T. DeKok [Sun, 25 Oct 2020 17:07:06 +0000 (13:07 -0400)] 
more xlat tests

5 years agoFix vendor specific tests
Arran Cudbard-Bell [Sun, 25 Oct 2020 15:13:54 +0000 (09:13 -0600)] 
Fix vendor specific tests

5 years agoadd tests for \%
Alan T. DeKok [Sun, 25 Oct 2020 13:36:42 +0000 (09:36 -0400)] 
add tests for \%

which aren't correct right now, but the tests pass...

5 years agoset server_cs, too
Alan T. DeKok [Sun, 25 Oct 2020 13:36:11 +0000 (09:36 -0400)] 
set server_cs, too

5 years agoFix programatically generated subrequests
Arran Cudbard-Bell [Sat, 24 Oct 2020 17:29:49 +0000 (12:29 -0500)] 
Fix programatically generated subrequests

5 years agoAdd missing vendor attribute
Arran Cudbard-Bell [Sat, 24 Oct 2020 17:07:06 +0000 (12:07 -0500)] 
Add missing vendor attribute

5 years agoupdate to match new behavior
Alan T. DeKok [Sat, 24 Oct 2020 13:32:06 +0000 (09:32 -0400)] 
update to match new behavior

5 years agos/REQUEST */request_t */g
Arran Cudbard-Bell [Sat, 24 Oct 2020 03:15:45 +0000 (22:15 -0500)] 
s/REQUEST */request_t */g

REMOVE ANOTHER LOUD TYPE

5 years agos/VALUE_PAIR/fr_pair_t/g
Arran Cudbard-Bell [Fri, 23 Oct 2020 21:59:24 +0000 (16:59 -0500)] 
s/VALUE_PAIR/fr_pair_t/g

FIX ONE OF THE LAST ALL CAPS TYPES IN THE SERVER

5 years agoShut up clang scan (#3705)
Jorge Pereira [Fri, 23 Oct 2020 20:57:11 +0000 (17:57 -0300)] 
Shut up clang scan (#3705)

5 years agoQuiet clang scan
Arran Cudbard-Bell [Fri, 23 Oct 2020 20:38:40 +0000 (15:38 -0500)] 
Quiet clang scan

5 years agoAdd subrequest src/dst evaluation code
Arran Cudbard-Bell [Fri, 23 Oct 2020 20:33:48 +0000 (15:33 -0500)] 
Add subrequest src/dst evaluation code

This allows us to produce nested attributes in unlang

5 years agoDon't assume the first ref is unparsed
Arran Cudbard-Bell [Fri, 23 Oct 2020 20:32:06 +0000 (15:32 -0500)] 
Don't assume the first ref is unparsed

5 years agoRevert "Write bytes as hex"
Arran Cudbard-Bell [Fri, 23 Oct 2020 20:16:21 +0000 (15:16 -0500)] 
Revert "Write bytes as hex"

This reverts commit 4b3623661c930200a95cc9c2acbf757763863408.

5 years agoFix filtering functions to work with nested attributes
Arran Cudbard-Bell [Fri, 23 Oct 2020 20:13:06 +0000 (15:13 -0500)] 
Fix filtering functions to work with nested attributes

5 years ago\n is EOF, too
Alan T. DeKok [Fri, 23 Oct 2020 20:11:57 +0000 (16:11 -0400)] 
\n is EOF, too

5 years agoWrite bytes as hex
Arran Cudbard-Bell [Fri, 23 Oct 2020 19:15:39 +0000 (14:15 -0500)] 
Write bytes as hex

5 years agoFix typo in process_subrequest
Arran Cudbard-Bell [Fri, 23 Oct 2020 18:40:28 +0000 (13:40 -0500)] 
Fix typo in process_subrequest

5 years agoallow unlang in subrequests
Alan T. DeKok [Fri, 23 Oct 2020 16:28:05 +0000 (12:28 -0400)] 
allow unlang in subrequests

5 years agowhoops, let's initialize everything
Alan T. DeKok [Fri, 23 Oct 2020 16:26:29 +0000 (12:26 -0400)] 
whoops, let's initialize everything

5 years agoreword process_subrequest() to take many arguments
Alan T. DeKok [Fri, 23 Oct 2020 16:19:01 +0000 (12:19 -0400)] 
reword process_subrequest() to take many arguments

5 years agoStart of process subrequests
Arran Cudbard-Bell [Fri, 23 Oct 2020 15:29:32 +0000 (10:29 -0500)] 
Start of process subrequests

5 years agoshut up clang scan. Fixes #3704
Alan T. DeKok [Fri, 23 Oct 2020 15:13:21 +0000 (11:13 -0400)] 
shut up clang scan.  Fixes #3704

5 years agopass original packet, not a crappy offset from a vector
Alan T. DeKok [Fri, 23 Oct 2020 14:11:32 +0000 (10:11 -0400)] 
pass original packet, not a crappy offset from a vector

5 years agoDefault to fr_value_box_to_network
Arran Cudbard-Bell [Fri, 23 Oct 2020 14:04:07 +0000 (09:04 -0500)] 
Default to fr_value_box_to_network

5 years agoWe don't need to list all the valid types for RADIUS either,
Arran Cudbard-Bell [Fri, 23 Oct 2020 13:56:44 +0000 (08:56 -0500)] 
We don't need to list all the valid types for RADIUS either,

It likely makes the code slower as well... switches aren't magic, it's up to the compiler to implement them and it may well choose a binary search for this number of elements.

5 years agodon't mangle things until AFTER we've freed the children
Alan T. DeKok [Fri, 23 Oct 2020 13:59:12 +0000 (09:59 -0400)] 
don't mangle things until AFTER we've freed the children

5 years agorecurse into all children for structural types
Alan T. DeKok [Fri, 23 Oct 2020 13:43:12 +0000 (09:43 -0400)] 
recurse into all children for structural types

5 years agothere's no reason to specify the full path of the files
Alan T. DeKok [Fri, 23 Oct 2020 13:24:04 +0000 (09:24 -0400)] 
there's no reason to specify the full path of the files

5 years agohoist tag code earlier, so we don't need to talloc_steal()
Alan T. DeKok [Fri, 23 Oct 2020 13:18:42 +0000 (09:18 -0400)] 
hoist tag code earlier, so we don't need to talloc_steal()

5 years agofr_value_box_to_network already has an "encodable" check
Arran Cudbard-Bell [Fri, 23 Oct 2020 13:41:18 +0000 (08:41 -0500)] 
fr_value_box_to_network already has an "encodable" check

There's no reason to restrict protocols to a subset of types when there are vendor specific attributes involved...

5 years agoSimpler function
Arran Cudbard-Bell [Fri, 23 Oct 2020 13:24:47 +0000 (08:24 -0500)] 
Simpler function

5 years agomake packet_ctx.vector[16] instead of a pointer. Fixes #3703
Alan T. DeKok [Fri, 23 Oct 2020 12:40:54 +0000 (08:40 -0400)] 
make packet_ctx.vector[16] instead of a pointer.  Fixes #3703

5 years agoMake sure we never merge flags by mistake
Matthew Newton [Fri, 23 Oct 2020 11:47:47 +0000 (12:47 +0100)] 
Make sure we never merge flags by mistake

5 years agoPass all standard types to fr_value_box_from_network
Arran Cudbard-Bell [Fri, 23 Oct 2020 03:22:14 +0000 (22:22 -0500)] 
Pass all standard types to fr_value_box_from_network

5 years agoDon't init the boxes twice
Arran Cudbard-Bell [Fri, 23 Oct 2020 03:15:19 +0000 (22:15 -0500)] 
Don't init the boxes twice

5 years agofixup option/len macros in DHCPv6
Arran Cudbard-Bell [Fri, 23 Oct 2020 03:11:15 +0000 (22:11 -0500)] 
fixup option/len macros in DHCPv6

5 years agoRevert "minor tweaks"
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:55:50 +0000 (21:55 -0500)] 
Revert "minor tweaks"

This reverts commit 44cb7e539f7e52199a30318be980fc2752d2f8f4.

5 years agopair: Pairs should free their children when they're freed
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:39:50 +0000 (21:39 -0500)] 
pair: Pairs should free their children when they're freed

5 years agoWhitespace
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:38:58 +0000 (21:38 -0500)] 
Whitespace

5 years agoMark certain attribute references as 'resolve_only'
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:38:44 +0000 (21:38 -0500)] 
Mark certain attribute references as 'resolve_only'

This means when we're attempting to build out structures we know that if we didn't manage to resolve the ar using the existing pair tree, we need to abort.

5 years agoRemove white space...
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:34:30 +0000 (21:34 -0500)] 
Remove white space...

5 years agoTypo
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:34:12 +0000 (21:34 -0500)] 
Typo

5 years agoUnused
Arran Cudbard-Bell [Fri, 23 Oct 2020 02:32:40 +0000 (21:32 -0500)] 
Unused

5 years agocomment why the option is removed
Matthew Newton [Thu, 22 Oct 2020 16:32:28 +0000 (17:32 +0100)] 
comment why the option is removed

5 years agouse "text" instead of "varchar".
Alan T. DeKok [Thu, 22 Oct 2020 14:37:02 +0000 (10:37 -0400)] 
use "text" instead of "varchar".

there's no reason to fix these fields at a small size

5 years agorlm_python: Anchor with a space so we don't mangle the middle of flags
Matthew Newton [Thu, 22 Oct 2020 09:27:43 +0000 (10:27 +0100)] 
rlm_python: Anchor with a space so we don't mangle the middle of flags

See #3693

5 years agorlm_smtp with unit test (#3547)
Stephen Blackwell [Thu, 22 Oct 2020 00:18:09 +0000 (20:18 -0400)] 
rlm_smtp with unit test (#3547)

* rlm_smtp with unit test

* Fix typo, remove extraneous info.

Co-authored-by: Arran Cudbard-Bell <a.cudbardb@freeradius.org>
5 years agoMake the underlying dbuff version of fr_radius_encode_pair() visible
James Jones [Wed, 7 Oct 2020 22:12:26 +0000 (17:12 -0500)] 
Make the underlying dbuff version of fr_radius_encode_pair() visible

This makes it possible to switch users of fr_radius_encode_pair()
over to dbuffs individually rather than all at once.