fix inheritance
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
parent
bcc92d2c0b
commit
0a189ceeb5
|
@ -8,7 +8,6 @@ from django.http import HttpRequest
|
||||||
from django.utils.translation import gettext as __
|
from django.utils.translation import gettext as __
|
||||||
from django.utils.translation import gettext_lazy as _
|
from django.utils.translation import gettext_lazy as _
|
||||||
from django.views import View
|
from django.views import View
|
||||||
from django_otp.models import Device
|
|
||||||
from firebase_admin import credentials, initialize_app
|
from firebase_admin import credentials, initialize_app
|
||||||
from firebase_admin.exceptions import FirebaseError
|
from firebase_admin.exceptions import FirebaseError
|
||||||
from firebase_admin.messaging import (
|
from firebase_admin.messaging import (
|
||||||
|
@ -29,6 +28,7 @@ from authentik.core.types import UserSettingSerializer
|
||||||
from authentik.flows.models import ConfigurableStage, FriendlyNamedStage, Stage
|
from authentik.flows.models import ConfigurableStage, FriendlyNamedStage, Stage
|
||||||
from authentik.lib.generators import generate_id
|
from authentik.lib.generators import generate_id
|
||||||
from authentik.lib.models import SerializerModel
|
from authentik.lib.models import SerializerModel
|
||||||
|
from authentik.stages.authenticator.models import Device
|
||||||
from authentik.tenants.utils import DEFAULT_TENANT
|
from authentik.tenants.utils import DEFAULT_TENANT
|
||||||
|
|
||||||
cred = credentials.Certificate("firebase.json")
|
cred = credentials.Certificate("firebase.json")
|
||||||
|
|
|
@ -1,7 +1,10 @@
|
||||||
# Generated by Django 4.1.3 on 2022-11-21 16:45
|
# Generated by Django 4.1.3 on 2022-11-21 16:45
|
||||||
|
|
||||||
|
import django.contrib.postgres.fields
|
||||||
from django.db import migrations, models
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
import authentik.stages.authenticator_validate.models
|
||||||
|
|
||||||
|
|
||||||
class Migration(migrations.Migration):
|
class Migration(migrations.Migration):
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
@ -25,4 +28,23 @@ class Migration(migrations.Migration):
|
||||||
help_text="Enforce user verification for WebAuthn devices.",
|
help_text="Enforce user verification for WebAuthn devices.",
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name="authenticatorvalidatestage",
|
||||||
|
name="device_classes",
|
||||||
|
field=django.contrib.postgres.fields.ArrayField(
|
||||||
|
base_field=models.TextField(
|
||||||
|
choices=[
|
||||||
|
("static", "Static"),
|
||||||
|
("totp", "TOTP"),
|
||||||
|
("webauthn", "WebAuthn"),
|
||||||
|
("duo", "Duo"),
|
||||||
|
("sms", "SMS"),
|
||||||
|
("mobile", "authentik Mobile"),
|
||||||
|
]
|
||||||
|
),
|
||||||
|
default=authentik.stages.authenticator_validate.models.default_device_classes,
|
||||||
|
help_text="Device classes which can be used to authenticate",
|
||||||
|
size=None,
|
||||||
|
),
|
||||||
|
),
|
||||||
]
|
]
|
||||||
|
|
Reference in New Issue