aboutsummaryrefslogtreecommitdiff
path: root/src/DevHive.Common
diff options
context:
space:
mode:
authortranstrike <transtrike@gmail.com>2021-01-21 09:23:06 +0200
committertranstrike <transtrike@gmail.com>2021-01-21 09:23:06 +0200
commit009e01dc3dc2f78db6a660c65bf0d20bae702348 (patch)
tree04d792a08f13e9bfe23841b393439dcd37ab8b16 /src/DevHive.Common
parent8179af787a7bf375753a178b89111a91d84a8bb8 (diff)
downloadDevHive-009e01dc3dc2f78db6a660c65bf0d20bae702348.tar
DevHive-009e01dc3dc2f78db6a660c65bf0d20bae702348.tar.gz
DevHive-009e01dc3dc2f78db6a660c65bf0d20bae702348.zip
Tryed implementing the http patch
Diffstat (limited to 'src/DevHive.Common')
-rw-r--r--src/DevHive.Common/Models/Misc/PasswordModifications.cs13
-rw-r--r--src/DevHive.Common/Models/Misc/Patch.cs9
2 files changed, 22 insertions, 0 deletions
diff --git a/src/DevHive.Common/Models/Misc/PasswordModifications.cs b/src/DevHive.Common/Models/Misc/PasswordModifications.cs
new file mode 100644
index 0000000..f10a334
--- /dev/null
+++ b/src/DevHive.Common/Models/Misc/PasswordModifications.cs
@@ -0,0 +1,13 @@
+using System.Security.Cryptography;
+using System.Text;
+
+namespace DevHive.Common.Models.Misc
+{
+ public static class PasswordModifications
+ {
+ public static string GeneratePasswordHash(string password)
+ {
+ return string.Join(string.Empty, SHA512.HashData(Encoding.ASCII.GetBytes(password)));
+ }
+ }
+}
diff --git a/src/DevHive.Common/Models/Misc/Patch.cs b/src/DevHive.Common/Models/Misc/Patch.cs
new file mode 100644
index 0000000..ea5a4f1
--- /dev/null
+++ b/src/DevHive.Common/Models/Misc/Patch.cs
@@ -0,0 +1,9 @@
+namespace DevHive.Common.Models.Misc
+{
+ public class Patch
+ {
+ public string Name { get; set; }
+ public object Value { get; set; }
+ public string Action { get; set; }
+ }
+}