7 #include "stg/os_int.h"
8 #include "stg/blowfish.h"
12 USER(const std::string & login,
13 const std::string & password,
17 const std::string & GetLogin() const { return login; }
18 uint32_t GetIP() const { return ip; }
19 uint32_t GetAliveTimeout() const { return aliveTimeout; }
20 uint32_t GetUserTimeout() const { return userTimeout; }
21 int GetPhase() const { return phase; }
22 uint32_t GetRnd() const { return rnd; }
23 int GetSocket() const { return sock; }
24 time_t GetPhaseChangeTime() const { return phaseChangeTime; }
26 BLOWFISH_CTX * GetCtx() { return &ctx; }
28 void SetPhase(int p) { phase = p; time(&phaseChangeTime); }
29 void SetRnd(uint32_t r) { rnd = r; }
30 uint32_t IncRnd() { return ++rnd; }
31 void SetAliveTimeout(uint32_t timeout) { aliveTimeout = timeout; }
32 void SetUserTimeout(uint32_t timeout) { userTimeout = timeout; }
38 uint32_t aliveTimeout;
41 time_t phaseChangeTime;