Mukund Sivaraman [Mon, 31 Mar 2008 00:51:51 +0000 (17:51 -0700)]
Free entry_buffer or it'll be leaked
vector_append() calls vector_insert() which makes a copy
of the passed buffer, so the caller can free its buffer.
Mukund Sivaraman [Mon, 31 Mar 2008 00:43:32 +0000 (17:43 -0700)]
Fixed leaks of va_lists
Mukund Sivaraman [Mon, 31 Mar 2008 00:18:58 +0000 (17:18 -0700)]
Generate RPM spec file from .spec.in file
Mukund Sivaraman [Mon, 31 Mar 2008 00:12:26 +0000 (17:12 -0700)]
Added Makefile.am in packaging dirs
Mukund Sivaraman [Mon, 31 Mar 2008 00:01:29 +0000 (17:01 -0700)]
Removed old RPM packaging files
Jeremy Hinegardner [Sun, 30 Mar 2008 23:59:11 +0000 (16:59 -0700)]
Added Fedora packaging files
Mukund Sivaraman [Sun, 30 Mar 2008 23:48:47 +0000 (16:48 -0700)]
Moved RPM packaging dir to top-level
Mukund Sivaraman [Sun, 30 Mar 2008 23:41:10 +0000 (16:41 -0700)]
Removed obsolete packaging patch file
Mukund Sivaraman [Sun, 30 Mar 2008 23:39:35 +0000 (16:39 -0700)]
Do not allow anyone except localhost by default
Mukund Sivaraman [Sun, 30 Mar 2008 23:38:44 +0000 (16:38 -0700)]
Made the default group nobody
Mukund Sivaraman [Sun, 30 Mar 2008 23:33:08 +0000 (16:33 -0700)]
Removed obsolete lexer/parser files
Andrew Stribblehill [Wed, 19 Mar 2008 22:11:13 +0000 (15:11 -0700)]
Added more patterns to .gitignore
Mukund Sivaraman [Thu, 13 Mar 2008 06:50:23 +0000 (23:50 -0700)]
Fixed format string warnings
Mukund Sivaraman [Sun, 9 Mar 2008 03:20:57 +0000 (19:20 -0800)]
Removed the clean target from the src directory
This was overriding the automake clean target to clean up
files like *.o by default.
Mukund Sivaraman [Sun, 9 Mar 2008 01:41:08 +0000 (17:41 -0800)]
Corrected datatype of salen to fix compiler warning
Mukund Sivaraman [Thu, 13 Mar 2008 22:09:09 +0000 (15:09 -0700)]
Added missing ltmain.sh
Mukund Sivaraman [Sun, 9 Mar 2008 01:36:21 +0000 (17:36 -0800)]
Added empty NEWS file that's required by autotools now
Mukund Sivaraman [Sun, 9 Mar 2008 01:35:50 +0000 (17:35 -0800)]
Renamed file to replace underscores in it with dashes
Mukund Sivaraman [Sun, 9 Mar 2008 01:33:54 +0000 (17:33 -0800)]
Renamed file to replace underscores in it with dashes
Mukund Sivaraman [Wed, 5 Mar 2008 22:11:48 +0000 (14:11 -0800)]
Renamed .cvsignore to .gitignore
Mukund Sivaraman [Wed, 5 Mar 2008 22:11:14 +0000 (14:11 -0800)]
Renamed bootstrap to autogen.sh
Robert James Kaes [Fri, 4 Nov 2005 05:15:47 +0000 (05:15 +0000)]
Added support for UPSTREAM directive.
Included the basic grammar and handler functions for the "upstream" and
"no upstream" directives. I still need to update the grammar to match
_all_ the possibilities documented in the tinyproxy.conf file, but at
least it now does as much as the old config parser.
Robert James Kaes [Fri, 4 Nov 2005 01:31:41 +0000 (01:31 +0000)]
Reformatted the reverse and filter configuration blocks. If either
section is not enabled at compile time, it should not be included in the
object file.
Robert James Kaes [Fri, 4 Nov 2005 00:47:07 +0000 (00:47 +0000)]
Fixed up whitespace formatting of the config file directives. Also
added blank lines to group related directives.
Robert James Kaes [Tue, 16 Aug 2005 14:22:39 +0000 (14:22 +0000)]
Added the typecheck.m4 macro file to improve type checking support in
the configure.ac script. The various typedefs are checked in a larger
collection of locations.
Robert James Kaes [Tue, 16 Aug 2005 04:03:19 +0000 (04:03 +0000)]
* [Refactor] Moved Reverse Proxy Code
Moved the reverse proxy code from reqs.c into it's own files
(reverse_proxy.c). The code in reqs.c is way too complicated, so I
want to move unrelated code into their own files to simplify the main
concepts in reqs.c.
Robert James Kaes [Mon, 15 Aug 2005 18:35:09 +0000 (18:35 +0000)]
* [Indent] Fixed typedef Formatting
Added the list of tinyproxy typedefs to the indent command to have them
formatted correctly as well.
Robert James Kaes [Mon, 15 Aug 2005 03:54:31 +0000 (03:54 +0000)]
* [Indent] Ran Source Through indent
I re-indented the source code using indent with the following options:
indent -kr -bad -bap -nut -i8 -l80 -psl -sob -ss -ncs
There are now _no_ tabs in the source files, and all indentation is
eight spaces. Lines are 80 characters long, and the procedure type is
on it's own line. Read the indent manual for more information about
what each option means.
Robert James Kaes [Tue, 12 Jul 2005 20:34:26 +0000 (20:34 +0000)]
* Specified Correct typedef in getsock_ip()
Changed the variable type for the namelen variable to the correct
socklen_t type. The configure script already checked for it, but for
some reason I never got around to actually using it in this function.
Robert James Kaes [Tue, 12 Jul 2005 17:39:44 +0000 (17:39 +0000)]
* Updated Copyright Email Addresses
Updated the copyright email addresses for Robert James Kaes. The
users.sourceforge.net address should always exist.
Robert James Kaes [Wed, 6 Jul 2005 21:44:08 +0000 (21:44 +0000)]
Removed the proxy-* headers from the list of headers to skip. Since
tinyproxy does not prompt for any proxy information from the client, it
should not be eating the proxy headers. They are most likely needed by
an upstream proxy.
Robert James Kaes [Tue, 3 May 2005 20:34:54 +0000 (20:34 +0000)]
* [
1118363] Proxy reverse order of headers
Changed the internal implementation of the hashmap to maintain the
insert order if the same key is repeated. The insertion is still
constant since we keep track of the head and tail of the bucket
chain.
Robert James Kaes [Tue, 24 Aug 2004 18:43:17 +0000 (18:43 +0000)]
Replaced all the AC_ARG_ENABLE calls with calls to our own
TP_ARG_ENABLE macro. Except for the transparent proxy option, all the
other options remain identical. To enable transparent proxy support
use only --enable-transparent, rather than the old
--enable-transparent-proxy.
Robert James Kaes [Tue, 24 Aug 2004 18:41:18 +0000 (18:41 +0000)]
Added config/argenable.m4 to the list of configuration files needed by
the autoconf system.
Robert James Kaes [Tue, 24 Aug 2004 18:40:21 +0000 (18:40 +0000)]
Initial checkin of the TP_ARG_ENABLE macro. This macro extends the
default AC_ARG_ENABLE macro to do better error checking of the input
values.
Robert James Kaes [Tue, 24 Aug 2004 16:41:11 +0000 (16:41 +0000)]
Moved the autoconf/automake configuration files into the config
directory, so inform autoconf of this (the AC_CONFIG_AUX_DIR and
AC_CONFIG_MACRO_DIR macros.)
Also added a bunch of portability tests discovered by autoscan.
Robert James Kaes [Tue, 24 Aug 2004 16:39:29 +0000 (16:39 +0000)]
Moved all the autoconf/automake configuration information into the
config directory.
Robert James Kaes [Tue, 24 Aug 2004 16:38:42 +0000 (16:38 +0000)]
Removed the "releases.txt" file from the distribution. It didn't
really add anything, so there's no point in having it.
Robert James Kaes [Tue, 24 Aug 2004 16:36:22 +0000 (16:36 +0000)]
(takesig): Fixed the return type to use the autoconf defined
RETSIGTYPE. This is portable, while simply using "void" is not.
Robert James Kaes [Tue, 24 Aug 2004 16:35:27 +0000 (16:35 +0000)]
Added code to handle HTTP/0.9 simple GET requests.
Robert James Kaes [Tue, 24 Aug 2004 16:34:22 +0000 (16:34 +0000)]
(get_bool_arg): Moved the initialization of "p" _before_ the assert()
calls. The code doesn't compile under gcc 2.95 otherwise. (I'm
surprised it compiles under gcc 3.3 without a problem.)
Robert James Kaes [Tue, 24 Aug 2004 16:33:00 +0000 (16:33 +0000)]
Changed some of the variable types so that the code compiles cleanly
on other operating systems. (Used cf.sourceforge.net as the test
system for cross compiling.)
Robert James Kaes [Tue, 24 Aug 2004 16:31:45 +0000 (16:31 +0000)]
Fixed up the acl_s structure so that it compiles correctly under
gcc 2.95.
Robert James Kaes [Fri, 20 Aug 2004 19:56:05 +0000 (19:56 +0000)]
Bootstrap the autoconf system
Robert James Kaes [Fri, 20 Aug 2004 16:01:31 +0000 (16:01 +0000)]
Moved the configuration information into it's own directory to avoid
cluttering up the root directory.
Robert James Kaes [Sat, 14 Aug 2004 03:21:28 +0000 (03:21 +0000)]
Changed the calls to the config_compile() and config_parse()
functions. Also, if the "logfile" directive is used, it will now
override use of the syslog system. Added an error message if neither
is defined.
Robert James Kaes [Sat, 14 Aug 2004 03:20:01 +0000 (03:20 +0000)]
(log_message): Added a fsync() call after each line outputted to the
log file.
Robert James Kaes [Sat, 14 Aug 2004 03:18:41 +0000 (03:18 +0000)]
Reorganized the source code. Added the missing reverse proxy
directives. Added a bunch of comments to clarify how the code works.
Robert James Kaes [Sat, 14 Aug 2004 00:37:51 +0000 (00:37 +0000)]
Removed the last code relating to the old configuration parsing
system. The grammar.y and scanner.l files still need to be removed.
Robert James Kaes [Fri, 13 Aug 2004 21:04:24 +0000 (21:04 +0000)]
Removed the grammar.y and scanner.l files from the list of files
required by tinyproxy.
Robert James Kaes [Fri, 13 Aug 2004 21:03:58 +0000 (21:03 +0000)]
Added some error logging information for directives that are
conditionally compiled. Still need to add info messages for the
directives.
Robert James Kaes [Fri, 13 Aug 2004 21:03:11 +0000 (21:03 +0000)]
Change the code to use the new config_parse() method rather than the
flex/bison based configuration system.
Robert James Kaes [Fri, 13 Aug 2004 20:19:50 +0000 (20:19 +0000)]
Added the new configuration parsing system (conffile.c and
conffile.h.) The new system is intended to replace the existing
grammar.y and scanner.l files. I don't want to depend on flex/bison
any longer.
Robert James Kaes [Thu, 12 Aug 2004 20:15:04 +0000 (20:15 +0000)]
(check_allowed_connect_ports): By default DENY any CONNECT requests
unless explicitly allowed by a configuration directive.
Robert James Kaes [Thu, 12 Aug 2004 19:57:15 +0000 (19:57 +0000)]
(add_xtinyproxy_header): Removed the runtime error checking of the
connptr->server_fd variable and moved it into an assert since we
should never be called with invalid data. Also made the function an
inline function since it's only called in one place.
Robert James Kaes [Wed, 11 Aug 2004 20:09:20 +0000 (20:09 +0000)]
Completely rewrote the ACL functionality. The new system is intended
to handle IPv6 style addresses along with the existing IPv4 and string
addresses. In addition, the hand-rolled "list" code has been replaced
with a vector (code reuse.) Also, the code should be a little easier
to understand (relatively speaking.)
I do need to add some kind of testing framework (in general) to check
that the new code does work with all the formats that will be thrown
at it.
Robert James Kaes [Wed, 11 Aug 2004 02:49:05 +0000 (02:49 +0000)]
(strip_username_password): Removed one of the pointer variables since
it's no longer needed. Reorganized the function to make it more
obvious what was actually being done.
Robert James Kaes [Tue, 10 Aug 2004 21:24:24 +0000 (21:24 +0000)]
Merged in changes from 1.6.3
Robert James Kaes [Tue, 27 Apr 2004 18:53:14 +0000 (18:53 +0000)]
Added the "BindSame" configure directive from Oswald Buddenhagen.
This allows tinyproxy to respond to a request bound to the same
interface that the request came in on. As Oswald explains:
"attached is a patch that adds the BindSame option. it causes
binding an outgoing connection to the ip address of the respective
incoming connection. that way one can simulate an entire proxy farm
with a single instance of tinyproxy on a multi-homed machine."
Cool.
Robert James Kaes [Tue, 27 Apr 2004 18:48:53 +0000 (18:48 +0000)]
(init_stats): Fixed a memset bug, where the structure was not cleared
properly. (The sizeof "struct stat" was being used rather than the
proper "struct stat_s". On my system, "struct stat" is 88 bytes long,
while "struct stat_s" is 20 bytes long. Quite a difference!)
Robert James Kaes [Tue, 27 Apr 2004 18:28:45 +0000 (18:28 +0000)]
These files list all the other files that CVS should ignore. It makes
looking at the CVS status information a little cleaner.
Robert James Kaes [Wed, 18 Feb 2004 20:18:53 +0000 (20:18 +0000)]
Converted the various socket functions to work with both IPv4 and IPv6
addresses.
Robert James Kaes [Wed, 18 Feb 2004 20:17:18 +0000 (20:17 +0000)]
Added two functions:
- get_ip_string() converts a binary network address into either a
dotted-decimal IPv4 address, or a IPv6 hex-string
- full_inet_pton() converts a numeric character string into an IPv6
network address (binary form). It's like the system inet_pton()
function, but it will work with bot IPv4 and IPv6 character
strings.
These functions are required for the conversion to Internet protocol
independence. (Or to put it more clearly: allow tinyproxy to work in
an IPv6 network.)
Robert James Kaes [Tue, 17 Feb 2004 19:49:54 +0000 (19:49 +0000)]
Rewrote the "early history" of the project, and added a section for
"major" addition authors.
Robert James Kaes [Fri, 13 Feb 2004 21:27:42 +0000 (21:27 +0000)]
Removed unnecessary casts (mostly dealing with memory allocation.) I
should never have added them in the first place. They don't really
buy anything, and they can hide bugs.
Robert James Kaes [Wed, 4 Feb 2004 19:57:40 +0000 (19:57 +0000)]
(strip_return_port): Patch from "alex" to strip the port from the host
string and return the port. I cleaned up and added error handling to
the code, but it's basically "alex"'s fix.
(extract_http_url): Rewrote this function to remove all the sscanf()
calls. It's much easier to just split on the path slash (if it's
present) and then strip the user name/password and port from the host
string. Less code, handles more cases!
Robert James Kaes [Mon, 26 Jan 2004 19:19:31 +0000 (19:19 +0000)]
# Updated change log
Robert James Kaes [Mon, 26 Jan 2004 19:11:52 +0000 (19:11 +0000)]
Added reverse proxy support from Kim Holviala. His comments regarding
this addition follow:
The patch implements a simple reverse proxy (with one funky extra
feature). It has all the regular features: mapping remote servers to local
namespace (ReversePath), disabling forward proxying (ReverseOnly) and HTTP
redirect rewriting (ReverseBaseURL).
The funky feature is this: You map Google to /google/ and the Google front
page opens up fine. Type in stuff and click "Google Search" and you'll get
an error from tinyproxy. Reason for this is that Google's form submits to
"/search" which unfortunately bypasses our /google/ mapping (if they'd
submit to "search" without the slash it would have worked ok). Turn on
ReverseMagic and it starts working....
ReverseMagic "hijacks" one cookie which it sends to the client browser.
This cookie contains the current reverse proxy path mapping (in the above
case /google/) so that even if the site uses absolute links the reverse
proxy still knows where to map the request.
And yes, it works. No, I've never seen this done before - I couldn't find
_any_ working OSS reverse proxies, and the commercial ones I've seen try
to parse the page and fix all links (in the above case changing "/search"
to "/google/search"). The problem with modifying the html is that it might
not be parsable (very common) or it might be encoded so that the proxy
can't read it (mod_gzip or likes).
Hope you like that patch. One caveat - I haven't coded with C in like
three years so my code might be a bit messy.... There shouldn't be any
security problems thou, but you never know. I did all the stuff out of my
memory without reading any RFC's, but I tested everything with Moz, Konq,
IE6, Links and Lynx and they all worked fine.
Robert James Kaes [Fri, 17 Oct 2003 16:11:00 +0000 (16:11 +0000)]
Merged in changes from the 1.6.2 release. (Fixes for the filtering code
and the HTML installation script.)
Robert James Kaes [Thu, 14 Aug 2003 15:16:50 +0000 (15:16 +0000)]
Merged in missing $(DESTDIR) in tinyproxy-html-files rules bug fix
from the stable branch.
Robert James Kaes [Thu, 7 Aug 2003 16:50:55 +0000 (16:50 +0000)]
Incorporated patches from Marc Silver to improve the readability and
understandability of the documentation.
Robert James Kaes [Thu, 7 Aug 2003 16:32:12 +0000 (16:32 +0000)]
tinyproxy no longer includes a fall-back regular expression library,
so these files needed to be modified to only use the system's
installed regular expression library.
Robert James Kaes [Thu, 7 Aug 2003 16:29:54 +0000 (16:29 +0000)]
Removed the included regular expression library, since it should come
standard on any reasonably modern system.
Robert James Kaes [Thu, 7 Aug 2003 15:31:20 +0000 (15:31 +0000)]
# Merged in changes from the stable 1.6 branch.
Robert James Kaes [Tue, 5 Aug 2003 21:14:43 +0000 (21:14 +0000)]
Patch from Marc Silver to improve the readability and accuracy of the
tinyproxy man page.
Robert James Kaes [Tue, 5 Aug 2003 16:11:59 +0000 (16:11 +0000)]
# Fixed a comment to actually reflect what the function does.
Robert James Kaes [Tue, 5 Aug 2003 16:11:06 +0000 (16:11 +0000)]
Added the cookie header to the documented list of headers to allow
through.
Robert James Kaes [Fri, 1 Aug 2003 00:14:34 +0000 (00:14 +0000)]
Included patches from Steven Young to use the hashmap functionality to
manage the HTML error pages. It simplifies the source, and also make
the object file smaller. Nice. Also added any casting from (void*)
to ensure that the code compiles using a C++ compiler.
Robert James Kaes [Thu, 31 Jul 2003 23:44:52 +0000 (23:44 +0000)]
Added appropriate casts (void*) casts to allow the code to compile
cleanly using a C++ compiler.
Changed the servers_waiting variable to an unsigned int, since the
number of servers waiting can never be negative, and added an assert()
to ensure this invariant.
Robert James Kaes [Thu, 31 Jul 2003 23:42:51 +0000 (23:42 +0000)]
(debugging_realloc): Removed the assert for the NULL pointer, since
realloc() can take a NULL pointer, as defined by the realloc() man
page.
Fixed the cast in both safefree() macros to compile cleaning using a
C++ compiler.
Robert James Kaes [Thu, 31 Jul 2003 23:41:26 +0000 (23:41 +0000)]
Fixed the cast in both safefree() macros to compile cleaning using a
C++ compiler.
Robert James Kaes [Thu, 31 Jul 2003 23:40:16 +0000 (23:40 +0000)]
# Fixed a preprocessor test (misspelled __cplusplus)
Robert James Kaes [Thu, 31 Jul 2003 23:38:28 +0000 (23:38 +0000)]
Added appropriate casts from (void*) so that the code will compile
cleanly with a C++ compiler. (Tested using GCC 3.3)
Robert James Kaes [Thu, 24 Jul 2003 15:13:00 +0000 (15:13 +0000)]
# Bumped up the version number because of a maintenance release (to fix
a problem with the scanner.c file.
Robert James Kaes [Mon, 14 Jul 2003 17:45:11 +0000 (17:45 +0000)]
# Updated ChangeLog
Robert James Kaes [Mon, 14 Jul 2003 17:43:26 +0000 (17:43 +0000)]
# Bumped up version number.
Robert James Kaes [Mon, 14 Jul 2003 17:42:43 +0000 (17:42 +0000)]
(indicate_http_error): Added calls to va_end() before leaving the
function.
Robert James Kaes [Thu, 26 Jun 2003 18:33:13 +0000 (18:33 +0000)]
# Updated the ChangeLog
Robert James Kaes [Thu, 26 Jun 2003 18:31:16 +0000 (18:31 +0000)]
# Bumped up the version number and made sure to only add the debugging
flags to flex if it really is flex.
Robert James Kaes [Thu, 26 Jun 2003 18:26:10 +0000 (18:26 +0000)]
# Removed the debugging information.
Robert James Kaes [Thu, 26 Jun 2003 18:23:01 +0000 (18:23 +0000)]
# Added debugging flags for the flex scanner.
Robert James Kaes [Thu, 26 Jun 2003 18:19:57 +0000 (18:19 +0000)]
(upstream_add): Rewrote the function to actually handle the various
types of upstream configurations correctly. Hopefully, the code is
also a little clearer in it's implementation.
Robert James Kaes [Thu, 26 Jun 2003 18:17:09 +0000 (18:17 +0000)]
# Removed the STRING_ADDRESS token since it was conflicting with the
IDENTIFIER directive and also the keyword directives.
Robert James Kaes [Thu, 26 Jun 2003 18:16:09 +0000 (18:16 +0000)]
Modified the patterns to allow the new upstream directives to work as
defined in the tinyproxy.conf documentation.
Robert James Kaes [Thu, 26 Jun 2003 18:14:13 +0000 (18:14 +0000)]
(debugging_free): Rather than assert on a NULL pointer, log the NULL
pointer and return.
Robert James Kaes [Wed, 25 Jun 2003 18:23:11 +0000 (18:23 +0000)]
# Bumped up the version number.
Robert James Kaes [Wed, 25 Jun 2003 18:22:37 +0000 (18:22 +0000)]
# Updated the changelog
Robert James Kaes [Wed, 25 Jun 2003 18:20:22 +0000 (18:20 +0000)]
Added a test to define INADDR_NONE if it's not present. For example,
SunOS (solaris 2.8) does not include this define. [Thank to Ben
Hartshorne for pointing this out.]
Robert James Kaes [Wed, 25 Jun 2003 18:18:19 +0000 (18:18 +0000)]
Changed the calls to "ps" and "grep" to use a more portable syntax.
Robert James Kaes [Mon, 23 Jun 2003 21:15:04 +0000 (21:15 +0000)]
# Bumped up the version number.