]>
git.ipfire.org Git - thirdparty/squid.git/blob - src/auth/Gadgets.h
2 * Copyright (C) 1996-2015 The Squid Software Foundation and contributors
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.
9 #ifndef SQUID_AUTH_GADGETS_H
10 #define SQUID_AUTH_GADGETS_H
14 #include "auth/Config.h"
15 #include "auth/User.h"
21 * This is used to link AuthUsers objects into the username cache.
22 * Because some schemes may link in aliases to a user,
23 * the link is not part of the AuthUser structure itself.
25 * Code must not hold onto copies of these objects.
26 * They may exist only so long as the AuthUser being referenced
27 * is recorded in the cache. Any caller using hash_remove_link
28 * must then delete the AuthUserHashPointer.
30 class AuthUserHashPointer
: public hash_link
32 MEMPROXY_CLASS(AuthUserHashPointer
);
35 AuthUserHashPointer(Auth::User::Pointer
);
36 ~AuthUserHashPointer() { auth_user
= NULL
; };
38 Auth::User::Pointer
user() const;
41 Auth::User::Pointer auth_user
;
53 \todo this should be a generic cachemgr API type ?
55 typedef void AUTHSSTATS(StoreEntry
*);
58 void authenticateInit(Auth::ConfigVector
*);
61 * Remove all idle authentication state. Intended for use by reconfigure.
63 * Removes the username cache contents and global configuration state.
64 * Stops just short of detaching the auth components completely.
66 * Currently active requests should finish. Howevee new requests will not use
67 * authentication unless something causes the global config to be rebuilt.
68 * Such as a configure load action adding config and re-running authenticateInit().
70 void authenticateReset(void);
72 void authenticateRotate(void);
75 void authenticateFreeProxyAuthUserACLResults(void *data
);
77 int authenticateActiveSchemeCount(void);
79 int authenticateSchemeCount(void);
82 void authenticateOnCloseConnection(ConnStateData
* conn
);
85 #endif /* SQUID_AUTH_GADGETS_H */