mirror of
https://github.com/lubosz/overte.git
synced 2025-04-24 00:13:53 +02:00
clean up formatting, make connectionUUID const in NodeList
This commit is contained in:
parent
73ea958640
commit
ffccc9ca96
2 changed files with 7 additions and 3 deletions
|
@ -820,8 +820,12 @@ bool DomainServer::verifyUserSignature(const QString& username,
|
|||
|
||||
if (rsaPublicKey) {
|
||||
QByteArray decryptedArray(RSA_size(rsaPublicKey), 0);
|
||||
int decryptResult =
|
||||
RSA_verify(NID_sha256, reinterpret_cast<const unsigned char*>(usernameWithToken.constData()), usernameWithToken.size(), reinterpret_cast<const unsigned char*>(usernameSignature.constData()), usernameSignature.size(), rsaPublicKey);
|
||||
int decryptResult = RSA_verify(NID_sha256,
|
||||
reinterpret_cast<const unsigned char*>(usernameWithToken.constData()),
|
||||
usernameWithToken.size(),
|
||||
reinterpret_cast<const unsigned char*>(usernameSignature.constData()),
|
||||
usernameSignature.size(),
|
||||
rsaPublicKey);
|
||||
|
||||
if (decryptResult == 1) {
|
||||
qDebug() << "Username signature matches for" << username << "- allowing connection.";
|
||||
|
|
|
@ -282,7 +282,7 @@ void NodeList::sendDomainServerCheckIn() {
|
|||
packetStream << accountInfo.getUsername();
|
||||
|
||||
// get connection token from the domain-server
|
||||
QUuid connectionToken = _domainHandler.getConnectionToken();
|
||||
const QUuid& connectionToken = _domainHandler.getConnectionToken();
|
||||
|
||||
if (!connectionToken.isNull()) {
|
||||
|
||||
|
|
Loading…
Reference in a new issue