Use specific attribute for nameID in SAML2 and another one as fallback

73 views
Skip to first unread message

Thiago Castro

unread,
Dec 11, 2025, 2:11:15 PMDec 11
to CAS Community
Hello everyone,

Currently, we can define a specific attribute for nameID in service definition. If that attribute is not present, it uses the default resolved in authentication according with documentation. Is there a way that I can set an attribute as fallback? I want to set "CPF" as the attribute for nameID (which can be done via service definition) and another one called "DRE" as the fallback. And the user authenticates in CAS using email.


Best regards,
Thiago

Ray Bon

unread,
Dec 11, 2025, 3:59:36 PMDec 11
to cas-...@apereo.org
Thiago,

You can use groovy scripting for either Attribute Definition or Attribute Resolution.

Ray

From: cas-...@apereo.org <cas-...@apereo.org> on behalf of Thiago Castro <thiag...@gmail.com>
Sent: December 11, 2025 11:02
To: CAS Community <cas-...@apereo.org>
Subject: [cas-user] Use specific attribute for nameID in SAML2 and another one as fallback
 
You don't often get email from thiag...@gmail.com. Learn why this is important
--
- Website: https://apereo.github.io/cas
- List Guidelines: https://goo.gl/1VRrw7
- Contributions: https://goo.gl/mh7qDG
---
You received this message because you are subscribed to the Google Groups "CAS Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cas-user+u...@apereo.org.
To view this discussion visit https://groups.google.com/a/apereo.org/d/msgid/cas-user/f4a0c9f4-ca66-4360-9a59-a2c6ae52e13en%40apereo.org.

Thiago Castro

unread,
Dec 11, 2025, 11:03:23 PMDec 11
to CAS Community, Ray Bon
Thank you, Ray! I just wrote one and I will test in a convenient time!


Kind regards,
Thiago
Reply all
Reply to author
Forward
0 new messages