2022-04-01 11:38:49 +00:00
|
|
|
---
|
2023-05-07 06:39:17 +00:00
|
|
|
default_redirection_url: 'https://home.example.com:8080/'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
server:
|
2023-05-07 06:39:17 +00:00
|
|
|
address: 'tcp://127.0.0.1:9091'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
log:
|
2023-05-07 06:39:17 +00:00
|
|
|
level: 'debug'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
totp:
|
2023-05-07 06:39:17 +00:00
|
|
|
issuer: 'authelia.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
duo_api:
|
2023-05-07 06:39:17 +00:00
|
|
|
hostname: 'api-123456789.example.com'
|
|
|
|
integration_key: 'ABCDEF'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
authentication_backend:
|
|
|
|
ldap:
|
2023-05-07 06:39:17 +00:00
|
|
|
address: 'ldap://127.0.0.1'
|
|
|
|
base_dn: 'dc=example,dc=com'
|
|
|
|
additional_users_dn: 'ou=users'
|
|
|
|
users_filter: '(&({username_attribute}={input})(objectCategory=person)(objectClass=user))'
|
|
|
|
additional_groups_dn: 'ou=groups'
|
|
|
|
groups_filter: '(&(member={dn})(objectClass=groupOfNames))'
|
2023-05-07 13:52:10 +00:00
|
|
|
attributes:
|
|
|
|
group_name: 'cn'
|
|
|
|
mail: 'mail'
|
|
|
|
username: 'uid'
|
|
|
|
|
2023-05-07 06:39:17 +00:00
|
|
|
user: 'cn=admin,dc=example,dc=com'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
access_control:
|
2023-05-07 06:39:17 +00:00
|
|
|
default_policy: 'deny'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
rules:
|
|
|
|
# Rules applied to everyone
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain_regex: '^(public|public2).example.com$'
|
|
|
|
policy: 'bypass'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain_regex: '^portfolio-(?P<User>[a-zA-Z0-9]+).example.com$'
|
|
|
|
policy: 'one_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain_regex: '^portfolio-(?P<User>[a-zA-Z0-9]+)-(?P<Group>[a-zA-Z0-9]+).example.com$'
|
|
|
|
policy: 'one_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: 'secure.example.com'
|
|
|
|
policy: 'one_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
# Network based rule, if not provided any network matches.
|
|
|
|
networks:
|
2023-05-07 06:39:17 +00:00
|
|
|
- '192.168.1.0/24'
|
|
|
|
- domain: 'secure.example.com'
|
|
|
|
policy: 'two_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: ['singlefactor.example.com', 'onefactor.example.com']
|
|
|
|
policy: 'one_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
# Rules applied to 'admins' group
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: 'mx2.mail.example.com'
|
|
|
|
subject: 'group:admins'
|
|
|
|
policy: 'deny'
|
|
|
|
- domain: '*.example.com'
|
|
|
|
subject: 'group:admins'
|
|
|
|
policy: 'two_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
# Rules applied to 'dev' group
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: 'dev.example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
resources:
|
2023-05-07 06:39:17 +00:00
|
|
|
- '^/groups/dev/.*$'
|
|
|
|
subject: 'group:dev'
|
|
|
|
policy: 'two_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
# Rules applied to user 'john'
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: 'dev.example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
resources:
|
2023-05-07 06:39:17 +00:00
|
|
|
- '^/users/john/.*$'
|
|
|
|
subject: 'user:john'
|
|
|
|
policy: 'two_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
# Rules applied to 'dev' group and user 'john'
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: 'dev.example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
resources:
|
2023-05-07 06:39:17 +00:00
|
|
|
- '^/deny-all.*$'
|
|
|
|
subject: ['group:dev', 'user:john']
|
|
|
|
policy: 'deny'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
# Rules applied to user 'harry'
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: 'dev.example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
resources:
|
2023-05-07 06:39:17 +00:00
|
|
|
- '^/users/harry/.*$'
|
|
|
|
subject: 'user:harry'
|
|
|
|
policy: 'two_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
# Rules applied to user 'bob'
|
2023-05-07 06:39:17 +00:00
|
|
|
- domain: '*.mail.example.com'
|
|
|
|
subject: 'user:bob'
|
|
|
|
policy: 'two_factor'
|
|
|
|
- domain: 'dev.example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
resources:
|
2023-05-07 06:39:17 +00:00
|
|
|
- '^/users/bob/.*$'
|
|
|
|
subject: 'user:bob'
|
|
|
|
policy: 'two_factor'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
session:
|
2023-05-07 06:39:17 +00:00
|
|
|
name: 'authelia_session'
|
|
|
|
expiration: '1h' # 1 hour
|
|
|
|
inactivity: '5m' # 5 minutes
|
|
|
|
domain: 'example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
redis:
|
2023-05-07 06:39:17 +00:00
|
|
|
host: '127.0.0.1'
|
2022-04-01 11:38:49 +00:00
|
|
|
port: 6379
|
|
|
|
high_availability:
|
2023-05-07 06:39:17 +00:00
|
|
|
sentinel_name: 'test'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
regulation:
|
|
|
|
max_retries: 3
|
2023-05-07 06:39:17 +00:00
|
|
|
find_time: '2m'
|
|
|
|
ban_time: '5m'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
storage:
|
|
|
|
mysql:
|
2023-05-07 06:39:17 +00:00
|
|
|
address: 'tcp://127.0.0.1:3306'
|
|
|
|
database: 'authelia'
|
|
|
|
username: 'authelia'
|
2022-04-01 11:38:49 +00:00
|
|
|
|
|
|
|
notifier:
|
|
|
|
smtp:
|
2023-05-07 06:39:17 +00:00
|
|
|
address: 'smtp://127.0.0.1:1025'
|
|
|
|
username: 'test'
|
|
|
|
sender: 'admin@example.com'
|
2022-04-01 11:38:49 +00:00
|
|
|
disable_require_tls: true
|
|
|
|
...
|