]>
Commit | Line | Data |
---|---|---|
1e5562e3 | 1 | /* |
f70aedc4 | 2 | * Copyright (C) 1996-2021 The Squid Software Foundation and contributors |
1e5562e3 | 3 | * |
bbc27441 AJ |
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. | |
1e5562e3 | 7 | */ |
8 | ||
bbc27441 AJ |
9 | /* DEBUG: section 82 External ACL */ |
10 | ||
1e5562e3 | 11 | #ifndef SQUID_EXTERNALACLENTRY_H |
12 | #define SQUID_EXTERNALACLENTRY_H | |
13 | ||
e5f825ea | 14 | #include "acl/Acl.h" |
abdd93d0 | 15 | #include "acl/forward.h" |
c6983ec7 | 16 | #include "hash.h" |
a0592634 | 17 | #include "Notes.h" |
c6983ec7 | 18 | #include "SquidString.h" |
aa839030 | 19 | |
613924ee | 20 | class external_acl; |
1e5562e3 | 21 | /****************************************************************** |
22 | * ExternalACLEntryData | |
23 | * Core data that ExternalACLEntry manages. | |
24 | * Not meant to be used as remote storage at any point: | |
25 | * stack or static or composition use only. | |
26 | */ | |
27 | ||
28 | class ExternalACLEntryData | |
29 | { | |
30 | ||
31 | public: | |
e5f825ea | 32 | ExternalACLEntryData() : result(ACCESS_DUNNO) {} |
1e5562e3 | 33 | |
329c128c | 34 | Acl::Answer result; |
a0592634 AJ |
35 | |
36 | /// list of all kv-pairs returned by the helper | |
37 | NotePairs notes; | |
38 | ||
2f1431ea AJ |
39 | #if USE_AUTH |
40 | // TODO use an AuthUser to hold this info | |
30abd221 | 41 | String user; |
42 | String password; | |
2f1431ea | 43 | #endif |
30abd221 | 44 | String message; |
45 | String tag; | |
46 | String log; | |
1e5562e3 | 47 | }; |
48 | ||
1e5562e3 | 49 | /******************************************************************* |
50 | * external_acl cache entry | |
741c2986 | 51 | * Used opaque in the interface |
1e5562e3 | 52 | */ |
53 | ||
abdd93d0 | 54 | class ExternalACLEntry: public hash_link, public RefCountable |
1e5562e3 | 55 | { |
741c2986 AJ |
56 | MEMPROXY_CLASS(ExternalACLEntry); |
57 | ||
1e5562e3 | 58 | public: |
1e5562e3 | 59 | ExternalACLEntry(); |
60 | ~ExternalACLEntry(); | |
61 | ||
62 | void update(ExternalACLEntryData const &); | |
63 | dlink_node lru; | |
329c128c | 64 | Acl::Answer result; |
1e5562e3 | 65 | time_t date; |
a0592634 AJ |
66 | |
67 | /// list of all kv-pairs returned by the helper | |
68 | NotePairs notes; | |
69 | ||
2f1431ea | 70 | #if USE_AUTH |
30abd221 | 71 | String user; |
72 | String password; | |
2f1431ea | 73 | #endif |
30abd221 | 74 | String message; |
75 | String tag; | |
76 | String log; | |
1e5562e3 | 77 | external_acl *def; |
1e5562e3 | 78 | }; |
79 | ||
1e5562e3 | 80 | #endif |
f53969cc | 81 |