]> git.ipfire.org Git - thirdparty/squid.git/blob - src/auth/ntlm/UserRequest.h
Merged from trunk 13172.
[thirdparty/squid.git] / src / auth / ntlm / UserRequest.h
1 #ifndef _SQUID_SRC_AUTH_NTLM_USERREQUEST_H
2 #define _SQUID_SRC_AUTH_NTLM_USERREQUEST_H
3
4 #include "auth/ntlm/auth_ntlm.h"
5 #include "auth/UserRequest.h"
6 #include "MemPool.h"
7
8 class ConnStateData;
9 class HttpReply;
10 class HttpRequest;
11 class helper_stateful_server;
12
13 namespace Auth
14 {
15 namespace Ntlm
16 {
17
18 class UserRequest : public Auth::UserRequest
19 {
20
21 public:
22 MEMPROXY_CLASS(Auth::Ntlm::UserRequest);
23
24 UserRequest();
25 virtual ~UserRequest();
26 virtual int authenticated() const;
27 virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type);
28 virtual Auth::Direction module_direction();
29 virtual void module_start(HttpRequest *req, AccessLogEntry::Pointer &al, AUTHCB *, void *);
30 virtual const char *credentialsStr();
31
32 virtual const char * connLastHeader();
33
34 /* we need to store the helper server between requests */
35 helper_stateful_server *authserver;
36 virtual void releaseAuthServer(); ///< Release authserver NTLM helpers properly when finished or abandoning.
37
38 /* our current blob to pass to the client */
39 char *server_blob;
40
41 /* our current blob to pass to the server */
42 char *client_blob;
43
44 /* currently waiting for helper response */
45 unsigned char waiting;
46
47 /* need access to the request flags to mess around on pconn failure */
48 HttpRequest *request;
49
50 private:
51 static HLPCB HandleReply;
52 };
53
54 } // namespace Ntlm
55 } // namespace Auth
56
57 MEMPROXY_CLASS_INLINE(Auth::Ntlm::UserRequest);
58
59 #endif /* _SQUID_SRC_AUTH_NTLM_USERREQUEST_H */