Configuration File Syntax

The configuration files are UTF-8 text. They are line oriented, in that each entity should be placed on a separate line. For example, a configuration item can be assigned a value via the following statement

answer = 42

Variables have data types. That is, they can be IP addresses, strings, numbers, etc.

Long lines can be split by using a backslash character at the end of the line:

foo = "This is a really long line which\
contains a lot of text"

Comments follow the standard format:

# this is a comment

Comments can be used at the end of a valid statement, but not in the middle of one:

foo = bar # assign "bar" to variable "foo"

Portions of the configuration can be grouped, by using "curly braces". These groupings are called sections.

texas {
  dallas = yes
  houston = no
  san_antonio = 70
}

A configuration file can load another via the $INCLUDE statement:

$INCLUDE other.conf

Data Types

The configuration directives can contain many different kinds of data, e.g. integer, ip address, etc. Please see the data types page for a list of data types, and their associated meanings.

Configuration Directives

Some parts of the configuration have directives with pre-defined meaning. The meaning of the directives is context-dependent. For example, a listen section cannot be used inside of module definition.

Please see the radiusd.conf documentation for a complete list of configuration directives and their locations.

Context-Dependent Syntax

The configuration files follow this basic syntax, except for some files in the raddb/mods-config/ directory.

Run-time policies and conditional checks are described in the unlang chapter.