]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
7 years agoMake the tests work without an internet connection/DNS cache
Arran Cudbard-Bell [Fri, 1 Mar 2019 05:50:27 +0000 (13:50 +0800)] 
Make the tests work without an internet connection/DNS cache

7 years agoUsing the standard fr_strerror functions produces identical errors to passing around...
Arran Cudbard-Bell [Fri, 1 Mar 2019 05:14:51 +0000 (13:14 +0800)] 
Using the standard fr_strerror functions produces identical errors to passing around a static char **error pointer

Error can now be stacked too, which generally gives the user much better context.

7 years agoIn the vast majority of cases we no longer need to modify the input string
Arran Cudbard-Bell [Fri, 1 Mar 2019 02:41:49 +0000 (10:41 +0800)] 
In the vast majority of cases we no longer need to modify the input string

7 years agoas posted to the list
Alan T. DeKok [Thu, 28 Feb 2019 12:39:33 +0000 (07:39 -0500)] 
as posted to the list

7 years agoFix DHCPv6 bool test
Arran Cudbard-Bell [Thu, 28 Feb 2019 10:22:02 +0000 (18:22 +0800)] 
Fix DHCPv6 bool test

Like EAP-SIM, DHCPv6 represents bools by presence (if true), or absence (if false), of the option.

7 years agoChange length to operate on incoming boxes instead of using an attribute ref
Arran Cudbard-Bell [Thu, 28 Feb 2019 10:15:38 +0000 (18:15 +0800)] 
Change length to operate on incoming boxes instead of using an attribute ref

The general rule is that refs are only used where information from the VALUE_PAIR is required

7 years agocomment out illegal dictionaries
Alan T. DeKok [Wed, 27 Feb 2019 22:14:51 +0000 (17:14 -0500)] 
comment out illegal dictionaries

these vendors haven't shipped product for a decade.  People
wanting terrible attributes can deal with it themselves

7 years agobutchery to make the tests pass.
Alan T. DeKok [Wed, 27 Feb 2019 21:21:28 +0000 (16:21 -0500)] 
butchery to make the tests pass.

Fix the unit-test dictionary so that it doesn't barf.

Fix all.mk so that it doesn't depend on a file that doesn't exist

Move most of the "Unit-*" tests to radius_unit.txt

remove dict.txt and command.txt from running during the tests.

For dict.txt, the framework doesn't provide for dictionary
definitions within a BEGIN-PROTOCOL framework.

For command.txt, the command parser no longer allows ":" in command
names, and there's no point in tracking it down right now.

7 years agoload the radius dictionary, too
Alan T. DeKok [Wed, 27 Feb 2019 21:02:12 +0000 (16:02 -0500)] 
load the radius dictionary, too

7 years agodon't depend on a file which doesn't exist
Alan T. DeKok [Wed, 27 Feb 2019 20:47:40 +0000 (15:47 -0500)] 
don't depend on a file which doesn't exist

t means that the unit tests haven't been running for months.

7 years agosome fixes to make it slightly better
Alan T. DeKok [Wed, 27 Feb 2019 20:19:01 +0000 (15:19 -0500)] 
some fixes to make it slightly better

7 years agoactually showing encoded data would be useful
Alan T. DeKok [Wed, 27 Feb 2019 19:50:55 +0000 (14:50 -0500)] 
actually showing encoded data would be useful

7 years agoMerge pull request #2535 from jpereira/v4/fix5
Alan DeKok [Wed, 27 Feb 2019 16:08:53 +0000 (11:08 -0500)] 
Merge pull request #2535 from jpereira/v4/fix5

rlm_isc_dhcp: Fix initialization

7 years agorlm_isc_dhcp: Fix initialization 2535/head
Jorge Pereira [Wed, 27 Feb 2019 16:07:27 +0000 (13:07 -0300)] 
rlm_isc_dhcp: Fix initialization

