Added token generation, user activation command and response.

This commit is contained in:
Fabio Bas
2015-05-24 00:37:45 +02:00
parent 42796b0d0e
commit ff1aed717e
19 changed files with 223 additions and 19 deletions

View File

@@ -70,3 +70,8 @@ QString PasswordHasher::generateRandomSalt(const int len)
return ret;
}
QString PasswordHasher::generateActivationToken()
{
return QCryptographicHash::hash(generateRandomSalt().toUtf8(), QCryptographicHash::Md5).toBase64().left(16);
}