providers/saml: include SSO Binding URLs in Provider API

closes #3179

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2022-06-30 22:18:21 +02:00
parent f6042f29f6
commit ea60c389be
16 changed files with 471 additions and 91 deletions

View File

@ -71,9 +71,9 @@ gen-client-web:
-o /local/gen-ts-api \
--additional-properties=typescriptThreePlus=true,supportsES6=true,npmName=@goauthentik/api,npmVersion=${NPM_VERSION}
mkdir -p web/node_modules/@goauthentik/api
ln -fs scripts/web_api_readme.md gen-ts-api/README.md
\cp -fv scripts/web_api_readme.md gen-ts-api/README.md
cd gen-ts-api && npm i
ln -fs gen-ts-api web/node_modules/@goauthentik/api
\cp -rfv gen-ts-api/* web/node_modules/@goauthentik/api
gen-client-go:
wget https://raw.githubusercontent.com/goauthentik/client-go/main/config.yaml -O config.yaml

View File

@ -2,6 +2,7 @@
from xml.etree.ElementTree import ParseError # nosec
from defusedxml.ElementTree import fromstring
from django.http import HttpRequest
from django.http.response import Http404, HttpResponse
from django.shortcuts import get_object_or_404
from django.urls import reverse
@ -44,14 +45,58 @@ LOGGER = get_logger()
class SAMLProviderSerializer(ProviderSerializer):
"""SAMLProvider Serializer"""
metadata_download_url = SerializerMethodField()
url_download_metadata = SerializerMethodField()
def get_metadata_download_url(self, instance: SAMLProvider) -> str:
url_sso_post = SerializerMethodField()
url_sso_redirect = SerializerMethodField()
url_sso_init = SerializerMethodField()
def get_url_download_metadata(self, instance: SAMLProvider) -> str:
"""Get metadata download URL"""
return (
request: HttpRequest = self._context["request"]._request
return request.build_absolute_uri(
reverse("authentik_api:samlprovider-metadata", kwargs={"pk": instance.pk}) + "?download"
)
def get_url_sso_post(self, instance: SAMLProvider) -> str:
"""Get SSO Post URL"""
request: HttpRequest = self._context["request"]._request
try:
return request.build_absolute_uri(
reverse(
"authentik_providers_saml:sso-post",
kwargs={"application_slug": instance.application.slug},
)
)
except Provider.application.RelatedObjectDoesNotExist: # pylint: disable=no-member
return "-"
def get_url_sso_redirect(self, instance: SAMLProvider) -> str:
"""Get SSO Redirect URL"""
request: HttpRequest = self._context["request"]._request
try:
return request.build_absolute_uri(
reverse(
"authentik_providers_saml:sso-redirect",
kwargs={"application_slug": instance.application.slug},
)
)
except Provider.application.RelatedObjectDoesNotExist: # pylint: disable=no-member
return "-"
def get_url_sso_init(self, instance: SAMLProvider) -> str:
"""Get SSO IDP-Initiated URL"""
request: HttpRequest = self._context["request"]._request
try:
return request.build_absolute_uri(
reverse(
"authentik_providers_saml:sso-init",
kwargs={"application_slug": instance.application.slug},
)
)
except Provider.application.RelatedObjectDoesNotExist: # pylint: disable=no-member
return "-"
class Meta:
model = SAMLProvider
@ -69,7 +114,10 @@ class SAMLProviderSerializer(ProviderSerializer):
"signing_kp",
"verification_kp",
"sp_binding",
"metadata_download_url",
"url_download_metadata",
"url_sso_post",
"url_sso_redirect",
"url_sso_init",
]

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-06-26 11:48+0000\n"
"POT-Creation-Date: 2022-06-30 20:17+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -895,11 +895,11 @@ msgstr ""
msgid "Proxy Providers"
msgstr ""
#: authentik/providers/saml/api.py:177
#: authentik/providers/saml/api.py:225
msgid "Invalid XML Syntax"
msgstr ""
#: authentik/providers/saml/api.py:187
#: authentik/providers/saml/api.py:235
#, python-format
msgid "Failed to import Metadata: %(message)s"
msgstr ""

View File

@ -29957,7 +29957,16 @@ components:
title: Service Provider Binding
description: This determines how authentik sends the response back to the
Service Provider.
metadata_download_url:
url_download_metadata:
type: string
readOnly: true
url_sso_post:
type: string
readOnly: true
url_sso_redirect:
type: string
readOnly: true
url_sso_init:
type: string
readOnly: true
required:
@ -29967,9 +29976,12 @@ components:
- authorization_flow
- component
- meta_model_name
- metadata_download_url
- name
- pk
- url_download_metadata
- url_sso_init
- url_sso_post
- url_sso_redirect
- verbose_name
- verbose_name_plural
SAMLProviderImportRequest:

View File

@ -369,6 +369,10 @@ msgstr "Erlaubt/verweigert Anfragen auf der Grundlage der Reputation der Nutzer
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "Auch bekannt als Entity ID. Standardmäßig wird die Metadaten-URL verwendet."
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "Alternativ kannst Du auch auf diesen Link klicken, wenn Du Duo auf Deinem Gerät installiert hast: "
@ -399,7 +403,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "App-Passwort (kann für die Anmeldung mit einem Ablauf genutzt werden)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1750,6 +1753,7 @@ msgstr "Domain"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "Download"
@ -1762,6 +1766,7 @@ msgstr "Zertifikat herunterladen"
msgid "Download Private key"
msgstr "Privaten Schlüssel herunterladen"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "Signierzertifikat herunterladen"
@ -1943,6 +1948,10 @@ msgstr "Anmeldung"
msgid "Enrollment flow"
msgstr "Registrierungsablauf"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "Fehler"
@ -4384,6 +4393,7 @@ msgstr "Regelmäßiger Benutzer"
msgid "Related"
msgstr "Verwandt"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "Verwandte Objekte"
@ -4517,6 +4527,10 @@ msgstr ""
msgid "SAML Attribute Name"
msgstr "SAML-Attributsname"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "SAML-Metadaten"
@ -4587,6 +4601,18 @@ msgstr "SMTP Benutzername"
msgid "SSO URL"
msgstr "SSO URL"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "Für alle Anbieter wird dieselbe Kennung verwendet"

View File

@ -359,6 +359,10 @@ msgstr "Allows/denys requests based on the users and/or the IPs reputation."
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "Also known as Entity ID. Defaults the Metadata URL."
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr "Also known as EntityID."
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "Alternatively, if your current device has Duo installed, click on this link:"
@ -389,7 +393,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "App password (can be used to login using a flow executor)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1775,6 +1778,7 @@ msgstr "Domain"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "Download"
@ -1787,6 +1791,7 @@ msgstr "Download Certificate"
msgid "Download Private key"
msgstr "Download Private key"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "Download signing certificate"
@ -1975,6 +1980,10 @@ msgstr "Enrollment"
msgid "Enrollment flow"
msgstr "Enrollment flow"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr "EntityID/Issuer"
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "Error"
@ -4458,6 +4467,7 @@ msgstr "Regular user"
msgid "Related"
msgstr "Related"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "Related objects"
@ -4597,6 +4607,10 @@ msgstr "SAML"
msgid "SAML Attribute Name"
msgstr "SAML Attribute Name"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr "SAML Configuration"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "SAML Metadata"
@ -4667,6 +4681,18 @@ msgstr "SMTP Username"
msgid "SSO URL"
msgstr "SSO URL"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr "SSO URL (IdP-initiated Login)"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr "SSO URL (Post)"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr "SSO URL (Redirect)"
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "Same identifier is used for all providers"

View File

@ -356,6 +356,10 @@ msgstr "Permitir/denegar solicitudes en función de los usuarios y/o la reputaci
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "También se conoce como ID de entidad. Default la URL de metadatos."
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "Como alternativa, si su dispositivo actual tiene instalado Duo, haga clic en este enlace:"
@ -386,7 +390,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "Contraseña de la aplicación (se puede usar para iniciar sesión con un ejecutor de flujo)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1741,6 +1744,7 @@ msgstr "Dominio"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "Descargar"
@ -1753,6 +1757,7 @@ msgstr "Descargar certificado"
msgid "Download Private key"
msgstr "Descargar clave privada"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "Descargar certificado de firma"
@ -1934,6 +1939,10 @@ msgstr "Inscripción"
msgid "Enrollment flow"
msgstr "Flujo de inscripción"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "Error"
@ -4377,6 +4386,7 @@ msgstr "Usuario habitual"
msgid "Related"
msgstr "Relacionado"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "Objetos relacionados"
@ -4510,6 +4520,10 @@ msgstr ""
msgid "SAML Attribute Name"
msgstr "Nombre de atributo SAML"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "Metadatos SAML"
@ -4580,6 +4594,18 @@ msgstr "Nombre de usuario SMTP"
msgid "SSO URL"
msgstr "URL SSO"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "Se usa el mismo identificador para todos los proveedores"

View File

@ -360,6 +360,10 @@ msgstr "Autorise/bloque les requêtes selon la réputation de l'utilisateur et/o
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "Aussi appelé Entity ID. URL de métadonnée par défaut."
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "Sinon, si Duo est installé sur cet appareil, cliquez sur ce lien :"
@ -390,7 +394,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "Mot de passe de l'App (peut être utilisé pour ouvrir une session en utilisant un flux d'exécution)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1758,6 +1761,7 @@ msgstr "Domaine"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "Télécharger"
@ -1770,6 +1774,7 @@ msgstr "Télécharger le certificat"
msgid "Download Private key"
msgstr "Télécharger la clé privée"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr ""
@ -1956,6 +1961,10 @@ msgstr "Inscription"
msgid "Enrollment flow"
msgstr "Flux d'inscription"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "Erreur"
@ -4420,6 +4429,7 @@ msgstr "Utilisateur normal"
msgid "Related"
msgstr "Lié"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr ""
@ -4558,6 +4568,10 @@ msgstr ""
msgid "SAML Attribute Name"
msgstr "Nom d'attribut SAML"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr ""
@ -4628,6 +4642,18 @@ msgstr "Utilisateur SMTP"
msgid "SSO URL"
msgstr "URL SSO"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "Le même identifiant est utilisé pour tous les fournisseurs"

View File

@ -356,6 +356,10 @@ msgstr "Zezwala/odrzuca żądania na podstawie reputacji użytkowników i/lub ad
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "Znany również jako Entity ID. Domyślny adres URL metadanych."
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "Alternatywnie, jeśli na Twoim obecnym urządzeniu jest zainstalowany Duo, kliknij ten link:"
@ -386,7 +390,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "Hasło aplikacji (może być użyte do zalogowania się za pomocą executora przepływu)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1738,6 +1741,7 @@ msgstr "Domena"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "Pobierz"
@ -1750,6 +1754,7 @@ msgstr "Pobierz certyfikat"
msgid "Download Private key"
msgstr "Pobierz klucz prywatny"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "Pobierz certyfikat podpisywania"
@ -1931,6 +1936,10 @@ msgstr "Rejestracja"
msgid "Enrollment flow"
msgstr "Przepływ rejestracji"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "Błąd"
@ -4374,6 +4383,7 @@ msgstr "Zwykły użytkownik"
msgid "Related"
msgstr "Związane z"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "Powiązane obiekty"
@ -4507,6 +4517,10 @@ msgstr ""
msgid "SAML Attribute Name"
msgstr "Nazwa atrybutu SAML"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "Metadane SAML"
@ -4577,6 +4591,18 @@ msgstr "Nazwa użytkownika SMTP"
msgid "SSO URL"
msgstr "SSO URL"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "Ten sam identyfikator jest używany dla wszystkich dostawców"

View File

@ -355,6 +355,10 @@ msgstr ""
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr ""
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr ""
@ -385,7 +389,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr ""
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1761,6 +1764,7 @@ msgstr ""
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr ""
@ -1773,6 +1777,7 @@ msgstr ""
msgid "Download Private key"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr ""
@ -1961,6 +1966,10 @@ msgstr ""
msgid "Enrollment flow"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr ""
@ -4438,6 +4447,7 @@ msgstr ""
msgid "Related"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr ""
@ -4577,6 +4587,10 @@ msgstr ""
msgid "SAML Attribute Name"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr ""
@ -4647,6 +4661,18 @@ msgstr ""
msgid "SSO URL"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr ""

View File

@ -356,6 +356,10 @@ msgstr "Kullanıcıların ve/veya IP'lerin itibarına göre isteklere izin ver/r
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "Entity ID olarak da bilinir. Metadata URL'sine varsayılan olarak ayarlanır."
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "Alternatif olarak, mevcut cihazınızda Duo yüklüyse, şu bağlantıya tıklayın:"
@ -386,7 +390,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "Uygulama parolası (bir akış yürütücüyle giriş yapmak için kullanılabilir)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1741,6 +1744,7 @@ msgstr "Alan Adı"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "Indir"
@ -1753,6 +1757,7 @@ msgstr "Sertifikayı İndirin"
msgid "Download Private key"
msgstr "Indir Özel anahtar"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "İmzalama sertifikasını indirme"
@ -1934,6 +1939,10 @@ msgstr "Kayıt"
msgid "Enrollment flow"
msgstr "Kayıt akışı"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "Hata"
@ -4379,6 +4388,7 @@ msgstr "Düzenli kullanıcı"
msgid "Related"
msgstr "İlgili"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "İlgili nesneler"
@ -4512,6 +4522,10 @@ msgstr ""
msgid "SAML Attribute Name"
msgstr "SAML Öznitelik Adı"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "SAML Meta Verileri"
@ -4582,6 +4596,18 @@ msgstr "SMTP Kullanıcı Adı"
msgid "SSO URL"
msgstr "SSO URL"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "Aynı tanımlayıcı tüm sağlayıcılar için kullanılır"

View File

@ -356,6 +356,10 @@ msgstr "根据用户和/或 IP 信誉允许/拒绝请求。"
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "也称为 Entity ID。 默认为元数据 URL。"
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "或者,如果您当前的设备已安装 Duo请点击此链接"
@ -386,7 +390,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "应用密码(可用于使用流程执行器登录)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1735,6 +1738,7 @@ msgstr "域名"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "下载"
@ -1747,6 +1751,7 @@ msgstr "下载证书"
msgid "Download Private key"
msgstr "下载私钥"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "下载签名证书"
@ -1927,6 +1932,10 @@ msgstr "注册"
msgid "Enrollment flow"
msgstr "注册流程"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "错误"
@ -4349,6 +4358,7 @@ msgstr "普通用户"
msgid "Related"
msgstr "相关"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "相关对象"
@ -4479,6 +4489,10 @@ msgstr "SAML"
msgid "SAML Attribute Name"
msgstr "SAML 属性名称"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "SAML 元数据"
@ -4548,6 +4562,18 @@ msgstr "SMTP 用户名"
msgid "SSO URL"
msgstr "SSO URL"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "所有提供程序都使用相同的标识符"

View File

@ -357,6 +357,10 @@ msgstr "根据用户和/或 IP 信誉允许/拒绝请求。"
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "也称为实体 ID。 默认为 Metadata URL。"
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "或者,如果您当前的设备已安装 Duo请单击此链接"
@ -387,7 +391,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "应用程序密码(可用于使用流程执行器登录)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1738,6 +1741,7 @@ msgstr "域"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "下載"
@ -1750,6 +1754,7 @@ msgstr "下载证书"
msgid "Download Private key"
msgstr "下载私钥"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "下载签名证书"
@ -1930,6 +1935,10 @@ msgstr "注册"
msgid "Enrollment flow"
msgstr "注册流程"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "错误"
@ -4355,6 +4364,7 @@ msgstr "普通用户"
msgid "Related"
msgstr "相关"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "相关对象"
@ -4485,6 +4495,10 @@ msgstr "SAML"
msgid "SAML Attribute Name"
msgstr "SAML 属性名称"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "SAML 元数据"
@ -4554,6 +4568,18 @@ msgstr "SMTP 用户名"
msgid "SSO URL"
msgstr "SSO 网址"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "所有提供商都使用相同的标识符"

View File

@ -357,6 +357,10 @@ msgstr "根据用户和/或 IP 信誉允许/拒绝请求。"
msgid "Also known as Entity ID. Defaults the Metadata URL."
msgstr "也称为实体 ID。 默认为 Metadata URL。"
#: src/pages/providers/saml/SAMLProviderForm.ts
msgid "Also known as EntityID."
msgstr ""
#: src/flows/stages/authenticator_duo/AuthenticatorDuoStage.ts
msgid "Alternatively, if your current device has Duo installed, click on this link:"
msgstr "或者,如果您当前的设备已安装 Duo请单击此链接"
@ -387,7 +391,6 @@ msgid "App password (can be used to login using a flow executor)"
msgstr "应用程序密码(可用于使用流程执行器登录)"
#: src/elements/user/UserConsentList.ts
#: src/flows/stages/consent/ConsentStage.ts
#: src/pages/admin-overview/TopApplicationsTable.ts
#: src/pages/providers/ProviderListPage.ts
msgid "Application"
@ -1738,6 +1741,7 @@ msgstr "域"
#: src/pages/crypto/CertificateKeyPairListPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/sources/saml/SAMLSourceViewPage.ts
msgid "Download"
msgstr "下載"
@ -1750,6 +1754,7 @@ msgstr "下载证书"
msgid "Download Private key"
msgstr "下载私钥"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Download signing certificate"
msgstr "下载签名证书"
@ -1930,6 +1935,10 @@ msgstr "注册"
msgid "Enrollment flow"
msgstr "注册流程"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "EntityID/Issuer"
msgstr ""
#: src/pages/system-tasks/SystemTaskListPage.ts
msgid "Error"
msgstr "错误"
@ -4355,6 +4364,7 @@ msgstr "普通用户"
msgid "Related"
msgstr "相关"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "Related objects"
msgstr "相关对象"
@ -4485,6 +4495,10 @@ msgstr "SAML"
msgid "SAML Attribute Name"
msgstr "SAML 属性名称"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Configuration"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SAML Metadata"
msgstr "SAML 元数据"
@ -4554,6 +4568,18 @@ msgstr "SMTP 用户名"
msgid "SSO URL"
msgstr "SSO 网址"
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (IdP-initiated Login)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Post)"
msgstr ""
#: src/pages/providers/saml/SAMLProviderViewPage.ts
msgid "SSO URL (Redirect)"
msgstr ""
#: src/pages/providers/oauth2/OAuth2ProviderForm.ts
msgid "Same identifier is used for all providers"
msgstr "所有提供商都使用相同的标识符"

View File

@ -110,6 +110,7 @@ export class SAMLProviderFormPage extends ModelForm<SAMLProvider, number> {
class="pf-c-form-control"
required
/>
<p class="pf-c-form__helper-text">${t`Also known as EntityID.`}</p>
</ak-form-element-horizontal>
<ak-form-element-horizontal
label=${t`Service Provider Binding`}

View File

@ -22,6 +22,8 @@ import PFButton from "@patternfly/patternfly/components/Button/button.css";
import PFCard from "@patternfly/patternfly/components/Card/card.css";
import PFContent from "@patternfly/patternfly/components/Content/content.css";
import PFDescriptionList from "@patternfly/patternfly/components/DescriptionList/description-list.css";
import PFForm from "@patternfly/patternfly/components/Form/form.css";
import PFFormControl from "@patternfly/patternfly/components/FormControl/form-control.css";
import PFPage from "@patternfly/patternfly/components/Page/page.css";
import PFGrid from "@patternfly/patternfly/layouts/Grid/grid.css";
import PFBase from "@patternfly/patternfly/patternfly-base.css";
@ -50,13 +52,15 @@ export class SAMLProviderViewPage extends LitElement {
static get styles(): CSSResult[] {
return [
PFBase,
PFPage,
PFButton,
PFBanner,
PFPage,
PFGrid,
PFContent,
PFCard,
PFDescriptionList,
PFGrid,
PFForm,
PFFormControl,
PFBanner,
AKGlobal,
];
}
@ -69,30 +73,36 @@ export class SAMLProviderViewPage extends LitElement {
});
}
renderSigningCert(): Promise<TemplateResult> {
async renderRelatedObjects(): Promise<TemplateResult> {
if (!this.provider?.signingKp) {
return Promise.resolve(html``);
}
return new CryptoApi(DEFAULT_CONFIG)
.cryptoCertificatekeypairsRetrieve({
kpUuid: this.provider.signingKp,
})
.then((kp) => {
return html` <div class="pf-c-description-list__group">
<dt class="pf-c-description-list__term">
<span class="pf-c-description-list__text"
>${t`Download signing certificate`}</span
>
</dt>
<dd class="pf-c-description-list__description">
<div class="pf-c-description-list__text">
<a class="pf-c-button pf-m-primary" href=${kp.certificateDownloadUrl}
>${t`Download`}</a
const kp = await new CryptoApi(DEFAULT_CONFIG).cryptoCertificatekeypairsRetrieve({
kpUuid: this.provider.signingKp,
});
return html` <div class="pf-c-card pf-l-grid__item pf-m-12-col">
<div class="pf-c-card__title">${t`Related objects`}</div>
<div class="pf-c-card__body">
<dl class="pf-c-description-list pf-m-2-col">
<div class="pf-c-description-list__group">
<dt class="pf-c-description-list__term">
<span class="pf-c-description-list__text"
>${t`Download signing certificate`}</span
>
</div>
</dd>
</div>`;
});
</dt>
<dd class="pf-c-description-list__description">
<div class="pf-c-description-list__text">
<a
class="pf-c-button pf-m-primary"
href=${kp.certificateDownloadUrl}
>${t`Download`}</a
>
</div>
</dd>
</div>
</dl>
</div>
</div>`;
}
render(): TemplateResult {
@ -178,56 +188,105 @@ export class SAMLProviderViewPage extends LitElement {
</ak-forms-modal>
</div>
</div>
<div class="pf-c-card pf-l-grid__item pf-m-12-col">
<div class="pf-c-card__title">
${t`Related objects`}
</div>
<div class="pf-c-card__body">
<dl class="pf-c-description-list pf-m-2-col">
${until(this.renderSigningCert())}
</dl>
</div>
</div>
${until(this.renderRelatedObjects())}
${
this.provider.assignedApplicationName
? html`<div class="pf-c-card pf-l-grid__item pf-m-12-col">
<div class="pf-c-card__title">${t`SAML Metadata`}</div>
<div class="pf-c-card__body">
${until(
new ProvidersApi(DEFAULT_CONFIG)
.providersSamlMetadataRetrieve({
id: this.provider.pk || 0,
})
.then((m) => {
return html`<ak-codemirror
mode="xml"
?readOnly=${true}
value="${ifDefined(m.metadata)}"
></ak-codemirror>`;
}),
)}
? html` <div class="pf-c-card pf-l-grid__item pf-m-12-col">
<div class="pf-c-card__title">${t`SAML Configuration`}</div>
<div class="pf-c-card__body">
<form class="pf-c-form">
<div class="pf-c-form__group">
<label class="pf-c-form__label">
<span class="pf-c-form__label-text"
>${t`EntityID/Issuer`}</span
>
</label>
<input
class="pf-c-form-control"
readonly
type="text"
value="${ifDefined(this.provider?.issuer)}"
/>
</div>
<div class="pf-c-form__group">
<label class="pf-c-form__label">
<span class="pf-c-form__label-text"
>${t`SSO URL (Post)`}</span
>
</label>
<input
class="pf-c-form-control"
readonly
type="text"
value="${ifDefined(this.provider.urlSsoPost)}"
/>
</div>
<div class="pf-c-form__group">
<label class="pf-c-form__label">
<span class="pf-c-form__label-text"
>${t`SSO URL (Redirect)`}</span
>
</label>
<input
class="pf-c-form-control"
readonly
type="text"
value="${ifDefined(this.provider.urlSsoRedirect)}"
/>
</div>
<div class="pf-c-form__group">
<label class="pf-c-form__label">
<span class="pf-c-form__label-text"
>${t`SSO URL (IdP-initiated Login)`}</span
>
</label>
<input
class="pf-c-form-control"
readonly
type="text"
value="${ifDefined(this.provider.urlSsoInit)}"
/>
</div>
</form>
</div>
</div>
<div class="pf-c-card__footer">
<a
class="pf-c-button pf-m-primary"
target="_blank"
href=${this.provider.metadataDownloadUrl}
>
${t`Download`}
</a>
<ak-action-button
class="pf-m-secondary"
.apiRequest=${() => {
const fullUrl =
window.location.origin +
this.provider?.metadataDownloadUrl;
return navigator.clipboard.writeText(fullUrl);
}}
>
${t`Copy download URL`}
</ak-action-button>
</div>
</div>`
<div class="pf-c-card pf-l-grid__item pf-m-12-col">
<div class="pf-c-card__title">${t`SAML Metadata`}</div>
<div class="pf-c-card__body">
${until(
new ProvidersApi(DEFAULT_CONFIG)
.providersSamlMetadataRetrieve({
id: this.provider.pk || 0,
})
.then((m) => {
return html`<ak-codemirror
mode="xml"
?readOnly=${true}
value="${ifDefined(m.metadata)}"
></ak-codemirror>`;
}),
)}
</div>
<div class="pf-c-card__footer">
<a
class="pf-c-button pf-m-primary"
target="_blank"
href=${this.provider.urlDownloadMetadata}
>
${t`Download`}
</a>
<ak-action-button
class="pf-m-secondary"
.apiRequest=${() => {
return navigator.clipboard.writeText(
this.provider?.urlDownloadMetadata || "",
);
}}
>
${t`Copy download URL`}
</ak-action-button>
</div>
</div>`
: html``
}
</div>