7 years agotypo
Alan T. DeKok [Wed, 27 Feb 2019 16:01:23 +0000 (11:01 -0500)] 
typo

7 years agoparse `server-identifier IPADDR`
Alan T. DeKok [Wed, 27 Feb 2019 15:58:10 +0000 (10:58 -0500)] 
parse `server-identifier IPADDR`

and do some minor cleanups

7 years agoone more fr_skip_spaces
Alan T. DeKok [Wed, 27 Feb 2019 13:43:18 +0000 (08:43 -0500)] 
one more fr_skip_spaces

7 years agoDoxygen
Arran Cudbard-Bell [Wed, 27 Feb 2019 12:23:07 +0000 (20:23 +0800)] 
Doxygen

7 years agoDrop h and H from randstr, people should use %{hex:%{randstr:b}} instead
Arran Cudbard-Bell [Wed, 27 Feb 2019 11:53:24 +0000 (19:53 +0800)] 
Drop h and H from randstr, people should use %{hex:%{randstr:b}} instead

- They were only there because the xlat evaluation code wasn't binary safe.  Now it is, there's no reason to keep them.
- Make generating large amounts of random binary data more efficient
- Increase repetition limit to 1024 and warn if we override what the user specified

7 years agoUnconst errstr
Arran Cudbard-Bell [Wed, 27 Feb 2019 11:44:08 +0000 (19:44 +0800)] 
Unconst errstr

7 years agoDon't leak errstr
Arran Cudbard-Bell [Wed, 27 Feb 2019 07:17:07 +0000 (15:17 +0800)] 
Don't leak errstr

7 years agoAllow fmt arguments in RDMARKER and REMARKER
Arran Cudbard-Bell [Wed, 27 Feb 2019 07:14:40 +0000 (15:14 +0800)] 
Allow fmt arguments in RDMARKER and REMARKER

7 years agoFix function documentation
Arran Cudbard-Bell [Wed, 27 Feb 2019 06:45:49 +0000 (14:45 +0800)] 
Fix function documentation

7 years agoDon't print anything if we're outside a module
Arran Cudbard-Bell [Wed, 27 Feb 2019 06:43:33 +0000 (14:43 +0800)] 
Don't print anything if we're outside a module

7 years agoMove skip spaces macro
Arran Cudbard-Bell [Wed, 27 Feb 2019 06:40:18 +0000 (14:40 +0800)] 
Move skip spaces macro

7 years agoUse fr_skip_spaces macro
Arran Cudbard-Bell [Wed, 27 Feb 2019 06:38:08 +0000 (14:38 +0800)] 
Use fr_skip_spaces macro

7 years agoAdd fr_value_box_list_len_min
Arran Cudbard-Bell [Wed, 27 Feb 2019 06:37:43 +0000 (14:37 +0800)] 
Add fr_value_box_list_len_min

7 years agoPrint concat error
Arran Cudbard-Bell [Wed, 27 Feb 2019 05:28:40 +0000 (13:28 +0800)] 
Print concat error

7 years agoMerge pull request #2530 from jpereira/v4/util1
Arran Cudbard-Bell [Wed, 27 Feb 2019 05:28:18 +0000 (13:28 +0800)] 
Merge pull request #2530 from jpereira/v4/util1

Add fr_skip_spaces() helper to strip whitespace

7 years agoMerge pull request #2531 from jpereira/v4/value-length
Arran Cudbard-Bell [Wed, 27 Feb 2019 05:27:55 +0000 (13:27 +0800)] 
Merge pull request #2531 from jpereira/v4/value-length

Add fr_value_box_list_length() function

7 years agoVarious xlat cleanups
Arran Cudbard-Bell [Wed, 27 Feb 2019 03:18:41 +0000 (11:18 +0800)] 
Various xlat cleanups

