aboutsummaryrefslogtreecommitdiff
path: root/src/or/eventdns.c
Commit message (Collapse)AuthorAge
* Triage the XXX022 and XXX021 comments remaining in the codeNick Mathewson2011-03-25
| | | | | Remove some, postpone others, leave some alone. Now the only remaining XXX022s are ones that seem important to fix or investigate.
* Fix compile wanrings revealed by gcc 4.5 on mingwSebastian Hahn2010-12-27
|
* Consistency issues in load_windows_system_library patch. Thanks SebastianNick Mathewson2010-09-24
|
* Use load_windows_system_library in place of LoadLibraryNick Mathewson2010-09-21
|
* Attempt to fix compilation on WindowsSebastian Hahn2010-09-19
| | | | | | | Our attempt to make compilation work on old versions of Windows again while keeping wince compatibility broke the build for Win2k+. helix reports this patch fixes the issue for WinXP. Bugfix on 0.2.2.15-alpha; related to bug 1797.
* Make the windows build succeed with or without -DUNICODE enabled.Nick Mathewson2010-08-20
| | | | | | | | | | | | | | This should keep WinCE working (unicode always-on) and get Win98 working again (unicode never-on). There are two places where we explicitly use ASCII-only APIs, still: in ntmain.c and in the unit tests. This patch also fixes a bug in windoes tor_listdir that would cause the first file to be listed an arbitrary number of times that was also introduced with WinCE support. Should fix bug 1797.
* Port Tor to work on Windows CEvalerino2010-05-24
| | | | | | | | | | | | Most of the changes here are switches to use APIs available on Windows CE. The most pervasive change is that Windows CE only provides the wide-character ("FooW") variants of most of the windows function, and doesn't support the older ASCII verions at all. This patch will require use of the wcecompat library to get working versions of the posix-style fd-based file IO functions. [commit message by nickm]
* Try to untangle the logic in server_port_flushNick Mathewson2010-01-25
| | | | | | | | | | | It's a bit confusing to have a loop where another function, confusingly named "*_free", is responsible for advancing the loop variable (or rather, for altering a structure so that the next time the loop variable's initializer is evaluated it evaluates to something different.) Not only has this confused people: it's also confused coverity scan. Let's fix that.
* Don't use OutboundBindAddress to connect to localhostNick Mathewson2010-01-20
| | | | | | | | | | | | | | | The OutboundBindAddress option is useful for making sure that all of your outbond connections use a given interface. But when connecting to 127.0.0.1 (or ::1 even) it's important to actually have the connection come _from_ localhost, since lots of programs running on localhost use the source address to authenticate that the connection is really coming from the same host. Our old code always bound to OutboundBindAddress, whether connecting to localhost or not. This would potentially break DNS servers on localhost, and socks proxies on localhost. This patch changes the behavior so that we only look at OutboundBindAddress when connecting to a non-loopback address.
* Include util.h and log.h as relative paths.Nathan Freitas2009-09-29
| | | | | | | This shouldn't be necessary, but apparently the Android cross-compiler doesn't respect -I as well as it should. (-I is supposed to add to the *front* of the search path. Android's gcc wrapper apparently likes to add to the end. This is broken, but we need to work around it.)
* Merge commit 'origin/maint-0.2.1'Nick Mathewson2009-09-01
|\
| * Fix compile warnings on Snow LeopardSebastian Hahn2009-09-01
| | | | | | | | Big thanks to nickm and arma for helping me with this!
* | Switch over to tor_strtok_r instead of strtok_r.Mike Perry2009-08-09
| |
* | Merge commit 'origin/maint-0.2.1'Nick Mathewson2009-06-30
|\|
| * Have eventdns set the "truncated" bit correctly.Nick Mathewson2009-06-30
| | | | | | | | | | Fixed bug 1022; This isn't actually a live bug in Tor, since in Tor we never generate large DNS replies.
* | Update Tor to use Libevent 2.0 APIs when available.Nick Mathewson2009-06-12
| | | | | | | | | | | | | | | | | | | | This patch adds a new compat_libevent.[ch] set of files, and moves our Libevent compatibility and utilitity functions there. We build them into a separate .a so that nothing else in src/commmon depends on Libevent (partially fixing bug 507). Also, do not use our own built-in evdns copy when we have Libevent 2.0, whose evdns is finally good enough (thus fixing Bug 920).
* | Merge commit 'origin/maint-0.2.1' into master.Nick Mathewson2009-05-25
|\| | | | | | | | | | | | | | | Conflicts: ChangeLog configure.in contrib/tor-mingw.nsi.in src/win32/orconfig.h
| * Use tor_socket_strerror in eventdns.c. Fixes bug 987.Nick Mathewson2009-05-25
| |
* | Improved bug-957 fix for 0.2.2.Nick Mathewson2009-05-22
|/ | | | | | | | | Really, our idiocy was that we were calling event_set() on the same event more than once, which sometimes led to us calling event_set() on an event that was already inserted, thus making it look uninserted. With this patch, we just initialize the timeout events when we create the requests and nameservers, and we don't need to worry about double-add and double-del cases at all.
* Finish up the 0.2.1 version of the bug 957 fix.Nick Mathewson2009-05-22
| | | | | | Basically, all this means is downgrading our warning messages to debug messages, since the bug workaround code here is adequate to stop the bug.
* Possible fix for crash bug related to event timeouts. [Bug 957]Nick Mathewson2009-05-18
| | | | | | | | | | | | | | If we ever add an event, then set it, then add it again, there will be now two pointers to the event in the event base. If we delete one and free it, the first pointer will still be there, and possibly cause a crash later. This patch adds detection for this case to the code paths in eventdns.c, and works around it. If the warning message ever displays, then a cleverer fix is in order. {I am not too confident that this *is* the fix, since bug 957 is very tricky. If it is, it is a bugfix on 0.2.0.}
* Fix one case of bug 929.Nick Mathewson2009-02-23
| | | | svn:r18683
* Add some debugging code to try to catch the likely cause of bug 929Nick Mathewson2009-02-23
| | | | svn:r18682
* Revert an erroneous part of the non-fix to bug 326, and add comments to ↵Nick Mathewson2009-02-11
| | | | | | explain why it was erroneous. svn:r18494
* I worry that the CLEAR() macro in eventdns.c is hiding bugs. That is sad, ↵Nick Mathewson2009-02-11
| | | | | | because it was meant to make them more detectable. Change it to change stuff to garbage rather than to 0. If no bugs turn up, we can remove it in 0.2.2.x svn:r18493
* Port some mostly cosmetic eventdns changes from libeventNick Mathewson2009-02-11
| | | | svn:r18492
* Remove some deadcode and use tor_inet_aton uniformly.Nick Mathewson2009-02-09
| | | | svn:r18422
* Fix a remote-crash bug. This will need a patch release.Nick Mathewson2009-02-09
| | | | svn:r18421
* Fix a race condition on nameserver reconfiguration.Nick Mathewson2009-01-28
| | | | | | | | | | | | | | | | | | | | This resolves bug 526, wherein we would crash if the following events occurred in this order: A: We're an OR, and one of our nameservers goes down. B: We launch a probe to it to see if it's up again. (We do this hourly in steady-state.) C: Before the probe finishes, we reconfigure our nameservers, usually because we got a SIGHUP and the resolve.conf file changed. D: The probe reply comes back, or times out. (There is a five-second window for this, after B has happens). IOW, if one of our nameservers is down and our nameserver configuration has changed, there were 5 seconds per hour where HUPing the server was unsafe. Bugfix on 0.1.2.1-alpha. Too obscure to backport. svn:r18306
* Fix a compile warning on win32.Nick Mathewson2009-01-14
| | | | svn:r18099
* Make outgoing DNS requests respect OutboundBindAddress.Nick Mathewson2009-01-06
| | | | | | Fixes the bug part of bug 789. svn:r17983
* Remove svn $Id$s from our source, and remove tor --version --version.Nick Mathewson2009-01-04
| | | | | | | | The subversion $Id$ fields made every commit force a rebuild of whatever file got committed. They were not actually useful for telling the version of Tor files in the wild. svn:r17867
* Only set sin_len/sin6_len when they exist.Nick Mathewson2009-01-02
| | | | svn:r17851
* Try harder to make sure we zero-out the extraneous sockaddr fields and that ↵Nick Mathewson2009-01-02
| | | | | | we set sockaddr_len. Conceivably a backport candidate, though nothing has yet been sen to break. svn:r17849
* Indeed, arma was right. There was one ntohl too many in debug_ntop in ↵Nick Mathewson2008-12-30
| | | | | | eventdns.c svn:r17826
* point out the bug location to nick. unless i'm wrong.Roger Dingledine2008-12-30
| | | | svn:r17825
* More compilation tweaks on Android: fix two clear errors in our code that ↵Nick Mathewson2008-12-29
| | | | | | apparently the compiler cares about there. svn:r17808
* Move in-addr.arpa parsing and generation into address.c, and simplify the ↵Nick Mathewson2008-12-19
| | | | | | code that does it elsewhere. Incidentally, this lets exit servers answer requests for ip6.arpa addresses. svn:r17707
* Do not leak the DNS server port structure.Nick Mathewson2008-12-18
| | | | svn:r17680
* Resolve many DOCDOCs.Nick Mathewson2008-12-17
| | | | svn:r17662
* Fix a logic error that would automatically reject all but the first ↵Nick Mathewson2008-12-10
| | | | | | configured DNS server. Bugfix on 0.2.1.5-alpha. Possible fix for part of 813/868. Spotted by coderman svn:r17569
* Consider GetNetworkParams() nameserver parsing to have suceeded if even one ↵Nick Mathewson2008-11-22
| | | | | | nameserver can be added. Log more useful info about what exactly is failing when we fail to add a nameserver. svn:r17368
* Implement the 0x20-hack to make DNS poisoning harder against us, especially ↵Nick Mathewson2008-10-29
| | | | | | when resolving large names. Add a cfg option to disable it, since apparently 3/10 of a percent of servers get it wrong. svn:r17171
* fix typo in log entryRoger Dingledine2008-10-08
| | | | svn:r17050
* Oops; we need to make sure that DNS request names are matched in the ↵Nick Mathewson2008-09-22
| | | | | | _questions_ section of the replies. Rejecting answers whether the _answers_ section did not match made us reject A records waiting at the end of a CNAME record. Bug 823. svn:r16933
* Fix mingw build with --enable-gcc-warnings set.Nick Mathewson2008-09-04
| | | | svn:r16759
* Oops; set address families on nameservers.Nick Mathewson2008-08-27
| | | | svn:r16674
* Oops. Linux has no sa_len field.Nick Mathewson2008-08-22
| | | | svn:r16627
* r17846@tombo: nickm | 2008-08-22 11:54:00 -0400Nick Mathewson2008-08-22
| | | | | | | Make dns resolver code more robust: handle nameservers with IPv6 addresses, make sure names in replies match requested names, make sure origin address of reply matches the address we asked. svn:r16621
* r14410@tombo: nickm | 2008-02-23 16:51:46 -0500Nick Mathewson2008-02-24
| | | | | | | Fix the last of the -Wshorten-64-to-32 warnings. svn:r13696