]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
7 years agothis attribute is text, not binary. Fixes #2322
Alan T. DeKok [Thu, 4 Oct 2018 20:00:20 +0000 (16:00 -0400)] 
this attribute is text, not binary.  Fixes #2322

7 years agosimplify code
Alan T. DeKok [Thu, 4 Oct 2018 14:36:26 +0000 (10:36 -0400)] 
simplify code

the buffer almost always shrinks, so just call the function

7 years agoshrink the message, and fix compile warning
Alan T. DeKok [Thu, 4 Oct 2018 14:00:40 +0000 (10:00 -0400)] 
shrink the message, and fix compile warning

7 years agoMinor fixes
Arran Cudbard-Bell [Thu, 4 Oct 2018 13:30:06 +0000 (20:30 +0700)] 
Minor fixes

7 years agoIt's ok for the ctx to be NULL
Arran Cudbard-Bell [Thu, 4 Oct 2018 12:53:06 +0000 (19:53 +0700)] 
It's ok for the ctx to be NULL

7 years agoNo longer used
Arran Cudbard-Bell [Thu, 4 Oct 2018 12:09:36 +0000 (19:09 +0700)] 
No longer used

7 years agoFix PCRE2 version output
Arran Cudbard-Bell [Thu, 4 Oct 2018 10:33:19 +0000 (17:33 +0700)] 
Fix PCRE2 version output

7 years agoDon't leak HMAC_CTXs
Arran Cudbard-Bell [Thu, 4 Oct 2018 02:44:21 +0000 (09:44 +0700)] 
Don't leak HMAC_CTXs

7 years agoRedundant declaration
Arran Cudbard-Bell [Thu, 4 Oct 2018 02:44:03 +0000 (09:44 +0700)] 
Redundant declaration

7 years agoDeclare some structures before includes
Arran Cudbard-Bell [Thu, 4 Oct 2018 02:37:05 +0000 (09:37 +0700)] 
Declare some structures before includes

7 years agoReplace remaining references to mainconfig with main_config
Arran Cudbard-Bell [Wed, 3 Oct 2018 19:39:10 +0000 (02:39 +0700)] 
Replace remaining references to mainconfig with main_config

7 years agoFix redundant declarations
Arran Cudbard-Bell [Wed, 3 Oct 2018 19:37:10 +0000 (02:37 +0700)] 
Fix redundant declarations

7 years agoInclude map.h in LDAP library
Arran Cudbard-Bell [Wed, 3 Oct 2018 19:26:36 +0000 (02:26 +0700)] 
Include map.h in LDAP library

7 years agofinally make thread_instance data for the master IO handler
Alan T. DeKok [Wed, 3 Oct 2018 18:41:10 +0000 (14:41 -0400)] 
finally make thread_instance data for the master IO handler

next step: do it for the rest of the IO modules

7 years agoadded "terminate" command
Alan T. DeKok [Wed, 3 Oct 2018 18:40:47 +0000 (14:40 -0400)] 
added "terminate" command

which stops the server from running

7 years agofix error message
Alan T. DeKok [Wed, 3 Oct 2018 18:37:45 +0000 (14:37 -0400)] 
fix error message

7 years agoadd fr_listen_t -> connected
Alan T. DeKok [Wed, 3 Oct 2018 18:16:49 +0000 (14:16 -0400)] 
add fr_listen_t -> connected

so that the code becomes simpler.

7 years agofix indentation
Alan T. DeKok [Wed, 3 Oct 2018 15:47:47 +0000 (11:47 -0400)] 
fix indentation

which seems to have been largely random

7 years agoadd fr_network_pre_event()
Alan T. DeKok [Wed, 3 Oct 2018 13:14:09 +0000 (09:14 -0400)] 
add fr_network_pre_event()

in order to get the event loop to run through it's work again.
so that the network side can say "hey, there's work to do!"
and then go do it.

7 years agobypass the channels if it's the same thread
Alan T. DeKok [Tue, 2 Oct 2018 17:24:50 +0000 (13:24 -0400)] 
bypass the channels if it's the same thread

this gives it about a 5-10% performance boost in single-threaded
mode.

7 years agoclean up debug3 messages
Alan T. DeKok [Tue, 2 Oct 2018 17:20:17 +0000 (13:20 -0400)] 
clean up debug3 messages

7 years agomove callbacks to "end" structures
Alan T. DeKok [Tue, 2 Oct 2018 17:03:52 +0000 (13:03 -0400)] 
move callbacks to "end" structures

