parse all available .access in the path
This commit is contained in:
parent
c395a837e0
commit
65f199299d
2 changed files with 13 additions and 7 deletions
|
|
@ -105,9 +105,11 @@ namespace Yavsc
|
|||
|
||||
var claims = new List<Claim>(
|
||||
context.Scope.Select(x => new Claim("urn:oauth:scope", x))
|
||||
);
|
||||
claims.Add(new Claim(ClaimTypes.NameIdentifier, user.Id));
|
||||
claims.Add(new Claim(ClaimTypes.Email, user.Email));
|
||||
)
|
||||
{
|
||||
new Claim(ClaimTypes.NameIdentifier, user.Id),
|
||||
new Claim(ClaimTypes.Email, user.Email)
|
||||
};
|
||||
claims.AddRange((await _usermanager.GetRolesAsync(user)).Select(
|
||||
r => new Claim(ClaimTypes.Role, r)
|
||||
));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue