# Our "conf to asciidoc" stuff.
#
CONF_FILES := $(filter-out %~,$(wildcard raddb/*conf raddb/mods-available/* raddb/sites-available/* raddb/dictionary))
-BASE_ADOC_FILES := $(wildcard doc/*.adoc doc/*/*.adoc doc/*/*/*.adoc) doc/raddb/mods-available/all_modules.adoc
+BASE_ADOC_FILES := $(wildcard doc/*.adoc doc/*/*.adoc doc/*/*/*.adoc) doc/antora/modules/reference/pages/raddb/mods-available/all_modules.adoc
ADOC_FILES := $(BASE_ADOC_FILES) $(AUTO_ADOC_FILES)
PDF_FILES := $(patsubst doc/%.adoc,doc/%.pdf,$(ADOC_FILES))
#
# Conf files get converted to Asciidoc via our own magic script.
#
-doc/antora/modules/raddb/pages/%.adoc: raddb/%
+doc/antora/modules/reference/pages/raddb/%.adoc: raddb/%
@echo ADOC $^
${Q}mkdir -p $(dir $@)
${Q}perl -pi -e 's/^# ([^ \t])/# $$1/;s/^([ \t]+)# ([^ \t])/$$1# $$2/;s/[ \t]+$$//' $^
# Simple rule for lazy people.
#
.PHONY: doc.raddb
-doc.raddb: $(patsubst raddb/%,doc/antora/modules/raddb/pages/%.adoc,$(CONF_FILES))
+doc.raddb: $(patsubst raddb/%,doc/antora/modules/reference/pages/raddb/%.adoc,$(CONF_FILES))
#
# antora rebuilds the entire documentation site on each run
#
IGNORE_MODULES := $(patsubst %,src/modules/%/README.md,rlm_dict rlm_securid rlm_sigtran rlm_test)
README_MODULES := $(filter-out $(IGNORE_MODULES), $(wildcard src/modules/rlm_*/README.md))
-doc/raddb/mods-available/all_modules.adoc: $(README_MODULES)
+doc/antora/modules/reference/pages/raddb/mods-available/all_modules.adoc: $(README_MODULES)
@echo ADOC mods-available/all_modules.adoc
${Q}./scripts/asciidoc/mod_readme2adoc $(README_MODULES) > $@
endif
* xref:concepts:index.adoc[Concepts] and introduction for newcomers.
* xref:installation:index.adoc[Installing] and xref:installation:upgrade.adoc[upgrading] FreeRADIUS.
* The syntax of the xref:reference:unlang/index.adoc[unlang] processing language.
-* The xref:raddb:index.adoc[configuration files] located in `/etc/raddb/`, or `/etc/freeradius/`
+* The xref:reference:raddb/index.adoc[configuration files] located in `/etc/raddb/`, or `/etc/freeradius/`
* Various xref:howto:index.adoc[how-to] guides.
* xref:developers:index.adoc[Developer documentation].
This section describes the syntax and functionality of the keywords,
data types, etc. used in the `unlang` processing language.
-All of the xref:raddb:index.adoc[configuration files] are available in
+All of the xref:reference:raddb/index.adoc[configuration files] are available in
hypertext format. It can often be easier to read the configuration files
in a nicely formatted version, instead of as a fixed-width font in a
text editor.
Use "bind as user"
MS-CHAP::
-Use xref:raddb:mods-available/ntlm_auth.adoc[`ntlm`] or xref:raddb:mods-available/winbind.adoc[`winbind`].
+Use xref:reference:raddb/mods-available/ntlm_auth.adoc[`ntlm`] or xref:reference:raddb/mods-available/winbind.adoc[`winbind`].
Due to the limitations of Active Directory, There are unfortunately no
other possible choices.
determine what format it is in (base64, binary, or text), and what
password "encryption" mechanism has been used (crypt, MD5, SHA, SSHA2,
SHA3, etc). All that is necessary is that the
-xref:raddb:mods-available/ldap.adoc[ldap module] be configured to map
+xref:reference:raddb/mods-available/ldap.adoc[ldap module] be configured to map
the `userPassword` LDAP field to the `&control.Password.With-Header`
attribute in FreeRADIUS. FreeRADIUS will then "do the right thing" to
authenticate the user.
This mapping is done in the default module configuration. There are
no additional changes required for FreeRADIUS to correctly read and
decode the `userPassword` field from LDAP. Please see the
-xref:raddb:mods-available/pap.adoc[pap module] for a full list of
+xref:reference:raddb/mods-available/pap.adoc[pap module] for a full list of
supported password "encryption" formats.
== Additional Considerations
= Configuring the CHAP module
-The xref:raddb:mods-available/chap.adoc[mods-available/chap]
+The xref:reference:raddb/mods-available/chap.adoc[mods-available/chap]
configuration file describes the configuration parameters accepted by
the CHAP module, and what they do. This document explains how to
perform testing with the CHAP module.
== Editing mods-available/chap
-The xref:raddb:mods-available/chap.adoc[mods-available/chap] module
+The xref:reference:raddb/mods-available/chap.adoc[mods-available/chap] module
contains no configuration items, and does not need to be edited.
== Enabling mods-available/chap
= Configuring a Module
The configuration files in
-xref:raddb:mods-available/index.adoc[mods-available/] file describe
+xref:reference:raddb/mods-available/index.adoc[mods-available/] file describe
the configuration parameters accepted by each module, and what they
do. This document explains how to perform generic testing with any
module.
The configuration step should be little more than
xref:modules/ldap/ldapsearch/index.adoc#_translating_ldapsearch_arguments_to_rlm_ldap_configuration_items[copying the parameters used by ldapsearch]
-to the xref:raddb:mods-available/ldap.adoc[ldap module] configuration file.
+to the xref:reference:raddb/mods-available/ldap.adoc[ldap module] configuration file.
-The xref:raddb:mods-available/ldap.adoc[ldap module] configuration file
+The xref:reference:raddb/mods-available/ldap.adoc[ldap module] configuration file
describes the configuration parameters accepted by the module, and what they do.
include::howto:partial$pre_test.adoc[]
xref:modules/ldap/ldapsearch/index.adoc#_translating_ldapsearch_arguments_to_rlm_ldap_configuration_items[translation table] on that page.
At a minimum you will need to set the following configuration items
-in in xref:raddb:mods-available/ldap.adoc[mods-available/ldap] using
+in in xref:reference:raddb/mods-available/ldap.adoc[mods-available/ldap] using
the values you discovered
running the xref:modules/ldap/ldapsearch/index.adoc[ldapsearch] tests.
== Sections in this tutorial
For features and configuration items not covered by this tutorial series
-xref:raddb:mods-available/ldap.adoc[mods-available/ldap] page provides a complete
+xref:reference:raddb/mods-available/ldap.adoc[mods-available/ldap] page provides a complete
reference for all the configuration items available for the rlm_ldap module.
=== xref:modules/ldap/base_configuration/index.adoc[Base configuration]
when the user logs in to services.
<5> A base64 encoded `userPassword` attribute. This shows the LDAP directory
is willing to provided user password hashes. These hashes can be used by
- the xref:raddb:mods-available/pap.adoc[pap] module to authenticate the
+ the xref:reference:raddb/mods-available/pap.adoc[pap] module to authenticate the
user locally without the overhead of additional bind operations.
====
The `log` section has been updated to remove many configuration items
which are specific to RADIUS, and to Access-Request packets. Please see
`sites-available/default`, and look for the `Access-Request`
-subsection there. See also xref:raddb:templates.conf.adoc[`templates.conf`]
+subsection there. See also xref:reference:raddb/templates.conf.adoc[`templates.conf`]
for a way to regain one global configuration for `Access-Request`
packets.
i.e. in version 4, just list the virtual module in a file, as if it
was a real module.
-See the xref:raddb:mods-available/redundant_sql.adoc[redundant_sql] module
+See the xref:reference:raddb/mods-available/redundant_sql.adoc[redundant_sql] module
for more information. In short, a virtual module can be put into
the `mods-enabled` directory as with any other module, as with the
following text:
+++ /dev/null
-* xref:index.adoc[Configuration]
-** xref:format.adoc[Format of the Configuration Files]
-
-** xref:certs/index.adoc[Certificates]
-
-** xref:global.d/index.adoc[Global Configuration]
-** xref:global.d/ldap.adoc[ldap]
-** xref:global.d/python.adoc[ldap]
-
-** xref:mods-available/index.adoc[Modules]
-*** xref:mods-available/all_modules.adoc[Summary of all modules]
-*** xref:mods-available/abfab_psk_sql.adoc[ADFAB PSK]
-*** xref:mods-available/always.adoc[Always]
-*** xref:mods-available/attr_filter.adoc[Attr_filter]
-*** xref:mods-available/cache.adoc[Cache]
-*** xref:mods-available/cache_eap.adoc[Cache EAP]
-*** xref:mods-available/cache_tls.adoc[Cache TLS Session]
-*** xref:mods-available/chap.adoc[CHAP module]
-*** xref:mods-available/cipher.adoc[Cipher]
-*** xref:mods-available/client.adoc[Client]
-*** xref:mods-available/couchbase.adoc[Couchbase]
-*** xref:mods-available/csv.adoc[CSV]
-*** xref:mods-available/cui.adoc[CUI]
-*** xref:mods-available/date.adoc[Date]
-*** xref:mods-available/delay.adoc[Delay]
-*** xref:mods-available/detail.adoc[Detail]
-*** xref:mods-available/detail.example.com.adoc[Detail (Sample)]
-*** xref:mods-available/detail.log.adoc[Detail (Log Sample)]
-*** xref:mods-available/dhcpv4.adoc[DHCPv4]
-*** xref:mods-available/dict.adoc[Dict]
-*** xref:mods-available/digest.adoc[Digest]
-*** xref:mods-available/eap.adoc[EAP]
-*** xref:mods-available/eap_inner.adoc[EAP/Inner]
-*** xref:mods-available/echo.adoc[Echo]
-*** xref:mods-available/escape.adoc[Escape]
-*** xref:mods-available/etc_group.adoc[etc_group]
-*** xref:mods-available/exec.adoc[Exec]
-*** xref:mods-available/files.adoc[Files]
-**** xref:mods-config/files/users.adoc[users file format]
-*** xref:mods-available/idn.adoc[IDN]
-*** xref:mods-available/isc_dhcp.adoc[ISC DHCP]
-*** xref:mods-available/imap.adoc[IMAP]
-*** xref:mods-available/json.adoc[JSON]
-*** xref:mods-available/krb5.adoc[Kerberos]
-*** xref:mods-available/ldap.adoc[LDAP (Lightweight Directory Access Protocol)]
-*** xref:mods-available/linelog.adoc[Linelog]
-*** xref:mods-available/logtee.adoc[Logtee]
-*** xref:mods-available/lua.adoc[Lua]
-*** xref:mods-available/mac2ip.adoc[Mac2IP]
-*** xref:mods-available/mac2vlan.adoc[Mac2Vlan]
-*** xref:mods-available/mschap.adoc[Microsoft CHAP authentication]
-*** xref:mods-available/ntlm_auth.adoc[NTLM Auth]
-*** xref:mods-available/opendirectory.adoc[OpenDirectory]
-*** xref:mods-available/pam.adoc[Pluggable Authentication]
-*** xref:mods-available/pap.adoc[PAP]
-*** xref:mods-available/passwd.adoc[Passwd]
-*** xref:mods-available/perl.adoc[Perl]
-*** xref:mods-available/python.adoc[Python]
-*** xref:mods-available/radius.adoc[Radius]
-*** xref:mods-available/radutmp.adoc[Radutmp]
-*** xref:mods-available/redis.adoc[REDIS]
-*** xref:mods-available/redis_ippool.adoc[Redis IP Pool]
-*** xref:mods-available/rediswho.adoc[REDISWho]
-*** xref:mods-available/redundant_sql.adoc[redundant_sql]
-*** xref:mods-available/rest.adoc[Rest]
-*** xref:mods-available/mruby.adoc[Ruby]
-*** xref:mods-available/smbpasswd.adoc[SMBPasswd]
-*** xref:mods-available/sometimes.adoc[Sometimes]
-*** xref:mods-available/sql.adoc[SQL]
-*** xref:mods-available/sqlcounter.adoc[SQL Counter]
-*** xref:mods-available/sqlippool.adoc[SQL-IP-Pool]
-*** xref:mods-available/sradutmp.adoc[sRadutmp]
-*** xref:mods-available/stats.adoc[Stats]
-*** xref:mods-available/totp.adoc[TOTP]
-*** xref:mods-available/unbound.adoc[Unbound]
-*** xref:mods-available/unix.adoc[Unix]
-*** xref:mods-available/unpack.adoc[Unpack]
-*** xref:mods-available/utf8.adoc[UTF-8]
-*** xref:mods-available/wimax.adoc[WiMAX]
-*** xref:mods-available/winbind.adoc[Winbind]
-*** xref:mods-available/yubikey.adoc[Yubikey]
-
-** xref:index.adoc[Virtual Servers]
-*** xref:sites-available/abfab-tls.adoc[ABFAB: Listening on TLS]
-*** xref:sites-available/abfab-tr-idp.adoc[ABFAB: Trust Router]
-*** xref:sites-available/arp.adoc[ARP Virtual Server]
-*** xref:sites-available/bfd.adoc[BFD - Bidirectional Forwarding Detection]
-*** xref:sites-available/buffered-sql.adoc[Buffered SQL]
-*** xref:sites-available/challenge.adoc[Challenge]
-*** xref:sites-available/channel_bindings.adoc[Channel Bindings]
-*** xref:sites-available/check-eap-tls.adoc[Check EAP-TLS]
-*** xref:sites-available/coa.adoc[CoA]
-*** xref:sites-available/control-socket.adoc[Control Socket Interface.]
-*** xref:sites-available/copy-acct-to-home-server.adoc[Copy ACCT to Home Server]
-*** xref:sites-available/decoupled-accounting.adoc[Decoupled Accounting]
-*** xref:sites-available/detail.adoc[Detail]
-*** xref:sites-available/dhcp.adoc[Dhcp]
-*** xref:sites-available/dhcp.relay.adoc[Dhcp Relay]
-*** xref:sites-available/dynamic-clients.adoc[Dynamic Clients]
-*** xref:sites-available/example.adoc[Example]
-*** xref:sites-available/inner-tunnel.adoc[Inner Tunnel]
-*** xref:sites-available/ldap_sync.adoc[LDAP Sync]
-*** xref:sites-available/originate-coa.adoc[Originate CoA-Request packets]
-*** xref:sites-available/proxy-inner-tunnel.adoc[Proxy Inner Tunnel]
-*** xref:sites-available/radius-acct.adoc[Radius Acct]
-*** xref:sites-available/robust-proxy-accounting.adoc[Robust Proxy Accounting]
-*** xref:sites-available/status.adoc[Status]
-*** xref:sites-available/tacacs.adoc[Tacacs]
-*** xref:sites-available/default.adoc[The default Virtual Server]
-*** xref:sites-available/tls-cache.adoc[TLS Cache]
-*** xref:sites-available/tls.adoc[TLS]
-*** xref:sites-available/virtual.example.com.adoc[virtual.example.com]
-*** xref:sites-available/vmps.adoc[VMPS]
-*** xref:experimental.conf.adoc[Experimental modules]
-
-** xref:clients.conf.adoc[Client Definitions]
-** xref:debug.conf.adoc[Debugging configuration]
-** xref:dictionary.adoc[Local dictionary definitions]
-** xref:radrelay.conf.adoc[Radrelay Configuration]
-** xref:radiusd.conf.adoc[Server Configuration File]
-** xref:templates.conf.adoc[Templates]
-** xref:trigger.conf.adoc[Triggers]
*** xref:man/radiusd.adoc[radiusd]
*** xref:man/radmin.adoc[radmin]
*** xref:man/radsniff.adoc[radsniff]
+
+** xref:index.adoc[Configuration Files]
+*** xref:format.adoc[Format of the Configuration Files]
+
+*** xref:certs/index.adoc[Certificates]
+
+*** xref:global.d/index.adoc[Global Configuration]
+*** xref:global.d/ldap.adoc[ldap]
+*** xref:global.d/python.adoc[ldap]
+
+*** xref:mods-available/index.adoc[Modules]
+**** xref:mods-available/all_modules.adoc[Summary of all modules]
+**** xref:mods-available/abfab_psk_sql.adoc[ADFAB PSK]
+**** xref:mods-available/always.adoc[Always]
+**** xref:mods-available/attr_filter.adoc[Attr_filter]
+**** xref:mods-available/cache.adoc[Cache]
+**** xref:mods-available/cache_eap.adoc[Cache EAP]
+**** xref:mods-available/cache_tls.adoc[Cache TLS Session]
+**** xref:mods-available/chap.adoc[CHAP module]
+**** xref:mods-available/cipher.adoc[Cipher]
+**** xref:mods-available/client.adoc[Client]
+**** xref:mods-available/couchbase.adoc[Couchbase]
+**** xref:mods-available/csv.adoc[CSV]
+**** xref:mods-available/cui.adoc[CUI]
+**** xref:mods-available/date.adoc[Date]
+**** xref:mods-available/delay.adoc[Delay]
+**** xref:mods-available/detail.adoc[Detail]
+**** xref:mods-available/detail.example.com.adoc[Detail (Sample)]
+**** xref:mods-available/detail.log.adoc[Detail (Log Sample)]
+**** xref:mods-available/dhcpv4.adoc[DHCPv4]
+**** xref:mods-available/dict.adoc[Dict]
+**** xref:mods-available/digest.adoc[Digest]
+**** xref:mods-available/eap.adoc[EAP]
+**** xref:mods-available/eap_inner.adoc[EAP/Inner]
+**** xref:mods-available/echo.adoc[Echo]
+**** xref:mods-available/escape.adoc[Escape]
+**** xref:mods-available/etc_group.adoc[etc_group]
+**** xref:mods-available/exec.adoc[Exec]
+**** xref:mods-available/files.adoc[Files]
+***** xref:mods-config/files/users.adoc[users file format]
+**** xref:mods-available/idn.adoc[IDN]
+**** xref:mods-available/isc_dhcp.adoc[ISC DHCP]
+**** xref:mods-available/imap.adoc[IMAP]
+**** xref:mods-available/json.adoc[JSON]
+**** xref:mods-available/krb5.adoc[Kerberos]
+**** xref:mods-available/ldap.adoc[LDAP (Lightweight Directory Access Protocol)]
+**** xref:mods-available/linelog.adoc[Linelog]
+**** xref:mods-available/logtee.adoc[Logtee]
+**** xref:mods-available/lua.adoc[Lua]
+**** xref:mods-available/mac2ip.adoc[Mac2IP]
+**** xref:mods-available/mac2vlan.adoc[Mac2Vlan]
+**** xref:mods-available/mschap.adoc[Microsoft CHAP authentication]
+**** xref:mods-available/ntlm_auth.adoc[NTLM Auth]
+**** xref:mods-available/opendirectory.adoc[OpenDirectory]
+**** xref:mods-available/pam.adoc[Pluggable Authentication]
+**** xref:mods-available/pap.adoc[PAP]
+**** xref:mods-available/passwd.adoc[Passwd]
+**** xref:mods-available/perl.adoc[Perl]
+**** xref:mods-available/python.adoc[Python]
+**** xref:mods-available/radius.adoc[Radius]
+**** xref:mods-available/radutmp.adoc[Radutmp]
+**** xref:mods-available/redis.adoc[REDIS]
+**** xref:mods-available/redis_ippool.adoc[Redis IP Pool]
+**** xref:mods-available/rediswho.adoc[REDISWho]
+**** xref:mods-available/redundant_sql.adoc[redundant_sql]
+**** xref:mods-available/rest.adoc[Rest]
+**** xref:mods-available/mruby.adoc[Ruby]
+**** xref:mods-available/smbpasswd.adoc[SMBPasswd]
+**** xref:mods-available/sometimes.adoc[Sometimes]
+**** xref:mods-available/sql.adoc[SQL]
+**** xref:mods-available/sqlcounter.adoc[SQL Counter]
+**** xref:mods-available/sqlippool.adoc[SQL-IP-Pool]
+**** xref:mods-available/sradutmp.adoc[sRadutmp]
+**** xref:mods-available/stats.adoc[Stats]
+**** xref:mods-available/totp.adoc[TOTP]
+**** xref:mods-available/unbound.adoc[Unbound]
+**** xref:mods-available/unix.adoc[Unix]
+**** xref:mods-available/unpack.adoc[Unpack]
+**** xref:mods-available/utf8.adoc[UTF-8]
+**** xref:mods-available/wimax.adoc[WiMAX]
+**** xref:mods-available/winbind.adoc[Winbind]
+**** xref:mods-available/yubikey.adoc[Yubikey]
+
+*** xref:index.adoc[Virtual Servers]
+**** xref:sites-available/abfab-tls.adoc[ABFAB: Listening on TLS]
+**** xref:sites-available/abfab-tr-idp.adoc[ABFAB: Trust Router]
+**** xref:sites-available/arp.adoc[ARP Virtual Server]
+**** xref:sites-available/bfd.adoc[BFD - Bidirectional Forwarding Detection]
+**** xref:sites-available/buffered-sql.adoc[Buffered SQL]
+**** xref:sites-available/challenge.adoc[Challenge]
+**** xref:sites-available/channel_bindings.adoc[Channel Bindings]
+**** xref:sites-available/check-eap-tls.adoc[Check EAP-TLS]
+**** xref:sites-available/coa.adoc[CoA]
+**** xref:sites-available/control-socket.adoc[Control Socket Interface.]
+**** xref:sites-available/copy-acct-to-home-server.adoc[Copy ACCT to Home Server]
+**** xref:sites-available/decoupled-accounting.adoc[Decoupled Accounting]
+**** xref:sites-available/detail.adoc[Detail]
+**** xref:sites-available/dhcp.adoc[Dhcp]
+**** xref:sites-available/dhcp.relay.adoc[Dhcp Relay]
+**** xref:sites-available/dynamic-clients.adoc[Dynamic Clients]
+**** xref:sites-available/example.adoc[Example]
+**** xref:sites-available/inner-tunnel.adoc[Inner Tunnel]
+**** xref:sites-available/ldap_sync.adoc[LDAP Sync]
+**** xref:sites-available/originate-coa.adoc[Originate CoA-Request packets]
+**** xref:sites-available/proxy-inner-tunnel.adoc[Proxy Inner Tunnel]
+**** xref:sites-available/radius-acct.adoc[Radius Acct]
+**** xref:sites-available/robust-proxy-accounting.adoc[Robust Proxy Accounting]
+**** xref:sites-available/status.adoc[Status]
+**** xref:sites-available/tacacs.adoc[Tacacs]
+**** xref:sites-available/default.adoc[The default Virtual Server]
+**** xref:sites-available/tls-cache.adoc[TLS Cache]
+**** xref:sites-available/tls.adoc[TLS]
+**** xref:sites-available/virtual.example.com.adoc[virtual.example.com]
+**** xref:sites-available/vmps.adoc[VMPS]
+**** xref:experimental.conf.adoc[Experimental modules]
+
+*** xref:clients.conf.adoc[Client Definitions]
+*** xref:debug.conf.adoc[Debugging configuration]
+*** xref:dictionary.adoc[Local dictionary definitions]
+*** xref:radrelay.conf.adoc[Radrelay Configuration]
+*** xref:radiusd.conf.adoc[Server Configuration File]
+*** xref:templates.conf.adoc[Templates]
+*** xref:trigger.conf.adoc[Triggers]
There are small number of high-level concepts associated with the server, as outlined below.
* xref:unlang/index.adoc[Unlang] syntax
-* xref:raddb:index.adoc[Configuration Files]
+* xref:reference:raddb/index.adoc[Configuration Files]
* xref:dictionary/index.adoc[Dictionary] where attribute names and data types are defined
* xref:type/index.adoc[Data Types] in the server
* xref:xlat/index.adoc[Dynamic expansions] i.e. "xlat"s.
The server includes a large number of
-xref:raddb:index.adoc[configuration files]. These files are
+xref:reference:raddb/index.adoc[configuration files]. These files are
automatically converted to HTML for the on-line documentation.
During normal operation, the server receives packets of information
With RADIUS, it is true that basic configuration is simple. For
example, policies such as "I have users in LDAP, and I want
authenticated users to access the network". For this policy, the
-administrator configures the xref:raddb:mods-available/ldap.adoc[LDAP]
-module, adds some xref:raddb:clients.conf.adoc[client] definitions,
+administrator configures the xref:reference:raddb/mods-available/ldap.adoc[LDAP]
+module, adds some xref:reference:raddb/clients.conf.adoc[client] definitions,
and _everything just works_.
The problem comes when people need policies like "allow users onto the
The `users` file as located in `raddb/mods-config/files/authorize`. (Livingston-style format).
-See the xref:raddb:mods-config/files/users.adoc[users] file documentation for information
+See the xref:reference:raddb/mods-config/files/users.adoc[users] file documentation for information
on the format of the input file, and how it operates.
Note that unlike v4, the key does not have to be a string, but could instead
be an IP address or netmask! For more information, see
-xref:raddb:mods-config/files/users.adoc[users]
+xref:reference:raddb/mods-config/files/users.adoc[users]
For authorization queries, the default schema mirrors the
functionality of the `files` module, including check items and
reply items. See the
-xref:raddb:mods-config/files/users.adoc[users] file
+xref:reference:raddb/mods-config/files/users.adoc[users] file
documentation for information on the format of the check items and
reply items.
= The users file
-The `users` file is managed by the xref:raddb:mods-available/files.adoc[files] module. The format largely goes back to the original Livingston RADIUS server in 1991!
+The `users` file is managed by the xref:reference:raddb/mods-available/files.adoc[files] module. The format largely goes back to the original Livingston RADIUS server in 1991!
-While the format is still called `users` for historical reasons, the name of the file is controlled by the configuration of the xref:raddb:mods-available/files.adoc[files] module, and can therefore something other than `users`.
+While the format is still called `users` for historical reasons, the name of the file is controlled by the configuration of the xref:reference:raddb/mods-available/files.adoc[files] module, and can therefore something other than `users`.
== Format
... reply items ...
----
-name:: The name of the entry. It must be an unquoted string such as `john`. The xref:raddb:mods-available/files.adoc[files] module configuration expands the `key` configuration item, and then uses the result to match the `name` of the entry.
+name:: The name of the entry. It must be an unquoted string such as `john`. The xref:reference:raddb/mods-available/files.adoc[files] module configuration expands the `key` configuration item, and then uses the result to match the `name` of the entry.
check items:: A comma-separated list of attributes to use for conditional matches, such as `Framed-IP-Address == 192.0.2.1`, or `NAS-IP-Address == 192.0.2.2, NAS-Port = 15`. Multiple conditions are matched with a logical "and". There is no way to use a logical "or" between conditions.
+
Despite these limitations, it has proven to be useful and powerful.
While the server includes plugins for languages such as
-xref:raddb:mods-available/lua.adoc[lua],
-xref:raddb:mods-available/python.adoc[python], and
-xref:raddb:mods-available/perl.adoc[perl], most policies can be done
+xref:reference:raddb/mods-available/lua.adoc[lua],
+xref:reference:raddb/mods-available/python.adoc[python], and
+xref:reference:raddb/mods-available/perl.adoc[perl], most policies can be done
in simple `unlang` statements. More general purpose programming
languages are more powerful than `unlang`, but they are generally
sustantially slower.
----
The processing sections are defined in
-xref:raddb:sites-available/index.adoc[virtual servers]. The
-xref:raddb:sites-available/index.adoc[virtual server] documentation
+xref:reference:raddb/sites-available/index.adoc[virtual servers]. The
+xref:reference:raddb/sites-available/index.adoc[virtual server] documentation
describes the larger context of which packets are recieved, and when
they are received. This section concentrates on the more narrow topic
`unlang` itself.
One key difference between normal programming languages and Unlang is
the concept of xref:unlang/module.adoc[modules]. The modules are
treated as keywords in the language which contain complex behavior.
-For example, the xref:raddb:mods-available/sql.adoc[sql] module has a
+For example, the xref:reference:raddb/mods-available/sql.adoc[sql] module has a
complex set of pre-defined behavior, depending on what kind of packet
it is processing.
The benefit of this approach is that the _policies_ are simple:
"allocate an IP, if that doesn't work, send a reject". However, the
_details_ of those policies are hidden behind the
-xref:raddb:mods-available/sqlippool.adoc[sqlippool] configuration.
+xref:reference:raddb/mods-available/sqlippool.adoc[sqlippool] configuration.
This abstraction allows the underyling
-xref:raddb:mods-available/sqlippool.adoc[sqlippool] configuration to
+xref:reference:raddb/mods-available/sqlippool.adoc[sqlippool] configuration to
be changed from MySQL to PostgreSQL without affecting any of the
policies.
The server includes dozens of
-xref:raddb:mods-available/index.adoc[modules], each of which defines a
+xref:reference:raddb/mods-available/index.adoc[modules], each of which defines a
complex set of behavior. Please see the
-xref:raddb:mods-available/index.adoc[modules] documentation for more
+xref:reference:raddb/mods-available/index.adoc[modules] documentation for more
information.
=== Algorithm
The documentation below describes how to reference modules. That is,
how to use `sql`, etc. in the policies. Please see the
-xref:raddb:mods-available/index.adoc[module configuration] and the
+xref:reference:raddb/mods-available/index.adoc[module configuration] and the
xref:howto:modules/configuring_modules.adoc[configuring modules] howto
pages for information on configuring and using the modules.
section.
In practice, these modules are implemented by the
-xref:raddb:mods-available/always.adoc[always] module and exist so that a
+xref:reference:raddb/mods-available/always.adoc[always] module and exist so that a
success or failure can be forced during the processing of a policy.
The names and behaviours of these modules are given below:
The following are single letter expansions.
The xref:xlat/builtin.adoc[builtin] `%time(...)` expansion and the
-xref:raddb:mods-available/date.adoc[date] module should be used
+xref:reference:raddb/mods-available/date.adoc[date] module should be used
instead of these expansions.
Request timestamp in SQL format, `YYYY-mmm-ddd HH:MM:SS`.
-The xref:raddb:mods-available/date.adoc[date] module should be used
+The xref:reference:raddb/mods-available/date.adoc[date] module should be used
instead.
`%t()`::
Request timestamp in _ctime_ format, `Www Mmm dd HH:MM:SS YYYY`.
-The xref:raddb:mods-available/date.adoc[date] module should be used
+The xref:reference:raddb/mods-available/date.adoc[date] module should be used
instead.
`%T()`::
Request timestamp in ISO format, `YYYY-mm-ddTHH:MM:SS.000`.
-The xref:raddb:mods-available/date.adoc[date] module should be used
+The xref:reference:raddb/mods-available/date.adoc[date] module should be used
instead.
// Copyright (C) 2023 Network RADIUS SAS. Licenced under CC-by-NC 4.0.
*Files:*
-- xref:raddb:mods-available/radius.adoc[`etc/raddb/mods-available/radius`]
-- xref:raddb:sites-available/default.adoc[`etc/raddb/sites-available/default`] (optionally)
-- xref:raddb:mods-available/linelog.adoc[`etc/raddb/mods-available/linelog`] (optionally)
+- xref:reference:raddb/mods-available/radius.adoc[`etc/raddb/mods-available/radius`]
+- xref:reference:raddb/sites-available/default.adoc[`etc/raddb/sites-available/default`] (optionally)
+- xref:reference:raddb/mods-available/linelog.adoc[`etc/raddb/mods-available/linelog`] (optionally)
*Time:* 20-30 minutes
*Files:*
-- xref:raddb:clients.conf.adoc[`etc/raddb/clients.conf`]
+- xref:reference:raddb/clients.conf.adoc[`etc/raddb/clients.conf`]
*Time*: 15-20 minutes
*Files:*
-- xref:raddb:mods-available/suffix.adoc[`etc/raddb/mods-available/suffix`]
-- xref:raddb:mods-available/files.adoc[`etc/raddb/mods-available/files`]
+- xref:reference:raddb/mods-available/suffix.adoc[`etc/raddb/mods-available/suffix`]
+- xref:reference:raddb/mods-available/files.adoc[`etc/raddb/mods-available/files`]
- `etc/raddb/mods-config/files/authorize`
-- xref:raddb:mods-available/ldap.adoc[`etc/raddb/mods-available/ldap`]
-- xref:raddb:mods-available/redis.adoc[`etc/raddb/mods-available/redis`]
-- xref:raddb:mods-available/rest.adoc[`etc/raddb/mods-available/rest`]
-- xref:raddb:mods-available/sql.adoc[`etc/raddb/mods-available/sql`]
+- xref:reference:raddb/mods-available/ldap.adoc[`etc/raddb/mods-available/ldap`]
+- xref:reference:raddb/mods-available/redis.adoc[`etc/raddb/mods-available/redis`]
+- xref:reference:raddb/mods-available/rest.adoc[`etc/raddb/mods-available/rest`]
+- xref:reference:raddb/mods-available/sql.adoc[`etc/raddb/mods-available/sql`]
*Time:* 20-60 minutes
- xref:reference:unlang/condition/index.adoc[Conditional Expressions]
- xref:reference:unlang/return_codes[Return Codes]
- xref:reference:unlang/condition/return_codes.adoc[The Return Code Operator]
-- xref:raddb:mods-available/always.adoc[The Always Module]
-- xref:raddb:mods-available/sometimes.adoc[The Sometimes Module]
+- xref:reference:raddb/mods-available/always.adoc[The Always Module]
+- xref:reference:raddb/mods-available/sometimes.adoc[The Sometimes Module]
include::partial$unlang_start.adoc[]
The server includes a number of instances of the
-xref:raddb:mods-available/always.adoc[always] module. These are used to set
+xref:reference:raddb/mods-available/always.adoc[always] module. These are used to set
return codes during policy evaluation.
For example, if the `ok` always module instance is called, the `ok` return code
special behaviour on failure.
To minimise external dependencies, for this exercise we will use the
-xref:raddb:mods-available/sometimes.adoc[sometimes] module to simulate an
+xref:reference:raddb/mods-available/sometimes.adoc[sometimes] module to simulate an
unreliable external database.
This module will return a specified xref:reference:unlang/return_codes[return code] 50%
[TIP]
====
You may need to modify the return code priorities of the
-xref:raddb:mods-available/sometimes.adoc[sometimes] module.
+xref:reference:raddb/mods-available/sometimes.adoc[sometimes] module.
====
If the policies are correct you will see that FreeRADIUS returns an