diff --git a/src/FiscalOS.Core/Data/Entity.cs b/src/FiscalOS.Core/Data/Entity.cs new file mode 100644 index 0000000..8b5f7f9 --- /dev/null +++ b/src/FiscalOS.Core/Data/Entity.cs @@ -0,0 +1,18 @@ +namespace FiscalOS.Core.Data; + +public abstract class Entity +{ + public Guid Id { get; init; } + public DateTimeOffset CreatedAt { get; private set; } + public DateTimeOffset UpdatedAt { get; private set; } + + public void SetCreatedAt(DateTimeOffset createdAt) + { + CreatedAt = createdAt; + } + + public void SetUpdatedAt(DateTimeOffset updatedAt) + { + UpdatedAt = updatedAt; + } +} \ No newline at end of file diff --git a/src/FiscalOS.Core/Identity/IPasswordHasher.cs b/src/FiscalOS.Core/Identity/IPasswordHasher.cs new file mode 100644 index 0000000..280ab67 --- /dev/null +++ b/src/FiscalOS.Core/Identity/IPasswordHasher.cs @@ -0,0 +1,7 @@ +namespace FiscalOS.Core.Identity; + +public interface IPasswordHasher +{ + string Hash(string password); + bool Verify(string providedPassword, string hashedPassword); +} \ No newline at end of file diff --git a/src/FiscalOS.Core/Usings.cs b/src/FiscalOS.Core/Usings.cs new file mode 100644 index 0000000..c70d0ad --- /dev/null +++ b/src/FiscalOS.Core/Usings.cs @@ -0,0 +1 @@ +global using FiscalOS.Core.Data; \ No newline at end of file