2018-01-28 14:16:52 +00:00
|
|
|
---
|
|
|
|
|
|
|
|
login:
|
|
|
|
title: "luzifer.io - Login"
|
|
|
|
default_method: "simple"
|
2019-04-21 01:22:45 +00:00
|
|
|
default_redirect: "https://luzifer.io/"
|
2018-12-24 09:07:49 +00:00
|
|
|
hide_mfa_field: false
|
2018-01-28 14:16:52 +00:00
|
|
|
names:
|
|
|
|
simple: "Username / Password"
|
|
|
|
yubikey: "Yubikey"
|
|
|
|
|
|
|
|
cookie:
|
|
|
|
domain: ".example.com"
|
|
|
|
authentication_key: "Ff1uWJcLouKu9kwxgbnKcU3ps47gps72sxEz79TGHFCpJNCPtiZAFDisM4MWbstH"
|
|
|
|
expire: 3600 # Optional, default: 3600
|
|
|
|
prefix: "nginx-sso" # Optional, default: nginx-sso
|
|
|
|
secure: true # Optional, default: false
|
|
|
|
|
|
|
|
# Optional, default: 127.0.0.1:8082
|
|
|
|
listen:
|
|
|
|
addr: "127.0.0.1"
|
|
|
|
port: 8082
|
|
|
|
|
2018-11-17 13:42:56 +00:00
|
|
|
audit_log:
|
|
|
|
targets:
|
|
|
|
- fd://stdout
|
|
|
|
- file:///var/log/nginx-sso/audit.jsonl
|
|
|
|
events: ['access_denied', 'login_success', 'login_failure', 'logout', 'validate']
|
|
|
|
headers: ['x-origin-uri']
|
|
|
|
trusted_ip_headers: ["X-Forwarded-For", "RemoteAddr", "X-Real-IP"]
|
|
|
|
|
2018-01-28 14:16:52 +00:00
|
|
|
acl:
|
|
|
|
rule_sets:
|
|
|
|
- rules:
|
|
|
|
- field: "host"
|
|
|
|
equals: "test.example.com"
|
|
|
|
- field: "x-origin-uri"
|
|
|
|
regexp: "^/api"
|
|
|
|
allow: ["luzifer", "@admins"]
|
|
|
|
|
2018-12-24 09:07:49 +00:00
|
|
|
mfa:
|
|
|
|
yubikey:
|
|
|
|
# Get your client / secret from https://upgrade.yubico.com/getapikey/
|
|
|
|
client_id: "12345"
|
|
|
|
secret_key: "foobar"
|
|
|
|
|
2018-12-28 22:54:11 +00:00
|
|
|
duo:
|
2018-12-28 23:38:56 +00:00
|
|
|
# Get your ikey / skey / host from https://duo.com/docs/duoweb#first-steps
|
2018-12-28 22:54:11 +00:00
|
|
|
ikey: "IKEY"
|
|
|
|
skey: "SKEY"
|
|
|
|
host: "HOST"
|
|
|
|
user_agent: "nginx-sso"
|
|
|
|
|
2019-02-21 23:10:43 +00:00
|
|
|
plugins:
|
|
|
|
directory: ./plugins/
|
|
|
|
|
2018-01-28 14:16:52 +00:00
|
|
|
providers:
|
2018-02-04 13:51:08 +00:00
|
|
|
# Authentication against an Atlassian Crowd directory server
|
|
|
|
# Supports: Users, Groups
|
|
|
|
crowd:
|
|
|
|
url: "https://crowd.example.com/crowd/"
|
|
|
|
app_name: ""
|
|
|
|
app_pass: ""
|
|
|
|
|
2019-04-21 14:54:32 +00:00
|
|
|
# Authentication through OAuth2 workflow with Google Account
|
|
|
|
# Supports: Users
|
|
|
|
google_oauth:
|
|
|
|
client_id: ""
|
|
|
|
client_secret: ""
|
|
|
|
redirect_url: "https://login.luifer.io/login"
|
|
|
|
|
|
|
|
# Optional, defaults to no limitations
|
|
|
|
require_domain: "example.com"
|
|
|
|
# Optional, defaults to "user-id"
|
|
|
|
user_id_method: "full-email"
|
|
|
|
|
2018-03-15 22:12:09 +00:00
|
|
|
# Authentication against (Open)LDAP server
|
|
|
|
# Supports: Users, Groups
|
|
|
|
ldap:
|
|
|
|
enable_basic_auth: false
|
|
|
|
manager_dn: "cn=admin,dc=example,dc=com"
|
|
|
|
manager_password: ""
|
|
|
|
root_dn: "dc=example,dc=com"
|
|
|
|
server: "ldap://ldap.example.com"
|
|
|
|
# Optional, defaults to root_dn
|
|
|
|
user_search_base: ou=users,dc=example,dc=com
|
|
|
|
# Optional, defaults to '(uid={0})'
|
|
|
|
user_search_filter: ""
|
|
|
|
# Optional, defaults to root_dn
|
|
|
|
group_search_base: "ou=groups,dc=example,dc=com"
|
|
|
|
# Optional, defaults to '(|(member={0})(uniqueMember={0}))'
|
|
|
|
group_membership_filter: ""
|
2018-06-13 14:23:12 +00:00
|
|
|
# Replace DN as the username with another attribute
|
|
|
|
# Optional, defaults to "dn"
|
|
|
|
username_attribute: "uid"
|
2018-09-24 09:57:27 +00:00
|
|
|
# Configure TLS parameters for LDAPs connections
|
|
|
|
# Optional, defaults to null
|
|
|
|
tls_config:
|
|
|
|
# Set the hostname for certificate validation
|
|
|
|
# Optional, defaults to host from the connection URI
|
|
|
|
validate_hostname: ldap.example.com
|
|
|
|
# Disable certificate validation
|
|
|
|
# Optional, defaults to false
|
|
|
|
allow_insecure: false
|
2018-03-15 22:12:09 +00:00
|
|
|
|
2019-04-22 22:39:02 +00:00
|
|
|
# Authentication through OAuth2 workflow with OpenID Connect provider
|
|
|
|
# Supports: Users
|
|
|
|
oidc:
|
|
|
|
client_id: ""
|
|
|
|
client_secret: ""
|
|
|
|
# Optional, defaults to "OpenID Connect"
|
|
|
|
issuer_name: ""
|
|
|
|
issuer_url: ""
|
|
|
|
redirect_url: "https://login.luifer.io/login"
|
|
|
|
|
|
|
|
# Optional, defaults to no limitations
|
|
|
|
require_domain: "example.com"
|
|
|
|
# Optional, defaults to "subject"
|
|
|
|
user_id_method: "full-email"
|
|
|
|
|
|
|
|
|
2018-01-28 14:16:52 +00:00
|
|
|
# Authentication against embedded user database
|
2018-12-24 09:07:49 +00:00
|
|
|
# Supports: Users, Groups, MFA
|
2018-01-28 14:16:52 +00:00
|
|
|
simple:
|
2018-01-28 20:54:30 +00:00
|
|
|
enable_basic_auth: false
|
|
|
|
|
2018-01-28 14:16:52 +00:00
|
|
|
# Unique username mapped to bcrypt hashed password
|
|
|
|
users:
|
|
|
|
luzifer: "$2a$10$FSGAF8qDWX52aBID8.WpxOyCvfSQ3JIUVFiwyd1jolb4jM3BzJmNu"
|
|
|
|
|
|
|
|
# Groupname to users mapping
|
|
|
|
groups:
|
|
|
|
admins: ["luzifer"]
|
|
|
|
|
2018-12-24 09:07:49 +00:00
|
|
|
# MFA configs: Username to configs mapping
|
|
|
|
mfa:
|
|
|
|
luzifer:
|
2018-12-28 22:54:11 +00:00
|
|
|
- provider: duo
|
2018-12-28 23:38:56 +00:00
|
|
|
|
|
|
|
- provider: totp
|
2018-12-24 09:07:49 +00:00
|
|
|
attributes:
|
2018-12-28 23:38:56 +00:00
|
|
|
secret: MZXW6YTBOIFA # required
|
|
|
|
period: 30 # optional, defaults to 30 (Google Authenticator)
|
|
|
|
skew: 1 # optional, defaults to 1 (Google Authenticator)
|
|
|
|
digits: 8 # optional, defaults to 6 (Google Authenticator)
|
|
|
|
algorithm: sha1 # optional (sha1, sha256, sha512), defaults to sha1 (Google Authenticator)
|
|
|
|
|
2018-12-24 09:07:49 +00:00
|
|
|
- provider: yubikey
|
|
|
|
attributes:
|
|
|
|
device: ccccccfcvuul
|
|
|
|
|
2018-01-28 14:16:52 +00:00
|
|
|
# Authentication against embedded token directory
|
2018-02-04 10:34:04 +00:00
|
|
|
# Supports: Users, Groups
|
2018-01-28 14:16:52 +00:00
|
|
|
token:
|
|
|
|
# Mapping of unique token names to the token
|
|
|
|
tokens:
|
|
|
|
tokenname: "MYTOKEN"
|
|
|
|
|
2018-02-04 10:34:04 +00:00
|
|
|
# Groupname to token mapping
|
|
|
|
groups:
|
|
|
|
mytokengroup: ["tokenname"]
|
|
|
|
|
2018-01-28 14:16:52 +00:00
|
|
|
# Authentication against Yubikey cloud validation servers
|
|
|
|
# Supports: Users, Groups
|
|
|
|
yubikey:
|
|
|
|
# Get your client / secret from https://upgrade.yubico.com/getapikey/
|
|
|
|
client_id: "12345"
|
|
|
|
secret_key: "foobar"
|
|
|
|
|
|
|
|
# First 12 characters of the OTP string mapped to the username
|
|
|
|
devices:
|
|
|
|
ccccccfcvuul: "luzifer"
|
|
|
|
|
|
|
|
# Groupname to users mapping
|
|
|
|
groups:
|
|
|
|
admins: ["luzifer"]
|
|
|
|
|
|
|
|
...
|