fixes
parent
77d6a5062e
commit
23025e1856
|
@ -6,6 +6,7 @@
|
|||
|
||||
## IdentityServer.Api
|
||||
|
||||
⚡️ Nu mai returna si status code din metoda de autentificare
|
||||
⚡️ Store passwords as hash\
|
||||
⚡️ Documentatie in fisier .md afisata in frontend - e diferite de release notes\
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ namespace IdentityServer.Application.Mappings
|
|||
{
|
||||
CreateMap<models.Token, dto.Token>();
|
||||
CreateMap<models.TokenCore, dto.TokenCore>();
|
||||
CreateMap<AppUser, dto.TokenCore>()
|
||||
CreateMap<AppUser, models.TokenCore>()
|
||||
.ForMember(z => z.Claims, src => src.MapFrom(z => ComposeClaims(z.Claims)));
|
||||
}
|
||||
|
||||
|
|
|
@ -9,16 +9,11 @@ namespace IdentityServer.Application.Stores
|
|||
internal class SecurityStore : ISecurityStore
|
||||
{
|
||||
private readonly ITokenService _tokenService;
|
||||
private ConcurrentDictionary<int, List<Token>> Tokens { get; }
|
||||
|
||||
public SecurityStore(ITokenService tokenService)
|
||||
{
|
||||
_tokenService = tokenService;
|
||||
}
|
||||
|
||||
private ConcurrentDictionary<int, List<Token>> Tokens { get; }
|
||||
|
||||
public SecurityStore()
|
||||
{
|
||||
Tokens = new ConcurrentDictionary<int, List<Token>>();
|
||||
}
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace IdentityServer.Domain.Data.EntityTypeConfiguration
|
|||
{
|
||||
public void Configure(EntityTypeBuilder<UserClaim> builder)
|
||||
{
|
||||
builder.ToTable("UserStatus").HasKey(z => z.ClaimId);
|
||||
builder.ToTable("UserClaim").HasKey(z => z.ClaimId);
|
||||
builder.Property(z => z.ClaimId).ValueGeneratedOnAdd();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@ begin
|
|||
Email varchar(100) constraint UQ_AppUser_Email unique,
|
||||
ProfilePictureUrl varchar(200),
|
||||
SecurityStamp varchar(200) constraint UQ_AppUser_SecurityStamp unique,
|
||||
StatusId int constraint FK_AppUser_UserStatus references UserStatus(StatusId),
|
||||
StatusId int not null constraint FK_AppUser_UserStatus references UserStatus(StatusId),
|
||||
CreationDate datetime constraint DF_AppUser_CreationDate default getdate(),
|
||||
FailedLoginAttempts int,
|
||||
LastLoginDate datetime,
|
||||
|
|
|
@ -3,7 +3,7 @@ begin
|
|||
create table UserClaim
|
||||
(
|
||||
ClaimId int identity(1, 1) constraint PK_UserClaim primary key,
|
||||
UserId int constraint FK_UserClaim_AppUser foreign key references AppUser(UserId),
|
||||
UserId int not null constraint FK_UserClaim_AppUser foreign key references AppUser(UserId),
|
||||
ClaimKey varchar(50) not null,
|
||||
ClaimValue varchar(300) not null
|
||||
)
|
||||
|
|
|
@ -15,9 +15,9 @@ namespace IdentityServer.Domain.Entities
|
|||
public string SecurityStamp { get; set; }
|
||||
public int StatusId { get; set; }
|
||||
public DateTime CreationDate { get; set; }
|
||||
public int FailedLoginAttempts { get; set; }
|
||||
public DateTime LastLoginDate { get; set; }
|
||||
public DateTime PasswordChangeDate { get; set; }
|
||||
public int? FailedLoginAttempts { get; set; }
|
||||
public DateTime? LastLoginDate { get; set; }
|
||||
public DateTime? PasswordChangeDate { get; set; }
|
||||
public UserStatus Status { get; set; }
|
||||
public ICollection<UserClaim> Claims { get; set; }
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue