[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Merge branch 'ticket32806'



commit 7f03ba06d8447025ef3e53906ebe9bcdd0d4d1b5
Merge: abd9ae48a 6d2b9c963
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Fri Jan 17 08:37:33 2020 -0500

    Merge branch 'ticket32806'

 changes/ticket32806                                |   3 +
 src/app/config/config.c                            |  25 ----
 src/app/config/or_options_st.h                     |  69 ---------
 src/feature/dirauth/bwauth.c                       |   4 +-
 src/feature/dirauth/dirauth_config.c               | 127 ++++++++---------
 src/feature/dirauth/dirauth_config.h               |   6 -
 src/feature/dirauth/dirauth_options.inc            |  80 +++++++++++
 src/feature/dirauth/dirauth_options_st.h           |   2 +
 src/feature/dirauth/dirauth_sys.c                  |   3 +-
 src/feature/dirauth/dirauth_sys.h                  |   4 +
 src/feature/dirauth/dirvote.c                      |  13 +-
 src/feature/dirauth/process_descs.c                |   6 +-
 src/feature/dirauth/reachability.c                 |  10 +-
 src/feature/dirauth/shared_random.c                |   6 +-
 src/feature/dirauth/voteflags.c                    |  46 +++---
 src/feature/nodelist/routerset.h                   |   2 +-
 .../conf_examples/large_1/expected_log_no_dirauth  |   1 +
 src/test/conf_examples/large_1/expected_no_dirauth | 158 +++++++++++++++++++++
 src/test/include.am                                |   2 +
 src/test/opts_test_helpers.c                       |  38 +++++
 src/test/opts_test_helpers.h                       |  22 +++
 src/test/test_dir.c                                | 102 ++++++-------
 src/test/test_options.c                            |  64 ++++-----
 src/test/test_voting_flags.c                       |   4 +-
 24 files changed, 508 insertions(+), 289 deletions(-)

diff --cc src/app/config/or_options_st.h
index 2733bf775,0e6e82585..35ba15a9e
--- a/src/app/config/or_options_st.h
+++ b/src/app/config/or_options_st.h
@@@ -732,11 -686,11 +700,6 @@@ struct or_options_t 
        voting. Only altered on testing networks. */
    int TestingV3AuthVotingStartOffset;
  
-   /** If an authority has been around for less than this amount of time, it
-    * does not believe its reachability information is accurate.  Only
-    * altered on testing networks. */
-   int TestingAuthDirTimeToLearnReachability;
 -  /** Clients don't download any descriptor this recent, since it will
 -   * probably not have propagated to enough caches.  Only altered on testing
 -   * networks. */
 -  int TestingEstimatedDescriptorPropagationTime;
--
    /** Schedule for when servers should download things in general.  Only
     * altered on testing networks. */
    int TestingServerDownloadInitialDelay;
diff --cc src/feature/dirauth/process_descs.c
index 139c6834a,207aae379..baf8f8c21
--- a/src/feature/dirauth/process_descs.c
+++ b/src/feature/dirauth/process_descs.c
@@@ -35,15 -33,13 +36,16 @@@
  #include "feature/relay/router.h"
  
  #include "core/or/tor_version_st.h"
+ #include "feature/dirauth/dirauth_options_st.h"
  #include "feature/nodelist/extrainfo_st.h"
  #include "feature/nodelist/node_st.h"
 +#include "feature/nodelist/microdesc_st.h"
  #include "feature/nodelist/routerinfo_st.h"
  #include "feature/nodelist/routerstatus_st.h"
 +#include "feature/nodelist/vote_routerstatus_st.h"
  
  #include "lib/encoding/confline.h"
 +#include "lib/crypt_ops/crypto_format.h"
  
  /** How far in the future do we allow a router to get? (seconds) */
  #define ROUTER_ALLOW_SKEW (60*60*12)
@@@ -289,9 -234,7 +291,9 @@@ dirserv_router_get_status(const routeri
                            int severity)
  {
    char d[DIGEST_LEN];
-   const int key_pinning = get_options()->AuthDirPinKeys;
+   const int key_pinning = dirauth_get_options()->AuthDirPinKeys;
 +  uint32_t r;
 +  ed25519_public_key_t *signing_key = NULL;
  
    if (crypto_pk_get_digest(router->identity_pkey, d)) {
      log_warn(LD_BUG,"Error computing fingerprint");
diff --cc src/test/test_dir.c
index 76c86c258,d929cfb27..3b2ba64d2
--- a/src/test/test_dir.c
+++ b/src/test/test_dir.c
@@@ -9,8 -9,10 +9,9 @@@
  #define BWAUTH_PRIVATE
  #define CONFIG_PRIVATE
  #define CONTROL_GETINFO_PRIVATE
+ #define DIRAUTH_SYS_PRIVATE
  #define DIRCACHE_PRIVATE
  #define DIRCLIENT_PRIVATE
 -#define DIRSERV_PRIVATE
  #define DIRVOTE_PRIVATE
  #define DLSTATUS_PRIVATE
  #define HIBERNATE_PRIVATE
diff --cc src/test/test_options.c
index fb12821ae,119b2a54a..b6a9a2150
--- a/src/test/test_options.c
+++ b/src/test/test_options.c
@@@ -3869,24 -3866,25 +3868,19 @@@ test_options_validate__testing_options(
    tor_free(msg); \
    STMT_END
  
-   TEST_TESTING_OPTION(TestingAuthDirTimeToLearnReachability, -1, 8000,
-                       "must be non-negative.", ENABLE_AUTHORITY_V3);
-   TEST_TESTING_OPTION(TestingAuthDirTimeToLearnReachability, -1, 8000,
-                       "must be non-negative.", ENABLE_AUTHORITY_BRIDGE);
- 
-   TEST_TESTING_OPTION(TestingClientMaxIntervalWithoutRequest, -1, 3601,
 -  TEST_TESTING_OPTION(TestingEstimatedDescriptorPropagationTime, , -1, 3601,
 -                      "must be non-negative.", "");
+   TEST_TESTING_OPTION(TestingClientMaxIntervalWithoutRequest, , -1, 3601,
                        "is way too low.", "");
-   TEST_TESTING_OPTION(TestingDirConnectionMaxStall, 1, 3601,
+   TEST_TESTING_OPTION(TestingDirConnectionMaxStall, , 1, 3601,
                        "is way too low.", "");
  
-   TEST_TESTING_OPTION(TestingClientMaxIntervalWithoutRequest, -1, 3601,
 -  TEST_TESTING_OPTION(TestingEstimatedDescriptorPropagationTime, , -1, 3601,
 -                      "must be non-negative.", ENABLE_AUTHORITY_V3);
+   TEST_TESTING_OPTION(TestingClientMaxIntervalWithoutRequest, , -1, 3601,
                        "is way too low.", ENABLE_AUTHORITY_V3);
-   TEST_TESTING_OPTION(TestingDirConnectionMaxStall, 1, 3601,
+   TEST_TESTING_OPTION(TestingDirConnectionMaxStall, , 1, 3601,
                        "is way too low.", ENABLE_AUTHORITY_V3);
  
-   TEST_TESTING_OPTION(TestingClientMaxIntervalWithoutRequest, -1, 3601,
 -  TEST_TESTING_OPTION(TestingEstimatedDescriptorPropagationTime, , -1, 3601,
 -                      "must be non-negative.", ENABLE_AUTHORITY_BRIDGE);
+   TEST_TESTING_OPTION(TestingClientMaxIntervalWithoutRequest, , -1, 3601,
                        "is way too low.", ENABLE_AUTHORITY_BRIDGE);
-   TEST_TESTING_OPTION(TestingDirConnectionMaxStall, 1, 3601,
+   TEST_TESTING_OPTION(TestingDirConnectionMaxStall, , 1, 3601,
                        "is way too low.", ENABLE_AUTHORITY_BRIDGE);
  
    free_options_test_data(tdata);

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits