]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
8 years agotidy random symlinks added in 8404a2a1
Matthew Newton [Wed, 17 Jan 2018 17:34:15 +0000 (17:34 +0000)] 
tidy random symlinks added in 8404a2a1

8 years ago'&' is not a valid attribute or list name
Alan T. DeKok [Wed, 17 Jan 2018 16:09:45 +0000 (11:09 -0500)] 
'&' is not a valid attribute or list name

8 years agosockfd is unused
Alan T. DeKok [Wed, 17 Jan 2018 15:59:50 +0000 (10:59 -0500)] 
sockfd is unused

8 years agoinitialize all of "address"
Alan T. DeKok [Wed, 17 Jan 2018 15:12:19 +0000 (10:12 -0500)] 
initialize all of "address"

8 years agolimit number of packets we read from one socket
Alan T. DeKok [Wed, 17 Jan 2018 14:54:08 +0000 (09:54 -0500)] 
limit number of packets we read from one socket

so that we don't starve other sockets

8 years agoreturn "no more data" when too many outstanding packets.
Alan T. DeKok [Wed, 17 Jan 2018 14:53:01 +0000 (09:53 -0500)] 
return "no more data" when too many outstanding packets.

Once a socket is ready, the network side tries to read many
packets.  So we have to check for max_outstanding ourselves

8 years agoignore write errors to the control plane
Alan T. DeKok [Wed, 17 Jan 2018 14:39:07 +0000 (09:39 -0500)] 
ignore write errors to the control plane

once the packet has been placed into the worker queue, then
the worker will pick it up.  If we can't signal the control
plane, then the worker has tons of pending messages, and will
pick up the packet.

8 years agoensure we don't pick the same worker twice...
Alan T. DeKok [Wed, 17 Jan 2018 14:20:44 +0000 (09:20 -0500)] 
ensure we don't pick the same worker twice...

8 years agoBreak most of the unlang keyword and operations code into a separate source file
Arran Cudbard-Bell [Wed, 17 Jan 2018 03:35:35 +0000 (20:35 -0700)] 
Break most of the unlang keyword and operations code into a separate source file

Progressing more towards a generic interpreter which is independent of the keywords and operations being executed

8 years agoExtra tests for strerror
Arran Cudbard-Bell [Wed, 17 Jan 2018 03:20:01 +0000 (20:20 -0700)] 
Extra tests for strerror

8 years agosupport NAT
Alan T. DeKok [Tue, 16 Jan 2018 21:30:11 +0000 (16:30 -0500)] 
support NAT

we track received but un-processed packets for dynamic clients.

Then, when we've processed the last pending packet, the dynamic
client is deleted.  That way, each connection gets it's own client.

8 years agoallow dynamic clients to say they're behind a NAT gateway
Alan T. DeKok [Tue, 16 Jan 2018 21:16:45 +0000 (16:16 -0500)] 
allow dynamic clients to say they're behind a NAT gateway

it's not yet glued into proto_radius_udp, but that's next

8 years agowork around crash
Alan T. DeKok [Tue, 16 Jan 2018 21:10:07 +0000 (16:10 -0500)] 
work around crash

fr_strerror_printf_push(..., fr_strerror_pop()) now crashes
in the address sanitizer.  It's not clear what's going on in
strerror.c, so it's easier to just avoid the issue.

The errors are still printed, just a bit less clearly.

8 years agoconst issues
Alan T. DeKok [Tue, 16 Jan 2018 21:04:39 +0000 (16:04 -0500)] 
const issues

8 years agoclean up expired / unused connected UDP sockets
Alan T. DeKok [Tue, 16 Jan 2018 20:24:28 +0000 (15:24 -0500)] 
clean up expired / unused connected UDP sockets

8 years agodon't print socket errors. let the read() routine do that.
Alan T. DeKok [Tue, 16 Jan 2018 20:24:13 +0000 (15:24 -0500)] 
don't print socket errors.  let the read() routine do that.

8 years agofinal tweaks to get connected UDP sockets working
Alan T. DeKok [Tue, 16 Jan 2018 19:48:34 +0000 (14:48 -0500)] 
final tweaks to get connected UDP sockets working

8 years agofree timers when freeing entries in the rbtree
Alan T. DeKok [Tue, 16 Jan 2018 19:48:00 +0000 (14:48 -0500)] 
free timers when freeing entries in the rbtree

8 years agoclean ups
Alan T. DeKok [Tue, 16 Jan 2018 19:35:17 +0000 (14:35 -0500)] 
clean ups

8 years agodon't push config parse rules if there's no config
Alan T. DeKok [Tue, 16 Jan 2018 19:29:51 +0000 (14:29 -0500)] 
don't push config parse rules if there's no config

8 years agoclone the client, too
Alan T. DeKok [Tue, 16 Jan 2018 19:25:29 +0000 (14:25 -0500)] 
clone the client, too

8 years agoadd client_clone() for connected UDP sockets
Alan T. DeKok [Tue, 16 Jan 2018 19:23:07 +0000 (14:23 -0500)] 
add client_clone() for connected UDP sockets

8 years agoinstantiate the child, and open the child socket
Alan T. DeKok [Tue, 16 Jan 2018 17:26:29 +0000 (12:26 -0500)] 
instantiate the child, and open the child socket

8 years agochild socket connects to client
Alan T. DeKok [Tue, 16 Jan 2018 17:21:52 +0000 (12:21 -0500)] 
child socket connects to client

8 years agoset SO_REUSEPORT for connected sockets
Alan T. DeKok [Tue, 16 Jan 2018 16:42:38 +0000 (11:42 -0500)] 
set SO_REUSEPORT for connected sockets

8 years agoglue mod_clone into the socket code.
Alan T. DeKok [Mon, 15 Jan 2018 21:41:13 +0000 (16:41 -0500)] 
glue mod_clone into the socket code.

still a few TODO's.  (i.e. you use it now, it crashes).
But the basics are laid out

8 years agotrack dst ip/port in child, too
Alan T. DeKok [Mon, 15 Jan 2018 21:40:44 +0000 (16:40 -0500)] 
track dst ip/port in child, too

8 years agonotes on splitting out dynamic clients, and connected UDP sockets
Alan T. DeKok [Mon, 15 Jan 2018 21:10:13 +0000 (16:10 -0500)] 
notes on splitting out dynamic clients, and connected UDP sockets

8 years agoDoxygen
Arran Cudbard-Bell [Tue, 16 Jan 2018 02:34:44 +0000 (19:34 -0700)] 
Doxygen

8 years agoMove signalling and resumption callbacks to the unlang_op_t
Arran Cudbard-Bell [Tue, 16 Jan 2018 00:33:45 +0000 (17:33 -0700)] 
Move signalling and resumption callbacks to the unlang_op_t

This is partly in preparation for dynamic registration and partly because it's easier to organise it this way.

8 years agoFix buffer scoping in fr_pair_make
Arran Cudbard-Bell [Tue, 16 Jan 2018 00:00:40 +0000 (17:00 -0700)] 
Fix buffer scoping in fr_pair_make

8 years agoPrint name of failing function
Arran Cudbard-Bell [Mon, 15 Jan 2018 23:39:06 +0000 (16:39 -0700)] 
Print name of failing function

8 years agoI have no idea what wimsie is...
Arran Cudbard-Bell [Mon, 15 Jan 2018 23:38:51 +0000 (16:38 -0700)] 
I have no idea what wimsie is...

8 years agoFormatting
Arran Cudbard-Bell [Mon, 15 Jan 2018 23:38:30 +0000 (16:38 -0700)] 
Formatting

8 years agoFix indentation
Arran Cudbard-Bell [Mon, 15 Jan 2018 23:38:21 +0000 (16:38 -0700)] 
Fix indentation

8 years agoAdd signal and resume callbacks to the unlang_op_t
Arran Cudbard-Bell [Mon, 15 Jan 2018 23:37:25 +0000 (16:37 -0700)] 
Add signal and resume callbacks to the unlang_op_t

Originally there wasn't the need for this type of abstraction as the only type of resumable frame was modcall.  Now we have multiple types of resumption it's better to add these types of callbacks directly to the unlang_action_t.

8 years agoremove LN-S from warnings
Alan T. DeKok [Fri, 12 Jan 2018 14:04:36 +0000 (09:04 -0500)] 
remove LN-S from warnings

8 years agoinclude dhcpclient binary in freeradius-dhcp debian package
Matthew Newton [Tue, 9 Jan 2018 15:28:53 +0000 (15:28 +0000)] 
include dhcpclient binary in freeradius-dhcp debian package

8 years agodon't fail in removing freeradius-config .deb pkg if dir no longer exists
Matthew Newton [Tue, 9 Jan 2018 12:53:33 +0000 (12:53 +0000)] 
don't fail in removing freeradius-config .deb pkg if dir no longer exists

8 years agoalso don't pull in boiler.mk whilst doing make deb
Matthew Newton [Tue, 9 Jan 2018 11:16:14 +0000 (11:16 +0000)] 
also don't pull in boiler.mk whilst doing make deb

8 years agomake sure install continues even if the daemon isn't running
Matthew Newton [Tue, 9 Jan 2018 10:35:12 +0000 (10:35 +0000)] 
make sure install continues even if the daemon isn't running

First install fails if freeradius package and module packages are
installed at the same time.

8 years agoautoconf typo
Matthew Newton [Mon, 15 Jan 2018 22:59:15 +0000 (22:59 +0000)] 
autoconf typo

8 years agoCheck for -Wno-date-time to pacify ancient compilers
Matthew Newton [Mon, 15 Jan 2018 22:31:37 +0000 (22:31 +0000)] 
Check for -Wno-date-time to pacify ancient compilers

8 years agoTypo
Arran Cudbard-Bell [Wed, 10 Jan 2018 23:57:20 +0000 (18:57 -0500)] 
Typo

8 years agoconst issues
Alan T. DeKok [Mon, 15 Jan 2018 17:15:14 +0000 (12:15 -0500)] 
const issues

8 years agobetter initialize packet_time
Alan T. DeKok [Mon, 15 Jan 2018 16:44:26 +0000 (11:44 -0500)] 
better initialize packet_time

8 years agoinitialize packet_len, not data_size
Alan T. DeKok [Mon, 15 Jan 2018 16:42:02 +0000 (11:42 -0500)] 
initialize packet_len, not data_size

8 years agorenames for doxygen
Alan T. DeKok [Mon, 15 Jan 2018 16:40:28 +0000 (11:40 -0500)] 
renames for doxygen

8 years agodon't delete conflicting packets
Alan T. DeKok [Mon, 15 Jan 2018 15:46:58 +0000 (10:46 -0500)] 
don't delete conflicting packets

8 years agomove tracking to proto_radius
Alan T. DeKok [Mon, 15 Jan 2018 15:34:44 +0000 (10:34 -0500)] 
move tracking to proto_radius

8 years agomove src_dst to array[0] at the end of the struct
Alan T. DeKok [Mon, 15 Jan 2018 15:28:52 +0000 (10:28 -0500)] 
move src_dst to array[0] at the end of the struct

8 years agostart of mod_clone() for connected UDP sockets
Alan T. DeKok [Fri, 12 Jan 2018 18:13:23 +0000 (13:13 -0500)] 
start of mod_clone() for connected UDP sockets

with notes for more future work

8 years agocache scheduler for connected UDP sockets
Alan T. DeKok [Fri, 12 Jan 2018 18:13:05 +0000 (13:13 -0500)] 
cache scheduler for connected UDP sockets

8 years agoadd mod_inject, along with handlers for it
Alan T. DeKok [Fri, 12 Jan 2018 15:56:23 +0000 (10:56 -0500)] 
add mod_inject, along with handlers for it

in preparation for connected UDP sockets

8 years agothese attributes are "string". Fixes #2130
Alan T. DeKok [Fri, 12 Jan 2018 15:34:11 +0000 (10:34 -0500)] 
these attributes are "string".  Fixes #2130

8 years agoinitialize data structures for connected sockets
Alan T. DeKok [Thu, 11 Jan 2018 18:56:56 +0000 (13:56 -0500)] 
initialize data structures for connected sockets

8 years agodata structures in preparation for connected sockets
Alan T. DeKok [Thu, 11 Jan 2018 18:39:09 +0000 (13:39 -0500)] 
data structures in preparation for connected sockets

8 years agoadded fr_network_listen_inject()
Alan T. DeKok [Thu, 11 Jan 2018 18:24:18 +0000 (13:24 -0500)] 
added fr_network_listen_inject()

to inject data into a socket.

Mainly to be used for connected sockets

8 years agoremove undef variable. Fixes #2156
Alan T. DeKok [Wed, 10 Jan 2018 21:24:51 +0000 (16:24 -0500)] 
remove undef variable.  Fixes #2156

8 years agosend fr_listen_t to network, not whole fr_network_socket_t
Alan T. DeKok [Wed, 10 Jan 2018 20:52:32 +0000 (15:52 -0500)] 
send fr_listen_t to network, not whole fr_network_socket_t

the socket_t is too large, and unnecessary.  we can just send
the one pointer we care about

8 years agohave different error for "ring buffer full"
Alan T. DeKok [Wed, 10 Jan 2018 18:37:09 +0000 (13:37 -0500)] 
have different error for "ring buffer full"

8 years agolook for overlapping networks, and complain if so
Alan T. DeKok [Wed, 10 Jan 2018 17:26:08 +0000 (12:26 -0500)] 
look for overlapping networks, and complain if so

8 years agomove "check for connected socket" code to bootstrap
Alan T. DeKok [Wed, 10 Jan 2018 17:17:25 +0000 (12:17 -0500)] 
move "check for connected socket" code to bootstrap

8 years agomove sanity checks to bootstrap
Alan T. DeKok [Wed, 10 Jan 2018 17:16:56 +0000 (12:16 -0500)] 
move sanity checks to bootstrap

so that instantiate can be called from proto_radius_connected_udp

8 years agonote todo for overlapping networks
Alan T. DeKok [Wed, 10 Jan 2018 17:14:36 +0000 (12:14 -0500)] 
note todo for overlapping networks

e.g.

192.168/16 is allowed, and so is 192.168.1/24.  They're overlapping
and the second is unnecessary.

8 years agomove dynamic clients to using patricia trie
Alan T. DeKok [Tue, 9 Jan 2018 18:19:19 +0000 (13:19 -0500)] 
move dynamic clients to using patricia trie

instead of walking down a list of networks

8 years agorename to fr_radius_dynamic_client_t
Alan T. DeKok [Tue, 9 Jan 2018 17:54:31 +0000 (12:54 -0500)] 
rename to fr_radius_dynamic_client_t

8 years agoupdate proto_radius_udp in preparation for connected sockets
Alan T. DeKok [Tue, 9 Jan 2018 16:39:27 +0000 (11:39 -0500)] 
update proto_radius_udp in preparation for connected sockets

8 years agomove "print name" to instantiate
Alan T. DeKok [Tue, 9 Jan 2018 16:27:19 +0000 (11:27 -0500)] 
move "print name" to instantiate

so that we can possibly skip mod_open() for connected sockets

8 years agoset s->dead, so we know it's dead
Alan T. DeKok [Tue, 9 Jan 2018 15:47:02 +0000 (10:47 -0500)] 
set s->dead, so we know it's dead

8 years agomark socket dead on read error.
Alan T. DeKok [Tue, 9 Jan 2018 15:45:46 +0000 (10:45 -0500)] 
mark socket dead on read error.

don't free it, as there still may be outstanding requests

8 years agore-arrange to make bools next to each other
Alan T. DeKok [Tue, 9 Jan 2018 15:38:47 +0000 (10:38 -0500)] 
re-arrange to make bools next to each other

8 years agoadd :* as an explicit wildcard tag match
Alan T. DeKok [Mon, 8 Jan 2018 20:57:57 +0000 (15:57 -0500)] 
add :* as an explicit wildcard tag match

8 years agoclean up code to parse tags
Alan T. DeKok [Mon, 8 Jan 2018 20:54:31 +0000 (15:54 -0500)] 
clean up code to parse tags

8 years agoremove support for Merit format tags
Alan T. DeKok [Mon, 8 Jan 2018 20:35:52 +0000 (15:35 -0500)] 
remove support for Merit format tags

which we haven't used for many years

8 years agountagged tmpls have TAG_NONE
Alan T. DeKok [Mon, 8 Jan 2018 20:33:58 +0000 (15:33 -0500)] 
untagged tmpls have TAG_NONE

8 years agoadd ATTR_TAG_MATCH
Alan T. DeKok [Mon, 8 Jan 2018 20:03:27 +0000 (15:03 -0500)] 
add ATTR_TAG_MATCH

which sees if attribute A matches tag T

8 years agoconvert complex code to one macro
Alan T. DeKok [Mon, 8 Jan 2018 19:24:31 +0000 (14:24 -0500)] 
convert complex code to one macro

8 years agoprint ":%d", so it's the same as the rest of the code
Alan T. DeKok [Mon, 8 Jan 2018 16:23:03 +0000 (11:23 -0500)] 
print ":%d", so it's the same as the rest of the code

