version: 1
metadata:
labels:
blueprints.goauthentik.io/system: "true"
name: System - SAML Provider - Mappings
entries:
- identifiers:
managed: goauthentik.io/providers/saml/upn
model: authentik_providers_saml.SAMLPropertyMapping
attrs:
name: "authentik default SAML Mapping: UPN"
saml_name: "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/upn"
expression: |
return request.user.attributes.get('upn', request.user.email)
managed: goauthentik.io/providers/saml/name
name: "authentik default SAML Mapping: Name"
saml_name: "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name"
return request.user.name
managed: goauthentik.io/providers/saml/email
name: "authentik default SAML Mapping: Email"
saml_name: "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress"
return request.user.email
managed: goauthentik.io/providers/saml/username
name: "authentik default SAML Mapping: Username"
saml_name: "http://schemas.goauthentik.io/2021/02/saml/username"
return request.user.username
managed: goauthentik.io/providers/saml/uid
name: "authentik default SAML Mapping: User ID"
saml_name: "http://schemas.goauthentik.io/2021/02/saml/uid"
return request.user.pk
managed: goauthentik.io/providers/saml/groups
name: "authentik default SAML Mapping: Groups"
saml_name: "http://schemas.xmlsoap.org/claims/Group"
for group in request.user.ak_groups.all():
yield group.name
managed: goauthentik.io/providers/saml/ms-windowsaccountname
name: "authentik default SAML Mapping: WindowsAccountname (Username)"
saml_name: "http://schemas.microsoft.com/ws/2008/06/identity/claims/windowsaccountname"