Age | Commit message (Collapse) | Author | Files | Lines | |
---|---|---|---|---|---|
2013-11-09 | sock: factor listening on one socket out of the gai-result-loop in listen_sock() | Michael Adam | 1 | -48/+62 | |
for clarity of the code Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: in listen_sock(), move variable for setsockopt() into scope | Michael Adam | 1 | -1/+1 | |
Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: log each result of getaddrinfo() in listen_sock() | Michael Adam | 1 | -0/+14 | |
Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: in listen_sock(), add a log message for when bind() has failed | Michael Adam | 1 | -0/+2 | |
Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: in listen_sock(), detect and log failure to call setsockopt() | Michael Adam | 1 | -2/+10 | |
Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: in listen_sock(), add debug message when socket() call failed. | Michael Adam | 1 | -1/+5 | |
Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: move listen() into the getaddrinfo result loop in listen_sock() | Michael Adam | 1 | -22/+22 | |
This also reverses the exit logic of the loop. It prepares listening on multiple addresses. Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | child: use a list of listen_fds instead of one single listenfd. | Michael Adam | 1 | -2/+5 | |
This prepares listenting on multiple sockets, which will be ussed to fix listening on the wildcard (listen on both ipv6 and ipv4) and help add the support for multiple Listen statements in the config Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock: add addr argument to listen_sock() | Michael Adam | 1 | -2/+2 | |
instead of using config.ipAddr internally. This is in preparation to make it possible to call it for multiple addresses. Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2013-11-09 | sock/child: remove global variable addrlen. | Michael Adam | 1 | -8/+3 | |
This changes listen_sock() to not return the addrlen of the used address from getaddrinfo call to the caller, stored in global addrlen in child.c. This was only used to be able to allocate enough space for the arguments to the later accept call depending on whether IPv4 or IPv6 is used. This removes the need to pass this info by always allocating sizeof(struct sockaddr_storage) instead, which is enough to carry both sockaddr_in and sockaddr_in6. Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2010-03-09 | Revert "Revert "Pass address family when binding to outgoing socket"" | Mukund Sivaraman | 1 | -4/+7 | |
This reverts commit 70885bf029a6f857684f99618f867b5c47767ae0. It looks like bug #69 needs this fix after all. | |||||
2010-03-03 | Use AI_PASSIVE flag to make tinyproxy listen on wildcard interface | Mukund Sivaraman | 1 | -0/+1 | |
Signed-off-by: Michael Adam <obnox@samba.org> | |||||
2010-01-21 | Revert "Pass address family when binding to outgoing socket" | Mukund Sivaraman | 1 | -7/+4 | |
This reverts commit 65ef313cc4601b5ad84d1da1800ff38bf8f046a9. This patch could've been the reason for BB#69. | |||||
2010-01-10 | Pass address family when binding to outgoing socket | Mukund Sivaraman | 1 | -4/+7 | |
2009-12-08 | Fix restarting of tinyproxy: call setsockopt with REUSEADDR _before_ calling ↵ | Michael Adam | 1 | -3/+4 | |
bind Somehow this got moved too far down in the ipv6 changes. Thanks to Mathew Mrosko for helping me debugging this. Michael | |||||
2009-12-07 | Move definition of "struct config_s" from main.h to conf.h | Michael Adam | 1 | -0/+1 | |
Michael | |||||
2009-11-17 | Use snprintf() with size of the portstr buf | Mukund Sivaraman | 1 | -2/+2 | |
2009-11-09 | Close listenfd upon errors | Mukund Sivaraman | 1 | -0/+3 | |
2009-11-09 | Add IPV6 support to listen_sock() | Mukund Sivaraman | 1 | -14/+34 | |
2009-09-15 | Indent code to Tinyproxy coding style | Mukund Sivaraman | 1 | -170/+150 | |
The modified files were indented with GNU indent using the following command: indent -npro -kr -i8 -ts8 -sob -l80 -ss -cs -cp1 -bs -nlps -nprs -pcs \ -saf -sai -saw -sc -cdw -ce -nut -il0 No other changes of any sort were made. | |||||
2009-08-07 | Rename tinyproxy.[ch] to main.[ch] | Mukund Sivaraman | 1 | -1/+1 | |
2008-12-08 | Convert tabs to spaces | Mukund Sivaraman | 1 | -25/+25 | |
2008-12-01 | Reformat code to GNU coding style | Mukund Sivaraman | 1 | -153/+167 | |
This is a commit which simply ran all C source code files through GNU indent. No other modifications were made. | |||||
2008-05-24 | Updated copyright, license notices in source code | Mukund Sivaraman | 1 | -16/+20 | |
The notices have been changed to a more GNU look. Documentation comments have been separated from the copyright header. I've tried to keep all copyright notices intact. Some author contact details have been updated. | |||||
2008-03-13 | Corrected datatype of salen to fix compiler warning | Mukund Sivaraman | 1 | -2/+2 | |
2005-08-15 | * [Indent] Ran Source Through indent | Robert James Kaes | 1 | -150/+152 | |
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. | |||||
2005-07-12 | * Specified Correct typedef in getsock_ip() | Robert James Kaes | 1 | -2/+2 | |
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. | |||||
2004-04-27 | Added the "BindSame" configure directive from Oswald Buddenhagen. | Robert James Kaes | 1 | -10/+38 | |
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. | |||||
2004-02-18 | Converted the various socket functions to work with both IPv4 and IPv6 | Robert James Kaes | 1 | -86/+84 | |
addresses. | |||||
2002-10-03 | #Style formatting change. | Robert James Kaes | 1 | -2/+2 | |
2002-05-31 | (getpeer_information): Fixed a problem retrieving the FQDN of a host because ↵ | Robert James Kaes | 1 | -3/+4 | |
I was passing in an incorrect parameter to gethostbyaddr(). D'oh. | |||||
2002-05-27 | (opensock): Changed a comment around to better state what the code is ↵ | Robert James Kaes | 1 | -2/+2 | |
actually doing. | |||||
2002-05-26 | Removed the DNS API calls and replaced them with the standard | Robert James Kaes | 1 | -24/+15 | |
gethostbyname() and gethostbyaddr() functions. This is possible because tinyproxy now uses a standard pre-forked() method. | |||||
2002-05-24 | Fixed some spelling mistakes, and removed the getpeer_ip() and | Robert James Kaes | 1 | -67/+1 | |
getpeer_string() functions as they've been replaced by the getpeer_information() function. | |||||
2002-05-23 | Changed the lookup_domain() function to use the new "dnsserver" API. | Robert James Kaes | 1 | -255/+67 | |
Also moved safe_write(), safe_read(), readline(), and write_message() functions into their own file. | |||||
2002-04-24 | bind_address has been moved inside the config structure. Fixed up a | Robert James Kaes | 1 | -5/+6 | |
problem where "data" was being freed even if it had not been allocated (because of an error condition.) | |||||
2002-04-22 | The "Bind" directive sets a binding address which the outgoing connections | Robert James Kaes | 1 | -4/+4 | |
will use. | |||||
2002-04-18 | Whoops. The previous include only had the code conditionally removed. | Robert James Kaes | 1 | -9/+1 | |
Remove for real this time. | |||||
2002-04-18 | Removed the call to inet_aton() since the gethostbyname() function handles | Robert James Kaes | 1 | -1/+3 | |
the dotted-decimal case itself. | |||||
2002-04-18 | Removed the call to hstrerror() in the getpeer_string() function. It's | Robert James Kaes | 1 | -3/+2 | |
not available on all machines. | |||||
2002-04-17 | Removed the LOOKUP_LOCK() and LOOKUP_UNLOCK() macros since I believe I | Robert James Kaes | 1 | -12/+4 | |
need locking around both gethostbyname() and gethostbyaddr() at the same time. | |||||
2002-04-16 | Tightened the lookup_domain() function. | Robert James Kaes | 1 | -3/+2 | |
2002-04-15 | Added a test to make sure the "whole_buffer" could be allocated. | Robert James Kaes | 1 | -3/+5 | |
2002-04-13 | Added additional error handling for the bind() and listen() system calls | Robert James Kaes | 1 | -3/+11 | |
when setting up the listening socket. | |||||
2002-04-13 | Modified the opensock() function to respect the Listen directive. If it's | Robert James Kaes | 1 | -1/+17 | |
set, bind all outgoing addresses to this local address. | |||||
2001-12-24 | Added the write_message() function (from reqs.c) | Robert James Kaes | 1 | -1/+53 | |
2001-12-19 | Changed the calls to write() to send() so that we can use send(..., | Robert James Kaes | 1 | -2/+2 | |
MSG_NOSIGNAL) and not get signals sent to the process. (easier for debugging and the system doesn't need to worry about signals.) | |||||
2001-12-17 | Added the assert() calls to safe_write() to make sure the arguments are | Robert James Kaes | 1 | -1/+5 | |
sane. | |||||
2001-12-15 | Changed safe_write() to fully send all the data in the buffer it was | Robert James Kaes | 1 | -8/+24 | |
passed. Also safe_write() and safe_read() now use char pointer buffers rather than the void pointer style. | |||||
2001-12-15 | Added the host name lookup code (which use to be in the DNS caching | Robert James Kaes | 1 | -3/+46 | |
system.) |