7 years agoAdd fr_value_box_list_length() function 2531/head
Jorge Pereira [Wed, 27 Feb 2019 03:04:24 +0000 (00:04 -0300)] 
Add fr_value_box_list_length() function

7 years agoAdd fr_skip_spaces() helper to strip whitespace 2530/head
Jorge Pereira [Wed, 27 Feb 2019 01:43:15 +0000 (22:43 -0300)] 
Add fr_skip_spaces() helper to strip whitespace

7 years agoMerge pull request #2529 from jpereira/v4/xlat-async-tag
Arran Cudbard-Bell [Wed, 27 Feb 2019 01:08:28 +0000 (09:08 +0800)] 
Merge pull request #2529 from jpereira/v4/xlat-async-tag

xlat: move '%{tag: ...}' to async

7 years agoMerge branch 'master' into v4/xlat-async-tag 2529/head
Arran Cudbard-Bell [Wed, 27 Feb 2019 01:08:21 +0000 (09:08 +0800)] 
Merge branch 'master' into v4/xlat-async-tag

7 years agoMerge pull request #2528 from jpereira/v4/xlat-async-length
Arran Cudbard-Bell [Wed, 27 Feb 2019 01:07:21 +0000 (09:07 +0800)] 
Merge pull request #2528 from jpereira/v4/xlat-async-length

xlat: move '%{length: ...} to async

7 years agoMerge branch 'master' into v4/xlat-async-length 2528/head
Arran Cudbard-Bell [Wed, 27 Feb 2019 01:06:53 +0000 (09:06 +0800)] 
Merge branch 'master' into v4/xlat-async-length

7 years agoMerge pull request #2523 from jpereira/v4/xlat-async-strlen
Arran Cudbard-Bell [Wed, 27 Feb 2019 00:59:37 +0000 (08:59 +0800)] 
Merge pull request #2523 from jpereira/v4/xlat-async-strlen

xlat: move '%{strlen: ...} to async

7 years agoMerge branch 'master' into v4/xlat-async-strlen 2523/head
Arran Cudbard-Bell [Wed, 27 Feb 2019 00:59:09 +0000 (08:59 +0800)] 
Merge branch 'master' into v4/xlat-async-strlen

7 years agoMerge pull request #2522 from jpereira/v4/xlat-async-module
Arran Cudbard-Bell [Wed, 27 Feb 2019 00:56:38 +0000 (08:56 +0800)] 
Merge pull request #2522 from jpereira/v4/xlat-async-module

xlat: move '%{module: ...} to async

7 years agoxlat: move '%{tag: ...}' to async
Jorge Pereira [Tue, 26 Feb 2019 23:56:49 +0000 (20:56 -0300)] 
xlat: move '%{tag: ...}' to async

7 years agofixup! xlat: move '%{length: ...}' to async
Jorge Pereira [Tue, 26 Feb 2019 23:44:02 +0000 (20:44 -0300)] 
fixup! xlat: move '%{length: ...}' to async

7 years agoxlat: move '%{length: ...}' to async
Jorge Pereira [Tue, 26 Feb 2019 23:24:02 +0000 (20:24 -0300)] 
xlat: move '%{length: ...}' to async

7 years agoadd support for `next-address IPADDR`
Alan T. DeKok [Tue, 26 Feb 2019 22:51:11 +0000 (17:51 -0500)] 
add support for `next-address IPADDR`

7 years agoadd parsers for `server-name STRING` and `filename STRING`
Alan T. DeKok [Tue, 26 Feb 2019 22:22:13 +0000 (17:22 -0500)] 
add parsers for `server-name STRING` and `filename STRING`

7 years agotypo
Alan T. DeKok [Tue, 26 Feb 2019 22:22:05 +0000 (17:22 -0500)] 
typo

7 years agoxlat: move '%{module: ...} to async 2522/head
Jorge Pereira [Tue, 26 Feb 2019 18:28:44 +0000 (15:28 -0300)] 
xlat: move '%{module: ...} to async

