X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=include%2Fnntp%2Fnntpconnection.h;h=d1161484d848a24fa010b2a9850b6ab3d3b5e407;hb=7ddb1aeb0b3dc7384597e75f7b3557f2d8f6d14c;hp=dd365c48b61dda397c12a9c0665cab4c868b23cc;hpb=868c533e84b3c81b6604b45b84efa32073aa20b4;p=fms.git diff --git a/include/nntp/nntpconnection.h b/include/nntp/nntpconnection.h index dd365c4..d116148 100644 --- a/include/nntp/nntpconnection.h +++ b/include/nntp/nntpconnection.h @@ -4,10 +4,12 @@ #include "../socketdefines.h" #include "../ilogger.h" #include "../message.h" +#include "../localidentity.h" #include #include -#include +//#include +#include "../pthreadwrapper/runnable.h" #ifdef _WIN32 @@ -20,7 +22,7 @@ #include #endif -class NNTPConnection:public ZThread::Runnable,public ILogger//,public IDatabase +class NNTPConnection:public PThread::Runnable,public ILogger { public: NNTPConnection(SOCKET sock); @@ -29,7 +31,7 @@ public: void Disconnect(); const bool Disconnected() { return m_socket==INVALID_SOCKET; } - void run(); + void Run(); private: @@ -50,6 +52,8 @@ private: bool m_isposting; long m_boardid; long m_messageid; + LocalIdentity m_authuser; // -1 if user not authenticated, otherwise id of user from tblLocalIdentity + bool m_authenticated; }; void SendBuffered(const std::string &data); @@ -82,6 +86,10 @@ private: const bool HandleNewGroupsCommand(const NNTPCommand &command); const bool HandlePostCommand(const NNTPCommand &command); const bool HandleOverCommand(const NNTPCommand &command); + const bool HandleAuthInfoCommand(const NNTPCommand &command); + const bool HandleGetTrustCommand(const NNTPCommand &command); + const bool HandleSetTrustCommand(const NNTPCommand &command); + const bool HandleGetTrustListCommand(const NNTPCommand &command); SOCKET m_socket; ClientStatus m_status;