]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
6 years agomore memory checks
Alan T. DeKok [Sun, 25 Aug 2019 20:35:04 +0000 (16:35 -0400)] 
more memory checks

6 years agofree memory on error
Alan T. DeKok [Sun, 25 Aug 2019 19:58:45 +0000 (15:58 -0400)] 
free memory on error

6 years agoallow match operator in regex, e.g. foo =~ m,bar,
Alan T. DeKok [Sun, 25 Aug 2019 19:55:16 +0000 (15:55 -0400)] 
allow match operator in regex, e.g. foo =~ m,bar,

which is sometimes nice to use.

6 years agomove check regex flags to after we create the map
Alan T. DeKok [Sun, 25 Aug 2019 19:50:44 +0000 (15:50 -0400)] 
move check regex flags to after we create the map

6 years agochange "allow_regex" to "require_regex"
Alan T. DeKok [Sun, 25 Aug 2019 19:44:49 +0000 (15:44 -0400)] 
change "allow_regex" to "require_regex"

which more closely matches our use-case

and pass the correct flag to tmpl_preparse()

6 years agouse correct data type
Alan T. DeKok [Sun, 25 Aug 2019 19:18:36 +0000 (15:18 -0400)] 
use correct data type

6 years agorename variables
Alan T. DeKok [Sun, 25 Aug 2019 18:27:11 +0000 (14:27 -0400)] 
rename variables

6 years agomove code to separate functions
Alan T. DeKok [Sun, 25 Aug 2019 18:26:33 +0000 (14:26 -0400)] 
move code to separate functions

which makes the flow of the parser easier to understand

6 years agologin attempts are messages, not errors
Alan T. DeKok [Sun, 25 Aug 2019 17:51:43 +0000 (13:51 -0400)] 
login attempts are messages, not errors

6 years agoWe should quote ${...} feature expansions
Alan T. DeKok [Sun, 25 Aug 2019 17:45:02 +0000 (13:45 -0400)] 
We should quote ${...} feature expansions

Otherwise when the feature is turned off, we start with:

if (${feature} == 'no')

and end up with

if ( == 'no')

Which is bad.

The old conditional parser accepted it, which is arguably wrong.
The new one is a bit smarter, and is more picky.

6 years agomake condition call tmpl_preparse()
Alan T. DeKok [Sun, 25 Aug 2019 13:10:25 +0000 (09:10 -0400)] 
make condition call tmpl_preparse()

which remove substantial amounts of code from the condition
parser

6 years agoadd "len" to tmpl_from_attr_substr()
Alan T. DeKok [Sun, 25 Aug 2019 12:51:02 +0000 (08:51 -0400)] 
add "len" to tmpl_from_attr_substr()

so that we can call it on pre-parsed data, and so that it
doesn't do strlen()

6 years agotmpl_afrom_str() now calls tmpl_from_attr_substr
Alan T. DeKok [Sun, 25 Aug 2019 01:24:06 +0000 (21:24 -0400)] 
tmpl_afrom_str() now calls tmpl_from_attr_substr

instead of tmpl_from_attr_str()

Because the tmpl_from_attr() functions don't take or respect
'inlen', which means that they parse too much.

6 years agoadd tmpl_preparse()
Alan T. DeKok [Sat, 24 Aug 2019 14:49:38 +0000 (10:49 -0400)] 
add tmpl_preparse()

Which pre-parses a string based on various criteria.
The caller gets told what kind of string it is, and what
parameters should be passed to tmpl_afrom_str()

6 years agoadd a list of all data types
Alan T. DeKok [Fri, 23 Aug 2019 18:59:57 +0000 (14:59 -0400)] 
add a list of all data types

6 years agoRemove som references to fr_pair_cursor
Arran Cudbard-Bell [Sat, 24 Aug 2019 22:50:18 +0000 (18:50 -0400)] 
Remove som references to fr_pair_cursor

6 years agodoc: fix link
Matthew Newton [Sat, 24 Aug 2019 16:07:51 +0000 (17:07 +0100)] 
doc: fix link