7 years agoremove extraneous printf
Alan T. DeKok [Tue, 26 Feb 2019 18:25:35 +0000 (13:25 -0500)] 
remove extraneous printf

7 years agomake hosts global
Alan T. DeKok [Tue, 26 Feb 2019 18:23:54 +0000 (13:23 -0500)] 
make hosts global

7 years agoxlat: move '%{strlen: ...} to async
Jorge Pereira [Tue, 26 Feb 2019 16:24:00 +0000 (13:24 -0300)] 
xlat: move '%{strlen: ...} to async

7 years agoremove duplicate sql config
Matthew Newton [Tue, 26 Feb 2019 16:05:20 +0000 (16:05 +0000)] 
remove duplicate sql config

7 years agoFix libcurl's apparently random line termination and concatenation in debug output
Arran Cudbard-Bell [Tue, 26 Feb 2019 14:01:27 +0000 (22:01 +0800)] 
Fix libcurl's apparently random line termination and concatenation in debug output

7 years agoDoxygen?
Arran Cudbard-Bell [Tue, 26 Feb 2019 11:48:59 +0000 (19:48 +0800)] 
Doxygen?

7 years agoAdd length to rest_debug_log
Arran Cudbard-Bell [Tue, 26 Feb 2019 11:47:18 +0000 (19:47 +0800)] 
Add length to rest_debug_log

7 years agoMinor doc typos closes #2524
Arran Cudbard-Bell [Tue, 26 Feb 2019 11:37:18 +0000 (19:37 +0800)] 
Minor doc typos closes #2524

7 years agoAdd debug functions for libcurl
Arran Cudbard-Bell [Tue, 26 Feb 2019 11:00:07 +0000 (19:00 +0800)] 
Add debug functions for libcurl

7 years agoIntegers passed to curl_set_option should be long
Arran Cudbard-Bell [Tue, 26 Feb 2019 10:59:56 +0000 (18:59 +0800)] 
Integers passed to curl_set_option should be long

7 years agoShould be debug level 2
Arran Cudbard-Bell [Tue, 26 Feb 2019 10:59:06 +0000 (18:59 +0800)] 
Should be debug level 2

7 years agoFormatting
Arran Cudbard-Bell [Tue, 26 Feb 2019 09:20:48 +0000 (17:20 +0800)] 
Formatting

7 years agoTypo
Arran Cudbard-Bell [Tue, 26 Feb 2019 09:20:38 +0000 (17:20 +0800)] 
Typo

7 years agoDocument PostgreSQL states override
Arran Cudbard-Bell [Tue, 26 Feb 2019 09:05:47 +0000 (17:05 +0800)] 
Document PostgreSQL states override

7 years agoRename 'done' rcode
Arran Cudbard-Bell [Tue, 26 Feb 2019 09:00:22 +0000 (17:00 +0800)] 
Rename 'done' rcode

7 years agoShouldn't be a title for $-INCLUDE
Arran Cudbard-Bell [Tue, 26 Feb 2019 09:00:10 +0000 (17:00 +0800)] 
Shouldn't be a title for $-INCLUDE

7 years agoBuild error
Arran Cudbard-Bell [Tue, 26 Feb 2019 08:23:02 +0000 (16:23 +0800)] 
Build error

7 years agoAllow user configurable sqlstate return codes for PostgreSQL
Arran Cudbard-Bell [Tue, 26 Feb 2019 07:07:40 +0000 (15:07 +0800)] 
Allow user configurable sqlstate return codes for PostgreSQL

7 years agoFormatting
Arran Cudbard-Bell [Tue, 26 Feb 2019 05:47:34 +0000 (13:47 +0800)] 
Formatting

7 years agoDefault to sending the application name in v4
Arran Cudbard-Bell [Tue, 26 Feb 2019 05:43:49 +0000 (13:43 +0800)] 
Default to sending the application name in v4