8 years ago0 is OK for untagged attributes
Alan T. DeKok [Mon, 8 Jan 2018 16:21:44 +0000 (11:21 -0500)] 
0 is OK for untagged attributes

8 years agocheck for TAG_VALID instead of !=TAG_ANY
Alan T. DeKok [Mon, 8 Jan 2018 16:05:14 +0000 (11:05 -0500)] 
check for TAG_VALID instead of !=TAG_ANY

looking for valid ranges is smarter than checking for different
from a magic value, because there may be LOTS of magic values,
and LOTS of invalid values

8 years agocheck valid rang
Alan T. DeKok [Mon, 8 Jan 2018 16:03:41 +0000 (11:03 -0500)] 
check valid rang

we can't just check tag < 32, because TAG_ANY is -128,
instead, we have to check for 0..32

8 years ago0 is not a valid tag
Alan T. DeKok [Mon, 8 Jan 2018 13:21:50 +0000 (08:21 -0500)] 
0 is not a valid tag

8 years agoonly print valid tags
Alan T. DeKok [Mon, 8 Jan 2018 13:19:33 +0000 (08:19 -0500)] 
only print valid tags

8 years agono need to double-check the IP and prefix
Alan T. DeKok [Fri, 5 Jan 2018 17:10:17 +0000 (12:10 -0500)] 
no need to double-check the IP and prefix

8 years agouse fr_trie_match() instead of doing it manually
Alan T. DeKok [Fri, 5 Jan 2018 17:05:54 +0000 (12:05 -0500)] 
use fr_trie_match() instead of doing it manually

8 years agoadd fr_trie_match()
Alan T. DeKok [Fri, 5 Jan 2018 17:05:34 +0000 (12:05 -0500)] 
add fr_trie_match()

which does a match on the exact length of the key

8 years agoseparate v4/v6 clients
Alan T. DeKok [Fri, 5 Jan 2018 15:36:58 +0000 (10:36 -0500)] 
separate v4/v6 clients

8 years agoignore old clients if their prefix is too small
Alan T. DeKok [Fri, 5 Jan 2018 15:26:37 +0000 (10:26 -0500)] 
ignore old clients if their prefix is too small

fr_trie_lookup() returns the longest prefix match.
Which still might be smaller than the prefix of the client
we're trying to add.

8 years agoone more try to quiet stupid compiler
Alan T. DeKok [Fri, 5 Jan 2018 15:21:52 +0000 (10:21 -0500)] 
one more try to quiet stupid compiler

it claims a variable / function is unused if it's used
inside of an assertion...

8 years agostupid scanner
Alan T. DeKok [Fri, 5 Jan 2018 13:58:08 +0000 (08:58 -0500)] 
stupid scanner

8 years agotry to quiet clang scan
Alan T. DeKok [Fri, 5 Jan 2018 13:29:05 +0000 (08:29 -0500)] 
try to quiet clang scan

8 years agoset base=0 if bits_used==0
Alan T. DeKok [Thu, 4 Jan 2018 21:31:07 +0000 (16:31 -0500)] 
set base=0 if bits_used==0

8 years agoip addresses are in network byte order
Alan T. DeKok [Thu, 4 Jan 2018 21:11:07 +0000 (16:11 -0500)] 
ip addresses are in network byte order

8 years agocomment out verification until the rest of the tests pass
Alan T. DeKok [Thu, 4 Jan 2018 20:55:55 +0000 (15:55 -0500)] 
comment out verification until the rest of the tests pass

8 years agoset output buffer
Alan T. DeKok [Thu, 4 Jan 2018 20:53:49 +0000 (15:53 -0500)] 
set output buffer

and add macros for max key bits / bytes

8 years agoadd distinction between UDP and TCP clients
Alan T. DeKok [Thu, 4 Jan 2018 20:46:55 +0000 (15:46 -0500)] 
add distinction between UDP and TCP clients

8 years agomake clients use new trie code.
Alan T. DeKok [Thu, 4 Jan 2018 20:42:21 +0000 (15:42 -0500)] 
make clients use new trie code.

8 years agochar const* for printing
Alan T. DeKok [Thu, 4 Jan 2018 20:04:57 +0000 (15:04 -0500)] 
char const* for printing

8 years agotypo
Alan T. DeKok [Thu, 4 Jan 2018 20:03:44 +0000 (15:03 -0500)] 
typo