7 years agomove worker side to callbacks, too
Alan T. DeKok [Tue, 2 Oct 2018 16:59:58 +0000 (12:59 -0400)] 
move worker side to callbacks, too

7 years agomove fr_channel_recv_reply() to using callbacks
Alan T. DeKok [Tue, 2 Oct 2018 14:51:54 +0000 (10:51 -0400)] 
move fr_channel_recv_reply() to using callbacks

in preparation for bypassing the atomic queues when both ends
of the channel are in the same thread

7 years agoremember if both ends are in the same thread
Alan T. DeKok [Tue, 2 Oct 2018 14:24:48 +0000 (10:24 -0400)] 
remember if both ends are in the same thread

7 years agorename _master_ to _network_
Alan T. DeKok [Tue, 2 Oct 2018 14:17:16 +0000 (10:17 -0400)] 
rename _master_ to _network_

which is more consistent

7 years agoFirst phase of restructuring server library headers
Arran Cudbard-Bell [Wed, 3 Oct 2018 14:46:47 +0000 (21:46 +0700)] 
First phase of restructuring server library headers

Everything needs to be broken out more as it was with the utility library, expect more commits in the future

7 years agoMerge pull request #2317 from cipherboy/hmac-openssl-master
Arran Cudbard-Bell [Wed, 3 Oct 2018 05:07:51 +0000 (13:07 +0800)] 
Merge pull request #2317 from cipherboy/hmac-openssl-master

HMAC -> OpenSSL against master

7 years agoReplace HMAC-SHA1 implementation with OpenSSL's 2317/head
Alexander Scheel [Fri, 28 Sep 2018 15:03:52 +0000 (11:03 -0400)] 
Replace HMAC-SHA1 implementation with OpenSSL's

If OpenSSL EVP is not found, fallback to internal implementation of
HMAC-SHA1.

Signed-off-by: Alexander Scheel <ascheel@redhat.com>
7 years agoReplace HMAC-MD5 implementation with OpenSSL's
Alexander Scheel [Fri, 28 Sep 2018 13:54:46 +0000 (09:54 -0400)] 
Replace HMAC-MD5 implementation with OpenSSL's

If OpenSSL EVP is not found, fallback to internal implementation of
HMAC-MD5.

Signed-off-by: Alexander Scheel <ascheel@redhat.com>
7 years agoAdd Moonshot-OTP-Secret attribute definition
Alejandro Perez [Tue, 2 Oct 2018 11:54:26 +0000 (13:54 +0200)] 
Add Moonshot-OTP-Secret attribute definition

7 years agomanual merge of commit b5b27fedba8f
Alan T. DeKok [Tue, 2 Oct 2018 13:48:20 +0000 (09:48 -0400)] 
manual merge of commit b5b27fedba8f

7 years ago"chunk" is unsigned
Alan T. DeKok [Mon, 1 Oct 2018 14:09:51 +0000 (10:09 -0400)] 
"chunk" is unsigned

7 years agoreset "chunk" to ensure we find the correct entry
Alan T. DeKok [Mon, 1 Oct 2018 13:17:16 +0000 (09:17 -0400)] 
reset "chunk" to ensure we find the correct entry

7 years ago"my_bool" isn't in MySQL 8.0
Alan T. DeKok [Mon, 1 Oct 2018 13:11:09 +0000 (09:11 -0400)] 
"my_bool" isn't in MySQL 8.0

but we have "bool"

7 years agoTrim whitespace
Arran Cudbard-Bell [Mon, 1 Oct 2018 05:26:16 +0000 (13:26 +0800)] 
Trim whitespace

7 years agoWork around faulty clang analyzer logic
Arran Cudbard-Bell [Sun, 30 Sep 2018 16:46:41 +0000 (00:46 +0800)] 
Work around faulty clang analyzer logic

7 years agoPass pointer to the handle
Arran Cudbard-Bell [Sun, 30 Sep 2018 16:25:11 +0000 (00:25 +0800)] 
Pass pointer to the handle

7 years agoInit valuebox in overflow case
Arran Cudbard-Bell [Sun, 30 Sep 2018 16:18:29 +0000 (00:18 +0800)] 
Init valuebox in overflow case

7 years agofind_lm_password and find_nt_password report failure to find password attributes
Arran Cudbard-Bell [Sun, 30 Sep 2018 16:07:46 +0000 (00:07 +0800)] 
find_lm_password and find_nt_password report failure to find password attributes

