]> git.ipfire.org Git - thirdparty/freeradius-server.git/log
thirdparty/freeradius-server.git
6 years agoRemove normalisation call from proto_radius_auth.c
Arran Cudbard-Bell [Thu, 29 Aug 2019 01:34:57 +0000 (21:34 -0400)] 
Remove normalisation call from proto_radius_auth.c

As discussed. It's bad to mix internal attribute processing with protocols.

The normalisation could be applied equally well to many protocols, and rlm_pap and rlm_chap will do their own normalisation without mangling the existing attributes in the request.

6 years agoFix Auth-Type checks in rlm_pap and rlm_chap
Arran Cudbard-Bell [Thu, 29 Aug 2019 01:33:17 +0000 (21:33 -0400)] 
Fix Auth-Type checks in rlm_pap and rlm_chap

They were looking in the wrong list, and the output should not have been an error

6 years agoPAP no longer checks for input password hashes, so we need to work around that in...
Arran Cudbard-Bell [Thu, 29 Aug 2019 01:32:17 +0000 (21:32 -0400)] 
PAP no longer checks for input password hashes, so we need to work around that in tests that remove &control:Cleartext-Password

6 years agoPassword should be const in fr_radius_encode_chap_password
Arran Cudbard-Bell [Thu, 29 Aug 2019 01:31:19 +0000 (21:31 -0400)] 
Password should be const in fr_radius_encode_chap_password

6 years agoProvide length of the match in prefix search functions
Arran Cudbard-Bell [Wed, 28 Aug 2019 23:15:10 +0000 (19:15 -0400)] 
Provide length of the match in prefix search functions

6 years agomore compiler fixes
Alan T. DeKok [Wed, 28 Aug 2019 22:05:38 +0000 (18:05 -0400)] 
more compiler fixes

6 years agopbkdf2 isn't always built
Alan T. DeKok [Wed, 28 Aug 2019 20:55:02 +0000 (16:55 -0400)] 
pbkdf2 isn't always built

6 years agocleanups and use common includes
Alan T. DeKok [Wed, 28 Aug 2019 18:42:05 +0000 (14:42 -0400)] 
cleanups and use common includes

6 years agoUpdate 'check.doc' target to save the input as parameter
Jorge Pereira [Wed, 28 Aug 2019 17:13:27 +0000 (14:13 -0300)] 
Update 'check.doc' target to save the input as parameter

The list of expected missing xlat's calls should be versioned
in scripts/checks/missing-xlat-doc.txt

6 years agomove to table lookups instead of if / then / else
Alan T. DeKok [Wed, 28 Aug 2019 14:55:02 +0000 (10:55 -0400)] 
move to table lookups instead of if / then / else

6 years agoshut up compiler
Alan T. DeKok [Wed, 28 Aug 2019 14:53:56 +0000 (10:53 -0400)] 
shut up compiler

6 years agouse known array size instead of anything else
Alan T. DeKok [Wed, 28 Aug 2019 14:42:33 +0000 (10:42 -0400)] 
use known array size instead of anything else

6 years agouse pointers in table, instead of ints & a switch statement
Alan T. DeKok [Wed, 28 Aug 2019 14:37:38 +0000 (10:37 -0400)] 
use pointers in table, instead of ints & a switch statement

6 years agoAdd missing config options in raddb/
Jorge Pereira [Tue, 27 Aug 2019 23:12:49 +0000 (20:12 -0300)] 
Add missing config options in raddb/

It helps #2919 involving the modules:

rlm_cipher
rlm_eap
rlm_ldap
rlm_lua
rlm_mschap
rlm_passwd
rlm_radius
rlm_redis_ippool

6 years agocall password_normalise()
Alan T. DeKok [Wed, 28 Aug 2019 14:18:13 +0000 (10:18 -0400)] 
call password_normalise()

so that we don't do all that work ourselves.

6 years agoload simple things first
Alan T. DeKok [Wed, 28 Aug 2019 14:11:49 +0000 (10:11 -0400)] 
load simple things first

We can later add checks that new dictionary entries are NOT
added after some point.  Otherwise the server fails with
"unknown attribute" error, instead of "attribute definition
is too late"

6 years agonew attributes MUST be define in the "bootstrap" phase
Alan T. DeKok [Wed, 28 Aug 2019 14:11:09 +0000 (10:11 -0400)] 
new attributes MUST be define in the "bootstrap" phase

6 years agouse consistent names
Alan T. DeKok [Wed, 28 Aug 2019 14:01:43 +0000 (10:01 -0400)] 
use consistent names

so `git grep` finds things

6 years agocall password_normalise()
Alan T. DeKok [Wed, 28 Aug 2019 13:54:49 +0000 (09:54 -0400)] 
call password_normalise()

which then means we don't need to loop over the attributes ourselves

6 years agocall password_normalise(), just in case
Alan T. DeKok [Wed, 28 Aug 2019 13:50:55 +0000 (09:50 -0400)] 
call password_normalise(), just in case

