From 5587f5afd5d21c2294ef7db8c4eebcdb68e5f2ac Mon Sep 17 00:00:00 2001 From: dec05eba Date: Wed, 18 Jul 2018 19:21:15 +0200 Subject: Add method to get user lowest permission level --- include/odhtdb/Database.hpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/odhtdb/Database.hpp') diff --git a/include/odhtdb/Database.hpp b/include/odhtdb/Database.hpp index 85207a0..372b19c 100644 --- a/include/odhtdb/Database.hpp +++ b/include/odhtdb/Database.hpp @@ -209,6 +209,9 @@ namespace odhtdb MapHash getStoredNodeUserInfoDecrypted(const std::string &username, const std::string &password) const; std::vector getUserGroups(const Hash &nodeHash, const Signature::PublicKey &userPublicKey) const; + + // Returns -1 on failure + int getUserLowestPermissionLevel(const Hash &nodeHash, const Signature::PublicKey &userPublicKey) const; std::future receiveCustomMessage(const dht::InfoHash &requestKey, ReceiveCustomMessageCallbackFunc callbackFunc); -- cgit v1.2.3