| 1 |
###################################################################### |
| 2 |
# |
| 3 |
# RADIUS over TLS (radsec) |
| 4 |
# |
| 5 |
# When a new client connects, the various TLS parameters for the |
| 6 |
# connection are available as dynamic expansions, e.g. |
| 7 |
# |
| 8 |
# %{listen:TLS-Client-Cert-Common-Name} |
| 9 |
# |
| 10 |
# Along with other TLS-Client-Cert-... attributes. |
| 11 |
# These expansions will only exist if the relevant fields |
| 12 |
# are in the client certificate. Read the debug output to see |
| 13 |
# which fields are available. Look for output like the following: |
| 14 |
# |
| 15 |
# (0) TLS - Creating attributes from certificate OIDs |
| 16 |
# (0) TLS-Client-Cert-Subject-Alt-Name-Dns := "one.example.org" |
| 17 |
# (0) TLS-Client-Cert-Subject-Alt-Name-Dns := "two.example.org" |
| 18 |
# ... |
| 19 |
# |
| 20 |
# It is also possible to distinguish between connections which have |
| 21 |
# TLS enables, and ones which do not. The expansion: |
| 22 |
# |
| 23 |
# %{listen:tls} |
| 24 |
# |
| 25 |
# Will return "yes" if the connection has TLS enabled. It will |
| 26 |
# return "no" if TLS is not enabled for a particular listen section. |
| 27 |
# |
| 28 |
# A number of TLS-Client-Cert-.. attributes holds X509v3 extensions |
| 29 |
# data, attributes named the way OpenSSL names them. It is possible |
| 30 |
# to extract data for an extension not known to OpenSSL by defining |
| 31 |
# a custom string attribute which contains extension OID in it's |
| 32 |
# name after 'TLS-Client-Cert-' prefix. E.g.: |
| 33 |
# |
| 34 |
# ATTRIBUTE TLS-Client-Cert-1.3.6.1.4.1.311.21.7 3002 string |
| 35 |
# |
| 36 |
# which will yield something simmilar to: |
| 37 |
# |
| 38 |
# (0) eap_tls: TLS - Creating attributes from certificate OIDs |
| 39 |
# (0) eap_tls: TLS-Client-Cert-1.3.6.1.4.1.311.21.7 += "0x302e06" |
| 40 |
# ... |
| 41 |
# |
| 42 |
###################################################################### |
| 43 |
|
| 44 |
listen { |
| 45 |
ipaddr = * |
| 46 |
port = 2083 |
| 47 |
|
| 48 |
# |
| 49 |
# TCP and TLS sockets can accept Access-Request and |
| 50 |
# Accounting-Request on the same socket. |
| 51 |
# |
| 52 |
# auth = only Access-Request |
| 53 |
# acct = only Accounting-Request |
| 54 |
# auth+acct = both |
| 55 |
# coa = only CoA / Disconnect requests |
| 56 |
# |
| 57 |
type = auth+acct |
| 58 |
|
| 59 |
# For now, only TCP transport is allowed. |
| 60 |
proto = tcp |
| 61 |
|
| 62 |
# Send packets to the default virtual server |
| 63 |
virtual_server = default |
| 64 |
|
| 65 |
# |
| 66 |
# We have clients specifically for TLS. |
| 67 |
# |
| 68 |
clients = radsec |
| 69 |
|
| 70 |
# |
| 71 |
# Use the haproxy "PROXY protocol". |
| 72 |
# |
| 73 |
# This configuration allows for many FreeRADIUS servers to be |
| 74 |
# behind a haproxy server. The "PROXY protocol" allows |
| 75 |
# haproxy to send the actual client IP to FreeRADIUS. |
| 76 |
# |
| 77 |
# This will work ONLY for RadSec (TLS). Both the haproxy AND |
| 78 |
# the RadSec client MUST be listed as allowed RADIUS clients. |
| 79 |
# |
| 80 |
# haproxy needs to have "send-proxy" configured for this server. |
| 81 |
# Health checks should be turned off, as haproxy does not |
| 82 |
# support RADIUS health checks. |
| 83 |
# |
| 84 |
# The main use of this feature is for scalability. There is no |
| 85 |
# longer any need to have a RADIUS proxy as a load balancer. |
| 86 |
# haproxy is fast, stable, and supports dynamic reloads! |
| 87 |
# |
| 88 |
# The only problem is that many RADIUS clients do not support |
| 89 |
# RadSec. That situation will hopefully change over time. |
| 90 |
# |
| 91 |
# proxy_protocol = no |
| 92 |
|
| 93 |
# |
| 94 |
# This configuration item should be enabled for all listen |
| 95 |
# sections which do TLS. |
| 96 |
# |
| 97 |
# It is only disabled because we are careful about changing |
| 98 |
# existing behavior in a stable release. |
| 99 |
# |
| 100 |
# Setting this configuration item to "yes" means that the |
| 101 |
# server will be able to gracefully recover if a TLS |
| 102 |
# connection is blocking at the network layer. |
| 103 |
# |
| 104 |
# Note that setting "nonblock = yes" is NOT possible for bare |
| 105 |
# TCP connections. RADIUS/TCP should generally be avoided. |
| 106 |
# |
| 107 |
# nonblock = yes |
| 108 |
|
| 109 |
# |
| 110 |
# When this is set to "yes", new TLS connections |
| 111 |
# are processed through a section called |
| 112 |
# |
| 113 |
# Autz-Type New-TLS-Connection { |
| 114 |
# ... |
| 115 |
# } |
| 116 |
# |
| 117 |
# The request contains TLS client certificate attributes, |
| 118 |
# and nothing else. The debug output will print which |
| 119 |
# attributes are available on your system. |
| 120 |
# |
| 121 |
# If the section returns "ok" or "updated", then the |
| 122 |
# connection is accepted. Otherwise the connection is |
| 123 |
# terminated. |
| 124 |
# |
| 125 |
# check_client_connections = yes |
| 126 |
|
| 127 |
# |
| 128 |
# Connection limiting for sockets with "proto = tcp". |
| 129 |
# |
| 130 |
limit { |
| 131 |
# |
| 132 |
# Limit the number of simultaneous TCP connections to the socket |
| 133 |
# |
| 134 |
# The default is 16. |
| 135 |
# Setting this to 0 means "no limit" |
| 136 |
max_connections = 16 |
| 137 |
|
| 138 |
# The per-socket "max_requests" option does not exist. |
| 139 |
|
| 140 |
# |
| 141 |
# The lifetime, in seconds, of a TCP connection. After |
| 142 |
# this lifetime, the connection will be closed. |
| 143 |
# |
| 144 |
# Setting this to 0 means "forever". |
| 145 |
lifetime = 0 |
| 146 |
|
| 147 |
# |
| 148 |
# The idle timeout, in seconds, of a TCP connection. |
| 149 |
# If no packets have been received over the connection for |
| 150 |
# this time, the connection will be closed. |
| 151 |
# |
| 152 |
# Setting this to 0 means "no timeout". |
| 153 |
# |
| 154 |
# We STRONGLY RECOMMEND that you set an idle timeout. |
| 155 |
# |
| 156 |
idle_timeout = 30 |
| 157 |
} |
| 158 |
|
| 159 |
# This is *exactly* the same configuration as used by the EAP-TLS |
| 160 |
# module. It's OK for testing, but for production use it's a good |
| 161 |
# idea to use different server certificates for EAP and for RADIUS |
| 162 |
# transport. |
| 163 |
# |
| 164 |
# If you want only one TLS configuration for multiple sockets, |
| 165 |
# then we suggest putting "tls { ...}" into radiusd.conf. |
| 166 |
# The subsection below can then be changed into a reference: |
| 167 |
# |
| 168 |
# tls = ${tls} |
| 169 |
# |
| 170 |
# Which means "the tls sub-section is not here, but instead is in |
| 171 |
# the top-level section called 'tls'". |
| 172 |
# |
| 173 |
# If you have multiple tls configurations, you can put them into |
| 174 |
# sub-sections of a top-level "tls" section. There's no need to |
| 175 |
# call them all "tls". You can then use: |
| 176 |
# |
| 177 |
# tls = ${tls.site1} |
| 178 |
# |
| 179 |
# to refer to the "site1" sub-section of the "tls" section. |
| 180 |
# |
| 181 |
tls { |
| 182 |
private_key_password = whatever |
| 183 |
private_key_file = /etc/ssl/private/ssl-cert-snakeoil.key |
| 184 |
|
| 185 |
# Accept an expired Certificate Revocation List |
| 186 |
# |
| 187 |
# allow_expired_crl = no |
| 188 |
|
| 189 |
# If Private key & Certificate are located in |
| 190 |
# the same file, then private_key_file & |
| 191 |
# certificate_file must contain the same file |
| 192 |
# name. |
| 193 |
# |
| 194 |
# If ca_file (below) is not used, then the |
| 195 |
# certificate_file below MUST include not |
| 196 |
# only the server certificate, but ALSO all |
| 197 |
# of the CA certificates used to sign the |
| 198 |
# server certificate. |
| 199 |
certificate_file = /etc/ssl/certs/ssl-cert-snakeoil.pem |
| 200 |
|
| 201 |
# Trusted Root CA list |
| 202 |
# |
| 203 |
# ALL of the CA's in this list will be trusted |
| 204 |
# to issue client certificates for authentication. |
| 205 |
# |
| 206 |
# In general, you should use self-signed |
| 207 |
# certificates for 802.1x (EAP) authentication. |
| 208 |
# In that case, this CA file should contain |
| 209 |
# *one* CA certificate. |
| 210 |
# |
| 211 |
# This parameter is used only for EAP-TLS, |
| 212 |
# when you issue client certificates. If you do |
| 213 |
# not use client certificates, and you do not want |
| 214 |
# to permit EAP-TLS authentication, then delete |
| 215 |
# this configuration item. |
| 216 |
ca_file = /etc/ssl/certs/ca-certificates.crt |
| 217 |
|
| 218 |
# For DH cipher suites to work in OpenSSL < 1.1.0, |
| 219 |
# you have to run OpenSSL to create the DH file |
| 220 |
# first: |
| 221 |
# |
| 222 |
# openssl dhparam -out certs/dh 2048 |
| 223 |
# |
| 224 |
# For OpenSSL >= 1.1.0, just leave this commented |
| 225 |
# out, and OpenSSL will do the right thing. |
| 226 |
# |
| 227 |
# dh_file = ${certdir}/dh |
| 228 |
|
| 229 |
# |
| 230 |
# If your system doesn't have /dev/urandom, |
| 231 |
# you will need to create this file, and |
| 232 |
# periodically change its contents. |
| 233 |
# |
| 234 |
# For security reasons, FreeRADIUS doesn't |
| 235 |
# write to files in its configuration |
| 236 |
# directory. |
| 237 |
# |
| 238 |
# random_file = /dev/urandom |
| 239 |
|
| 240 |
# |
| 241 |
# The default fragment size is 1K. |
| 242 |
# However, it's possible to send much more data than |
| 243 |
# that over a TCP connection. The upper limit is 64K. |
| 244 |
# Setting the fragment size to more than 1K means that |
| 245 |
# there are fewer round trips when setting up a TLS |
| 246 |
# connection. But only if the certificates are large. |
| 247 |
# |
| 248 |
fragment_size = 8192 |
| 249 |
|
| 250 |
# include_length is a flag which is |
| 251 |
# by default set to yes If set to |
| 252 |
# yes, Total Length of the message is |
| 253 |
# included in EVERY packet we send. |
| 254 |
# If set to no, Total Length of the |
| 255 |
# message is included ONLY in the |
| 256 |
# First packet of a fragment series. |
| 257 |
# |
| 258 |
# include_length = yes |
| 259 |
|
| 260 |
# Check the Certificate Revocation List |
| 261 |
# |
| 262 |
# 1) Copy CA certificates and CRLs to same directory. |
| 263 |
# 2) Execute 'c_rehash <CA certs&CRLs Directory>'. |
| 264 |
# 'c_rehash' is OpenSSL's command. |
| 265 |
# 3) uncomment the line below. |
| 266 |
# 5) Restart radiusd |
| 267 |
# check_crl = yes |
| 268 |
ca_path = ${cadir} |
| 269 |
|
| 270 |
# OpenSSL does not reload contents of ca_path dir over time. |
| 271 |
# That means that if check_crl is enabled and CRLs are loaded |
| 272 |
# from ca_path dir, at some point CRLs will expire and |
| 273 |
# RADIUSd will stop authenticating NASes. |
| 274 |
# If ca_path_reload_interval is non-zero, it will force OpenSSL |
| 275 |
# to reload all data from ca_path periodically |
| 276 |
# |
| 277 |
# Flush ca_path each hour |
| 278 |
ca_path_reload_interval = 3600 |
| 279 |
|
| 280 |
# |
| 281 |
# If check_cert_issuer is set, the value will |
| 282 |
# be checked against the DN of the issuer in |
| 283 |
# the client certificate. If the values do not |
| 284 |
# match, the certificate verification will fail, |
| 285 |
# rejecting the user. |
| 286 |
# |
| 287 |
# This check can be done more generally by checking |
| 288 |
# the value of the TLS-Client-Cert-Issuer attribute. |
| 289 |
# This check can be done via any mechanism you choose. |
| 290 |
# |
| 291 |
# check_cert_issuer = "/C=GB/ST=Berkshire/L=Newbury/O=My Company Ltd" |
| 292 |
|
| 293 |
# |
| 294 |
# If check_cert_cn is set, the value will |
| 295 |
# be xlat'ed and checked against the CN |
| 296 |
# in the client certificate. If the values |
| 297 |
# do not match, the certificate verification |
| 298 |
# will fail rejecting the user. |
| 299 |
# |
| 300 |
# This check is done only if the previous |
| 301 |
# "check_cert_issuer" is not set, or if |
| 302 |
# the check succeeds. |
| 303 |
# |
| 304 |
# In 2.1.10 and later, this check can be done |
| 305 |
# more generally by checking the value of the |
| 306 |
# TLS-Client-Cert-Common-Name attribute. This check |
| 307 |
# can be done via any mechanism you choose. |
| 308 |
# |
| 309 |
# check_cert_cn = %{User-Name} |
| 310 |
# |
| 311 |
# Set this option to specify the allowed |
| 312 |
# TLS cipher suites. The format is listed |
| 313 |
# in "man 1 ciphers". |
| 314 |
cipher_list = "DEFAULT" |
| 315 |
|
| 316 |
# If enabled, OpenSSL will use server cipher list |
| 317 |
# (possibly defined by cipher_list option above) |
| 318 |
# for choosing right cipher suite rather than |
| 319 |
# using client-specified list which is OpenSSl default |
| 320 |
# behavior. Having it set to yes is a current best practice |
| 321 |
# for TLS |
| 322 |
cipher_server_preference = no |
| 323 |
|
| 324 |
# |
| 325 |
# Older TLS versions are deprecated. But for RadSec, |
| 326 |
# we CAN allow TLS 1.3. |
| 327 |
# |
| 328 |
tls_min_version = "1.2" |
| 329 |
tls_max_version = "1.3" |
| 330 |
|
| 331 |
# |
| 332 |
# See mods-available/eap for documentation |
| 333 |
# |
| 334 |
ecdh_curve = "" |
| 335 |
|
| 336 |
# |
| 337 |
# Session resumption / fast reauthentication |
| 338 |
# cache. |
| 339 |
# |
| 340 |
# The cache contains the following information: |
| 341 |
# |
| 342 |
# session Id - unique identifier, managed by SSL |
| 343 |
# User-Name - from the Access-Accept |
| 344 |
# Stripped-User-Name - from the Access-Request |
| 345 |
# Cached-Session-Policy - from the Access-Accept |
| 346 |
# |
| 347 |
# The "Cached-Session-Policy" is the name of a |
| 348 |
# policy which should be applied to the cached |
| 349 |
# session. This policy can be used to assign |
| 350 |
# VLANs, IP addresses, etc. It serves as a useful |
| 351 |
# way to re-apply the policy from the original |
| 352 |
# Access-Accept to the subsequent Access-Accept |
| 353 |
# for the cached session. |
| 354 |
# |
| 355 |
# On session resumption, these attributes are |
| 356 |
# copied from the cache, and placed into the |
| 357 |
# reply list. |
| 358 |
# |
| 359 |
# You probably also want "use_tunneled_reply = yes" |
| 360 |
# when using fast session resumption. |
| 361 |
# |
| 362 |
cache { |
| 363 |
# |
| 364 |
# Enable it. The default is "no". |
| 365 |
# Deleting the entire "cache" subsection |
| 366 |
# Also disables caching. |
| 367 |
# |
| 368 |
# |
| 369 |
# The session cache requires the use |
| 370 |
# of the "name" and "persist_dir" configuration items, below. |
| 371 |
# |
| 372 |
# The internal OpenSSL session cache has been permanently |
| 373 |
# disabled. |
| 374 |
# |
| 375 |
# You can disallow resumption for a |
| 376 |
# particular user by adding the following |
| 377 |
# attribute to the control item list: |
| 378 |
# |
| 379 |
# Allow-Session-Resumption = No |
| 380 |
# |
| 381 |
# If "enable = no" below, you CANNOT |
| 382 |
# enable resumption for just one user |
| 383 |
# by setting the above attribute to "yes". |
| 384 |
# |
| 385 |
enable = no |
| 386 |
|
| 387 |
# |
| 388 |
# Lifetime of the cached entries, in hours. |
| 389 |
# The sessions will be deleted after this |
| 390 |
# time. |
| 391 |
# |
| 392 |
lifetime = 24 # hours |
| 393 |
|
| 394 |
# |
| 395 |
# Internal "name" of the session cache. |
| 396 |
# Used to distinguish which TLS context |
| 397 |
# sessions belong to. |
| 398 |
# |
| 399 |
# The server will generate a random value |
| 400 |
# if unset. This will change across server |
| 401 |
# restart so you MUST set the "name" if you |
| 402 |
# want to persist sessions (see below). |
| 403 |
# |
| 404 |
# If you use IPv6, change the "ipaddr" below |
| 405 |
# to "ipv6addr" |
| 406 |
# |
| 407 |
#name = "TLS ${..ipaddr} ${..port} ${..proto}" |
| 408 |
|
| 409 |
# |
| 410 |
# Simple directory-based storage of sessions. |
| 411 |
# Two files per session will be written, the SSL |
| 412 |
# state and the cached VPs. This will persist session |
| 413 |
# across server restarts. |
| 414 |
# |
| 415 |
# The server will need write perms, and the directory |
| 416 |
# should be secured from anyone else. You might want |
| 417 |
# a script to remove old files from here periodically: |
| 418 |
# |
| 419 |
# find ${logdir}/tlscache -mtime +2 -exec rm -f {} \; |
| 420 |
# |
| 421 |
# This feature REQUIRES "name" option be set above. |
| 422 |
# |
| 423 |
#persist_dir = "${logdir}/tlscache" |
| 424 |
} |
| 425 |
|
| 426 |
# |
| 427 |
# Require a client certificate. |
| 428 |
# |
| 429 |
# If you set this to "no", then any client can |
| 430 |
# connect anonymously. This is bad, and is likely |
| 431 |
# not what you want. |
| 432 |
# |
| 433 |
require_client_cert = yes |
| 434 |
|
| 435 |
# |
| 436 |
# As of version 2.1.10, client certificates can be |
| 437 |
# validated via an external command. This allows |
| 438 |
# dynamic CRLs or OCSP to be used. |
| 439 |
# |
| 440 |
# This configuration is commented out in the |
| 441 |
# default configuration. Uncomment it, and configure |
| 442 |
# the correct paths below to enable it. |
| 443 |
# |
| 444 |
verify { |
| 445 |
# A temporary directory where the client |
| 446 |
# certificates are stored. This directory |
| 447 |
# MUST be owned by the UID of the server, |
| 448 |
# and MUST not be accessible by any other |
| 449 |
# users. When the server starts, it will do |
| 450 |
# "chmod go-rwx" on the directory, for |
| 451 |
# security reasons. The directory MUST |
| 452 |
# exist when the server starts. |
| 453 |
# |
| 454 |
# You should also delete all of the files |
| 455 |
# in the directory when the server starts. |
| 456 |
# |
| 457 |
# Note that, on Linux systems with systemd, the |
| 458 |
# /tmp directory may be restricted. In this case |
| 459 |
# it may be best to use `${run_dir}/tmp` here |
| 460 |
# and create the temporary directory with the |
| 461 |
# systemd `RuntimeDirectory` unit option. |
| 462 |
# |
| 463 |
# tmpdir = /tmp/radiusd |
| 464 |
|
| 465 |
# The command used to verify the client cert. |
| 466 |
# We recommend using the OpenSSL command-line |
| 467 |
# tool. |
| 468 |
# |
| 469 |
# The ${..ca_path} text is a reference to |
| 470 |
# the ca_path variable defined above. |
| 471 |
# |
| 472 |
# The %{TLS-Client-Cert-Filename} is the name |
| 473 |
# of the temporary file containing the cert |
| 474 |
# in PEM format. This file is automatically |
| 475 |
# deleted by the server when the command |
| 476 |
# returns. |
| 477 |
# client = "/path/to/openssl verify -CApath ${..ca_path} %{TLS-Client-Cert-Filename}" |
| 478 |
} |
| 479 |
|
| 480 |
# |
| 481 |
# When the RadSec clients use SNI, the server will |
| 482 |
# automatically choose the correct certificate from |
| 483 |
# "realm_dir". See raddb/certs/realms/README.md for |
| 484 |
# more information. |
| 485 |
# |
| 486 |
# Note that the default is to use the same set of |
| 487 |
# realm certificates for both EAP and RadSec! If |
| 488 |
# this is not what you want, you should use different |
| 489 |
# subdirectories or each, e.g. ${certdir}/realms/radsec/, |
| 490 |
# and ${certdir}/realms/eap/ |
| 491 |
# |
| 492 |
# realm_dir = ${certdir}/realms/ |
| 493 |
} |
| 494 |
} |
| 495 |
|
| 496 |
clients radsec { |
| 497 |
client 127.0.0.1 { |
| 498 |
ipaddr = 127.0.0.1 |
| 499 |
|
| 500 |
# |
| 501 |
# Ensure that this client is TLS *only*. |
| 502 |
# |
| 503 |
proto = tls |
| 504 |
|
| 505 |
# |
| 506 |
# TCP clients can have any shared secret. |
| 507 |
# |
| 508 |
# TLS clients MUST have the shared secret |
| 509 |
# set to "radsec". Or, for "proto = tls", |
| 510 |
# you can omit the secret, and it will |
| 511 |
# automatically be set to "radsec". |
| 512 |
# |
| 513 |
secret = radsec |
| 514 |
|
| 515 |
# |
| 516 |
# You can also use a "limit" section here. |
| 517 |
# See raddb/clients.conf for examples. |
| 518 |
# |
| 519 |
# Note that BOTH limits are applied. You |
| 520 |
# should therefore set the "listen" limits |
| 521 |
# higher than the ones for each individual |
| 522 |
# client. |
| 523 |
# |
| 524 |
} |
| 525 |
} |
| 526 |
|
| 527 |
# |
| 528 |
# When a request is proxied to a TLS-enabled home server, |
| 529 |
# the TLS parameters are available via the expansion: |
| 530 |
# |
| 531 |
# %{proxy_listen: ... } |
| 532 |
# |
| 533 |
# The contents of the expansion are the same as described |
| 534 |
# above with the %{listen: ... } expansion, and have similar |
| 535 |
# meanings. "client" in this case is the proxy (this system) |
| 536 |
# and "server" is the remote system (home server). |
| 537 |
# |
| 538 |
# Note that the %{proxy_listen: ... } parameters are available |
| 539 |
# only AFTER the connection has been made to the home server. |
| 540 |
# |
| 541 |
home_server tls { |
| 542 |
ipaddr = 127.0.0.1 |
| 543 |
port = 2083 |
| 544 |
|
| 545 |
# type can be the same types as for the "listen" section/ |
| 546 |
# e.g. auth, acct, auth+acct, coa |
| 547 |
type = auth |
| 548 |
secret = radsec |
| 549 |
proto = tcp |
| 550 |
status_check = none |
| 551 |
|
| 552 |
# |
| 553 |
# This configuration item should be enabled for all |
| 554 |
# home_server sections which do TLS. |
| 555 |
# |
| 556 |
# It is only disabled because we are careful about changing |
| 557 |
# existing behavior in a stable release. |
| 558 |
# |
| 559 |
# Setting this configuration item to "yes" means that the |
| 560 |
# server will be able to gracefully recover if a TLS |
| 561 |
# connection is blocking at the network layer. |
| 562 |
# |
| 563 |
# Note that setting "nonblock = yes" is NOT possible for bare |
| 564 |
# TCP connections. RADIUS/TCP should generally be avoided. |
| 565 |
# |
| 566 |
# nonblock = yes |
| 567 |
|
| 568 |
# |
| 569 |
# The TLS settings used by the proxy (i.e. RADIUS client) |
| 570 |
# when it connects to a home server. |
| 571 |
# |
| 572 |
tls { |
| 573 |
# |
| 574 |
# Similarly to HTTP, the client can use Server Name |
| 575 |
# Indication to inform the RadSec server as to which |
| 576 |
# domain it is requesting. This selection allows |
| 577 |
# multiple sites to exist at the same IP address. |
| 578 |
# |
| 579 |
# For example, an identity provider could host |
| 580 |
# multiple sites, but present itself with one public |
| 581 |
# IP address. If the RadSec clients do not use SNI, |
| 582 |
# then they must be configured with the certificate |
| 583 |
# of the identity provider. |
| 584 |
# |
| 585 |
# When SNI is used, the clients can be configured |
| 586 |
# with the certificate of the hosted system that |
| 587 |
# they're connecting to. This ability means that |
| 588 |
# there is no need to change certificates when |
| 589 |
# changing providers. In addition, there is no need |
| 590 |
# to change the configuration of all RadSec clients |
| 591 |
# when the hosting system changes its certifiates. |
| 592 |
# Because the hosting system certificates are never used. |
| 593 |
# |
| 594 |
# Instead, each hosted company is responsible for its |
| 595 |
# own certificates, and for its own clients. |
| 596 |
# |
| 597 |
# SNI also permits the use of a load balancer such as |
| 598 |
# haproxy. That load balancer can terminate the TLS |
| 599 |
# connection, and then use SNI to route the |
| 600 |
# underlying RADIUS TCP traffic to a particular host. |
| 601 |
# |
| 602 |
# Note that "hostname" here is only for SNI, and is NOT |
| 603 |
# the hostname or IP address we connect to. For that, |
| 604 |
# see "ipaddr", above. |
| 605 |
# |
| 606 |
# hostname = "example.com" |
| 607 |
|
| 608 |
private_key_password = whatever |
| 609 |
private_key_file = /etc/ssl/private/ssl-cert-snakeoil.key |
| 610 |
|
| 611 |
# If Private key & Certificate are located in |
| 612 |
# the same file, then private_key_file & |
| 613 |
# certificate_file must contain the same file |
| 614 |
# name. |
| 615 |
# |
| 616 |
# If ca_file (below) is not used, then the |
| 617 |
# certificate_file below MUST include not |
| 618 |
# only the server certificate, but ALSO all |
| 619 |
# of the CA certificates used to sign the |
| 620 |
# server certificate. |
| 621 |
certificate_file = /etc/ssl/certs/ssl-cert-snakeoil.pem |
| 622 |
|
| 623 |
# Trusted Root CA list |
| 624 |
# |
| 625 |
# ALL of the CA's in this list will be trusted |
| 626 |
# to issue client certificates for authentication. |
| 627 |
# |
| 628 |
# In general, you should use self-signed |
| 629 |
# certificates for 802.1x (EAP) authentication. |
| 630 |
# In that case, this CA file should contain |
| 631 |
# *one* CA certificate. |
| 632 |
# |
| 633 |
# This parameter is used only for EAP-TLS, |
| 634 |
# when you issue client certificates. If you do |
| 635 |
# not use client certificates, and you do not want |
| 636 |
# to permit EAP-TLS authentication, then delete |
| 637 |
# this configuration item. |
| 638 |
ca_file = /etc/ssl/certs/ca-certificates.crt |
| 639 |
|
| 640 |
# |
| 641 |
# Before version 3.2.1, outbound RadSec connections |
| 642 |
# would put the home server certificate into the |
| 643 |
# TLS-Client-Cert* attributes. Set this configuration |
| 644 |
# item to "yes" in order to have the home server |
| 645 |
# certificates placed into the "TLS-Cert-*" attributes. |
| 646 |
# |
| 647 |
# fix_cert_order = yes |
| 648 |
|
| 649 |
# |
| 650 |
# For TLS-PSK, the key should be specified |
| 651 |
# dynamically, instead of using a hard-coded |
| 652 |
# psk_identity and psk_hexphrase. |
| 653 |
# |
| 654 |
# The input to the dynamic expansion will be the PSK |
| 655 |
# identity supplied by the client, in the |
| 656 |
# TLS-PSK-Identity attribute. The output of the |
| 657 |
# expansion should be a hex string, of no more than |
| 658 |
# 512 characters. The string should not be prefixed |
| 659 |
# with "0x". e.g. "abcdef" is OK. "0xabcdef" is not. |
| 660 |
# |
| 661 |
# psk_query = "%{psksql:select hex(key) from psk_keys where keyid = '%{TLS-PSK-Identity}'}" |
| 662 |
|
| 663 |
# For TLS-PSK, you can hard-code a fixed PSK identity |
| 664 |
# and (hex) password here. |
| 665 |
# |
| 666 |
# psk_identity = "test" |
| 667 |
# psk_hexphrase = "036363823" |
| 668 |
|
| 669 |
# |
| 670 |
# For TLS-PSK, uncomment the following line to use |
| 671 |
# standard ciphers for TLS 1.3. |
| 672 |
# |
| 673 |
# TLS-PSK may work without this line, but it is |
| 674 |
# likely to not work when the "next hop" home_server |
| 675 |
# accepts both certificates and PSK. OpenSSL will |
| 676 |
# negotiate cipher suites which are incompatible with |
| 677 |
# PSK, and then fail. |
| 678 |
# |
| 679 |
# Setting the cipher_suites here forces PSK to be negotiated. |
| 680 |
# |
| 681 |
# cipher_suites = "TLS_CHACHA20_POLY1305_SHA256:TLS_AES_128_GCM_SHA256" |
| 682 |
|
| 683 |
# |
| 684 |
# For DH cipher suites to work, you have to |
| 685 |
# run OpenSSL to create the DH file first: |
| 686 |
# |
| 687 |
# openssl dhparam -out certs/dh 1024 |
| 688 |
# |
| 689 |
# dh_file = ${certdir}/dh |
| 690 |
# random_file = /dev/urandom |
| 691 |
|
| 692 |
# |
| 693 |
# The default fragment size is 1K. |
| 694 |
# However, TLS can send 64K of data at once. |
| 695 |
# It can be useful to set it higher. |
| 696 |
# |
| 697 |
fragment_size = 8192 |
| 698 |
|
| 699 |
# include_length is a flag which is |
| 700 |
# by default set to yes If set to |
| 701 |
# yes, Total Length of the message is |
| 702 |
# included in EVERY packet we send. |
| 703 |
# If set to no, Total Length of the |
| 704 |
# message is included ONLY in the |
| 705 |
# First packet of a fragment series. |
| 706 |
# |
| 707 |
# include_length = yes |
| 708 |
|
| 709 |
# Check the Certificate Revocation List |
| 710 |
# |
| 711 |
# 1) Copy CA certificates and CRLs to same directory. |
| 712 |
# 2) Execute 'c_rehash <CA certs&CRLs Directory>'. |
| 713 |
# 'c_rehash' is OpenSSL's command. |
| 714 |
# 3) uncomment the line below. |
| 715 |
# 5) Restart radiusd |
| 716 |
# check_crl = yes |
| 717 |
ca_path = ${cadir} |
| 718 |
|
| 719 |
# |
| 720 |
# If check_cert_issuer is set, the value will |
| 721 |
# be checked against the DN of the issuer in |
| 722 |
# the client certificate. If the values do not |
| 723 |
# match, the certificate verification will fail, |
| 724 |
# rejecting the user. |
| 725 |
# |
| 726 |
# In 2.1.10 and later, this check can be done |
| 727 |
# more generally by checking the value of the |
| 728 |
# TLS-Client-Cert-Issuer attribute. This check |
| 729 |
# can be done via any mechanism you choose. |
| 730 |
# |
| 731 |
# check_cert_issuer = "/C=GB/ST=Berkshire/L=Newbury/O=My Company Ltd" |
| 732 |
|
| 733 |
# |
| 734 |
# If check_cert_cn is set, the value will |
| 735 |
# be xlat'ed and checked against the CN |
| 736 |
# in the client certificate. If the values |
| 737 |
# do not match, the certificate verification |
| 738 |
# will fail rejecting the user. |
| 739 |
# |
| 740 |
# This check is done only if the previous |
| 741 |
# "check_cert_issuer" is not set, or if |
| 742 |
# the check succeeds. |
| 743 |
# |
| 744 |
# In 2.1.10 and later, this check can be done |
| 745 |
# more generally by checking the value of the |
| 746 |
# TLS-Client-Cert-Common-Name attribute. This check |
| 747 |
# can be done via any mechanism you choose. |
| 748 |
# |
| 749 |
# check_cert_cn = %{User-Name} |
| 750 |
# |
| 751 |
# Set this option to specify the allowed |
| 752 |
# TLS cipher suites. The format is listed |
| 753 |
# in "man 1 ciphers". |
| 754 |
cipher_list = "DEFAULT" |
| 755 |
|
| 756 |
# |
| 757 |
# Connection timeout for outgoing TLS connections. |
| 758 |
# Values are 1..30. |
| 759 |
# |
| 760 |
connect_timeout = 30 |
| 761 |
} |
| 762 |
} |
| 763 |
|
| 764 |
home_server_pool tls { |
| 765 |
type = fail-over |
| 766 |
home_server = tls |
| 767 |
} |
| 768 |
|
| 769 |
realm tls { |
| 770 |
auth_pool = tls |
| 771 |
} |