| Commit message (Expand) | Author | Age |
* | tor_accept_socket() should take tor_addr_t for listener arg•••Fixes bug 4535; bugfix on 0.2.2.28-beta; found by "troll_un"
| Nick Mathewson | 2011-12-02 |
* | Looks like Windows version 6.2 will be Windows 8•••Thanks to funkstar for the report
| Sebastian Hahn | 2011-10-01 |
* | Merge remote-tracking branch 'origin/maint-0.2.1' into maint-0.2.2 | Nick Mathewson | 2011-07-01 |
|\ |
|
| * | Fix insanely large stack_allocation in log_credential_status•••I'm not one to insist on C's miserly stack limits, but allocating a
256K array on the stack is too much even for me.
Bugfix on 0.2.1.7-alpha. Found by coverity. Fixes CID # 450.
| Nick Mathewson | 2011-07-01 |
* | | Fix minor comment issues | Robert Ransom | 2011-06-22 |
* | | 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 Mathewson | 2011-05-23 |
* | | Fix up some comment issues spotted by rransom | Nick Mathewson | 2011-05-15 |
* | | Add a function to pull off the final component of a path | Nick Mathewson | 2011-05-15 |
* | | Merge remote-tracking branch 'public/3122_memcmp_squashed' into bug3122_memcm...•••Conflicts throughout. All resolved in favor of taking HEAD and
adding tor_mem* or fast_mem* ops as appropriate.
src/common/Makefile.am
src/or/circuitbuild.c
src/or/directory.c
src/or/dirserv.c
src/or/dirvote.c
src/or/networkstatus.c
src/or/rendclient.c
src/or/rendservice.c
src/or/router.c
src/or/routerlist.c
src/or/routerparse.c
src/or/test.c
| Nick Mathewson | 2011-05-11 |
|\| |
|
| * | Hand-conversion and audit phase of memcmp transition•••Here I looked at the results of the automated conversion and cleaned
them up as follows:
If there was a tor_memcmp or tor_memeq that was in fact "safe"[*] I
changed it to a fast_memcmp or fast_memeq.
Otherwise if there was a tor_memcmp that could turn into a
tor_memneq or tor_memeq, I converted it.
This wants close attention.
[*] I'm erring on the side of caution here, and leaving some things
as tor_memcmp that could in my opinion use the data-dependent
fast_memcmp variant.
| Nick Mathewson | 2011-05-11 |
| * | Automated conversion of memcmp to tor_memcmp/tor_mem[n]eq•••This commit is _exactly_ the result of
perl -i -pe 's/\bmemcmp\(/tor_memcmp\(/g' src/*/*.[ch]
perl -i -pe 's/\!\s*tor_memcmp\(/tor_memeq\(/g' src/*/*.[ch]
perl -i -pe 's/0\s*==\s*tor_memcmp\(/tor_memeq\(/g' src/*/*.[ch]
perl -i -pe 's/0\s*!=\s*tor_memcmp\(/tor_memneq\(/g' src/*/*.[ch]
git checkout src/common/di_ops.[ch]
git checkout src/or/test.c
git checkout src/common/test.h
| Nick Mathewson | 2011-05-11 |
* | | Fix up some check-spaces issues | Nick Mathewson | 2011-05-05 |
* | | Correct the logic from f14754fbd for tor_gmtime_r | John Brooks | 2011-04-28 |
* | | Detect and handle NULL returns from (gm/local)time_r•••These functions can return NULL for otherwise-valid values of
time_t. Notably, the glibc gmtime manpage says it can return NULL
if the year if greater than INT_MAX, and the windows MSDN gmtime
page says it can return NULL for negative time_t values.
Also, our formatting code is not guaranteed to correctly handle
years after 9999 CE.
This patch tries to correct this by detecting NULL values from
gmtime/localtime_r, and trying to clip them to a reasonable end of
the scale. If they are in the middle of the scale, we call it a
downright error.
Arguably, it's a bug to get out-of-bounds dates like this to begin
with. But we've had bugs of this kind in the past, and warning when
we see a bug is much kinder than doing a NULL-pointer dereference.
Boboper found this one too.
| Nick Mathewson | 2011-04-28 |
* | | Doxygen documentation for about 100 things that didn't have any•••About 860 doxygen-less things remain in 0.2.2
| Nick Mathewson | 2011-03-16 |
* | | Windows has EACCES, not EACCESS•••Once again spotted by mobmix
Also add a changes file for the fix
| Sebastian Hahn | 2011-02-11 |
* | | Locking failures on windows are indicated by EACCES•••Patch our implementation of tor_lockfile_lock() to handle this case
correctly. Also add a note that blocking behaviour differs from windows
to *nix. Fixes bug 2504, issue pointed out by mobmix.
| Sebastian Hahn | 2011-02-08 |
* | | Merge remote branch 'origin/maint-0.2.1' into maint-0.2.2•••Conflicts:
src/common/test.h
src/or/test.c
| Nick Mathewson | 2011-01-03 |
|\| |
|
| * | Bump copyright statements to 2011 | Nick Mathewson | 2011-01-03 |
* | | Merge remote branch fix_security_bug_021 into fix_security_bug_022•••Conflicts:
src/common/memarea.c
src/or/or.h
src/or/rendclient.c
| Nick Mathewson | 2010-12-15 |
|\| |
|
| * | Make payloads into uint8_t.•••This will avoid some signed/unsigned assignment-related bugs.
| Nick Mathewson | 2010-12-15 |
| * | Have all of our allocation functions and a few others check for underflow•••It's all too easy in C to convert an unsigned value to a signed one,
which will (on all modern computers) give you a huge signed value. If
you have a size_t value of size greater than SSIZE_T_MAX, that is way
likelier to be an underflow than it is to be an actual request for
more than 2gb of memory in one go. (There's nothing in Tor that
should be trying to allocate >2gb chunks.)
| Nick Mathewson | 2010-12-13 |
* | | Add wrappers function for libc random()•••On windows, it's called something different.
| Nick Mathewson | 2010-11-29 |
* | | Make the windows build succeed with or without -DUNICODE enabled.•••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.
| Nick Mathewson | 2010-08-20 |
* | | Merge commit 'sebastian/mlockall' | Nick Mathewson | 2010-08-03 |
|\ \ |
|
| * | | Remove the request for current memlock limits•••The getrlimit call didn't have any effect. Also make some logging
less verbose on default log level, and refactor a bit.
| Sebastian Hahn | 2010-02-28 |
* | | | Rename log.h to torlog.h•••This should make us conflict less with system files named "log.h".
Yes, we shouldn't have been conflicting with those anyway, but some
people's compilers act very oddly.
The actual change was done with one "git mv", by editing
Makefile.am, and running
find . -name '*.[ch]' | xargs perl -i -pe 'if (/^#include.*\Wlog.h/) {s/log.h/torlog.h/; }'
| Nick Mathewson | 2010-07-09 |
* | | | Make pointer types correct in WinCE patch | Nick Mathewson | 2010-05-24 |
* | | | moved wince related includes and defs to compat.h where possible, removed unu... | valerino | 2010-05-24 |
* | | | Port Tor to work on Windows CE•••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]
| valerino | 2010-05-24 |
* | | | Fix two compile-blockers in tor_vasprintf().•••1) mingw doesn't have _vscprintf(); mingw instead has a working snprintf.
2) windows compilers that _do_ have a working _vscprintf spell it so; they do
not spell it _vcsprintf().
| Nick Mathewson | 2010-04-19 |
* | | | Merge branch 'asprintf' | Nick Mathewson | 2010-04-02 |
|\ \ \
| |/ /
|/| | |
|
| * | | better handle the case where *strp is in asprintf args | Nick Mathewson | 2010-02-28 |
| * | | Add a tor_asprintf() function, and use it in a couple of places.•••asprintf() is a GNU extension that some BSDs have picked up: it does a printf
into a newly allocated chunk of RAM.
Our tor_asprintf() differs from standard asprintf() in that:
- Like our other malloc functions, it asserts on OOM.
- It works on windows.
- It always sets its return-field.
| Nick Mathewson | 2010-02-25 |
* | | | Merge remote branch 'origin/maint-0.2.1'•••Conflicts:
src/common/test.h
src/or/test.c
| Nick Mathewson | 2010-02-27 |
|\ \ \
| | |/
| |/| |
|
| * | | Update Tor Project copyright years | Nick Mathewson | 2010-02-27 |
* | | | Remove misc unnecessary newlines found by new check. | Mike Perry | 2010-02-22 |
| |/
|/| |
|
* | | Remove the --enable-iphone option as needless.•••On or-talk, Marco Bonetti reports that recent iPhone SDKs build
Tor fine without it.
| Nick Mathewson | 2010-02-12 |
* | | Add Windows version detection for Vista and 7•••Vista is Windows 6.0, and 7 is Windows 6.1. Fixes bug 1097.
Also fix a coding style violation.
| Sebastian Hahn | 2010-02-10 |
* | | Fix build on Solaris by disabling support for DisableAllSwap•••Fixes bug 1198. Solaris doesn't have RLIMIT_MEMLOCK for get/setrlimit,
so disable support because we don't know if all memory can be locked.
| Sebastian Hahn | 2010-01-19 |
* | | don't list windows capabilities in windows uname•••we never used them, and maybe it's a bad idea to publish them
| Roger Dingledine | 2010-01-15 |
* | | *_free functions now accept NULL•••Some *_free functions threw asserts when passed NULL. Now all of them
accept NULL as input and perform no action when called that way.
This gains us consistence for our free functions, and allows some
code simplifications where an explicit null check is no longer necessary.
| Sebastian Hahn | 2009-12-12 |
* | | Use the same mlockall checks with tor_set_max_memlock | Nick Mathewson | 2009-11-20 |
* | | Fix compilation on OSX 10.3.•••On this OSX version, there is a stub mlockall() function
that doesn't work, *and* the declaration for it is hidden by
an '#ifdef _P1003_1B_VISIBLE'. This would make autoconf
successfully find the function, but our code fail to build
when no declaration was found.
This patch adds an additional test for the declaration.
| Nick Mathewson | 2009-11-20 |
* | | Fix compilation with with bionic libc.•••This fixes bug 1147:
bionic doesn't have an actual implementation of mlockall();
mlockall() is merely in the headers but not actually in the library.
This prevents Tor compilation with the bionic libc for Android handsets.
| Jacob Appelbaum | 2009-11-14 |
* | | Implement DisableAllSwap to avoid putting secret info in page files.•••This commit implements a new config option: 'DisableAllSwap'
This option probably only works properly when Tor is started as root.
We added two new functions: tor_mlockall() and tor_set_max_memlock().
tor_mlockall() attempts to mlock() all current and all future memory pages.
For tor_mlockall() to work properly we set the process rlimits for memory to
RLIM_INFINITY (and beyond) inside of tor_set_max_memlock().
We behave differently from mlockall() by only allowing tor_mlockall() to be
called one single time. All other calls will result in a return code of 1.
It is not possible to change DisableAllSwap while running.
A sample configuration item was added to the torrc.complete.in config file.
A new item in the man page for DisableAllSwap was added.
Thanks to Moxie Marlinspike and Chris Palmer for their feedback on this patch.
Please note that we make no guarantees about the quality of your OS and its
mlock/mlockall implementation. It is possible that this will do nothing at all.
It is also possible that you can ulimit the mlock properties of a given user
such that root is not required. This has not been extensively tested and is
unsupported. I have included some comments for possible ways we can handle
this on win32.
| Jacob Appelbaum | 2009-10-27 |
* | | some cleanups:•••documentation fix for get_uint64
remove extra "." from a log line
fix a long line
| Sebastian Hahn | 2009-09-15 |
* | | Add a new tor_strtok_r for platforms that don't have one, plus tests.•••I don't think we actually use (or plan to use) strtok_r in a reentrant
way anywhere in our code, but would be nice not to have to think about
whether we're doing it.
| Nick Mathewson | 2009-08-09 |
|/ |
|
* | Don't attempt to log messages to a controller from a worker thread.•••This patch adds a function to determine whether we're in the main
thread, and changes control_event_logmsg() to return immediately if
we're in a subthread. This is necessary because otherwise we will
call connection_write_to_buf, which modifies non-locked data
structures.
Bugfix on 0.2.0.x; fix for at least one of the things currently
called "bug 977".
| Nick Mathewson | 2009-05-30 |
* | Spell-check Tor. | Nick Mathewson | 2009-05-27 |