mirror of
https://github.com/Govor-team/Govor.git
synced 2026-07-21 19:54:55 +00:00
AuthSystem
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
namespace Govor.Core.DTOs;
|
||||
|
||||
public record UserDto(string Password, string Name);
|
||||
@@ -6,10 +6,6 @@
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="DTOs\" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="9.0.6" />
|
||||
</ItemGroup>
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace Govor.Core.Infrastructure.Extensions;
|
||||
|
||||
public interface IPasswordHasher
|
||||
{
|
||||
string Hash(string password);
|
||||
bool Verify(string hashedPassword, string providedPassword);
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace Govor.Core.Services;
|
||||
|
||||
public interface IAccountService
|
||||
{
|
||||
public Task RegistrationAsync(string name, string password);
|
||||
public Task<string> LoginAsync(string name, string password);
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
using Govor.Core.Models;
|
||||
|
||||
namespace Govor.Core.Services;
|
||||
|
||||
public interface IGroupService
|
||||
{
|
||||
ChatGroup GetGroupByInvite(string code);
|
||||
}
|
||||
Reference in New Issue
Block a user