7 years agoFunction to mark pair as parsed, for when we're manually processing pairs
Arran Cudbard-Bell [Tue, 26 Feb 2019 05:42:51 +0000 (13:42 +0800)] 
Function to mark pair as parsed, for when we're manually processing pairs

7 years agoMinor fixes in trie function
Arran Cudbard-Bell [Tue, 26 Feb 2019 05:42:23 +0000 (13:42 +0800)] 
Minor fixes in trie function

- Data to insert should be marked as const
- Callback should take keylen as size_t

7 years agoNotes on setting up PostgreSQL server for macOS
Arran Cudbard-Bell [Tue, 26 Feb 2019 05:35:43 +0000 (13:35 +0800)] 
Notes on setting up PostgreSQL server for macOS

7 years agoadd "pedantic" flag
Alan T. DeKok [Mon, 25 Feb 2019 20:44:23 +0000 (15:44 -0500)] 
add "pedantic" flag

7 years agoadd "inst" to parsing state
Alan T. DeKok [Mon, 25 Feb 2019 20:34:14 +0000 (15:34 -0500)] 
add "inst" to parsing state

7 years agocheck for first 3 characters, to avoid strncmp() cost
Alan T. DeKok [Mon, 25 Feb 2019 20:31:54 +0000 (15:31 -0500)] 
check for first 3 characters, to avoid strncmp() cost

7 years agotypo
Alan T. DeKok [Mon, 25 Feb 2019 20:31:44 +0000 (15:31 -0500)] 
typo

7 years agoencode "bool" types, too
Alan T. DeKok [Mon, 25 Feb 2019 20:29:16 +0000 (15:29 -0500)] 
encode "bool" types, too

7 years agorun through the formatting script.
Alan T. DeKok [Mon, 25 Feb 2019 20:23:04 +0000 (15:23 -0500)] 
run through the formatting script.

and touch up a few attributes

7 years agoMerge pull request #2514 from jpereira/v4/isc-dictionary2
Alan DeKok [Mon, 25 Feb 2019 20:05:32 +0000 (15:05 -0500)] 
Merge pull request #2514 from jpereira/v4/isc-dictionary2

Add ISC dictionaries for rlm_isc_dhcp. ref #2501

7 years agoMerge pull request #2519 from jpereira/v4/fix1
Alan DeKok [Mon, 25 Feb 2019 20:01:26 +0000 (15:01 -0500)] 
Merge pull request #2519 from jpereira/v4/fix1

rlm_isc_dhcp: Add missing talloc_free()

7 years agorlm_isc_dhcp: Add missing talloc_free() 2519/head
Jorge Pereira [Mon, 25 Feb 2019 19:47:55 +0000 (16:47 -0300)] 
rlm_isc_dhcp: Add missing talloc_free()

7 years agoallow and parse 'array of'
Alan T. DeKok [Sun, 24 Feb 2019 18:21:56 +0000 (13:21 -0500)] 
allow and parse 'array of'

and parse arrays attributes properly, too

7 years agocreate a new VP for each array VPs
Alan T. DeKok [Sun, 24 Feb 2019 18:21:29 +0000 (13:21 -0500)] 
create a new VP for each array VPs

7 years agoadd in the new option that the user defined
Alan T. DeKok [Sun, 24 Feb 2019 18:00:58 +0000 (13:00 -0500)] 
add in the new option that the user defined

7 years agostart of adding option definitions
Alan T. DeKok [Sun, 24 Feb 2019 17:02:26 +0000 (12:02 -0500)] 
start of adding option definitions

7 years agocleanups and fixes
Alan T. DeKok [Sun, 24 Feb 2019 15:34:30 +0000 (10:34 -0500)] 
cleanups and fixes

differentiate between options we deliberately ignore, and ones
we don't implement.

start of parsing for multiple different option statements

