X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/9a834ba2e0caea6edffec5c1db403cf9832ea96e..04711171fa39f7b76f5f4f291a016ddbe4ddcccd:/projects/stargazer/user_impl.h?ds=sidebyside diff --git a/projects/stargazer/user_impl.h b/projects/stargazer/user_impl.h index a581f2e5..6f6030ca 100644 --- a/projects/stargazer/user_impl.h +++ b/projects/stargazer/user_impl.h @@ -185,7 +185,8 @@ public: time_t GetConnectedModificationTime() const { return connected.ModificationTime(); } int GetAuthorized() const { return static_cast(authorizedBy.size()); } int Authorize(uint32_t ip, uint32_t enabledDirs, const AUTH * auth); - void Unauthorize(const AUTH * auth); + void Unauthorize(const AUTH * auth, + const std::string & reason = std::string()); bool IsAuthorizedBy(const AUTH * auth) const; std::vector GetAuthorizers() const; @@ -249,6 +250,7 @@ private: USER_PROPERTY currIP; uint32_t lastIPForDisconnect; // User's ip after unauth but before disconnect + std::string lastDisconnectReason; time_t pingTime;