APi Scopes

This commit is contained in:
Paul Schneider 2026-03-16 23:16:12 +00:00
commit be7df3d054
25 changed files with 823 additions and 116 deletions

View file

@ -1,5 +1,4 @@
using IdentityServer8.EntityFramework.Entities;
using IdentityServer8.EntityFramework.Interfaces;
using Microsoft.AspNetCore.Identity.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.ChangeTracking;
@ -23,8 +22,8 @@ namespace Yavsc.Models
using IT.Fixing;
using Market;
using Messaging;
using Microsoft.AspNetCore.Http;
using Musical;
using Microsoft.AspNetCore.Http;
using Musical;
using Musical.Profiles;
using Payment;
using Relationship;
@ -36,8 +35,7 @@ namespace Yavsc.Models
using Workflow;
using Workflow.Profiles;
public class ApplicationDbContext : IdentityDbContext<ApplicationUser>,
IConfigurationDbContext, IPersistedGrantDbContext
public class ApplicationDbContext : IdentityDbContext<ApplicationUser>
{
public ApplicationDbContext()
{
@ -81,7 +79,7 @@ namespace Yavsc.Models
;
builder.Entity<Activity>().Property(a => a.ParentCode).IsRequired(false);
builder.Entity<Client>().Property("Id").UseIdentityAlwaysColumn();
builder.Entity<ClientSecret>().Property("Id").UseIdentityAlwaysColumn();
builder.Entity<ClientScope>().Property("Id").UseIdentityAlwaysColumn();
@ -240,12 +238,12 @@ namespace Yavsc.Models
return await base.SaveChangesAsync(ctoken);
}
public Task<int> SaveChangesAsync()
{
return base.SaveChangesAsync();
}
public Task<int> SaveChangesAsync()
{
return base.SaveChangesAsync();
}
public DbSet<Circle> Circle { get; set; }
public DbSet<Circle> Circle { get; set; }
public DbSet<CircleAuthorizationToBlogPost> CircleAuthorizationToBlogPost { get; set; }
@ -338,8 +336,7 @@ namespace Yavsc.Models
public DbSet<PersistedGrant> PersistedGrants { get; set; }
public DbSet<DeviceFlowCodes> DeviceFlowCodes { get; set; }
public DbSet<YavscApiScope> YavscApiScopes { get; set; }
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiResource : ApiResource
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiResourceClaim : ApiResourceClaim
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiResourceProperty : ApiResourceProperty
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiResourceScope : ApiResourceScope
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiResourceSecret : ApiResourceSecret
{
}
}

View file

@ -0,0 +1,9 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiScope : ApiScope
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiScopeClaim : ApiScopeClaim
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscApiScopeProperty : ApiScopeProperty
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscDeviceFlowCodes : DeviceFlowCodes
{
}
}

View file

@ -0,0 +1,8 @@
using IdentityServer8.EntityFramework.Entities;
namespace Yavsc.Models
{
public class YavscPersistedGrant : PersistedGrant
{
}
}