7 years agoInitialise output pointer
Arran Cudbard-Bell [Sun, 30 Sep 2018 15:53:52 +0000 (23:53 +0800)] 
Initialise output pointer

7 years agoInitialise client in a way that Clang Analyzer understands
Arran Cudbard-Bell [Sun, 30 Sep 2018 15:47:41 +0000 (23:47 +0800)] 
Initialise client in a way that Clang Analyzer understands

7 years agoUse corrext context
Arran Cudbard-Bell [Sun, 30 Sep 2018 14:11:06 +0000 (22:11 +0800)] 
Use corrext context

7 years agoBetter encapsulate regex match data
Arran Cudbard-Bell [Sun, 30 Sep 2018 13:32:17 +0000 (21:32 +0800)] 
Better encapsulate regex match data

Switch regex xlat to an async expression.

Make regex xalt ploymorphic to allow querying by name or by capture number.

Allow N capture groups for PCRE and PCRE2 regexes.

7 years agoIf we have REGEX_PCRE2 or REGEX_PCRE set the feature 'regex-pcre' to true
Arran Cudbard-Bell [Fri, 28 Sep 2018 13:18:58 +0000 (21:18 +0800)] 
If we have REGEX_PCRE2 or REGEX_PCRE set the feature 'regex-pcre' to true

7 years agoAdd support for PCRE2 Closes #2315
Arran Cudbard-Bell [Fri, 28 Sep 2018 08:10:07 +0000 (16:10 +0800)] 
Add support for PCRE2 Closes #2315

7 years agoFix elsif (should be elif) in inet.c
Arran Cudbard-Bell [Fri, 28 Sep 2018 07:37:14 +0000 (15:37 +0800)] 
Fix elsif (should be elif) in inet.c

7 years agoFormatting and use talloc_bstrndup for binary safe copying of POSIX regex captures
Arran Cudbard-Bell [Thu, 27 Sep 2018 15:43:26 +0000 (23:43 +0800)] 
Formatting and use talloc_bstrndup for binary safe copying of POSIX regex captures

7 years agoFormatting
Arran Cudbard-Bell [Thu, 27 Sep 2018 15:42:10 +0000 (23:42 +0800)] 
Formatting

7 years agoFormatting
Arran Cudbard-Bell [Thu, 27 Sep 2018 15:41:14 +0000 (23:41 +0800)] 
Formatting

7 years agoExplicitly prevent overflow
Arran Cudbard-Bell [Wed, 26 Sep 2018 23:42:03 +0000 (07:42 +0800)] 
Explicitly prevent overflow

7 years agomove common code to fr_app_process_instantiate()
Alan T. DeKok [Wed, 26 Sep 2018 19:24:10 +0000 (15:24 -0400)] 
move common code to fr_app_process_instantiate()

7 years agoLength changes size and size between versions of json-c
Arran Cudbard-Bell [Wed, 26 Sep 2018 18:42:04 +0000 (02:42 +0800)] 
Length changes size and size between versions of json-c

7 years agocall tokenize_cast only if there's a cast
Alan T. DeKok [Wed, 26 Sep 2018 18:50:02 +0000 (14:50 -0400)] 
call tokenize_cast only if there's a cast

7 years agomove "bootstrap app_process" into common function
Alan T. DeKok [Wed, 26 Sep 2018 12:53:13 +0000 (08:53 -0400)] 
move "bootstrap app_process" into common function

7 years agoFix potential NULL dereference for function with NULL argument list
Arran Cudbard-Bell [Wed, 26 Sep 2018 10:23:30 +0000 (18:23 +0800)] 
Fix potential NULL dereference for function with NULL argument list

7 years agoShould be const too
Arran Cudbard-Bell [Wed, 26 Sep 2018 09:48:47 +0000 (17:48 +0800)] 
Should be const too

7 years agoFix clang scan stupidity
Arran Cudbard-Bell [Wed, 26 Sep 2018 07:02:37 +0000 (15:02 +0800)] 
Fix clang scan stupidity

7 years agoFix incorrect return code check for cond_tokenize_cast
Arran Cudbard-Bell [Wed, 26 Sep 2018 06:29:53 +0000 (14:29 +0800)] 
Fix incorrect return code check for cond_tokenize_cast

Fix uninitialised return in input on error

7 years agoOut may be NULL
Arran Cudbard-Bell [Wed, 26 Sep 2018 06:25:01 +0000 (14:25 +0800)] 
Out may be NULL

