
dye4h (dye4h) asked a question.
I have multiple groups in Okta, for example below are the groups.
- Test
- Demo
- United
- Brazil
How can I add these groups in the SAML assertion if any of these groups are assigned to the User. For example, User has the two groups assigned 'Test' and 'Brazil' so the assertion should be as below.
<saml:Attribute xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Name="Group_Name" NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:unspecified">
<saml:AttributeValue xsi:type="xs:string">Test</saml:AttributeValue>
<saml:AttributeValue xsi:type="xs:string">Brazil</saml:AttributeValue>
</saml:Attribute>

I fix this using the below regex.
.*Test.*|.*Demo.*|.*United.*|.*Brazil.*