6 years agocall password_normalise() instead of doing it ourselves
Alan T. DeKok [Wed, 28 Aug 2019 13:50:44 +0000 (09:50 -0400)] 
call password_normalise() instead of doing it ourselves

6 years agoadd server_init() and server_free()
Alan T. DeKok [Wed, 28 Aug 2019 13:49:38 +0000 (09:49 -0400)] 
add server_init() and server_free()

so that src/lib/server/ can be initialized all at once.

And the callers then don't need to have a list of init/free
functions

6 years agoadd password_normalise() which normalises all passwords
Alan T. DeKok [Wed, 28 Aug 2019 13:01:11 +0000 (09:01 -0400)] 
add password_normalise() which normalises all passwords

6 years agoAdd missing config options in raddb/
Jorge Pereira [Fri, 23 Aug 2019 20:44:16 +0000 (17:44 -0300)] 
Add missing config options in raddb/

It helps #2919 involving the modules:

rlm_attr_filter
rlm_cache
rlm_rest
rlm_sometimes

6 years agoLet the PAP module normalize passwords
Alan T. DeKok [Tue, 27 Aug 2019 18:36:18 +0000 (14:36 -0400)] 
Let the PAP module normalize passwords

No, we do NOT want it to fail if there's no User-Password
in the request.  Instead, we want it to do stuff

6 years agoremove warning which is now in proto_radius_auth
Alan T. DeKok [Tue, 27 Aug 2019 18:27:55 +0000 (14:27 -0400)] 
remove warning which is now in proto_radius_auth

6 years agowe don't need User-Password here.
Alan T. DeKok [Tue, 27 Aug 2019 18:27:25 +0000 (14:27 -0400)] 
we don't need User-Password here.