7 years agoDeal with NULL ptr value in dlist code
Arran Cudbard-Bell [Wed, 26 Sep 2018 06:23:03 +0000 (14:23 +0800)] 
Deal with NULL ptr value in dlist code

Markup other arguments as nonnull, so we get warnings earlier in clang scan

7 years agoMove fr_command_register_hook call inside the HAVE_PTHREAD_H ifdef
Arran Cudbard-Bell [Wed, 26 Sep 2018 06:18:12 +0000 (14:18 +0800)] 
Move fr_command_register_hook call inside the HAVE_PTHREAD_H ifdef

We only spawn workers if we're built with threads, and the list is life uninitialised otherwise

7 years agoDon't continue if we error out spawning worker threads, destroy the scheduler and...
Arran Cudbard-Bell [Wed, 26 Sep 2018 06:17:30 +0000 (14:17 +0800)] 
Don't continue if we error out spawning worker threads, destroy the scheduler and return NULL

7 years agoSilence various compiler warnings in Clang 7.0
Arran Cudbard-Bell [Wed, 26 Sep 2018 06:07:09 +0000 (14:07 +0800)] 
Silence various compiler warnings in Clang 7.0

7 years agomove common code to master_io mod_instantiate()
Alan T. DeKok [Tue, 25 Sep 2018 23:00:29 +0000 (19:00 -0400)] 
move common code to master_io mod_instantiate()

7 years agomove common code to master_io mod_bootstrap()
Alan T. DeKok [Tue, 25 Sep 2018 22:55:49 +0000 (18:55 -0400)] 
move common code to master_io mod_bootstrap()

7 years agomove dynamic_submodule into master_io
Alan T. DeKok [Tue, 25 Sep 2018 22:15:44 +0000 (18:15 -0400)] 
move dynamic_submodule into master_io

now that we have master_io bootstrap, etc. functions.
All of the duplicated work can be done there.

7 years agowe no longer need master IO talloc context
Alan T. DeKok [Tue, 25 Sep 2018 22:12:14 +0000 (18:12 -0400)] 
we no longer need master IO talloc context

7 years agoparent things from the parent structure
Alan T. DeKok [Tue, 25 Sep 2018 22:11:58 +0000 (18:11 -0400)] 
parent things from the parent structure

7 years agoignore editor ~ files
Alan T. DeKok [Tue, 25 Sep 2018 21:41:56 +0000 (17:41 -0400)] 
ignore editor ~ files

7 years agotypo
Alan T. DeKok [Tue, 25 Sep 2018 19:06:27 +0000 (15:06 -0400)] 
typo

7 years agomove fr_io_client_t handling to destructor
Alan T. DeKok [Tue, 25 Sep 2018 19:06:10 +0000 (15:06 -0400)] 
move fr_io_client_t handling to destructor

7 years agomove "live" to it's own variable
Alan T. DeKok [Tue, 25 Sep 2018 18:51:40 +0000 (14:51 -0400)] 
move "live" to it's own variable

7 years agomore separation of variables
Alan T. DeKok [Tue, 25 Sep 2018 18:46:18 +0000 (14:46 -0400)] 
more separation of variables

7 years agomore separation of "const inst" and non-const thread_instance
Alan T. DeKok [Tue, 25 Sep 2018 18:40:12 +0000 (14:40 -0400)] 
more separation of "const inst" and non-const thread_instance

7 years agomake fr_io_instance_t "const"
Alan T. DeKok [Tue, 25 Sep 2018 17:47:04 +0000 (13:47 -0400)] 
make fr_io_instance_t "const"

7 years agoclean up talloc parenting
Alan T. DeKok [Tue, 25 Sep 2018 17:44:22 +0000 (13:44 -0400)] 
clean up talloc parenting

in preparation for making fr_io_instance_t "const"

7 years agoheader levels
Matthew Newton [Tue, 25 Sep 2018 21:10:14 +0000 (22:10 +0100)] 
header levels

7 years agodictionary doesn't have a .conf suffix, include it anyway
Matthew Newton [Tue, 25 Sep 2018 21:03:19 +0000 (22:03 +0100)] 
dictionary doesn't have a .conf suffix, include it anyway

7 years agoconvert local links to inter-document cross-refs
Matthew Newton [Tue, 25 Sep 2018 20:52:21 +0000 (21:52 +0100)] 
convert local links to inter-document cross-refs

