Commit Graph

33853 Commits

Author SHA1 Message Date
Nick Mathewson
dc6d7f072d Make foo_validate() functions call config_validate().
The former foo_validate() functions are now toplevel
legacy_validate_fn callbacks.  The new foo_validate() functions now
call them.

This change lets us remove the old shared_random disk state
validation callback entirely.
2019-10-24 20:30:32 -04:00
Nick Mathewson
0cb4238537 Add a config_validate() function to invoke verify callbacks.
As we turn our monolithic configuration objects into suites of
smaller module-specific configuration objects, we will want each one
to be able to provide its own verification callbacks.  That means
that instead of invoking these verification callbacks directly, we will
want to call them via the configuration manager object.
2019-10-24 20:30:32 -04:00
Nick Mathewson
4a248bafba Rename validate_fn{,_t} to start with "legacy_".
The current API of this callback mixes responsibilities, including:
  * validation
  * transition checking
  * processing (modifying) the configuration object.

These will have to be disentangled piece by piece, so for now, we'll
have "legacy" validate functions as well.

This is an automated commit, generated by this command:

./scripts/maint/rename_c_identifier.py \
        validate_fn_t legacy_validate_fn_t \
        validate_fn legacy_validate_fn
2019-10-24 20:30:32 -04:00
Nick Mathewson
24ee44df90 test_options: stop generating old_data entirely.
Now that we no longer use it anywhere, we can remove this variable
from the test data structure.
2019-10-24 20:30:32 -04:00
Nick Mathewson
7c0f966668 test_options: don't pass an old_options argument to options_validate()
This input was inessential, and none of the tests actually depended
on it or tested anything about it (as can be seen from the fact that
tests all still pass when it's removed).

I tried to generate this commit with a coccinelle script, but it had
trouble parsing a lot of options_validate as it stands.  Instead, I
did a search-and-replace to replace "tdata->old_opt," with "NULL,".
2019-10-24 20:30:32 -04:00
Nick Mathewson
27dbf20bf4 Use named-member syntax for initializing config_format_t objects
I'm about to mess with their lists of callbacks, and I don't want to
proliferate lists where we say "NULL, NULL, NULL, ..."
2019-10-24 20:30:32 -04:00
Nick Mathewson
68e1ced607 Merge branch 'maint-0.4.2'
"ours" to avoid version bump.
2019-10-24 15:55:38 -04:00
Nick Mathewson
570d1367ea bump to 0.4.2.3-alpha-dev 2019-10-24 15:55:22 -04:00
Nick Mathewson
d0c97bf3b6 Forward-port the changelog for 0.4.2.3-alpha 2019-10-24 15:52:55 -04:00
Nick Mathewson
9a66b33229 A little more text in the SEE ALSO section. 2019-10-24 11:45:07 -04:00
Nick Mathewson
fefee871a6 Merge remote-tracking branch 'tor-github/pr/1437' 2019-10-24 11:44:19 -04:00
David Goulet
cf5f52d694 configure: Add --disable-module-relay to summary
Closes #32266

Signed-off-by: David Goulet <dgoulet@torproject.org>
2019-10-24 09:08:36 -04:00
Nick Mathewson
a03c0394a3 Merge branch 'maint-0.4.2'
"ours" to avoid version bump.
2019-10-23 20:26:15 -04:00
Nick Mathewson
76939cf293 Bump to 0.4.2.3-alpha 2019-10-23 20:25:34 -04:00
teor
20606b8a15
Merge remote-tracking branch 'tor-github/pr/1447' 2019-10-24 10:00:47 +10:00
David Goulet
9586ae178a Merge branch 'tor-github/pr/1451' 2019-10-23 09:11:43 -04:00
teor
34509e78c6
Merge remote-tracking branch 'tor-github/pr/1449' 2019-10-23 22:59:16 +10:00
teor
226f11002d
changes: file for 32216 2019-10-23 13:36:39 +10:00
teor
f43a7a4d96
scripts/git: Avoid sleeping before the last push in git-push-all.sh
Change the loop order, so that we only sleep between pushes,
and avoid sleeping after all the pushes are done.

(In rare cases, there may still be an extra sleep.)

Part of 32216.
2019-10-23 13:28:37 +10:00
teor
4f6f006c99
scripts/git: Make git-push-all.sh skip more branches that match upstream
The script now skips master, maint-* and release-* branches that match
upstream, not just test branches.

And fix "no branches" bugs that this change makes happen more often.

Part of 32216.
2019-10-23 13:28:15 +10:00
teor
9a3b768fae
scripts/git: Pass all unrecognised arguments to git-push-all.sh
This makes the behaviour of git-push-all.sh -n identical to the other
git scripts.

Part of 32216.
2019-10-23 13:04:28 +10:00
teor
71191fa3dc
scripts/git: Fix a variable name typo in git-push-all.sh
Obviously correct changes to already reviewed code.
2019-10-23 13:01:55 +10:00
teor
d804a81cf1
changes: file for 29603
We merged this change without a changes file.
2019-10-23 12:26:32 +10:00
teor
8a56819d23
Merge branch 'maint-0.4.2' 2019-10-23 10:00:49 +10:00
teor
65545e1345
Merge branch 'maint-0.4.1' into maint-0.4.2
`git merge --strategy ours` to use STATIC for unit tests in
maint-0.4.2.
2019-10-23 09:59:07 +10:00
teor
8bc65cda44
Merge branch 'pr1450_squashed' into maint-0.4.1 2019-10-23 09:58:22 +10:00
Nick Mathewson
f3c0a0b9fe
Authorities reject relays running unsupported Tor release series.
Our minimum version is now 0.2.9.5-alpha.  Series 0.3.0, 0.3.1,
0.3.2, 0.3.3, and 0.3.4 are now rejected.

Also, extract this version-checking code into a new function, so we
can test it.

Closes ticket 31549.

Also reject 0.3.5.0 through 0.3.5.6-rc as unstable.
2019-10-23 09:57:51 +10:00
teor
9db1602ec5
Merge branch 'maint-0.4.2' 2019-10-23 08:47:30 +10:00
teor
b45048feaf
Merge branch 'maint-0.4.1' into maint-0.4.2 2019-10-23 08:47:23 +10:00
teor
4a5c909ce5
Merge branch 'maint-0.4.0' into maint-0.4.1 2019-10-23 08:47:15 +10:00
teor
57acdaa3f1
Merge branch 'maint-0.3.5' into maint-0.4.0 2019-10-23 08:47:08 +10:00
teor
d175e70817
Merge branch 'maint-0.2.9' into maint-0.3.5 2019-10-23 08:47:01 +10:00
teor
641f130447
Merge remote-tracking branch 'tor-github/pr/1361' into maint-0.4.0 2019-10-23 08:35:17 +10:00
teor
c77162e4e9
Merge remote-tracking branch 'tor-github/pr/1360' into maint-0.3.5 2019-10-23 08:32:52 +10:00
teor
8682442c76
Merge remote-tracking branch 'tor-github/pr/1351' into maint-0.2.9 2019-10-23 08:32:22 +10:00
teor
27965f1ef2
Merge remote-tracking branch 'tor-github/pr/1284' into maint-0.3.5 2019-10-23 08:30:48 +10:00
teor
003be727c4
Merge remote-tracking branch 'tor-github/pr/1256' into maint-0.3.5 2019-10-23 08:28:03 +10:00
teor
1ea19d7a5b
Merge branch 'maint-0.2.9' into maint-0.3.5
`git merge --strategy ours` to take the 0.3.5 changes for 31001,
and ignore the conflicting 0.2.9 changes.
2019-10-23 08:25:42 +10:00
teor
7660a7cf7d
Merge remote-tracking branch 'tor-github/pr/1178' into maint-0.2.9 2019-10-23 08:20:45 +10:00
Philipp Winter
80a198928e
Remove outdated note.
BridgeDB supports bridge-distribution lines since version 0.5.0:
<https://bugs.torproject.org/23957>
2019-10-23 07:52:05 +10:00
Roger Dingledine
4233fb7014
clarify in man page: we count by powers of two
Make clear in the man page, in both the bandwidth section and the
accountingmax section, that Tor counts in powers of two, not
powers of ten: 1 GByte is 1024*1024*1024 bytes, not one billion
bytes.

Resolves ticket 32106.
2019-10-23 07:50:20 +10:00
teor
339c18d6c7
Tidy whitespace around some STMT_BEGINs and STMT_ENDs 2019-10-23 07:37:39 +10:00
Nick Mathewson
1cdc030c3d Merge branch 'maint-0.4.2' 2019-10-22 14:47:28 -04:00
Nick Mathewson
2ed194c9a9 Merge remote-tracking branch 'tor-github/pr/1441' into maint-0.4.2 2019-10-22 14:46:10 -04:00
Nick Mathewson
04addabb04 Changes file for options_validate() API changes in #32187. 2019-10-22 14:24:09 -04:00
Nick Mathewson
6bc2b41e54 config validation: make the "old_options" argument const.
We can't do this with the "options" argument yet, since several
places in the code change those right now.
2019-10-22 14:24:09 -04:00
Nick Mathewson
3656fdae98 test_options: remove def_opt member of test data. 2019-10-22 14:24:09 -04:00
Nick Mathewson
86a1d670ac test_options: remove "dflt" part of setup_options().
It is no longer used anywhere.
2019-10-22 14:24:09 -04:00
Nick Mathewson
475a1dc9be Remove a pair of now-unused default-options arguments. 2019-10-22 14:24:03 -04:00
Nick Mathewson
3dc0944acd test_options: Fix options_validate() calls in macros.
Coccinelle missed these.
2019-10-22 14:24:03 -04:00