Forums, Documentation & Knowledge Base - ComponentSpace
Home
»
ComponentSpace Support Forums
»
Questions - SAML SSO for ASP.NET Core
IdentityServer4 configuration to get the role attributes
https://componentspace.com/forums/Topic10550.aspx
By Kanngarnix
-
1/14/2020
Hi,
can you give me an example how i must configure the identityserver as an Service Provider to get the role attributes in the claims.
I create demo project and can connect me with our IdentityNow System over the Identity Server 4.
I get the following SAML Response with the role Attributes:
<saml:AttributeStatement>
<saml:Attribute Name="Firstname">
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">Max</saml:AttributeValue>
</saml:Attribute>
<saml:Attribute Name="Roles">
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">role_1</saml:AttributeValue>
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">role_2</saml:AttributeValue>
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">role_3</saml:AttributeValue>
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">role_4</saml:AttributeValue>
</saml:Attribute>
<saml:Attribute Name="Email">
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">
[email protected]
</saml:AttributeValue>
</saml:Attribute>
<saml:Attribute Name="lastname">
<saml:AttributeValue xmlns:xs="
http://www.w3.org/2001/XMLSchema"
xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
xsi:type="xs:string">Mustermann</saml:AttributeValue>
</saml:Attribute>
</saml:AttributeStatement>
Thanks
By ComponentSpace
-
1/15/2020
Thanks for the confirmation.