]>
git.ipfire.org Git - thirdparty/freeradius-server.git/log
Arran Cudbard-Bell [Sun, 24 May 2020 14:45:32 +0000 (09:45 -0500)]
dns: Use box initialiser instead of doing it manually
Alan T. DeKok [Sun, 24 May 2020 13:23:31 +0000 (09:23 -0400)]
concatenate multiple results from child. Fixes #3466
Alan T. DeKok [Sun, 24 May 2020 12:53:16 +0000 (08:53 -0400)]
add test for things after the expansion
Alan T. DeKok [Sun, 24 May 2020 12:12:57 +0000 (08:12 -0400)]
initialize heap_id
Alan T. DeKok [Sun, 24 May 2020 12:11:20 +0000 (08:11 -0400)]
allow adding to an empty heap when heap_id==0
Alan T. DeKok [Sat, 23 May 2020 22:25:30 +0000 (18:25 -0400)]
initialize heap_id, and don't assert on cleanup
if we can't insert the ev into the heap, then _event_timer_free()
shouldn't assert that it is in the heap. We fix this by just
setting the talloc destructor to NULL.
Alan T. DeKok [Sat, 23 May 2020 22:02:35 +0000 (18:02 -0400)]
use struct initializers instead of manually setting fields
as this should ensure the other fields are NULL
Alan T. DeKok [Sat, 23 May 2020 20:18:55 +0000 (16:18 -0400)]
typo
Alan T. DeKok [Sat, 23 May 2020 18:57:29 +0000 (14:57 -0400)]
fix build rules
OUTPUT is only defined by $(eval $(call TEST_BOOTSTRAP)), so it
can't be used before that function is called. And it can't be
used if that function isn't called.
Hoist TEST definition to a place where it's available, even if
we're not running the tests.
Arran Cudbard-Bell [Sat, 23 May 2020 19:00:35 +0000 (14:00 -0500)]
tmpl: Fix direct box value assignments (for most cases)
Arran Cudbard-Bell [Sat, 23 May 2020 18:59:19 +0000 (13:59 -0500)]
conf: Initialise temporary boxes correctly/completely
Arran Cudbard-Bell [Sat, 23 May 2020 18:54:09 +0000 (13:54 -0500)]
value: Ensure talloc buffer types are always explicitly set
Arran Cudbard-Bell [Sat, 23 May 2020 17:16:21 +0000 (12:16 -0500)]
redis: Use boxing macros, and add support for 64bit signed types
Arran Cudbard-Bell [Sat, 23 May 2020 17:12:31 +0000 (12:12 -0500)]
ldap: Don't modify boxes directly, use assignment functions
Arran Cudbard-Bell [Sat, 23 May 2020 17:11:57 +0000 (12:11 -0500)]
cache-redis: Use value box assignment functions
Arran Cudbard-Bell [Sat, 23 May 2020 17:11:32 +0000 (12:11 -0500)]
cache: Remove unused type assignment
Arran Cudbard-Bell [Sat, 23 May 2020 17:11:20 +0000 (12:11 -0500)]
rlm_redis_ippool: Don't touch boxes directly, use assignment functions
Arran Cudbard-Bell [Sat, 23 May 2020 17:09:18 +0000 (12:09 -0500)]
rest: Don't touch intermediary boxes or martialed boxes directly, use the assignment functions
Arran Cudbard-Bell [Sat, 23 May 2020 17:04:28 +0000 (12:04 -0500)]
value: Allow bools to be boxed
Arran Cudbard-Bell [Sat, 23 May 2020 17:03:15 +0000 (12:03 -0500)]
json: Use VB boxing macros instead of doing assignment manually
Arran Cudbard-Bell [Sat, 23 May 2020 17:02:38 +0000 (12:02 -0500)]
Fix _CONST macro position in dict.h
Arran Cudbard-Bell [Sat, 23 May 2020 16:59:50 +0000 (11:59 -0500)]
more *cpy to *dup
Arran Cudbard-Bell [Sat, 23 May 2020 16:53:37 +0000 (11:53 -0500)]
global: Correct function names, should be *dup not *cpy as we allocate memory
Arran Cudbard-Bell [Sat, 23 May 2020 16:47:03 +0000 (11:47 -0500)]
pair: Remove more code by using the value box assignment functions instead of re-implementing them
Arran Cudbard-Bell [Sat, 23 May 2020 16:34:37 +0000 (11:34 -0500)]
pair: Make fr_pair_value_snprintf use our interanl fr_vasprintf function via the value box API
Arran Cudbard-Bell [Sat, 23 May 2020 16:33:58 +0000 (11:33 -0500)]
print: Fix the talloc buffer type emittted by fr_vasprintf
Arran Cudbard-Bell [Sat, 23 May 2020 16:07:47 +0000 (11:07 -0500)]
Fix const issues and initialisation issues in pair_legacy.c
Arran Cudbard-Bell [Sat, 23 May 2020 15:49:48 +0000 (10:49 -0500)]
Temporarily revert changes to remove strsteal functions
Alan T. DeKok [Sat, 23 May 2020 14:02:29 +0000 (10:02 -0400)]
remove fr_value_box_bstrsteal() and fr_value_box_bstrnsteal()
they are no longer used, needed, or wanted.
Alan T. DeKok [Sat, 23 May 2020 14:00:21 +0000 (10:00 -0400)]
switch to fr_value_box_bstrassign()
Alan T. DeKok [Sat, 23 May 2020 13:31:57 +0000 (09:31 -0400)]
switch to fr_value_box_bstrassign()
Alan T. DeKok [Sat, 23 May 2020 13:30:54 +0000 (09:30 -0400)]
switch to fr_value_box_bstrassign()
Alan T. DeKok [Sat, 23 May 2020 12:41:49 +0000 (08:41 -0400)]
allow for text immediately after expansion. Fixes #3466
Sometimes less code is better
Alan T. DeKok [Sat, 23 May 2020 12:30:12 +0000 (08:30 -0400)]
use fr_value_box_bstrassign()
which can be done with only minimal code rearrangements
Alan T. DeKok [Sat, 23 May 2020 12:28:35 +0000 (08:28 -0400)]
add fr_value_box_bstrassign()
which avoids talloc_steal(). That function is O(n) in the
number of chunks in the parent's talloc ctx.
Alan T. DeKok [Sat, 23 May 2020 02:04:14 +0000 (22:04 -0400)]
move GNU make magic && shell scripts to more GNU make magic
the rules to create $(OUTPUT)/%.attrs didn't work. This failure
is shown by the fact that the make file has 3 different ways
to produce the same files:
* a set of BOOTSTRAP variables
* $(OUTPUT)/%.attrs: %(DIR)/%.attrs rule
* shell script if / cp rules
So we delete all 3 methods, and replace them with a simple 'cp',
along with a $(if) and $(wildcard), to select files A or B.
We would _like_ to do:
$(OUTPUT)/%: $(DIR)/% $(OUTPUT)/%.attrs
except GNU make it too stupid to allow that.
Alan T. DeKok [Fri, 22 May 2020 16:06:46 +0000 (12:06 -0400)]
remove one more bstrsteal by reordering code
Alan T. DeKok [Fri, 22 May 2020 15:55:26 +0000 (11:55 -0400)]
remove one more use of talloc_steal()
along with getting rid of snprintf.
Which ends up being simpler and less code
Arran Cudbard-Bell [Fri, 22 May 2020 21:22:22 +0000 (16:22 -0500)]
Reduce scope of ret closes #3465
Arran Cudbard-Bell [Fri, 22 May 2020 16:57:05 +0000 (11:57 -0500)]
May as well skip the strlen
Arran Cudbard-Bell [Fri, 22 May 2020 16:55:04 +0000 (11:55 -0500)]
xlat: Use assignment functions when setting vb values, closes #3464
Arran Cudbard-Bell [Fri, 22 May 2020 16:05:33 +0000 (11:05 -0500)]
event: More detailed asserts
Arran Cudbard-Bell [Fri, 22 May 2020 15:57:07 +0000 (10:57 -0500)]
event: remove redundant assert in _event_timer_free
The heap will catch this condition and return an error, along with a bunch of other invalid heap_id issues
Arran Cudbard-Bell [Fri, 22 May 2020 15:54:32 +0000 (10:54 -0500)]
heap: Remove duplicate/redundant asserts, and quiet clang scan
Alan T. DeKok [Fri, 22 May 2020 14:24:05 +0000 (10:24 -0400)]
if we remove something from the heap, it must be in the heap.
Alan T. DeKok [Fri, 22 May 2020 14:19:46 +0000 (10:19 -0400)]
fix typo
Alan T. DeKok [Fri, 22 May 2020 13:34:33 +0000 (09:34 -0400)]
if it's not in the heap, don't extract it
Alan T. DeKok [Fri, 22 May 2020 13:33:47 +0000 (09:33 -0400)]
don't extract things which aren't in the heap
Alan T. DeKok [Thu, 21 May 2020 20:41:28 +0000 (16:41 -0400)]
the timer is frame-local
when the frame goes away, so should the timer.
Alan T. DeKok [Thu, 21 May 2020 19:00:16 +0000 (15:00 -0400)]
tests are good
Alan T. DeKok [Thu, 21 May 2020 18:55:40 +0000 (14:55 -0400)]
make functions take explicit TALLOC_CTX
which avoids talloc_parent()
Arran Cudbard-Bell [Thu, 21 May 2020 14:47:38 +0000 (09:47 -0500)]
xlat: Make %{pack:} work on boxes not attribute references
Arran Cudbard-Bell [Thu, 21 May 2020 14:19:21 +0000 (09:19 -0500)]
log: There are many types of error
Arran Cudbard-Bell [Thu, 21 May 2020 14:02:58 +0000 (09:02 -0500)]
heap: Shutup pedantic compiler
Alan T. DeKok [Thu, 21 May 2020 12:23:30 +0000 (08:23 -0400)]
allow attributes of type "struct" with flag "internal"
These attributes don't do anything right now, so they can't
be problematic.
The hope is to allow structs for pack / unpack xlats
Alan T. DeKok [Thu, 21 May 2020 12:14:24 +0000 (08:14 -0400)]
document %{pack:...}
Arran Cudbard-Bell [Thu, 21 May 2020 00:45:33 +0000 (19:45 -0500)]
heap: Cleanup get/set code
Arran Cudbard-Bell [Wed, 20 May 2020 22:17:15 +0000 (17:17 -0500)]
global: Fixup incorrect uses of fr_strerror
Arran Cudbard-Bell [Wed, 20 May 2020 20:56:27 +0000 (15:56 -0500)]
talloc: Extend link_ctx functionality so that we can run custom destructors
Alan T. DeKok [Wed, 20 May 2020 23:04:15 +0000 (19:04 -0400)]
re-add test.radclient
Alan T. DeKok [Wed, 20 May 2020 23:03:33 +0000 (19:03 -0400)]
ensure that the heap_id is always -1 before insert
Alan T. DeKok [Wed, 20 May 2020 20:45:03 +0000 (16:45 -0400)]
more "shut up clang analyzer"
Alan T. DeKok [Wed, 20 May 2020 20:39:08 +0000 (16:39 -0400)]
remove debugging messages
Alan T. DeKok [Wed, 20 May 2020 20:37:23 +0000 (16:37 -0400)]
radclient tests fail for unknown reasons.
disabling so that we can get travis back to a working state.
if a number of things fail in travis, they should be disabled until
such time as they're fixed. Otherwise new code may introduce new
travis failures, which won't be seen until the other issues are
fixed.
Alan T. DeKok [Wed, 20 May 2020 20:34:32 +0000 (16:34 -0400)]
remove debugging line
Alan T. DeKok [Wed, 20 May 2020 20:33:09 +0000 (16:33 -0400)]
add %{pack:&Attr-foo &Attr-bar} as a parallel to %{unpack:...}
Alan T. DeKok [Wed, 20 May 2020 20:09:26 +0000 (16:09 -0400)]
typo
Alan T. DeKok [Wed, 20 May 2020 19:34:09 +0000 (15:34 -0400)]
suppress things which are known to not work under travis
Alan T. DeKok [Wed, 20 May 2020 18:51:24 +0000 (14:51 -0400)]
request cap_net_raw on Linux
Alan T. DeKok [Wed, 20 May 2020 18:13:27 +0000 (14:13 -0400)]
print out strerror from thread instantiate
so that we don't need to do it in each module
Alan T. DeKok [Wed, 20 May 2020 17:04:10 +0000 (13:04 -0400)]
asserts to keep clang scan happy
Arran Cudbard-Bell [Wed, 20 May 2020 16:40:35 +0000 (11:40 -0500)]
rlm_rest should depend on libfreeradius-curl
Alan T. DeKok [Wed, 20 May 2020 16:19:16 +0000 (12:19 -0400)]
tests for ICMP
Alan T. DeKok [Wed, 20 May 2020 16:25:06 +0000 (12:25 -0400)]
allow unit_test_module to use the parent event list
so that it can run modules which yield
Alan T. DeKok [Wed, 20 May 2020 16:20:01 +0000 (12:20 -0400)]
try to run tests in alphabetical order, instead of random order
Arran Cudbard-Bell [Wed, 20 May 2020 16:04:34 +0000 (11:04 -0500)]
s/create/alloc/
Alan T. DeKok [Wed, 20 May 2020 15:29:49 +0000 (11:29 -0400)]
also check that node 0 isn't already in the heap
Alan T. DeKok [Wed, 20 May 2020 15:28:08 +0000 (11:28 -0400)]
remove redundant code
Alan T. DeKok [Wed, 20 May 2020 15:21:21 +0000 (11:21 -0400)]
more sanity checking
on extract, we set heap_id = -1
on insert, we check that heap_id == -1 or 0
0 is still technically wrong, but we allow it as a special case
for nodes allocated via talloc_zero(). And changing the heap code
to start at offset 1 instead of 0, will require many changes.
The current code is a good compromise
Arran Cudbard-Bell [Wed, 20 May 2020 14:46:48 +0000 (09:46 -0500)]
Unused
Alan T. DeKok [Tue, 19 May 2020 23:21:44 +0000 (19:21 -0400)]
there's no reason to have `test` depend on the binaries
each individual test should have its own dependency on the
binaries that it needs.
Arran Cudbard-Bell [Tue, 19 May 2020 23:51:42 +0000 (18:51 -0500)]
dict: More detail in lineage assert
Arran Cudbard-Bell [Tue, 19 May 2020 23:24:28 +0000 (18:24 -0500)]
Undo some assertion changes in proto_radius_udp.c
Arran Cudbard-Bell [Tue, 19 May 2020 23:18:59 +0000 (18:18 -0500)]
stop radsniff tests running until they work...
Arran Cudbard-Bell [Tue, 19 May 2020 23:12:56 +0000 (18:12 -0500)]
shutup clang scan
Matthew Newton [Tue, 19 May 2020 23:06:47 +0000 (00:06 +0100)]
allow apt https installs in jenkins travis dockerfile
Matthew Newton [Tue, 19 May 2020 23:06:06 +0000 (00:06 +0100)]
make the jenkins travis dockerfile readable
Alan T. DeKok [Tue, 19 May 2020 23:00:26 +0000 (19:00 -0400)]
remove more unused variables
Alan T. DeKok [Tue, 19 May 2020 22:54:56 +0000 (18:54 -0400)]
cleanups and fixes
- just use "counter" to loop packets
- don't create per-request data / ident. These should be
per-thread. Checking them per thread allows us to avoid
rbtree lookups when the packets aren't for us
- clean up other debugging
tested for IPv4 and IPv6
Arran Cudbard-Bell [Tue, 19 May 2020 22:47:45 +0000 (17:47 -0500)]
tmpl: Fix tmpl_attr_resolve_unparsed so it doesn't trash num or tag
...and works for nested attributes correctly.
Jorge Pereira [Tue, 19 May 2020 22:31:26 +0000 (19:31 -0300)]
remove unused variable
Arran Cudbard-Bell [Tue, 19 May 2020 22:20:41 +0000 (17:20 -0500)]
event: Fix assert msg
Jorge Pereira [Tue, 19 May 2020 01:18:16 +0000 (22:18 -0300)]
rlm_icmp: Fix icmp6 support
The documentation says that sockets() created with IPPROTO_ICMPV6 will receive packets
without the IPv6 header nor IPv6 extension headers.
In this case, we don't have a way to extract the source address. That is the reason for
we are using the ICMP requests 'ident' field instead of the IP address.
Jorge Pereira [Mon, 18 May 2020 21:46:53 +0000 (18:46 -0300)]
rlm_icmp: Print the icmp-reply payload
Jorge Pereira [Mon, 18 May 2020 20:14:50 +0000 (17:14 -0300)]
rlm_icmp: Just keep 'ping6'
Arran Cudbard-Bell [Tue, 19 May 2020 21:53:39 +0000 (16:53 -0500)]
cond: Print operands correctly
Alan T. DeKok [Tue, 19 May 2020 21:02:39 +0000 (17:02 -0400)]
remove unused variable
Arran Cudbard-Bell [Tue, 19 May 2020 20:16:26 +0000 (15:16 -0500)]
sranddev() is FreeBSD only
Arran Cudbard-Bell [Tue, 19 May 2020 18:30:28 +0000 (13:30 -0500)]
remove redundant function
Arran Cudbard-Bell [Tue, 19 May 2020 14:10:37 +0000 (09:10 -0500)]
heap: Convert heap tests to acutest tests