|
| 1 | +################# |
| 2 | +# glauth.conf |
| 3 | + |
| 4 | +################# |
| 5 | +# General configuration. |
| 6 | +debug = true |
| 7 | +# syslog = true |
| 8 | +# structuredlog = true |
| 9 | +# |
| 10 | +# Enable hot-reload of configuration on changes |
| 11 | +# - does NOT work [ldap], [ldaps], [backend] or [api] sections |
| 12 | +# watchconfig = true |
| 13 | + |
| 14 | +################# |
| 15 | +# yubikeyclientid = "yubi-api-clientid" |
| 16 | +# yubikeysecret = "yubi-api-secret" |
| 17 | + |
| 18 | +################# |
| 19 | +# Server configuration. |
| 20 | +[ldap] |
| 21 | + enabled = true |
| 22 | + # run on a non privileged port |
| 23 | + listen = "0.0.0.0:3893" |
| 24 | + |
| 25 | +[ldaps] |
| 26 | +# to enable ldaps generate a certificate, eg. with: |
| 27 | +# openssl req -x509 -newkey rsa:4096 -keyout glauth.key -out glauth.crt -days 365 -nodes -subj '/CN=`hostname`' |
| 28 | + enabled = false |
| 29 | + listen = "0.0.0.0:3894" |
| 30 | + cert = "glauth.crt" |
| 31 | + key = "glauth.key" |
| 32 | + |
| 33 | +################# |
| 34 | +# The backend section controls the data store. |
| 35 | +[backend] |
| 36 | + datastore = "plugin" |
| 37 | + plugin = "bin/postgres-linux-amd64.so" |
| 38 | + pluginHandler = "NewPostgresHandler" |
| 39 | + database = "host=127.0.0.1 port=5432 dbname=glauth user=glauthtest password=glauth sslmode=disable" |
| 40 | + baseDN = "dc=glauth,dc=com" |
| 41 | + nameformat = "cn" |
| 42 | + groupformat = "ou" |
| 43 | + |
| 44 | + # If you are using a client that requires reading the root DSE first |
| 45 | + # such as SSSD |
| 46 | + # anonymousdse = true |
| 47 | + |
| 48 | + ## Configure dn format to use structures like |
| 49 | + ## "uid=serviceuser,cn=svcaccts,$BASEDN" instead of "cn=serviceuser,ou=svcaccts,$BASEDN" |
| 50 | + ## to help ease migrations from other LDAP systems |
| 51 | + # nameformat = "uid" |
| 52 | + # groupformat = "cn" |
| 53 | + |
| 54 | + ## Configure ssh-key attribute name, default is 'sshPublicKey' |
| 55 | + # sshkeyattr = "ipaSshPubKey" |
| 56 | + |
| 57 | +[behaviors] |
| 58 | + # Ignore all capabilities restrictions, for instance allowing every user to perform a search |
| 59 | + IgnoreCapabilities = false |
| 60 | + # Enable a "fail2ban" type backoff mechanism temporarily banning repeated failed login attempts |
| 61 | + LimitFailedBinds = true |
| 62 | + # How many failed login attempts are allowed before a ban is imposed |
| 63 | + NumberOfFailedBinds = 3 |
| 64 | + # How long (in seconds) is the window for failed login attempts |
| 65 | + PeriodOfFailedBinds = 10 |
| 66 | + # How long (in seconds) is the ban duration |
| 67 | + BlockFailedBindsFor = 60 |
| 68 | + # Clean learnt IP addresses every N seconds |
| 69 | + PruneSourceTableEvery = 600 |
| 70 | + # Clean learnt IP addresses not seen in N seconds |
| 71 | + PruneSourcesOlderThan = 600 |
| 72 | + |
| 73 | +################# |
| 74 | +# Enable and configure the optional REST API here. |
| 75 | +[api] |
| 76 | + enabled = true |
| 77 | + internals = true # debug application performance |
| 78 | + tls = false # enable TLS for production!! |
| 79 | + listen = "0.0.0.0:5555" |
| 80 | + cert = "cert.pem" |
| 81 | + key = "key.pem" |
0 commit comments