Centralize local account creation and create API endpoint for creation

This commit is contained in:
Akkadius
2019-07-07 04:32:59 -05:00
parent 4bc6493718
commit 392b328a95
8 changed files with 171 additions and 13 deletions
+6
View File
@@ -21,6 +21,7 @@
#pragma once
#include <string>
#include "../common/types.h"
enum EncryptionMode
{
@@ -40,6 +41,11 @@ enum EncryptionMode
EncryptionModeSCrypt = 14
};
/**
* @param mode
* @return
*/
std::string GetEncryptionByModeId(uint32 mode);
const char* eqcrypt_block(const char *buffer_in, size_t buffer_in_sz, char* buffer_out, bool enc);
std::string eqcrypt_hash(const std::string &username, const std::string &password, int mode);
bool eqcrypt_verify_hash(const std::string &username, const std::string &password, const std::string &pwhash, int mode);