blueprints: add required password stage backends
Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
parent
070714abe4
commit
0ab8f4eed7
|
@ -183,8 +183,6 @@ class Format(YAMLTag):
|
|||
|
||||
def resolve(self, entry: BlueprintEntry, blueprint: Blueprint) -> Any:
|
||||
try:
|
||||
print(self.format_string)
|
||||
print(self.args)
|
||||
return self.format_string % tuple(self.args)
|
||||
except TypeError as exc:
|
||||
raise EntryInvalidError(exc)
|
||||
|
|
|
@ -15,7 +15,8 @@ def update_default_backends(apps: Apps, schema_editor: BaseDatabaseSchemaEditor)
|
|||
if not stages.exists():
|
||||
return
|
||||
stage = stages.first()
|
||||
stage.backends.append(BACKEND_APP_PASSWORD)
|
||||
if BACKEND_APP_PASSWORD not in stage.backends:
|
||||
stage.backends.append(BACKEND_APP_PASSWORD)
|
||||
stage.save()
|
||||
|
||||
|
||||
|
|
|
@ -11,6 +11,10 @@ entries:
|
|||
model: authentik_flows.flow
|
||||
id: flow
|
||||
- attrs:
|
||||
backends:
|
||||
- authentik.core.auth.InbuiltBackend
|
||||
- authentik.sources.ldap.auth.LDAPBackend
|
||||
- authentik.core.auth.TokenBackend
|
||||
configure_flow: !Find [authentik_flows.flow, [slug, default-password-change]]
|
||||
identifiers:
|
||||
name: default-authentication-password
|
||||
|
@ -20,7 +24,11 @@ entries:
|
|||
name: default-authentication-mfa-validation
|
||||
id: default-authentication-mfa-validation
|
||||
model: authentik_stages_authenticator_validate.authenticatorvalidatestage
|
||||
- identifiers:
|
||||
- attrs:
|
||||
user_fields:
|
||||
- email
|
||||
- username
|
||||
identifiers:
|
||||
name: default-authentication-identification
|
||||
id: default-authentication-identification
|
||||
model: authentik_stages_identification.identificationstage
|
||||
|
|
Reference in New Issue