7 years agorlm_isc_dhcp: Add ISC dictionary. ref #2501 2514/head
Jorge Pereira [Sat, 23 Feb 2019 23:31:52 +0000 (20:31 -0300)] 
rlm_isc_dhcp: Add ISC dictionary. ref #2501

7 years agodon't print offset
Alan T. DeKok [Sat, 23 Feb 2019 19:04:06 +0000 (14:04 -0500)] 
don't print offset

we don't track which token came from which line, so it's best
to not mislead the admin.

We can fix this by tracking line numbers and start of lines
in the input buffer, which is a bit more work...

7 years agostart of a parser for quoted strings, too
Alan T. DeKok [Sat, 23 Feb 2019 19:03:49 +0000 (14:03 -0500)] 
start of a parser for quoted strings, too

7 years agouse a macro for less cut & paste
Alan T. DeKok [Sat, 23 Feb 2019 18:39:48 +0000 (13:39 -0500)] 
use a macro for less cut & paste

note that the macro is lowercase, for less shouting.
It also lets us more clearly distinguish between the "not done"
commands, and the commands which do something

7 years agoadd more commands. Manual merge of #2515
Alan T. DeKok [Sat, 23 Feb 2019 18:38:10 +0000 (13:38 -0500)] 
add more commands.  Manual merge of #2515

7 years agolook at first character for speed
Alan T. DeKok [Sat, 23 Feb 2019 18:37:46 +0000 (13:37 -0500)] 
look at first character for speed

7 years agoxlat_debug_attr should not produce an error if we're not at DEBUG level 2
Arran Cudbard-Bell [Sat, 23 Feb 2019 14:52:24 +0000 (22:52 +0800)] 
xlat_debug_attr should not produce an error if we're not at DEBUG level 2

I think these were previously ignored in bare xlats which is why this wasn't previously a problem

7 years agoChange more messages to DEBUG2
Arran Cudbard-Bell [Sat, 23 Feb 2019 14:39:24 +0000 (22:39 +0800)] 
Change more messages to DEBUG2

7 years agoPrint the result of policy evaluations
Arran Cudbard-Bell [Sat, 23 Feb 2019 14:30:10 +0000 (22:30 +0800)] 
Print the result of policy evaluations

7 years agoSwitch most calls to RDEBUG to REDBUG2
Arran Cudbard-Bell [Sat, 23 Feb 2019 14:01:34 +0000 (22:01 +0800)] 
Switch most calls to RDEBUG to REDBUG2

Frontend modules left using RDEBUG, module return codes changed to RDEBUG, this should hopefully produce more consistent debug output, and make radiusd -x  more useful

7 years agoUse fr_value_box_to_network in DHCPv4 encoder
Arran Cudbard-Bell [Sat, 23 Feb 2019 13:59:22 +0000 (21:59 +0800)] 
Use fr_value_box_to_network in DHCPv4 encoder

7 years agoremove the options from the top-level table.
Alan T. DeKok [Fri, 22 Feb 2019 22:40:58 +0000 (17:40 -0500)] 
remove the options from the top-level table.

The options are implicit in `option NAME VALUE`

the NAME is looked up in the DHCPv4 dictionary

7 years agoignore boolean options with "ignore"
Alan T. DeKok [Fri, 22 Feb 2019 20:23:29 +0000 (15:23 -0500)] 
ignore boolean options with "ignore"

7 years agoformatting
Alan T. DeKok [Fri, 22 Feb 2019 20:20:23 +0000 (15:20 -0500)] 
formatting

7 years agomake notes about matching `host` only if `fixed-address` matches
Alan T. DeKok [Fri, 22 Feb 2019 20:12:05 +0000 (15:12 -0500)] 
make notes about matching `host` only if `fixed-address` matches

7 years agomove to binary search for commands
Alan T. DeKok [Fri, 22 Feb 2019 20:11:43 +0000 (15:11 -0500)] 
move to binary search for commands