summary refs log tree commit diff
path: root/src/encryption/VerificationManager.cpp
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2021-10-30 00:22:47 +0200
committerNicolas Werner <nicolas.werner@hotmail.de>2021-10-30 00:23:07 +0200
commit5688b2647ee686559303203a394bad1a92a744b0 (patch)
treeac0a0082e8edc770eaa278dd712278645c70f892 /src/encryption/VerificationManager.cpp
parentMerge pull request #777 from LorenDB/focusRoomSearch (diff)
downloadnheko-5688b2647ee686559303203a394bad1a92a744b0.tar.xz
Add self verification after login
Diffstat (limited to 'src/encryption/VerificationManager.cpp')
-rw-r--r--src/encryption/VerificationManager.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/encryption/VerificationManager.cpp b/src/encryption/VerificationManager.cpp

index b9b51d35..f4c7ddf2 100644 --- a/src/encryption/VerificationManager.cpp +++ b/src/encryption/VerificationManager.cpp
@@ -120,7 +120,16 @@ VerificationManager::removeVerificationFlow(DeviceVerificationFlow *flow) void VerificationManager::verifyDevice(QString userid, QString deviceid) { - auto flow = DeviceVerificationFlow::InitiateDeviceVerification(this, userid, deviceid); + auto flow = DeviceVerificationFlow::InitiateDeviceVerification(this, userid, {deviceid}); + this->dvList[flow->transactionId()] = flow; + emit newDeviceVerificationRequest(flow.data()); +} + +void +VerificationManager::verifyOneOfDevices(QString userid, std::vector<QString> deviceids) +{ + auto flow = + DeviceVerificationFlow::InitiateDeviceVerification(this, userid, std::move(deviceids)); this->dvList[flow->transactionId()] = flow; emit newDeviceVerificationRequest(flow.data()); }