mirror of
https://git.alee14.me/shiftos-archive/ShiftOS_TheReturn.git
synced 2025-02-02 06:17:34 +00:00
Stop hashing passwords - we encrypt saves now
This commit is contained in:
parent
19b13528f6
commit
ae7553fa95
1 changed files with 1 additions and 8 deletions
|
@ -105,14 +105,7 @@ namespace ShiftOS.Server
|
|||
/// <param name="args">The command-line arguments.</param>
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
foreach(var save in Directory.GetFiles("saves"))
|
||||
{
|
||||
var save_obj = JsonConvert.DeserializeObject<Save>(File.ReadAllText(save));
|
||||
if (save_obj.PasswordHashed == false)
|
||||
save_obj.Password = Encryption.Encrypt(save_obj.Password);
|
||||
File.WriteAllText(save, JsonConvert.SerializeObject(save_obj, Formatting.Indented));
|
||||
}
|
||||
|
||||
|
||||
if (!Directory.Exists("saves"))
|
||||
{
|
||||
Directory.CreateDirectory("saves");
|
||||
|
|
Loading…
Add table
Reference in a new issue