6 years ago rlm_lua: Remove unused options (#2929)
Jorge Pereira [Tue, 27 Aug 2019 19:03:49 +0000 (16:03 -0300)] 
 rlm_lua: Remove unused options (#2929)

* rlm_lua: Remove unused options

* rlm_lua: The correct should be 'fr.requests'

6 years agoadded documentation for the CHAP module
Alan T. DeKok [Tue, 27 Aug 2019 17:52:42 +0000 (13:52 -0400)] 
added documentation for the CHAP module

6 years agotypo
Alan T. DeKok [Tue, 27 Aug 2019 17:52:38 +0000 (13:52 -0400)] 
typo

6 years agodon't be retarded. Use a percentage.
Alan T. DeKok [Tue, 27 Aug 2019 17:39:35 +0000 (13:39 -0400)] 
don't be retarded.  Use a percentage.

Who was the idiot who wrote that code?

6 years agoCopy "normalise password" code from rlm_pap to proto_radius_auth
Alan T. DeKok [Tue, 27 Aug 2019 16:57:39 +0000 (12:57 -0400)] 
Copy "normalise password" code from rlm_pap to proto_radius_auth

Instead of having this code in multiple modules, just have it
once in proto_radius_auth.  That way it runs just before the
"authenticate" section.

And, it ALWAYS runs.  If people delete the "pap" module from
"recv Access-Request", then everything still works.

6 years agodon't normalize passwords
Alan T. DeKok [Tue, 27 Aug 2019 17:09:50 +0000 (13:09 -0400)] 
don't normalize passwords

it should be done elsewhere

6 years agorlm_lua: Clean up (#2926)
Jorge Pereira [Tue, 27 Aug 2019 17:25:37 +0000 (14:25 -0300)] 
rlm_lua: Clean up (#2926)

* rlm_lua: Clean up

* rlm_lua: Clean up related to 9bc7d44921

6 years agorlm_rest: Clean up (#2928)
Jorge Pereira [Tue, 27 Aug 2019 17:25:07 +0000 (14:25 -0300)] 
rlm_rest: Clean up (#2928)

6 years agoun-break CHAP module
Alan T. DeKok [Tue, 27 Aug 2019 15:38:34 +0000 (11:38 -0400)] 
un-break CHAP module

If there's no "known good" password, we still set Auth-Type = CHAP,
because that's the only thing which cam be done.  We issue a
warning, but we hope that a subsequent module will do the right thing

6 years agotypos
Alan T. DeKok [Tue, 27 Aug 2019 15:28:33 +0000 (11:28 -0400)] 
typos

6 years agoadd more documentation
Alan T. DeKok [Tue, 27 Aug 2019 14:49:00 +0000 (10:49 -0400)] 
add more documentation

6 years agoIt helps to print out "Ready to process requests"
Alan T. DeKok [Tue, 27 Aug 2019 14:29:38 +0000 (10:29 -0400)] 
It helps to print out "Ready to process requests"

6 years agomore cleanups and rearrangement
Alan T. DeKok [Tue, 27 Aug 2019 13:55:52 +0000 (09:55 -0400)] 
more cleanups and rearrangement

6 years agomore cleanups and split authentication into its own page
Alan T. DeKok [Tue, 27 Aug 2019 13:26:30 +0000 (09:26 -0400)] 
more cleanups and split authentication into its own page

6 years agocleanups and typos
Alan T. DeKok [Tue, 27 Aug 2019 13:26:21 +0000 (09:26 -0400)] 
cleanups and typos

6 years agoUse cf_table_parse_ctx_t structure instead of passing in the table directly Closes...
Arran Cudbard-Bell [Tue, 27 Aug 2019 05:14:20 +0000 (01:14 -0400)] 
Use cf_table_parse_ctx_t structure instead of passing in the table directly Closes #2925

6 years agoNo enum name needed
Arran Cudbard-Bell [Mon, 26 Aug 2019 22:18:25 +0000 (18:18 -0400)] 
No enum name needed

6 years agoradsqlrelay systemd watchdog (#2922)
Terry Burton [Tue, 27 Aug 2019 05:09:00 +0000 (06:09 +0100)] 
radsqlrelay systemd watchdog (#2922)

* radsqlrelay: Clean up strict and warnings pragmas

The modules we use are clean so ensure that these pragmas apply to
includes.

* radsqlrelay: Add support for systemd watchdogs

systemd can terminate (and restart) the service if it stops providing
watchdogs for a defined interval.

* radsqlrelay: Don't get stuck processing the same broken SQL statements

If the file contains a broken SQL statement then it is continually
retried with a 1 sec delay.

Restarting the radsqlrelay will replay the entire file (which could get
stuck even earlier due to duplicate key fields).

We instead continue when we encounter a failing statement unless the
failure was the result of a database disconnect in which case it is
resumed once the connection is available.

6 years agodoc: typos and small fixes
Matthew Newton [Mon, 26 Aug 2019 23:53:50 +0000 (00:53 +0100)] 
doc: typos and small fixes

6 years agodoc: install & upgrade on the intro page
Matthew Newton [Mon, 26 Aug 2019 23:30:07 +0000 (00:30 +0100)] 
doc: install & upgrade on the intro page

6 years agocherry pick text from #2921
Matthew Newton [Mon, 26 Aug 2019 23:24:21 +0000 (00:24 +0100)] 
cherry pick text from #2921

6 years agodoc: move 'upgrading' to 'install & upgrade' section
Matthew Newton [Mon, 26 Aug 2019 21:12:18 +0000 (22:12 +0100)] 
doc: move 'upgrading' to 'install & upgrade' section

6 years agodoc: start splitting up install document
Matthew Newton [Mon, 26 Aug 2019 21:17:20 +0000 (22:17 +0100)] 
doc: start splitting up install document

6 years agodoc: update dependencies page
Matthew Newton [Mon, 26 Aug 2019 21:15:48 +0000 (22:15 +0100)] 
doc: update dependencies page

6 years agodoc: move build dependencies to installation section
Matthew Newton [Mon, 26 Aug 2019 19:00:24 +0000 (20:00 +0100)] 
doc: move build dependencies to installation section

6 years agodoc: move installation to new 'install & upgrade' section
Matthew Newton [Mon, 26 Aug 2019 18:47:11 +0000 (19:47 +0100)] 
doc: move installation to new 'install & upgrade' section

6 years agoMove stupid perl hack to where it should be
Arran Cudbard-Bell [Mon, 26 Aug 2019 21:28:04 +0000 (17:28 -0400)] 
Move stupid perl hack to where it should be

6 years agoNot you...
Arran Cudbard-Bell [Mon, 26 Aug 2019 21:21:34 +0000 (17:21 -0400)] 
Not you...

6 years agoAdd back source files that should not have been removed
Arran Cudbard-Bell [Mon, 26 Aug 2019 21:20:49 +0000 (17:20 -0400)] 
Add back source files that should not have been removed

This reverts commit 4e6df7bd9827452339bd3e8f7f219f49715536f2.

6 years agorearrange, reformat, and do word smithing
Alan T. DeKok [Mon, 26 Aug 2019 18:32:49 +0000 (14:32 -0400)] 
rearrange, reformat, and do word smithing

many small pages is better than few large pages

6 years agothese files should not have been committed
Alan T. DeKok [Mon, 26 Aug 2019 18:09:24 +0000 (14:09 -0400)] 
these files should not have been committed

6 years agoI went up the mountain, and wrote the wisdom I received
Alexander Clouter [Sat, 24 Aug 2019 15:01:57 +0000 (16:01 +0100)] 
I went up the mountain, and wrote the wisdom I received

6 years agoimprove "how to build docs"
Alexander Clouter [Sat, 24 Aug 2019 19:26:46 +0000 (20:26 +0100)] 
improve "how to build docs"

6 years agofix ldap config example
Alexander Clouter [Sun, 25 Aug 2019 16:18:22 +0000 (17:18 +0100)] 
fix ldap config example

6 years ago{cleartext} is not interpreted by OpenLDAP
Alexander Clouter [Sun, 25 Aug 2019 18:19:40 +0000 (19:19 +0100)] 
{cleartext} is not interpreted by OpenLDAP

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.