mirror of https://github.com/abpframework/abp.git
7 changed files with 86 additions and 15 deletions
@ -0,0 +1,17 @@ |
|||
using Volo.Abp.Security.Claims; |
|||
|
|||
namespace Microsoft.AspNetCore.Authentication.OAuth.Claims |
|||
{ |
|||
public static class AbpClaimActionCollectionExtensions |
|||
{ |
|||
public static void MapAbpClaimTypes(this ClaimActionCollection claimActions) |
|||
{ |
|||
claimActions.MapJsonKey(AbpClaimTypes.Role, "role"); |
|||
claimActions.MapJsonKey(AbpClaimTypes.Email, "email"); |
|||
claimActions.MapJsonKey(AbpClaimTypes.UserName, "name"); |
|||
claimActions.MapJsonKey(AbpClaimTypes.EmailVerified, "email_verified"); |
|||
claimActions.MapJsonKey(AbpClaimTypes.PhoneNumber, "phone_number"); |
|||
claimActions.MapJsonKey(AbpClaimTypes.PhoneNumberVerified, "phone_number_verified"); |
|||
} |
|||
} |
|||
} |
|||
@ -0,0 +1,25 @@ |
|||
<Project Sdk="Microsoft.NET.Sdk"> |
|||
|
|||
<Import Project="..\..\common.props" /> |
|||
|
|||
<PropertyGroup> |
|||
<TargetFramework>netstandard2.0</TargetFramework> |
|||
<AssemblyName>Volo.Abp.AspNetCore.Authentication.OAuth</AssemblyName> |
|||
<PackageId>Volo.Abp.AspNetCore.Authentication.OAuth</PackageId> |
|||
<AssetTargetFallback>$(AssetTargetFallback);portable-net45+win8+wp8+wpa81;</AssetTargetFallback> |
|||
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute> |
|||
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute> |
|||
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute> |
|||
<RootNamespace /> |
|||
</PropertyGroup> |
|||
|
|||
<ItemGroup> |
|||
<ProjectReference Include="..\Volo.Abp.Core\Volo.Abp.Core.csproj" /> |
|||
<ProjectReference Include="..\Volo.Abp.Security\Volo.Abp.Security.csproj" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<PackageReference Include="Microsoft.AspNetCore.Authentication.OAuth" Version="2.0.1" /> |
|||
</ItemGroup> |
|||
|
|||
</Project> |
|||
@ -0,0 +1,15 @@ |
|||
using Microsoft.Extensions.DependencyInjection; |
|||
using Volo.Abp.Modularity; |
|||
using Volo.Abp.Security; |
|||
|
|||
namespace Volo.Abp.AspNetCore.Authentication.OAuth |
|||
{ |
|||
[DependsOn(typeof(AbpSecurityModule))] |
|||
public class AbpAspNetCoreAuthenticationOAuthModule : AbpModule |
|||
{ |
|||
public override void ConfigureServices(IServiceCollection services) |
|||
{ |
|||
services.AddAssemblyOf<AbpAspNetCoreAuthenticationOAuthModule>(); |
|||
} |
|||
} |
|||
} |
|||
Loading…
Reference in new issue