]> git.ipfire.org Git - thirdparty/squid.git/blob - src/auth/negotiate/UserRequest.h
SourceFormat Enforcement
[thirdparty/squid.git] / src / auth / negotiate / UserRequest.h
1 /*
2 * Copyright (C) 1996-2014 The Squid Software Foundation and contributors
3 *
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
7 */
8
9 #ifndef _SQUID_SRC_AUTH_NEGOTIATE_USERREQUEST_H
10 #define _SQUID_SRC_AUTH_NEGOTIATE_USERREQUEST_H
11
12 #include "auth/UserRequest.h"
13 #include "helper/forward.h"
14
15 class ConnStateData;
16 class HttpReply;
17 class HttpRequest;
18
19 namespace Auth
20 {
21 namespace Negotiate
22 {
23
24 /// \ingroup AuthNegotiateAPI
25 class UserRequest : public Auth::UserRequest
26 {
27 MEMPROXY_CLASS(Auth::Negotiate::UserRequest);
28
29 public:
30 UserRequest();
31 virtual ~UserRequest();
32 virtual int authenticated() const;
33 virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type);
34 virtual Direction module_direction();
35 virtual void startHelperLookup(HttpRequest *request, AccessLogEntry::Pointer &al, AUTHCB *, void *);
36 virtual const char *credentialsStr();
37
38 virtual void addAuthenticationInfoHeader(HttpReply * rep, int accel);
39
40 virtual const char * connLastHeader();
41
42 /* we need to store the helper server between requests */
43 helper_stateful_server *authserver;
44 void releaseAuthServer(void); ///< Release the authserver helper server properly.
45
46 /* what connection is this associated with */
47 /* ConnStateData * conn;*/
48
49 /* our current blob to pass to the client */
50 char *server_blob;
51 /* our current blob to pass to the server */
52 char *client_blob;
53
54 /* currently waiting for helper response */
55 unsigned char waiting;
56
57 /* need access to the request flags to mess around on pconn failure */
58 HttpRequest *request;
59
60 private:
61 static HLPCB HandleReply;
62 };
63
64 } // namespace Negotiate
65 } // namespace Auth
66
67 #endif /* _SQUID_SRC_AUTH_NEGOTIATE_USERREQUEST_H */
68