]> git.ipfire.org Git - thirdparty/squid.git/blame - src/ExternalACLEntry.cc
Boilerplate: update copyright blurbs on src/
[thirdparty/squid.git] / src / ExternalACLEntry.cc
CommitLineData
1e5562e3 1/*
bbc27441 2 * Copyright (C) 1996-2014 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
582c2af2 11#include "squid.h"
1e5562e3 12#include "ExternalACLEntry.h"
985c86bc 13#include "SquidTime.h"
1e5562e3 14
15/******************************************************************
16 * external_acl cache
17 */
18
19CBDATA_CLASS_INIT(ExternalACLEntry);
20
a0592634
AJ
21ExternalACLEntry::ExternalACLEntry() :
22 notes()
1e5562e3 23{
24 lru.next = lru.prev = NULL;
e5f825ea 25 result = ACCESS_DENIED;
1e5562e3 26 date = 0;
1e5562e3 27 def = NULL;
28}
29
30ExternalACLEntry::~ExternalACLEntry()
31{
32 safe_free(key);
1e5562e3 33}
34
35void
36ExternalACLEntry::update(ExternalACLEntryData const &someData)
37{
38 date = squid_curtime;
39 result = someData.result;
a0592634
AJ
40
41 // replace all notes. not combine
c33a88ca 42 notes.entries.clear();
a0592634
AJ
43 notes.append(&someData.notes);
44
2f1431ea 45#if USE_AUTH
d7bd27db 46 user = someData.user;
abb929f0 47 password = someData.password;
2f1431ea 48#endif
d7bd27db 49 message = someData.message;
1e5562e3 50 tag = someData.tag;
4a972fa2 51 log = someData.log;
1e5562e3 52}