1 #ifndef SQUID_ACLFILLED_CHECKLIST_H
2 #define SQUID_ACLFILLED_CHECKLIST_H
4 #include "AccessLogEntry.h"
5 #include "acl/Checklist.h"
6 #include "acl/forward.h"
7 #include "ip/Address.h"
9 #include "auth/UserRequest.h"
12 #include "ssl/support.h"
17 class ExternalACLEntry
;
22 ACLChecklist filled with specific data, representing Squid and transaction
23 state for access checks along with some data-specific checking methods */
24 class ACLFilledChecklist
: public ACLChecklist
28 ACLFilledChecklist(const acl_access
*, HttpRequest
*, const char *ident
);
29 ~ACLFilledChecklist();
32 /// The client connection manager
33 ConnStateData
* conn() const;
35 /// The client side fd. It uses conn() if available
39 void conn(ConnStateData
*);
40 /// set the client side FD
41 void fd(int aDescriptor
);
43 //int authenticated();
45 bool destinationDomainChecked() const;
46 void markDestinationDomainChecked();
47 bool sourceDomainChecked() const;
48 void markSourceDomainChecked();
51 virtual bool hasRequest() const { return request
!= NULL
; }
52 virtual bool hasReply() const { return reply
!= NULL
; }
64 char rfc931
[USER_IDENT_SZ
];
66 Auth::UserRequest::Pointer auth_user_request
;
73 /// SSL [certificate validation] errors, in undefined order
74 Ssl::CertErrors
*sslErrors
;
75 /// The peer certificate
76 Ssl::X509_Pointer serverCert
;
79 AccessLogEntry::Pointer al
; ///< info for the future access.log entry
81 ExternalACLEntry
*extacl_entry
;
84 ConnStateData
* conn_
; /**< hack for ident and NTLM */
85 int fd_
; /**< may be available when conn_ is not */
86 bool destinationDomainChecked_
;
87 bool sourceDomainChecked_
;
88 /// not implemented; will cause link failures if used
89 ACLFilledChecklist(const ACLFilledChecklist
&);
90 /// not implemented; will cause link failures if used
91 ACLFilledChecklist
&operator=(const ACLFilledChecklist
&);
93 CBDATA_CLASS2(ACLFilledChecklist
);
96 /// convenience and safety wrapper for dynamic_cast<ACLFilledChecklist*>
98 ACLFilledChecklist
*Filled(ACLChecklist
*checklist
)
100 // this should always be safe because ACLChecklist is an abstract class
101 // and ACLFilledChecklist is its only [concrete] child
102 return dynamic_cast<ACLFilledChecklist
*>(checklist
);
105 #endif /* SQUID_ACLFILLED_CHECKLIST_H */