Commit e4a0726d authored by Stefan Schlesinger's avatar Stefan Schlesinger
Browse files

Merge branch 'master' into huntgroup

parents f4d11566 96836bc9
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -42,6 +42,10 @@ versions of Debian and Ubuntu still package FreeRADIUS 2.2.x which is end-of-lif
If you use Debian or Ubuntu, you will need to use version 1.x of this module,
which itself is no longer maintained.

This module requires Puppet 4.0.0 or greater. Puppet 3.x was
[discontinued](https://puppet.com/misc/puppet-enterprise-lifecycle) at
the end of 2016.

| `jgazeley/freeradius` | FreeRADIUS  |
| --------------------- | ----------- |
| 2.x                   | 3.x         |
@@ -77,6 +81,9 @@ of the global settings to increase flexibility. Patches are welcome.
##### `control_socket`
Use of the control_socket parameter in the freeradius class is deprecated. Use the `freeradius::control_socket` class instead.

##### `correct_escapes`
Use correct backslash escaping in unlang. Default: `true`

##### `max_requests`
The maximum number of requests which the server keeps track of. This should be 256 multiplied by the number of clients. Default: `4096`

@@ -267,7 +274,7 @@ Default: `undef`.
The IPv6 address of the client or range in CIDR format. `ip` and `ip6` are mutually exclusive but one must be supplied. Default: `undef`.

##### `shortname`
A short alias that is used in place of the IP address or fully qualified hostname provided in the first line of the section. Required.
A short alias that is used in place of the IP address or fully qualified hostname provided in the first line of the section. Defaults to resource name.

##### `secret`
The RADIUS shared secret used for communication between the client/NAS and the RADIUS server. Required.
+1 −1
Original line number Diff line number Diff line
# Install FreeRADIUS clients (WISMs or testing servers)
define freeradius::client (
  $shortname,
  $secret,
  $shortname                     = $title,
  $ip                            = undef,
  $ip6                           = undef,
  $proto                         = undef,
+23 −0
Original line number Diff line number Diff line

# == Define: freeradius::module::detail
#
define freeradius::module::detail (
  Enum['present','absent'] $ensure                 = 'present',
  String $filename                                 = "\${radacctdir}/%{%{Packet-Src-IP-Address}:-%{Packet-Src-IPv6-Address}}/detail-%Y%m%d",
  Freeradius::Boolean $escape_filenames            = 'no',
  String $permissions                              = '0600',
  Optional[String] $group                          = undef,
  String $header                                   = '%t',
  Optional[Freeradius::Boolean] $locking           = undef,
  Optional[Freeradius::Boolean] $log_packet_header = undef,
  Array[String] $suppress                          = [],
) {
  if $suppress {
    validate_array($suppress)
  }

  freeradius::module {"detail.${name}":
    ensure  => $ensure,
    content => template('freeradius/detail.erb'),
  }
}
+76 −0
Original line number Diff line number Diff line
# == Class: freeradius::eap
#
# Define to configure eap FreeRADIUS module
#
define freeradius::module::eap (
  $ensure                                                           = 'present',
  $default_eap_type                                                 = 'md5',
  Integer $timer_expire                                             = 60,
  Freeradius::Boolean $ignore_unknown_eap_types                     = 'no',
  Freeradius::Boolean $cisco_accounting_username_bug                = 'no',
  Freeradius::Integer $max_sessions                                 = "\${max_requests}",
  Boolean $eap_pwd                                                  = false,
  Optional[Variant[String,Integer]] $pwd_group                      = undef,
  Optional[String] $pwd_server_id                                   = undef,
  Optional[Integer] $pwd_fragment_size                              = undef,
  Optional[String] $pwd_virtual_server                              = undef,
  Optional[String] $gtc_challenge                                   = undef,
  String $gtc_auth_type                                             = 'PAP',
  String $tls_config_name                                           = 'tls-common',
  Optional[String] $tls_private_key_password                        = undef,
  String $tls_private_key_file                                      = "\${certdir}/server.pem",
  String $tls_certificate_file                                      = "\${certdir}/server.pem",
  String $tls_ca_file                                               = "\${certdir}/ca.pem",
  Optional[Freeradius::Boolean] $tls_auto_chain                     = undef,
  Optional[String] $tls_psk_identity                                = undef,
  Optional[String] $tls_psk_hexphrase                               = undef,
  String $tls_dh_file                                               = "\${certdir}/dh",
  Optional[String] $tls_random_file                                 = undef,
  Optional[Integer] $tls_fragment_size                              = undef,
  Optional[Freeradius::Boolean] $tls_include_length                 = undef,
  Optional[Freeradius::Boolean] $tls_check_crl                      = undef,
  Optional[Freeradius::Boolean] $tls_check_all_crl                  = undef,
  String $tls_ca_path                                               = "\${cadir}",
  Optional[String] $tls_check_cert_issuer                           = undef,
  Optional[String] $tls_check_cert_cn                               = undef,
  String $tls_cipher_list                                           = 'DEFAULT',
  Optional[Freeradius::Boolean] $tls_disable_tlsv1_2                = undef,
  String $tls_ecdh_curve                                            = 'prime256v1',
  Freeradius::Boolean $tls_cache_enable                             = 'yes',
  Integer $tls_cache_lifetime                                       = 24,
  Integer $tls_cache_max_entries                                    = 255,
  Optional[String] $tls_cache_name                                  = undef,
  Optional[String] $tls_cache_persist_dir                           = undef,
  Optional[Freeradius::Boolean] $tls_verify_skip_if_ocsp_ok         = undef,
  Optional[String] $tls_verify_tmpdir                               = undef,
  Optional[String] $tls_verify_client                               = undef,
  Freeradius::Boolean $tls_ocsp_enable                              = 'no',
  Freeradius::Boolean $tls_ocsp_override_cert_url                   = 'yes',
  String $tls_ocsp_url                                              = 'http://127.0.0.1/ocsp/',
  Optional[Freeradius::Boolean] $tls_ocsp_use_nonce                 = undef,
  Optional[Integer] $tls_ocsp_timeout                               = undef,
  Optional[Freeradius::Boolean] $tls_ocsp_softfail                  = undef,
  Optional[String] $tls_virtual_server                              = undef,
  String $ttls_default_eap_type                                     = 'md5',
  Freeradius::Boolean $ttls_copy_request_to_tunnel                  = 'no',
  Freeradius::Boolean $ttls_use_tunneled_reply                      = 'no',
  String $ttls_virtual_server                                       = 'inner-tunnel',
  Optional[Freeradius::Boolean] $ttls_include_length                = undef,
  Optional[Freeradius::Boolean] $ttls_require_client_cert           = undef,
  String $peap_default_eap_type                                     = 'mschapv2',
  Freeradius::Boolean $peap_copy_request_to_tunnel                  = 'no',
  Freeradius::Boolean $peap_use_tunneled_reply                      = 'no',
  Optional[Freeradius::Boolean] $peap_proxy_tunneled_request_as_eap = undef,
  String $peap_virtual_server                                       = 'inner-tunnel',
  Optional[Freeradius::Boolean] $peap_soh                           = undef,
  Optional[String] $peap_soh_virtual_server                         = undef,
  Optional[Freeradius::Boolean] $peap_require_client_cert           = undef,
  Optional[Freeradius::Boolean] $mschapv2_send_error                = undef,
  Optional[String] $mschapv2_identity                               = undef,
) {

  freeradius::module{$name:
    ensure  => $ensure,
    content => template('freeradius/eap.erb'),
  }
}
+20 −0
Original line number Diff line number Diff line
# == Define: freeradius::module::ippool
#
define freeradius::module::ippool (
  String $range_start,
  String $range_stop,
  String $netmask,
  $ensure                       = 'present',
  Optional[Integer] $cache_size = undef,
  String $filename              = "\${db_dir}/db.${name}",
  String $ip_index              = "\${db_dir}/db.${name}.index",
  Freeradius::Boolean $override = 'no',
  Integer $maximum_timeout      = 0,
  Optional[String] $key         = undef,
) {

  freeradius::module { "ippool_${name}":
    ensure  => $ensure,
    content => template('freeradius/ippool.erb'),
  }
}
Loading