]> git.ipfire.org Git - thirdparty/squid.git/blame - src/auth/State.h
Boilerplate: update copyright blurbs on src/
[thirdparty/squid.git] / src / auth / State.h
CommitLineData
bbc27441
AJ
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
928f3421
AJ
9#ifndef __AUTH_AUTHENTICATE_STATE_T__
10#define __AUTH_AUTHENTICATE_STATE_T__
11
2f1431ea
AJ
12#if USE_AUTH
13
928f3421 14#include "auth/UserRequest.h"
1c756645 15#include "cbdata.h"
e166785a 16#include "helper.h"
1c756645
AJ
17
18namespace Auth
19{
928f3421 20
928f3421
AJ
21/**
22 * CBDATA state for NTLM, Negotiate, and Digest stateful authentication.
23 */
a9336c23
A
24class StateData
25{
1c756645 26public:
4c535e87 27 StateData(const UserRequest::Pointer &r, AUTHCB *h, void *d) :
a9336c23
A
28 data(cbdataReference(d)),
29 auth_user_request(r),
30 handler(h) {}
1c756645
AJ
31
32 ~StateData() {
33 auth_user_request = NULL;
34 cbdataReferenceDone(data);
35 }
36
928f3421 37 void *data;
c7baff40 38 UserRequest::Pointer auth_user_request;
4c535e87 39 AUTHCB *handler;
928f3421 40
1c756645
AJ
41private:
42 CBDATA_CLASS2(StateData);
43};
928f3421 44
1c756645 45} // namespace Auth
928f3421 46
2f1431ea 47#endif /* USE_AUTH */
928f3421 48#endif /* __AUTH_AUTHENTICATE_STATE_T__ */