]>
Commit | Line | Data |
---|---|---|
928f3421 AJ |
1 | #ifndef _SQUID_SRC_AUTH_DIGEST_USERREQUEST_H |
2 | #define _SQUID_SRC_AUTH_DIGEST_USERREQUEST_H | |
3 | ||
928f3421 | 4 | #include "auth/digest/auth_digest.h" |
602d9612 | 5 | #include "auth/UserRequest.h" |
928f3421 AJ |
6 | #include "MemPool.h" |
7 | ||
8 | class ConnStateData; | |
9 | class HttpReply; | |
10 | class HttpRequest; | |
11 | ||
c7baff40 AJ |
12 | namespace Auth |
13 | { | |
14 | namespace Digest | |
15 | { | |
16 | ||
928f3421 | 17 | /** |
c7baff40 | 18 | * The UserRequest structure is what follows the http_request around |
928f3421 | 19 | */ |
c7baff40 | 20 | class UserRequest : public Auth::UserRequest |
928f3421 AJ |
21 | { |
22 | ||
23 | public: | |
c7baff40 | 24 | MEMPROXY_CLASS(Auth::Digest::UserRequest); |
928f3421 | 25 | |
c7baff40 AJ |
26 | UserRequest(); |
27 | virtual ~UserRequest(); | |
928f3421 AJ |
28 | |
29 | virtual int authenticated() const; | |
30 | virtual void authenticate(HttpRequest * request, ConnStateData * conn, http_hdr_type type); | |
c7baff40 | 31 | virtual Direction module_direction(); |
7afc3bf2 | 32 | virtual void addAuthenticationInfoHeader(HttpReply * rep, int accel); |
928f3421 | 33 | #if WAITING_FOR_TE |
7afc3bf2 | 34 | virtual void addAuthenticationInfoTrailer(HttpReply * rep, int accel); |
928f3421 AJ |
35 | #endif |
36 | ||
4c535e87 | 37 | virtual void module_start(AUTHCB *, void *); |
928f3421 | 38 | |
928f3421 AJ |
39 | char *nonceb64; /* "dcd98b7102dd2f0e8b11d0f600bfb0c093" */ |
40 | char *cnonce; /* "0a4f113b" */ | |
41 | char *realm; /* = "testrealm@host.com" */ | |
42 | char *pszPass; /* = "Circle Of Life" */ | |
43 | char *algorithm; /* = "md5" */ | |
44 | char nc[9]; /* = "00000001" */ | |
45 | char *pszMethod; /* = "GET" */ | |
46 | char *qop; /* = "auth" */ | |
47 | char *uri; /* = "/dir/index.html" */ | |
48 | char *response; | |
49 | ||
50 | struct { | |
3dd52a0b FC |
51 | bool authinfo_sent; |
52 | bool invalid_password; | |
53 | bool helper_queried; | |
928f3421 AJ |
54 | } flags; |
55 | digest_nonce_h *nonce; | |
56 | ||
57 | private: | |
928f3421 AJ |
58 | static HLPCB HandleReply; |
59 | }; | |
60 | ||
c7baff40 AJ |
61 | } // namespace Digest |
62 | } // namespace Auth | |
63 | ||
64 | MEMPROXY_CLASS_INLINE(Auth::Digest::UserRequest); | |
928f3421 AJ |
65 | |
66 | #endif /* _SQUID_SRC_AUTH_DIGEST_USERREQUEST_H */ |