aboutsummaryrefslogtreecommitdiff
path: root/src/or/connection.c
Commit message (Expand)AuthorAge
...
| * | | Small tweaks to 2841 code••• - const-ify some transport_t pointers - Remove a vestigial argument to parse_bridge_line - Make it compile without warnings on my laptop with --enable-gcc-warnings Nick Mathewson2011-07-02
| * | | Trivial code tweaks and documentation updates.George Kadianakis2011-06-28
| * | | Revised how we handle ClientTransportPlugin and Bridge lines.•••Multiple Bridge lines can point to the same one ClientTransportPlugin line, and we can have multiple ClientTransportPlugin lines in our configuration file that don't match with a bridge. We also issue a warning when we have a Bridge line with a pluggable transport but we can't match it to a ClientTransportPlugin line. George Kadianakis2011-06-22
| * | | Tweaked connection{.c,.h,_or.c} based on nick's comments.•••* Tweaked doxygen comments. * Changed returns of get_proxy_addrport(). * Ran make check-spaces. * Various small code tweaks. George Kadianakis2011-06-21
| * | | Fixes small bugs.George Kadianakis2011-06-14
| * | | This commit is an attempt to beautify the previous commit.•••It creates some helper functions that return the proxy type, proxy addr/port, etc. George Kadianakis2011-06-14
| * | | Our warning now is much more specific, mentioning proxy type/addr/port.•••Not included in the previous commit, because the implementation is ugly; I see no other way of doing this though. George Kadianakis2011-06-14
| * | | We now warn the user if a proxy server is not up when we try to connect with it.George Kadianakis2011-06-14
* | | | Avoid double-free in bufferevent read/write cbs•••Fixes bug 3404; bugfix on 0.2.3.1-alpha. Nick Mathewson2011-07-07
* | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-07-01
|\ \ \ \ | | |_|/ | |/| |
| * | | Merge remote-tracking branch 'origin/maint-0.2.1' into maint-0.2.2Nick Mathewson2011-07-01
| |\ \ \
| | * | | Use strlcpy in create_unix_sockaddr()•••Using strncpy meant that if listenaddress were ever >= sizeof(sockaddr_un.sun_path), we would fail to nul-terminate sun_path. This isn't a big deal: we never read sun_path, and the kernel is smart enough to reject the sockaddr_un if it isn't nul-terminated. Nonetheless, it's a dumb failure mode. Instead, we should reject addresses that don't fit in sockaddr_un.sun_path. Coverity found this; it's CID 428. Bugfix on 0.2.0.3-alpha. Nick Mathewson2011-07-01
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-06-22
|\| | | |
| * | | | Fix minor comment issuesRobert Ransom2011-06-22
* | | | | Add, use a bufferevent-safe connection_flush()•••A couple of places in control.c were using connection_handle_write() to flush important stuff (the response to a SIGNAL command, an ERR-level status event) before Tor went down. But connection_handle_write() isn't meaningful for bufferevents, so we'd crash. This patch adds a new connection_flush() that works for all connection backends, and makes control.c use that instead. Fix for bug 3367; bugfix on 0.2.3.1-alpha. Nick Mathewson2011-06-21
* | | | | Make the get_options() return const•••This lets us make a lot of other stuff const, allows the compiler to generate (slightly) better code, and will make me get slightly fewer patches from folks who stick mutable stuff into or_options_t. const: because not every input is an output! Nick Mathewson2011-06-14
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-06-14
|\| | | | | |_|/ / |/| | |
| * | | Make ControlSocketsGroupWritable work with User.•••Original message from bug3393: check_private_dir() to ensure that ControlSocketsGroupWritable is safe to use. Unfortunately, check_private_dir() only checks against the currently running user… which can be root until privileges are dropped to the user and group configured by the User config option. The attached patch fixes the issue by adding a new effective_user argument to check_private_dir() and updating the callers. It might not be the best way to fix the issue, but it did in my tests. (Code by lunar; changelog by nickm) Jérémy Bobbio2011-06-14
* | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/or/dirserv.c Nick Mathewson2011-06-02
|\| | |
| * | | Fix unit test failure in dir/formats•••options->DirPort is 0 in the unit tests, so router_get_advertised_dir_port() would return 0 so we wouldn't pick a dirport. This isn't what we want for the unit tests. Fixes bug introduced in 95ac3ea5946. Sebastian Hahn2011-06-02
* | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-05-30
|\| | |
| * | | Merge branch 'bug3216_v2' into maint-0.2.2Nick Mathewson2011-05-30
| |\ \ \
| | * | | Don't try to build descriptors when router_get_advertised_or_port()==0•••The previous attempt was incomplete: it told us not to publish a descriptor, but didn't stop us from generating one. Now we treat an absent OR port the same as not knowing our address. (This means that when we _do_ get an OR port, we need to mark the descriptor dirty.) More attempt to fix bug3216. Nick Mathewson2011-05-24
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/common/compat.c src/or/main.c Nick Mathewson2011-05-30
|\| | | |
| * | | | Merge remote-tracking branch 'public/bug3270' into maint-0.2.2Nick Mathewson2011-05-30
| |\ \ \ \ | | |/ / / | |/| | |
| | * | | Use a 64-bit type to hold sockets on win64.•••On win64, sockets are of type UINT_PTR; on win32 they're u_int; elsewhere they're int. The correct windows way to check a socket for being set is to compare it with INVALID_SOCKET; elsewhere you see if it is negative. On Libevent 2, all callbacks take sockets as evutil_socket_t; we've been passing them int. This patch should fix compilation and correctness when built for 64-bit windows. Fixes bug 3270. Nick Mathewson2011-05-23
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/common/Makefile.am src/or/control.c Nick Mathewson2011-05-23
|\| | | |
| * | | | Merge branch 'feature3049-v2' into maint-0.2.2•••Conflicts: src/common/Makefile.am Nick Mathewson2011-05-23
| |\ \ \ \ | | |/ / / | |/| | |
| | * | | Split control connection cleanup out of connection_freeRobert Ransom2011-05-20
* | | | | Merge branch 'maint-0.2.2'Roger Dingledine2011-05-20
|\| | | |
| * | | | Fix a compile warning on OSX 10.6Sebastian Hahn2011-05-20
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-05-17
|\| | | |
| * | | | Fix bug2752 : 48-char HTTPProxyAuthenticator limitation•••Bumped the char maximum to 512 for HTTPProxyAuthenticator & HTTPSProxyAuthenticator. Now stripping all '\n' after base64 encoding in alloc_http_authenticator. Michael Yakubovich2011-05-16
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/or/connection.c Nick Mathewson2011-05-16
|\| | | |
| * | | | Merge remote-tracking branch 'public/bug2850' into maint-0.2.2•••Fixed a trivial conflict where this and the ControlSocketGroupWritable code both added different functions to the same part of connection.c. Conflicts: src/or/connection.c Nick Mathewson2011-05-16
| |\ \ \ \
| | * | | | Set SO_REUSEADDR on all sockets, not just listeners•••See bug 2850 for rationale: it appears that on some busy exits, the OS decides that every single port is now unusable because they have been all used too recently. Nick Mathewson2011-05-03
* | | | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-05-15
|\| | | | |
| * | | | | Check permissions on the directory holding a control socketNick Mathewson2011-05-15
| * | | | | Add a function to pull off the final component of a pathNick Mathewson2011-05-15
| * | | | | Clean up the 2972 implementation a littleSebastian Hahn2011-05-15
| * | | | | Add UnixSocketsGroupWritable config flag•••When running a system-wide instance of Tor on Unix-like systems, having a ControlSocket is a quite handy mechanism to access Tor control channel. But it would be easier if access to the Unix domain socket can be granted by making control users members of the group running the Tor process. This change introduces a UnixSocketsGroupWritable option, which will create Unix domain sockets (and thus ControlSocket) 'g+rw'. This allows ControlSocket to offer same access control measures than ControlPort+CookieAuthFileGroupReadable. See <http://bugs.debian.org/552556> for more details. Jérémy Bobbio2011-05-15
* | | | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/or/config.c src/or/dirserv.c src/or/or.h Nick Mathewson2011-05-13
|\| | | | |
| * | | | | Write automatically-chosen control ports to a file.Nick Mathewson2011-05-13
| * | | | | Teach retry_listener about "auto" ports.•••Otherwise, it will just immediately close any port declared with "auto" on the grounds that it wasn't configured. Now, it will allow "auto" to match any port. This means FWIW if you configure a socks port with SocksPort 9999 and then transition to SocksPort auto, the original socksport will not get closed and reopened. I'm considering this a feature. Nick Mathewson2011-05-13
| * | | | | "(Socks|Control|etc)Port auto" now tells Tor to open an arbitrary port•••This is the major part of the implementation for trac issue 3076. Nick Mathewson2011-05-13
* | | | | | Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson2011-05-12
|\| | | | |
| * | | | | Fixes ticket #2503•••HTTPS error code 403 is now reported as: "The https proxy refused to allow connection". Used a switch statement for additional error codes to be explained in the future. mikey992011-05-12
| | |/ / / | |/| | |
* | | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/or/connection.c Nick Mathewson2011-05-09
|\| | | |
| * | | | Remove a duplicated line, found by clangSebastian Hahn2011-05-09
| |/ / /
* | | | Merge remote-tracking branch 'origin/maint-0.2.2'•••Conflicts: src/common/address.c src/common/compat_libevent.c src/common/memarea.c src/common/util.h src/or/buffers.c src/or/circuitbuild.c src/or/circuituse.c src/or/connection.c src/or/directory.c src/or/networkstatus.c src/or/or.h src/or/routerlist.c Nick Mathewson2011-04-07
|\| | |