Add configuration options for F-Ticks logging.
[libradsec.git] / radsecproxy.conf-example
1 # Master config file, must be in /etc/radsecproxy or specified with -c option
2 #       All possible config options are listed below
3
4 # First you may define any global options, these are:
5 #
6 # You can optionally specify addresses and ports to listen on
7 # Multiple statements can be used for multiple ports/addresses
8 #ListenUDP              *:1814
9 #listenUDP              localhost
10 #ListenTCP              [2001:700:1:7:215:f2ff:fe35:307d]:1812
11 #listenTLS              10.10.10.10:2084
12 #ListenTLS              [2001:700:1:7:215:f2ff:fe35:307d]:2084
13 #ListenDTLS             [2001:700:1:7:215:f2ff:fe35:307d]:2084
14
15 # To specify a certain address/port for UDP/TLS requests you can use e.g.
16 #SourceUDP              127.0.0.1:33000
17 #SourceTCP              *:33000
18 #SourceTLS              *:33001
19 #SourceDTLS             *:33001
20
21 # Optional log level. 3 is default, 1 is less, 5 is more
22 #LogLevel               3
23 # Optional LogDestination, else stderr used for logging
24 # Logging to file
25 #LogDestination         file:///tmp/rp.log
26 # Or logging with Syslog. LOG_DAEMON used if facility not specified
27 # The supported facilities are LOG_DAEMON, LOG_MAIL, LOG_USER and
28 # LOG_LOCAL0, ..., LOG_LOCAL7
29 #LogDestination         x-syslog:///
30 #LogDestination         x-syslog:///log_local2
31
32 # For generating log entries conforming to the F-Ticks system, specify
33 # F-Ticks-Reporting with one of
34 #   None  -- Do not log in F-Ticks format.  This is the default.
35 #   Basic -- Do log in F-Ticks format but do not log VISINST.
36 #   Full  -- Do log in F-Ticks format and do log VISINST.
37
38 # You can optionally specify F-Ticks-MAC in order to determine if and
39 # how Calling-Station-Id is logged.
40 #   Static          -- Use a static string as a placeholder for
41 #                      Calling-Station-Id.  This is the default.
42 #   Original        -- Log Calling-Station-Id as-is.
43 #   VendorHashed    -- Keep first three segments as-is, hash the rest.
44 #   VendorKeyHashed -- Like VendorHashed but salt with F-Ticks-Key.
45 #   FullyHashed     -- Hash the entire string.
46 #   FullyKeyHashed  -- Like FullyHashed but salt with F-Ticks-Key.
47
48 # In order to use F-Ticks-MAC with one of VendorKeyHashed or
49 # FullyKeyHashed, specify a key with F-Ticks-Key.
50 # F-Ticks-Key <key>
51
52 # Default F-Ticks configuration:
53 #F-Ticks-Reporting None
54 #F-Ticks-Mac FullyKeyHashed
55
56 # There is an option for doing some simple loop prevention.  Note that
57 # the LoopPrevention directive can be used in server blocks too,
58 # overriding what's set here in the basic settings.
59 #LoopPrevention         on
60 # Add TTL attribute with value 20 if not present (prevents endless loops)
61 #addTTL 20
62
63 # If we have TLS clients or servers we must define at least one tls block.
64 # You can name them whatever you like and then reference them by name when
65 # specifying clients or servers later. There are however three special names
66 # "default", "defaultclient" and "defaultserver". If no name is defined for
67 # a client, the "defaultclient" block will be used if it exists, if not the
68 # "default" will be used. For a server, "defaultserver" followed by "default"
69 # will be checked.
70 #
71 # The simplest configuration you can do is:
72 tls default {
73     # You must specify at least one of CACertificateFile or CACertificatePath
74     # for TLS to work. We always verify peer certificate (client and server)
75     # CACertificateFile    /etc/cacerts/CA.pem
76     CACertificatePath   /etc/cacerts
77
78     # You must specify the below for TLS, we always present our certificate
79     CertificateFile     /etc/hostcertkey/host.example.com.pem
80     CertificateKeyFile  /etc/hostcertkey/host.example.com.key.pem
81     # Optionally specify password if key is encrypted (not very secure)
82     CertificateKeyPassword      "follow the white rabbit"
83     # Optionally enable CRL checking
84     # CRLCheck on
85     # Optionally specify how long CAs and CRLs are cached, default forever
86     # CacheExpiry 3600
87     # Optionally require that peer certs have one of the specified policyOIDs
88     # policyoid     1.2.3 # this option can be used multiple times
89     # policyoid     1.3.4
90 }
91
92 # If you want one cert for all clients and another for all servers, use
93 # defaultclient and defaultserver instead of default. If we wanted some
94 # particular server to use something else you could specify a block
95 # "tls myserver" and then reference that for that server. If you always
96 # name the tls block in the client/server config you don't need a default
97
98 # Now we configure clients, servers and realms. Note that these and
99 # also the lines above may be in any order, except that a realm
100 # can only be configured to use a server that is previously configured.
101
102 # A realm can be a literal domain name, * which matches all, or a
103 # regexp. A regexp is specified by the character prefix /
104 # For regexp we do case insensitive matching of the entire username string.
105 # The matching of realms is done in the order they are specified, using the
106 # first match found. Some examples are
107 # "@example\.com$", "\.com$", ".*" and "^[a-z].*@example\.com$".
108 # To treat local users separately you might try first specifying "@"
109 # and after that "*".
110
111 # Configure a rewrite block if you want to add/remove/modify attributes
112 # rewrite example {
113 #       # Remove NAS-Port.
114 #       removeAttribute 5
115 #       # Remove vendor attribute 100.
116 #       removeVendorAttribute 99:100
117 #       # Called-Station-Id = "123456"
118 #       addAttribute 30:123456
119 #       # Vendor-99-Attr-101 = 0x0f
120 #       addVendorAttribute 99:101:%0f
121 #       # Change users @local to @example.com.
122 #       modifyAttribute 1:/^(.*)@local$/\1@example.com/
123 # }
124
125 client 2001:db8::1 {
126         type    tls
127         secret  verysecret
128 # we could specify tls here, e.g.
129 #       tls myclient
130 # in order to use tls parameters named myclient. We don't, so we will
131 # use "tls defaultclient" if defined, or look for "tls default" as a
132 # last resort
133 }
134 client 127.0.0.1 {
135         type    udp
136         secret  secret
137 #       Might do rewriting of incoming messages using rewrite block example
138 #       rewriteIn example
139 #       Can also do rewriting of outgoing messages
140 #       rewriteOut example      
141 }
142 client 127.0.0.1 {
143         type    tcp
144         secret  secret
145 }
146 client radius.example.com {
147         type tls
148 # secret is optional for TLS
149 }
150 client radius.example.com {
151         type dtls
152 # secret is optional for DTLS
153 }
154
155 server 127.0.0.1 {
156         type    UDP
157         secret  secret
158 #       Might do rewriting of incoming messages using rewrite block example
159 #       rewriteIn example
160 #       Can also do rewriting of outgoing messages
161 #       rewriteOut example      
162 #       Might override loop prevention here too:
163 #       LoopPrevention off
164 }
165 realm   eduroam.cc {
166         server  127.0.0.1
167 # If also want to use this server for accounting, specify
168 #       accountingServer 127.0.0.1
169 }
170
171 server 2001:db8::1 {
172         type    TLS
173         port    2283
174 # secret is optional for TLS
175 # we could specify tls here, e.g.
176 #       tls myserver
177 # in order to use tls parameters named myserver. We don't, so we will
178 # use "tls defaultserver" if defined, or look for "tls default" as a
179 # last resort
180 }
181 server radius.example.com {
182         type    tls
183         secret  verysecret
184         StatusServer on
185 # statusserver is optional, can be on or off. Off is default
186 }
187 #server radius.example.com {
188 #       type    dtls
189 #       secret  verysecret
190 #       StatusServer on
191 ## statusserver is optional, can be on or off. Off is default
192 #}
193
194 # Equivalent to example.com
195 realm /@example\.com$ {
196         server 2001:db8::1
197 }
198 # One can define a realm without servers, the proxy will then reject
199 # and requests matching this. Optionally one can specify ReplyMessage
200 # attribute to be included in the reject message. One can also use
201 # AccountingResponse option to specify that the proxy should send such.
202 realm /\.com$ {
203 }
204 realm /^anonymous$ {
205         replymessage "No Access"
206 #       AccountingResponse On
207 }
208 # The realm below is equivalent to /.*
209 realm * {
210         server radius.example.com
211 }
212 # If you don't have a default server you probably want to
213 # reject all unknowns. Optionally you can also include a message
214 #realm * {
215 #        replymessage "User unknown"
216 #}