6 years agoMerge man/man5/rlm_$mod & raddb/mods-available/$mod (#2917)
Jorge Pereira [Fri, 23 Aug 2019 20:12:40 +0000 (17:12 -0300)] 
Merge man/man5/rlm_$mod & raddb/mods-available/$mod (#2917)

* Remove man/man5/rlm_idn.5

* Remove man/man5/rlm_digest.5

* Remove man/man5/rlm_sql.5

* Merge rlm_detail.5 with raddb/mods-available/detail

The 'man/man5/rlm_detail.5' is not necessary anymore.

* Merge rlm_counter.5 with raddb/mods-available/counter

The 'man/man5/rlm_counter.5' is not necessary anymore.

* Merge rlm_expr.5 with raddb/mods-available/expr

The 'man/man5/rlm_expr.5' is not necessary anymore.

6 years agotypos
Alan T. DeKok [Fri, 23 Aug 2019 18:39:38 +0000 (14:39 -0400)] 
typos

6 years agolink to the main page
Alan T. DeKok [Fri, 23 Aug 2019 13:52:16 +0000 (09:52 -0400)] 
link to the main page

6 years agoMerge rlm_mschap.5 with raddb/mods-available/mschap
Jorge Pereira [Fri, 23 Aug 2019 18:22:19 +0000 (15:22 -0300)] 
Merge rlm_mschap.5 with raddb/mods-available/mschap

The 'man/man5/rlm_mschap.5' is not necessary anymore.

6 years agoMerge rlm_passwd.5 with raddb/mods-available/passwd
Jorge Pereira [Fri, 23 Aug 2019 18:08:17 +0000 (15:08 -0300)] 
Merge rlm_passwd.5 with raddb/mods-available/passwd

The 'man/man5/rlm_passwd.5' is not necessary anymore.

6 years agoMerge rlm_unix.5 with raddb/mods-available/unix
Jorge Pereira [Fri, 23 Aug 2019 14:16:58 +0000 (11:16 -0300)] 
Merge rlm_unix.5 with raddb/mods-available/unix

The 'man/man5/rlm_unix.5' is not necessary anymore.

6 years agoMerge rlm_chap.5 with raddb/mods-available/chap
Jorge Pereira [Fri, 23 Aug 2019 14:13:12 +0000 (11:13 -0300)] 
Merge rlm_chap.5 with raddb/mods-available/chap

The 'man/man5/rlm_chap.5' is not necessary anymore.

6 years agoMySQL queries.conf: Use expansions consistent with those of other drivers
Terry Burton [Fri, 23 Aug 2019 14:56:40 +0000 (15:56 +0100)] 
MySQL queries.conf: Use expansions consistent with those of other drivers

6 years agoPostgreSQL queries.conf: Fix typo in expansion
Terry Burton [Fri, 23 Aug 2019 14:55:51 +0000 (15:55 +0100)] 
PostgreSQL queries.conf: Fix typo in expansion

6 years agoOracle: Remove references to non-existent X-Ascend-Session-Svr-Key
Terry Burton [Fri, 16 Aug 2019 18:42:35 +0000 (19:42 +0100)] 
Oracle: Remove references to non-existent X-Ascend-Session-Svr-Key

6 years agoMSSQL: Remove references to non-existent X-Ascend-Session-Svr-Key
Terry Burton [Fri, 16 Aug 2019 18:42:08 +0000 (19:42 +0100)] 
MSSQL: Remove references to non-existent X-Ascend-Session-Svr-Key

6 years agoSQLite queries.conf: Simplify using expansions
Terry Burton [Fri, 16 Aug 2019 11:13:33 +0000 (12:13 +0100)] 
SQLite queries.conf: Simplify using expansions

6 years agoPostgreSQL queries.conf: Simplify using expansions
Terry Burton [Fri, 16 Aug 2019 11:12:58 +0000 (12:12 +0100)] 
PostgreSQL queries.conf: Simplify using expansions

6 years agoOracle queries.conf: Simplify using expansions
Terry Burton [Fri, 16 Aug 2019 11:12:28 +0000 (12:12 +0100)] 
Oracle queries.conf: Simplify using expansions

6 years agoMySQL queries.conf: Simplify using expansions
Terry Burton [Fri, 16 Aug 2019 11:11:42 +0000 (12:11 +0100)] 
MySQL queries.conf: Simplify using expansions

6 years agoMSSQL queries.conf: Simplify using expansions
Terry Burton [Fri, 16 Aug 2019 11:10:51 +0000 (12:10 +0100)] 
MSSQL queries.conf: Simplify using expansions

6 years agoCassandra queries.conf: Simplify using expansions
Terry Burton [Fri, 16 Aug 2019 11:09:24 +0000 (12:09 +0100)] 
Cassandra queries.conf: Simplify using expansions

6 years agoCassandra queries.conf: Increase post-auth logging precision
Terry Burton [Tue, 13 Aug 2019 14:34:20 +0000 (15:34 +0100)] 
Cassandra queries.conf: Increase post-auth logging precision

Timestamps are stored with millisecond precision.

6 years agoOracle queries.conf: Use Event-Timestamp rather than %S
Terry Burton [Tue, 13 Aug 2019 19:22:31 +0000 (20:22 +0100)] 
Oracle queries.conf: Use Event-Timestamp rather than %S

6 years agoOracle schema.conf: Special handling of empty strings
Terry Burton [Tue, 13 Aug 2019 17:49:55 +0000 (18:49 +0100)] 
Oracle schema.conf: Special handling of empty strings

Be forgiving of fields that might contain empty strings which Oracle conflates
with NULL!

6 years agoOracle schema.conf and query.conf: Increase post-auth logging precision
Terry Burton [Tue, 13 Aug 2019 16:42:14 +0000 (17:42 +0100)] 
Oracle schema.conf and query.conf: Increase post-auth logging precision

Switch to microsecond precision on timestamps.

6 years agoOracle schema.conf: Typo
Terry Burton [Tue, 13 Aug 2019 17:18:10 +0000 (18:18 +0100)] 
Oracle schema.conf: Typo

6 years agoMSSQL queries.conf: Use Event-Timestamp rather than %S
Terry Burton [Tue, 13 Aug 2019 23:23:26 +0000 (00:23 +0100)] 
MSSQL queries.conf: Use Event-Timestamp rather than %S

6 years agoMSSQL queries.conf: Add a post-auth logging query
Terry Burton [Tue, 13 Aug 2019 15:04:54 +0000 (16:04 +0100)] 
MSSQL queries.conf: Add a post-auth logging query

MSSQL accepts SQL timestamps to millisecond precision.
Don't log the CHAP password hex string, just a moniker.

6 years agoMSSQL queries.conf: Typo
Terry Burton [Tue, 13 Aug 2019 23:22:22 +0000 (00:22 +0100)] 
MSSQL queries.conf: Typo

Column name not matching schema.

6 years agoMSSQL schema.conf: Invalid syntax.
Terry Burton [Tue, 13 Aug 2019 14:28:07 +0000 (15:28 +0100)] 
MSSQL schema.conf: Invalid syntax.

Fix CREATE TABLE lines with invalid syntax.

The defaults that were provided in these lines are applied subsequent ALTER
TABLE statements.

6 years agoSQLite queries.conf: Use %l as default for missing Event-Timestamp
Terry Burton [Tue, 13 Aug 2019 20:38:31 +0000 (21:38 +0100)] 
SQLite queries.conf: Use %l as default for missing Event-Timestamp

6 years agoSQLite queries.conf: Fix acctsessiontime calculation for accounting-on/off
Terry Burton [Tue, 13 Aug 2019 20:35:43 +0000 (21:35 +0100)] 
SQLite queries.conf: Fix acctsessiontime calculation for accounting-on/off

acctstarttime is already in epoch format.

6 years agoSQLite query.conf: Increase post-auth logging precision
Terry Burton [Tue, 13 Aug 2019 19:37:31 +0000 (20:37 +0100)] 
SQLite query.conf: Increase post-auth logging precision

Switch to microsecond precision on timestamps.

6 years agoMySQL queries.conf: Use %l as default for missing Event-Timestamp.
Terry Burton [Tue, 13 Aug 2019 20:48:22 +0000 (21:48 +0100)] 
MySQL queries.conf: Use %l as default for missing Event-Timestamp.

6 years agoMySQL schema.conf: Enable fractional timestamps for post-auth logging
Terry Burton [Tue, 13 Aug 2019 15:55:09 +0000 (16:55 +0100)] 
MySQL schema.conf: Enable fractional timestamps for post-auth logging

All vendor-supported versions of MySQL (since 5.6.4) support a fractional
precision timestamp data type for an additional cost of three bytes per datum.

We enable this for the post-auth table.

6 years agoMySQL queries.conf: Increase post-auth logging precision
Terry Burton [Tue, 13 Aug 2019 15:45:38 +0000 (16:45 +0100)] 
MySQL queries.conf: Increase post-auth logging precision

MySQL can support microsecond precision on timestamps. When it isn't supported
the fractional part is simply discarded.

6 years agoPostgreSQL queries.conf: Use %l as default for missing Event-Timestamp
Terry Burton [Tue, 13 Aug 2019 21:00:09 +0000 (22:00 +0100)] 
PostgreSQL queries.conf: Use %l as default for missing Event-Timestamp

6 years agoPostgreSQL queries.conf: Use Event-Timestamp rather than %S
Terry Burton [Tue, 13 Aug 2019 20:52:29 +0000 (21:52 +0100)] 
PostgreSQL queries.conf: Use Event-Timestamp rather than %S

Use the provided Event-Timestamp to close accounting records
when receiving an Accounting-On/Off request.

6 years agoPostgreSQL queries.conf: Increase post-auth logging precision
Terry Burton [Tue, 13 Aug 2019 14:43:43 +0000 (15:43 +0100)] 
PostgreSQL queries.conf: Increase post-auth logging precision

PostgreSQL supports microsecond precision on timestamps.

Don't use NOW() since the queries can be replayed from a file.

6 years agodoc: Add sanity checks for verify if the xlat's is documented
Jorge Pereira [Thu, 22 Aug 2019 21:51:27 +0000 (18:51 -0300)] 
doc: Add sanity checks for verify if the xlat's is documented

6 years agoAdd tables that can hold pointers
Arran Cudbard-Bell [Thu, 22 Aug 2019 19:54:06 +0000 (15:54 -0400)] 
Add tables that can hold pointers

6 years agoMinor naming fixups
Arran Cudbard-Bell [Thu, 22 Aug 2019 02:53:20 +0000 (22:53 -0400)] 
Minor naming fixups

6 years agofilter out test / example / whatever modules
Alan T. DeKok [Thu, 22 Aug 2019 19:44:54 +0000 (15:44 -0400)] 
filter out test / example / whatever modules

6 years agoIgnore doc/doxygen/html directory
Jorge Pereira [Thu, 22 Aug 2019 19:02:33 +0000 (16:02 -0300)] 
Ignore doc/doxygen/html directory

6 years agoAdd some documentation for missing xlat's functions.
Jorge Pereira [Tue, 20 Aug 2019 23:43:46 +0000 (20:43 -0300)] 
Add some documentation for missing xlat's functions.

for the below modules:

rlm_dhcpv4
rlm_eap
rlm_json
rlm_ldap
rlm_yubikey

6 years agomake sure that the heading starts on a new line
Alan T. DeKok [Thu, 22 Aug 2019 17:54:20 +0000 (13:54 -0400)] 
make sure that the heading starts on a new line

6 years agoRename heading to be clearer
Alan T. DeKok [Thu, 22 Aug 2019 17:30:43 +0000 (13:30 -0400)] 
Rename heading to be clearer

perl -p -i -e 's/## Default instance/## Configuration Settings/' raddb/mods-available/*

6 years agothis is a link, not a config item
Alan T. DeKok [Thu, 22 Aug 2019 17:27:09 +0000 (13:27 -0400)] 
this is a link, not a config item

6 years agoprint module config at the end of the file
Alan T. DeKok [Thu, 22 Aug 2019 17:25:31 +0000 (13:25 -0400)] 
print module config at the end of the file

instead of in-line, which can get confusing

The behavior can be toggle via `-t`, which is nice

6 years agocleanups
Alan T. DeKok [Thu, 22 Aug 2019 17:15:08 +0000 (13:15 -0400)] 
cleanups

6 years agodon't refer to documentation which may move
Alan T. DeKok [Thu, 22 Aug 2019 17:06:55 +0000 (13:06 -0400)] 
don't refer to documentation which may move

6 years agoregenerate
Alan T. DeKok [Thu, 22 Aug 2019 17:00:36 +0000 (13:00 -0400)] 
regenerate

6 years agotypo here, too
Alan T. DeKok [Thu, 22 Aug 2019 17:02:56 +0000 (13:02 -0400)] 
typo here, too

6 years agouse the correct name
Alan T. DeKok [Thu, 22 Aug 2019 17:02:32 +0000 (13:02 -0400)] 
use the correct name

6 years agotypo
Alan T. DeKok [Thu, 22 Aug 2019 16:59:10 +0000 (12:59 -0400)] 
typo

6 years agono one uses this, and it's non-standard
Alan T. DeKok [Thu, 22 Aug 2019 16:56:45 +0000 (12:56 -0400)] 
no one uses this, and it's non-standard

6 years agoneed this, too
Alan T. DeKok [Thu, 22 Aug 2019 16:09:46 +0000 (12:09 -0400)] 
need this, too

6 years agoclarifications and cleanups
Alan T. DeKok [Thu, 22 Aug 2019 15:08:55 +0000 (11:08 -0400)] 
clarifications and cleanups

6 years agoadd an "all module" list
Alan T. DeKok [Thu, 22 Aug 2019 14:54:51 +0000 (10:54 -0400)] 
add an "all module" list

and a script to generate it.

6 years agofix help text
Alan T. DeKok [Thu, 22 Aug 2019 14:54:06 +0000 (10:54 -0400)] 
fix help text

6 years agoword smithing
Alan T. DeKok [Thu, 22 Aug 2019 14:53:45 +0000 (10:53 -0400)] 
word smithing

6 years agoAllow parsing of 'float64' in configuration files (#2913)
Nicolas C [Thu, 22 Aug 2019 13:16:20 +0000 (15:16 +0200)] 
Allow parsing of 'float64' in configuration files (#2913)

This small patch adds support of type 'float64' in configuration file.

Rationale: precision of float32 is not always sufficient, even for what would seem to be very simple numbers.
For example: "88.005" when printed with the default precision shows "88.004997".

6 years agoMerge rlm_attr_filter.5 with raddb/mods-available/attr_filter
Jorge Pereira [Thu, 22 Aug 2019 01:45:51 +0000 (22:45 -0300)] 
Merge rlm_attr_filter.5 with raddb/mods-available/attr_filter

The 'man/man5/rlm_attr_filter.5' is not necessary anymore.

6 years agoMerge rlm_pap.5 with raddb/mods-available/pap
Jorge Pereira [Thu, 22 Aug 2019 01:17:25 +0000 (22:17 -0300)] 
Merge rlm_pap.5 with raddb/mods-available/pap

The 'man/man5/rlm_pap.5' is not necessary anymore.

6 years agoMerge rlm_always.5 with raddb/mods-available/always
Jorge Pereira [Thu, 22 Aug 2019 00:14:52 +0000 (21:14 -0300)] 
Merge rlm_always.5 with raddb/mods-available/always

The 'man/man5/rlm_always.5' is not necessary anymore.

6 years agoAllow parsing of 'float64' in configuration files
nchaigne [Thu, 22 Aug 2019 08:16:34 +0000 (10:16 +0200)] 
Allow parsing of 'float64' in configuration files

This small patch adds support of type 'float64' in configuration file.

Rationale: precision of float32 is not always sufficient, even for what would seem to be very simple numbers.
For example: "88.005" when printed with the default precision shows "88.004997".

6 years agoReorganise dictionary code into separate files
Arran Cudbard-Bell [Thu, 22 Aug 2019 00:29:28 +0000 (20:29 -0400)] 
Reorganise dictionary code into separate files

6 years agocleanups and additions
Alan T. DeKok [Thu, 22 Aug 2019 00:02:50 +0000 (20:02 -0400)] 
cleanups and additions

6 years agotypo
Alan T. DeKok [Thu, 22 Aug 2019 00:02:45 +0000 (20:02 -0400)] 
typo

6 years agoclean ups and rephrasing
Alan T. DeKok [Thu, 22 Aug 2019 00:02:32 +0000 (20:02 -0400)] 
clean ups and rephrasing

6 years agoIgnore generated adoc files for now...
Arran Cudbard-Bell [Wed, 21 Aug 2019 22:55:05 +0000 (18:55 -0400)] 
Ignore generated adoc files for now...

6 years agorenamed and moved
Alan T. DeKok [Wed, 21 Aug 2019 21:30:30 +0000 (17:30 -0400)] 
renamed and moved

6 years agoall of the content here is wrong, old, or in mods-available/files
Alan T. DeKok [Wed, 21 Aug 2019 21:25:53 +0000 (17:25 -0400)] 
all of the content here is wrong, old, or in mods-available/files

6 years agowe don't need this any more.
Alan T. DeKok [Wed, 21 Aug 2019 19:50:42 +0000 (15:50 -0400)] 
we don't need this any more.

All of the radrelay configuration is documented elsewhere

6 years agomove radsniff to asciidoc format
Alan T. DeKok [Wed, 21 Aug 2019 19:43:24 +0000 (15:43 -0400)] 
move radsniff to asciidoc format

6 years agotypo
Alan T. DeKok [Wed, 21 Aug 2019 19:42:21 +0000 (15:42 -0400)] 
typo

6 years agouse descriptive error messages for all cases
Alan T. DeKok [Wed, 21 Aug 2019 19:24:20 +0000 (15:24 -0400)] 
use descriptive error messages for all cases

6 years agorlm_client: Don't leak memory on error conditions.
Jorge Pereira [Wed, 21 Aug 2019 17:52:47 +0000 (14:52 -0300)] 
rlm_client: Don't leak memory on error conditions.

6 years agoTake a pass through builtin.adoc
Arran Cudbard-Bell [Wed, 21 Aug 2019 18:09:41 +0000 (14:09 -0400)] 
Take a pass through builtin.adoc

Still only partially complete

6 years agorlm_dhcpv4: Don't leak memory on error conditions. (#2910)
Jorge Pereira [Wed, 21 Aug 2019 17:39:29 +0000 (14:39 -0300)] 
rlm_dhcpv4: Don't leak memory on error conditions. (#2910)

6 years agopull call to localtime_r() higher in the function.
Alan T. DeKok [Wed, 21 Aug 2019 14:12:14 +0000 (10:12 -0400)] 
pull call to localtime_r() higher in the function.

6 years agoadd tests for dates with millisecond precision
Alan T. DeKok [Wed, 21 Aug 2019 14:05:06 +0000 (10:05 -0400)] 
add tests for dates with millisecond precision

note that despite inputs in various time zones, the tests
run in GMT

6 years agoadd '.' to subseconds
Alan T. DeKok [Wed, 21 Aug 2019 14:04:39 +0000 (10:04 -0400)] 
add '.' to subseconds

and fix closing quote

6 years agoparse subseconds correctly by scaling them
Alan T. DeKok [Wed, 21 Aug 2019 13:58:04 +0000 (09:58 -0400)] 
parse subseconds correctly by scaling them

and add descriptive error messages.

6 years agoallow attributes of type 'date' to set type_size
Alan T. DeKok [Wed, 21 Aug 2019 13:43:25 +0000 (09:43 -0400)] 
allow attributes of type 'date' to set type_size

for setting time precision

6 years agoadd parser for ISO8601 date formats
Alan T. DeKok [Wed, 21 Aug 2019 12:54:51 +0000 (08:54 -0400)] 
add parser for ISO8601 date formats

Which incidentally also gets the time zone conversions correct.
The old parser just ignored the time zone.

6 years agomake fr_time_from_str() use fr_time_t
Alan T. DeKok [Wed, 21 Aug 2019 11:50:47 +0000 (07:50 -0400)] 
make fr_time_from_str() use fr_time_t

In preparation for parsing RFC 3339 dates.