AuthSystem

This commit is contained in:
Artemy
2025-06-18 12:08:21 +07:00
parent de8d97e5bf
commit 2c2c2b805c
12 changed files with 230 additions and 10 deletions
+3
View File
@@ -0,0 +1,3 @@
namespace Govor.Core.DTOs;
public record UserDto(string Password, string Name);
-4
View File
@@ -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);
}
+7
View File
@@ -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);
}
+8
View File
@@ -0,0 +1,8 @@
using Govor.Core.Models;
namespace Govor.Core.Services;
public interface IGroupService
{
ChatGroup GetGroupByInvite(string code);
}