zitadel/internal/repository
Livio Spring e57a9b57c8
feat(saml): allow setting nameid-format and alternative mapping for transient format (#7979)
# Which Problems Are Solved

ZITADEL currently always uses
`urn:oasis:names:tc:SAML:2.0:nameid-format:persistent` in SAML requests,
relying on the IdP to respect that flag and always return a peristent
nameid in order to be able to map the external user with an existing
user (idp link) in ZITADEL.
In case the IdP however returns a
`urn:oasis:names:tc:SAML:2.0:nameid-format:transient` (transient)
nameid, the attribute will differ between each request and it will not
be possible to match existing users.

# How the Problems Are Solved

This PR adds the following two options on SAML IdP:
- **nameIDFormat**: allows to set the nameid-format used in the SAML
Request
- **transientMappingAttributeName**: allows to set an attribute name,
which will be used instead of the nameid itself in case the returned
nameid-format is transient

# Additional Changes

To reduce impact on current installations, the `idp_templates6_saml`
table is altered with the two added columns by a setup job. New
installations will automatically get the table with the two columns
directly.
All idp unit tests are updated to use `expectEventstore` instead of the
deprecated `eventstoreExpect`.

# Additional Context

Closes #7483
Closes #7743

---------

Co-authored-by: peintnermax <max@caos.ch>
Co-authored-by: Stefan Benz <46600784+stebenz@users.noreply.github.com>
2024-05-23 05:04:07 +00:00
..
action fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
asset refactor: rename package errors to zerrors (#7039) 2023-12-08 15:30:55 +01:00
authrequest perf(oidc): optimize token creation (#7822) 2024-05-16 07:07:56 +02:00
deviceauth perf(oidc): optimize token creation (#7822) 2024-05-16 07:07:56 +02:00
execution feat: add action v2 execution on requests and responses (#7637) 2024-05-04 11:55:57 +02:00
feature fix: add action v2 execution to features (#7597) 2024-04-09 20:21:21 +03:00
flow refactor: rename package errors to zerrors (#7039) 2023-12-08 15:30:55 +01:00
idp feat(saml): allow setting nameid-format and alternative mapping for transient format (#7979) 2024-05-23 05:04:07 +00:00
idpconfig refactor: rename package errors to zerrors (#7039) 2023-12-08 15:30:55 +01:00
idpintent fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
instance feat(saml): allow setting nameid-format and alternative mapping for transient format (#7979) 2024-05-23 05:04:07 +00:00
keypair fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
limits fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
member refactor: rename package errors to zerrors (#7039) 2023-12-08 15:30:55 +01:00
metadata refactor: rename package errors to zerrors (#7039) 2023-12-08 15:30:55 +01:00
milestone fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
oidcsession perf(oidc): optimize token creation (#7822) 2024-05-16 07:07:56 +02:00
org feat(saml): allow setting nameid-format and alternative mapping for transient format (#7979) 2024-05-23 05:04:07 +00:00
policy feat(cnsl): docs link can be customized and custom button is available (#7840) 2024-05-13 16:01:50 +02:00
project feat(crypto): use passwap for machine and app secrets (#7657) 2024-04-05 09:35:49 +00:00
pseudo feat: push telemetry (#6027) 2023-07-06 08:38:13 +02:00
quota fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
restrictions fix(setup): init projections (#7194) 2024-01-25 17:28:20 +01:00
session perf(oidc): optimize token creation (#7822) 2024-05-16 07:07:56 +02:00
settings refactor: rename package errors to zerrors (#7039) 2023-12-08 15:30:55 +01:00
target feat: add action v2 execution on requests and responses (#7637) 2024-05-04 11:55:57 +02:00
user perf(oidc): optimize token creation (#7822) 2024-05-16 07:07:56 +02:00
usergrant refactor(fmt): run gci on complete project (#7557) 2024-04-03 10:43:43 +00:00