Reputation: 482
When ever I use or generate ClaimIdentities I face these schema Urls. In MS Docs microsoft says these urls have a semantic meaning but why are they using urls instead of the name of the type? In fact some of them do so i.e. the SecurityStamp has a Type of:
"AspNet.Identity.SecurityStamp"
This makes sense: It's a description of the value rather than a real type.
But what about these urls?
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name"
Do they point to some page / definition?
Upvotes: 1
Views: 1569
Reputation: 1627
They are basically predefined types of claim. You can use the claim types class to set a claim to one of these predefined types. It means you don’t have to use magic strings but instead you can use preset types which are designed for specific types of claims which makes querying claims a bit easier.
https://msdn.microsoft.com/en-us/library/system.security.claims.claimtypes%28v=vs.110%29.aspx
https://msdn.microsoft.com/en-us/library/microsoft.identitymodel.claims.claimtypes_members.aspx
Upvotes: 1