]>
git.ipfire.org Git - thirdparty/freeradius-server.git/log
Matthew Newton [Thu, 5 Dec 2019 19:08:50 +0000 (19:08 +0000)]
rpm spec: include mssql files
Alan T. DeKok [Thu, 5 Dec 2019 17:14:36 +0000 (12:14 -0500)]
shut up C compiler
Alan T. DeKok [Thu, 5 Dec 2019 16:22:33 +0000 (11:22 -0500)]
allow encoding and decoding of structs with 16-bit length prefixes.
Alan T. DeKok [Thu, 5 Dec 2019 14:51:59 +0000 (09:51 -0500)]
now that events are linked, we don't need to free it.
Alan T. DeKok [Thu, 5 Dec 2019 14:48:38 +0000 (09:48 -0500)]
move printing to load generator function
which lets us change the stats without changing all users
of the load generator
Arran Cudbard-Bell [Thu, 5 Dec 2019 15:04:16 +0000 (22:04 +0700)]
Call notify update when requests enter the cancelled state and we have a cancel muxer, and again when the request enters with cancel sent state
Terry Burton [Wed, 4 Dec 2019 19:31:38 +0000 (19:31 +0000)]
rlm_sql_unixodbc: Use descriptor corresponding to the resultset not the source
Fixes #2822
Terry Burton [Wed, 4 Dec 2019 19:30:54 +0000 (19:30 +0000)]
rlm_sql_unixodbc: Some drivers do not write to all bytes of the value
Arran Cudbard-Bell [Thu, 5 Dec 2019 11:57:23 +0000 (18:57 +0700)]
Add many more tests
Add cancel partial state for dealing with partial writes when cancelling
Restore in_handler correctly when doing nested handler calls. We *may* need to move this to a stack, but lets not do that unless we have to.
When requing requests, free the cancelled ones, don't try and move them to a new connection *sigh*
Arran Cudbard-Bell [Thu, 5 Dec 2019 11:56:28 +0000 (18:56 +0700)]
Notify function does not return a void *
Arran Cudbard-Bell [Thu, 5 Dec 2019 04:39:39 +0000 (11:39 +0700)]
shouldn't have been comitted...
Arran Cudbard-Bell [Thu, 5 Dec 2019 03:48:18 +0000 (10:48 +0700)]
Add callback to update the event loop for when the trunk wants to be notified that a connection is readable or writable
Alan T. DeKok [Wed, 4 Dec 2019 15:32:12 +0000 (10:32 -0500)]
don't link a context to itself.
and don't allow linking to a NULL context. It doesn't make sense.
Alan T. DeKok [Wed, 4 Dec 2019 15:18:07 +0000 (10:18 -0500)]
don't dereference a NULL pointer.
And it's stupid to call fr_event_list_time() with a NULL pointer.
Alan T. DeKok [Wed, 4 Dec 2019 15:11:07 +0000 (10:11 -0500)]
add documentation for load testing
Alan T. DeKok [Wed, 4 Dec 2019 14:51:26 +0000 (09:51 -0500)]
track and print accepted PPS
Alan T. DeKok [Wed, 4 Dec 2019 14:50:51 +0000 (09:50 -0500)]
stop printing stats if the test is over
Alan T. DeKok [Wed, 4 Dec 2019 14:24:59 +0000 (09:24 -0500)]
remove "inline".
The compiler is complaining that it's use is incorrect. And,
the compiler is smart enough to do inlining anyways. "inline"
is a hint, and can be ignored by the compiler for non-trivial
functions.:
Terry Burton [Wed, 4 Dec 2019 13:08:03 +0000 (13:08 +0000)]
Implement SQL IP pools for SQLite
Arran Cudbard-Bell [Wed, 4 Dec 2019 12:16:40 +0000 (19:16 +0700)]
Add basic enqueue test
Arran Cudbard-Bell [Wed, 4 Dec 2019 12:02:53 +0000 (19:02 +0700)]
Add trunk request ID
Arran Cudbard-Bell [Wed, 4 Dec 2019 12:02:07 +0000 (19:02 +0700)]
Change connection log format to help keep is consistent between the trunk and connection
Arran Cudbard-Bell [Wed, 4 Dec 2019 07:45:34 +0000 (14:45 +0700)]
Fix issue where post handlers were inserted as pre handlers
Only call post handlers if the transition succeeded.
Arran Cudbard-Bell [Wed, 4 Dec 2019 07:44:48 +0000 (14:44 +0700)]
Expose the connection ID
Arran Cudbard-Bell [Wed, 4 Dec 2019 07:06:54 +0000 (14:06 +0700)]
Allow overriding of the time source for event loops
Arran Cudbard-Bell [Wed, 4 Dec 2019 07:04:11 +0000 (14:04 +0700)]
Re-add the context linkage between the FD events and the provided talloc context
Not sure if this was removed or just an omission?
Arran Cudbard-Bell [Wed, 4 Dec 2019 00:49:00 +0000 (07:49 +0700)]
Revert "Add the ability to add timers relative to el->now"
This reverts commit
d60355fc4b9ad8163f9637d9b23f1247edee6894 .
Alan T. DeKok [Wed, 4 Dec 2019 00:34:42 +0000 (19:34 -0500)]
manual merge of commit
f04091f61
Alan T. DeKok [Tue, 3 Dec 2019 14:44:31 +0000 (09:44 -0500)]
move ema to backlog_ema
in preparation for adding pps_ema
Alan T. DeKok [Mon, 2 Dec 2019 16:19:22 +0000 (11:19 -0500)]
OSX is different from Linux
We shouldn't say "debugger attached" if there's no debugger
attached.
Arran Cudbard-Bell [Wed, 27 Nov 2019 00:24:53 +0000 (19:24 -0500)]
Trunk API
Jorge Pereira [Tue, 3 Dec 2019 15:52:51 +0000 (12:52 -0300)]
Add extra tests for xlat related to #3169
It will help us to avoid the crash again.
Jorge Pereira [Tue, 26 Nov 2019 20:14:41 +0000 (17:14 -0300)]
Import .pcap RADIUS tests from wireshark project
Copied from https://wiki.wireshark.org/SampleCaptures and converted
with:
./scripts/pcap2decode-proto.py -p radius -f ~/radius_localhost.pcapng \
> src/tests/unit/protocols/radius/packet_wireshark01.txt
Jorge Pereira [Tue, 3 Dec 2019 00:50:15 +0000 (21:50 -0300)]
Fix mod_event_list_set() to stop if failed to open()
If failed to open() the file, just report and stop it.
Jorge Pereira [Mon, 2 Dec 2019 21:14:45 +0000 (18:14 -0300)]
Fix leak in xlat_tokenize_attribute() (#3172)
towingie [Mon, 2 Dec 2019 20:57:14 +0000 (23:57 +0300)]
new vendor support (#3168)
* - added dictionary for rcntec's RPCM hardware
* - added missing `$INCLUDE dictionary.rcntec` include into `share/dictionary/radius/dictionary`
* - added session expire parameter
* - updated RCNTEC-RPCM-Session-Expire attribute number, was incorrect
Jorge Pereira [Mon, 2 Dec 2019 20:27:55 +0000 (17:27 -0300)]
Fix leak in xlat_tokenize_literal() (#3171)
Alan T. DeKok [Mon, 2 Dec 2019 14:25:02 +0000 (09:25 -0500)]
Internal functions aren't attributes. Fixes #3169
Alan T. DeKok [Mon, 2 Dec 2019 14:09:20 +0000 (09:09 -0500)]
don't use "new" as a variable name
lldb doesn't like it.
Alan T. DeKok [Mon, 2 Dec 2019 14:00:33 +0000 (09:00 -0500)]
add missing definition
Alan T. DeKok [Mon, 2 Dec 2019 13:46:26 +0000 (08:46 -0500)]
allow $INCLUDE dir/ to happen twice
which means include all of the files twice
Alan T. DeKok [Sun, 1 Dec 2019 16:23:14 +0000 (11:23 -0500)]
remove wrong struct member
Alan T. DeKok [Sun, 1 Dec 2019 14:24:57 +0000 (09:24 -0500)]
complain if write fails
but there isn't much else we can do
Alan T. DeKok [Sun, 1 Dec 2019 14:10:52 +0000 (09:10 -0500)]
minor cleanups and add link to audit tool
Alan T. DeKok [Sun, 1 Dec 2019 13:42:26 +0000 (08:42 -0500)]
set actual start time
Alan T. DeKok [Sun, 1 Dec 2019 01:14:32 +0000 (20:14 -0500)]
write stats to a CSV file once every second
Alan T. DeKok [Sun, 1 Dec 2019 01:13:32 +0000 (20:13 -0500)]
better track "send net packet time"
so it doesn't vary.
Alan T. DeKok [Sun, 1 Dec 2019 00:39:23 +0000 (19:39 -0500)]
track step end in absolute nanoseconds
Alan T. DeKok [Sat, 30 Nov 2019 23:14:36 +0000 (18:14 -0500)]
set "last_send" so that we can properly calculate deltas
Alan T. DeKok [Fri, 29 Nov 2019 21:26:04 +0000 (16:26 -0500)]
always set last_send packet
Alan T. DeKok [Fri, 29 Nov 2019 21:16:05 +0000 (16:16 -0500)]
typos
Jorge Pereira [Fri, 29 Nov 2019 19:15:45 +0000 (16:15 -0300)]
Fix missing fclose()
Alan T. DeKok [Fri, 29 Nov 2019 18:46:04 +0000 (13:46 -0500)]
start of RADIUS load generation routines.
Tested with simple tests. Seems to work.
Still have to add printing of the statistics.
Alan T. DeKok [Fri, 29 Nov 2019 18:23:49 +0000 (13:23 -0500)]
add load generation routines
Alan T. DeKok [Fri, 29 Nov 2019 17:22:10 +0000 (12:22 -0500)]
call app_io->event_list_set() if one exists
Alan T. DeKok [Fri, 29 Nov 2019 16:59:45 +0000 (11:59 -0500)]
use correct source list for transition
Terry Burton [Wed, 27 Nov 2019 16:00:49 +0000 (16:00 +0000)]
SQL IP Pools support for MS SQL
Tested using the FreeTDS driver against SQL Server 2017 on Linux Docker, mostly
focussing on the stored procedure which gives 350 allocs/sec; 425 reallocs/sec
(with no specific database server optimisation).
The queries are more complicated than with most other dialects since MS SQL
lacks a "SELECT FOR UPDATE" statement, and its table hints do not provide a
direct means to implement the row-level read lock needed to guarentee that
concurrent queries do not select the same Framed-IP-Address for allocation to
distinct users.
Terry Burton [Wed, 27 Nov 2019 16:11:24 +0000 (16:11 +0000)]
MS SQL schema: Syntax fixes and reorganise
Rework this dump so that it is suitable for humans _and_ computers.
Jorge Pereira [Wed, 27 Nov 2019 16:45:19 +0000 (13:45 -0300)]
Update description for rfc5176 payload test
Arran Cudbard-Bell [Tue, 26 Nov 2019 18:08:34 +0000 (13:08 -0500)]
Rename timer callback to be consistent
Arran Cudbard-Bell [Tue, 26 Nov 2019 18:08:16 +0000 (13:08 -0500)]
Add iterator for heaps
Arran Cudbard-Bell [Tue, 26 Nov 2019 18:07:32 +0000 (13:07 -0500)]
Quiet compiler warnings
Jorge Pereira [Tue, 26 Nov 2019 17:25:16 +0000 (14:25 -0300)]
Don't need to append '_radius' to the test files (#3160)
Jorge Pereira [Mon, 25 Nov 2019 22:49:36 +0000 (19:49 -0300)]
Import .pcap RADIUS tests from tcpdump project
It was imported using scripts/pcap2decode-proto.py
e.g:
./scripts/pcap2decode-proto.py -p radius \
-f ../tcpdump.git/tests/RADIUS-RFC4675.pcap \
> src/tests/unit/protocols/radius/packet_radius-rfc4675.txt
Jorge Pereira [Wed, 20 Nov 2019 21:24:08 +0000 (18:24 -0300)]
Add script to convert .pcap payload to '{decode,encode}-proto' format
It was created to help us to create the dhcpv6 unit tests based on
the tcpdump .pcap files.
Jorge Pereira [Mon, 25 Nov 2019 22:25:04 +0000 (19:25 -0300)]
Update dhcpv6 tests with payload description
Arran Cudbard-Bell [Mon, 25 Nov 2019 01:29:05 +0000 (20:29 -0500)]
Add the ability to add timers relative to el->now
Add "CLOSED" state in connection API to avoid transitioning through failed for connections which haven't
Arran Cudbard-Bell [Sun, 24 Nov 2019 19:03:32 +0000 (14:03 -0500)]
Fix condition in fr_event_corral
Arran Cudbard-Bell [Sun, 24 Nov 2019 19:02:28 +0000 (14:02 -0500)]
Don't update el->now in the service function
We only want the set of events identified by event_corral
Arran Cudbard-Bell [Sun, 24 Nov 2019 18:57:38 +0000 (13:57 -0500)]
Formatting
Arran Cudbard-Bell [Sun, 24 Nov 2019 18:57:30 +0000 (13:57 -0500)]
Always return +1 pending event if there's a timer ready
Arran Cudbard-Bell [Sun, 24 Nov 2019 18:57:14 +0000 (13:57 -0500)]
More debug messages from the interpretor
Arran Cudbard-Bell [Sun, 24 Nov 2019 05:33:17 +0000 (00:33 -0500)]
Fix list count decrement on fr_dlist_remove
Arran Cudbard-Bell [Sun, 24 Nov 2019 05:07:09 +0000 (00:07 -0500)]
fr_dlist_num_elements should take a const head
Arran Cudbard-Bell [Sun, 24 Nov 2019 05:06:53 +0000 (00:06 -0500)]
Only set num_timer_events if the event is going to execute the next time the service function is called
Arran Cudbard-Bell [Sun, 24 Nov 2019 05:06:28 +0000 (00:06 -0500)]
More checks for talloc_pooled_object
Arran Cudbard-Bell [Sun, 24 Nov 2019 05:06:15 +0000 (00:06 -0500)]
Have event corral take an external time
This can be more efficient, and means that was can control time for the purposes of testing
Arran Cudbard-Bell [Sun, 24 Nov 2019 04:56:02 +0000 (23:56 -0500)]
Always indicate when the connection was signalled to reconnect
Arran Cudbard-Bell [Sun, 24 Nov 2019 04:54:22 +0000 (23:54 -0500)]
Immediately transition connections back to init if there's no reconnection delay
Arran Cudbard-Bell [Sun, 24 Nov 2019 03:41:01 +0000 (22:41 -0500)]
Add debug output whenever we call a connection callback
Arran Cudbard-Bell [Sun, 24 Nov 2019 02:49:42 +0000 (21:49 -0500)]
Initialise lists when the connection is allocated, not when it enters the init state
Alan T. DeKok [Sat, 23 Nov 2019 20:17:17 +0000 (15:17 -0500)]
dns_label_length can return 0
Alan T. DeKok [Fri, 22 Nov 2019 16:54:32 +0000 (11:54 -0500)]
revert to before changes
Alan T. DeKok [Fri, 22 Nov 2019 16:16:18 +0000 (11:16 -0500)]
run only one child make
Alan T. DeKok [Fri, 22 Nov 2019 16:10:45 +0000 (11:10 -0500)]
try to quiet make
Alan T. DeKok [Fri, 22 Nov 2019 15:48:55 +0000 (10:48 -0500)]
ensure we build CA before server / ocsp / client certs
Alan T. DeKok [Fri, 22 Nov 2019 15:48:23 +0000 (10:48 -0500)]
reorder rules for generating passwords.mk
Jorge Pereira [Fri, 22 Nov 2019 00:42:57 +0000 (21:42 -0300)]
The dhcpv6 'packet_*.txt' should decode only the hex
It was updated using the tool scripts/pcap2decode-proto.py
e.g:
./scripts/pcap2decode-proto.py -p dhcpv6 \
-f ../tcpdump.git/tests/dhcpv6-ia-pd.pcap \
> src/tests/unit/protocols/dhcpv6/packet_ia-pd.txt
Alan T. DeKok [Fri, 22 Nov 2019 15:19:52 +0000 (10:19 -0500)]
always define GENERATED_CERT_FILES
Alan T. DeKok [Fri, 22 Nov 2019 14:28:08 +0000 (09:28 -0500)]
add rule for "dh", too
Alan T. DeKok [Fri, 22 Nov 2019 13:57:59 +0000 (08:57 -0500)]
better rules to create certificates
so we don't have all certs depending on all cnf files
Alan T. DeKok [Thu, 21 Nov 2019 20:48:26 +0000 (15:48 -0500)]
call dhcpv6 encode_value from the struct encoder
which then changes all of the dates in the tests, as DHCPv6
starts dates from Jan 1 2000, instead of Jan 1 1970.
Alan T. DeKok [Thu, 21 Nov 2019 19:26:09 +0000 (14:26 -0500)]
fix DHCPv6 date encode / decode
decode didn't add the date offset from Jan 1 1970 --> Jan 1, 2000.
encode added 30*365*86400, which doesn't account for the fact that
years are ~365.25 days long.
Alan T. DeKok [Thu, 21 Nov 2019 19:09:07 +0000 (14:09 -0500)]
allow encoding of time_delta in dhcpv6
and print out type names for unsupported types
Alan T. DeKok [Thu, 21 Nov 2019 19:07:52 +0000 (14:07 -0500)]
return correct lengths for time delta / date attributes
Alan T. DeKok [Thu, 21 Nov 2019 18:54:35 +0000 (13:54 -0500)]
copy over key fields, too
Alan T. DeKok [Thu, 21 Nov 2019 13:39:36 +0000 (08:39 -0500)]
remove extraneous check
Jorge Pereira [Tue, 19 Nov 2019 22:01:47 +0000 (19:01 -0300)]
Increase the 'nasportid' SQL field for 'varchar(32)'. ref #3141
Alan T. DeKok [Thu, 21 Nov 2019 13:31:24 +0000 (08:31 -0500)]
always call protocol-specific decode_value, if we have it
Jorge Pereira [Wed, 20 Nov 2019 22:44:59 +0000 (19:44 -0300)]
Print the test module dir and the test file (#3153)
It will print like:
UNIT-TEST dhcpv6 rfc6939
Instead of:
UNIT-TEST src/tests/unit/protocols/dhcpv6/rfc6939.txt