Describe the bug
When setting up a SAML service provider for user federation, the user is given a choice of nameIDFormat, which will be included in the service provider metadata in the \<md:NameIDFormat> element. Only the chosen format should be added to the metadata, but currently all format are appended. This will cause errors for some SAML IdPs and is not the correct way of handling this element.
How the metadata appears, when choosing the "persistent" nameID format:
Version and Deployment (please complete the following information):
authentik version: 2024.8.3
Deployment: docker compose
Aside from SAML experience, I'm also using the Danish goverments SAML Metadata validator This specific validator checks that metadata is compliant with the Danish OIO-SAML but this specific issue should be relevant for standard SAML2 as well.
Describe the bug When setting up a SAML service provider for user federation, the user is given a choice of nameIDFormat, which will be included in the service provider metadata in the \<md:NameIDFormat> element. Only the chosen format should be added to the metadata, but currently all format are appended. This will cause errors for some SAML IdPs and is not the correct way of handling this element.
How the metadata appears, when choosing the "persistent" nameID format:
How it should be:
To Reproduce Steps to reproduce the behavior:
Version and Deployment (please complete the following information):
Aside from SAML experience, I'm also using the Danish goverments SAML Metadata validator This specific validator checks that metadata is compliant with the Danish OIO-SAML but this specific issue should be relevant for standard SAML2 as well.