Refactoring and password hashing

This commit is contained in:
kdeng00
2023-09-26 18:58:46 -04:00
parent 8f090bd2e2
commit d2c84966b9
5 changed files with 182 additions and 66 deletions
+14
View File
@@ -3,6 +3,7 @@ using System;
using MongoDB.Bson;
using MongoDB.Bson.Serialization.Attributes;
using MongoDB.Bson.Serialization.Conventions;
using MongoDB.Bson.Serialization.IdGenerators;
using MongoDB.Driver;
namespace TextSender_API.Models;
@@ -27,3 +28,16 @@ public class User
public DateTime? DateCreated { get; set; }
#endregion
}
public class Salt
{
#region Properties
[BsonId]
[BsonRepresentation(BsonType.ObjectId)]
public string? Id { get; set; }
[BsonElement("key")]
public byte[]? Key { get; set; }
[BsonElement("user_id")]
public string? UserId { get; set; }
#endregion
}