Amos Jeffries [Sun, 17 Jan 2010 11:58:04 +0000 (00:58 +1300)]
Ref-count AuthScheme objects. Restructure the scheme-config relationship.
* Schemes are now global permanent objects describing the components
available. They hold the defaults for each auth mechanism (if any).
* Config are now temporary objects created by schemes and held in
Auth::TheConfig until no longer needed. They hold all current config
data about and auth mechanism.
TODO: ref-count the config items and clarify their relationship to
requests, connections, and user details.
Amos Jeffries [Fri, 18 Dec 2009 04:15:55 +0000 (17:15 +1300)]
Remove redundant user() functions
The child classes of AuthUserRequest turned out to have alternative
verions of user() set and get functions. These did the same operations
but stored the AuthUser class in different locations.
This makes user() always NULL for pointers to the parent object inside
the core authentication code. Regardess of whether an AuthUser was set.
Also digest auth had a completely alternative set of functions authUser()
to do user() operations on the parent object and locking. This has been
cleaned up.
Amos Jeffries [Thu, 17 Dec 2009 04:48:51 +0000 (17:48 +1300)]
Upgrade AuthUserRequest ref-counting
TODO:
Test auth still runs. Some problems were noted in conversion which affect
digest, NTLM, Negotiate AuthUser objects.
Notably that the virtual functions setting a custom field instead of the
parent objects _auth_user woudl result in teh *::Pointer having a NULL user()
Convert AuthUser, AuthScheme, AuthConfig to ref-counted as well.
Amos Jeffries [Fri, 11 Dec 2009 14:15:28 +0000 (03:15 +1300)]
Bug 2395: FTP errors not displayed
* Fix PUT and other errors hanging
* Fix assertion "entry->store_status == STORE_PENDING" caused by FTP
* Several variable-shadowing cases resolved for the fix.
Amos Jeffries [Thu, 3 Dec 2009 02:38:11 +0000 (15:38 +1300)]
Account for mem_node overheaders inside cache_mem
This makes squid include the overhead memory space when determining the
number of data pages available in cache_mem memory space. Forming a much
better limit on memory cache usage.
This does NOT solve any issues created by sizeof(mem_node) being unaligned
with the system malloc implementation page size. That still needs to be
resolved.
Amos Jeffries [Wed, 2 Dec 2009 22:27:33 +0000 (11:27 +1300)]
Bug 2830: clarify where NULL byte is in headers.
Debug printing used to naturally stop string output at the null byte.
This should show the first segment of headers up to the NULL and the
segment of headers after it. So that its clear to admin that there are
more headers _after_ the portion that used to be logged.
Amos Jeffries [Mon, 23 Nov 2009 01:43:45 +0000 (14:43 +1300)]
Polish ACL src/dst magic monikers and push upgrading to 'all'.
* Adds 'ipv4' magic moniker. Slightly safer and friendlier than !ipv6
* Updates the IP range parse to detect several old broken cases of 'all'.
Warn loudly and replace with 'all' during parse.
This is needed for all the people who use the 'all' pattern for special
purposes under another name; auth hiding, deny_info redirects, etc.
Amos Jeffries [Sun, 22 Nov 2009 20:37:27 +0000 (09:37 +1300)]
Author: Adrian Chadd + Tim Starling
Port from 2.7: Logging infrastructure updates.
* Basic port of the Squid-2.7 modular logging code
* Adds support for async daemon helpers.
* One daemon helper for file IO is included.
* Adds UDP stream logging facility. (Tim Starling)
Henrik Nordstrom [Sat, 21 Nov 2009 22:16:31 +0000 (23:16 +0100)]
FreeBSD for some reason some times do not like our big cf.data script
Split in multiple expressions specified by -e arguments. Seems to work better.
The large blob had a bit of extra space characters in it from the line folding
which seems to be related to the failure. (each command began with a space)
Henrik Nordstrom [Wed, 11 Nov 2009 11:44:58 +0000 (12:44 +0100)]
Style Makefile.am to use instead of @AUTOMAKEVAR
@AUTOMAKEVAR@ is troublesome when used in \ constructs as it may expand
to empty and the last line in a \ construct must not be empty or some
make versions will fail.
thankfully automake adds all variables for us, so using
is preferred.
Amos Jeffries [Mon, 9 Nov 2009 11:25:11 +0000 (00:25 +1300)]
Polish rfc1738 library code. Add cppunit tests.
* Adds API header file for this library.
* Reveals the do_escape API and creates meaningful flags for its API.
* Adds documentation.
* Convert original unit tests by Robert Collins to cppunit code
* Add new tests based on work for Samba by Andrew Bartlett
SunCC doesn't handle inline extern functions, and misses some duplicate
code detection features gcc has; as a result squid-specific operator new and
operator delete get defined multiple times and fail linking.
Implemented a compiler-specific workaround by de-inlining the code.
Improved Solaris OS detection logic (and dropped _SQUID_SUNOS_ which was not
used anyways)