providers/oauth2: fix verification_keys being required

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2022-03-31 20:19:13 +02:00
parent 4cf00ed5cf
commit 99008252f8
3 changed files with 28 additions and 2 deletions

View file

@ -0,0 +1,26 @@
# Generated by Django 4.0.3 on 2022-03-31 18:17
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("authentik_crypto", "0003_certificatekeypair_managed"),
("authentik_providers_oauth2", "0009_oauth2provider_verification_keys_and_more"),
]
operations = [
migrations.AlterField(
model_name="oauth2provider",
name="verification_keys",
field=models.ManyToManyField(
blank=True,
default=None,
help_text="JWTs created with the configured certificates can authenticate with this provider.",
related_name="+",
to="authentik_crypto.certificatekeypair",
verbose_name="Allowed certificates for JWT-based client_credentials",
),
),
]

View file

@ -227,6 +227,8 @@ class OAuth2Provider(Provider):
"JWTs created with the configured certificates can authenticate with this provider." "JWTs created with the configured certificates can authenticate with this provider."
), ),
related_name="+", related_name="+",
default=None,
blank=True,
) )
def create_refresh_token( def create_refresh_token(

View file

@ -23124,7 +23124,6 @@ components:
- pk - pk
- verbose_name - verbose_name
- verbose_name_plural - verbose_name_plural
- verification_keys
OAuth2ProviderRequest: OAuth2ProviderRequest:
type: object type: object
description: OAuth2Provider Serializer description: OAuth2Provider Serializer
@ -23198,7 +23197,6 @@ components:
required: required:
- authorization_flow - authorization_flow
- name - name
- verification_keys
OAuth2ProviderSetupURLs: OAuth2ProviderSetupURLs:
type: object type: object
description: OAuth2 Provider Metadata serializer description: OAuth2 Provider Metadata serializer