7 years agoadd comment to get auto-expanded in asciidoc
Matthew Newton [Tue, 25 Sep 2018 20:25:15 +0000 (21:25 +0100)] 
add comment to get auto-expanded in asciidoc

7 years agomake sure asciidoc links are in inter-document xref format
Matthew Newton [Tue, 25 Sep 2018 16:18:37 +0000 (17:18 +0100)] 
make sure asciidoc links are in inter-document xref format

So that when files are converted to HTML, they still link nicely
to each other.

7 years agofix links
Matthew Newton [Tue, 25 Sep 2018 20:23:51 +0000 (21:23 +0100)] 
fix links

7 years agoconvert to markdown (text still needs updating)
Matthew Newton [Tue, 25 Sep 2018 20:22:53 +0000 (21:22 +0100)] 
convert to markdown (text still needs updating)

7 years agoconvert asciidoc to pretty HTML
Matthew Newton [Sun, 23 Sep 2018 20:50:43 +0000 (21:50 +0100)] 
convert asciidoc to pretty HTML

7 years agoremove "parent" from client
Alan T. DeKok [Tue, 25 Sep 2018 17:37:36 +0000 (13:37 -0400)] 
remove "parent" from client

we have access to the relevant fields already

7 years agoone more const issue
Alan T. DeKok [Tue, 25 Sep 2018 13:21:44 +0000 (09:21 -0400)] 
one more const issue

7 years agomove mod_open() to using thread_instance
Alan T. DeKok [Tue, 25 Sep 2018 12:37:10 +0000 (08:37 -0400)] 
move mod_open() to using thread_instance

7 years agouse thread_instance
Alan T. DeKok [Tue, 25 Sep 2018 11:52:57 +0000 (07:52 -0400)] 
use thread_instance

7 years agoconst issues
Alan T. DeKok [Tue, 25 Sep 2018 10:35:13 +0000 (06:35 -0400)] 
const issues

7 years agoThe length of chap challenge isn't bounded
Arran Cudbard-Bell [Tue, 25 Sep 2018 02:44:18 +0000 (10:44 +0800)] 
The length of chap challenge isn't bounded

7 years agohandle longer CHAP-Password when using debug level 3
Alan T. DeKok [Mon, 24 Sep 2018 23:07:59 +0000 (19:07 -0400)] 
handle longer CHAP-Password when using debug level 3

7 years agomove writable socket stuff to private structure
Alan T. DeKok [Fri, 21 Sep 2018 18:01:55 +0000 (14:01 -0400)] 
move writable socket stuff to private structure

which means we're one step closer to using thread_instance

and we can now remove mod_detach(), as the per-socket stuff
is talloc'd, and we can use a talloc destructor for it

7 years agodetach can only be called for the main instance
Alan T. DeKok [Fri, 21 Sep 2018 17:36:46 +0000 (13:36 -0400)] 
detach can only be called for the main instance

not for child connections

7 years ago"open" shouldn't be called for connections
Alan T. DeKok [Fri, 21 Sep 2018 17:33:56 +0000 (13:33 -0400)] 
"open" shouldn't be called for connections

7 years agomake app_io_instance "const"
Alan T. DeKok [Fri, 21 Sep 2018 17:29:34 +0000 (13:29 -0400)] 
make app_io_instance "const"

in yet another step to making thread-specific data structures

7 years agodon't call detach, the dl APIs take care of that for us
Alan T. DeKok [Fri, 21 Sep 2018 17:27:04 +0000 (13:27 -0400)] 
don't call detach, the dl APIs take care of that for us

7 years agowrite to thread_instance, and then copy it to app_io_instance
Alan T. DeKok [Fri, 21 Sep 2018 17:26:15 +0000 (13:26 -0400)] 
write to thread_instance, and then copy it to app_io_instance

7 years agoRevert "move "free clients" to mod_close(), instead of mod_detach()"
Alan T. DeKok [Fri, 21 Sep 2018 17:21:50 +0000 (13:21 -0400)] 
Revert "move "free clients" to mod_close(), instead of mod_detach()"

This reverts commit a505ccc195fc49847166ad2bf3839e099282944b.

we don't yet have thread-specific data structures for sockets.
so the "alive_clients" are still in the app_io_instance, not the
thread_instance.  Once we have thread data, the alive_clients
can move there, and then be free'd on mod_close()

7 years agodon't bind client tcp sockets
Alan T. DeKok [Fri, 21 Sep 2018 16:09:10 +0000 (12:09 -0400)] 
don't bind client tcp sockets