aboutsummaryrefslogtreecommitdiff
path: root/src/or
AgeCommit message (Collapse)Author
2016-12-03Use a temporary service list when validating and adding hidden servicesteor
This resolves two issues: * the checks in rend_add_services were only being performed when adding the service, and not when the service was validated, (this meant that duplicate checks were not being performed, and some SETCONF commands appeared to succeed when they actually failed), and * if one service failed while services were being added, then the service list would be left in an inconsistent state (tor dies when this happens, but the code is cleaner now). Fixes #20860.
2016-12-03Add a missing rend_service_free in rend_service_addteor
2016-12-03Clarify the function documentation for rend_get_service_list_mutableteor
Comment-only change
2016-12-02Merge branch 'maint-0.2.9'Nick Mathewson
2016-12-02protover: Fix old tor hardcoded version checkDavid Goulet
When computing old Tor protocol line version in protover, we were looking at 0.2.7.5 twice instead of the specific case for 0.2.9.1-alpha. Fixes #20810 Signed-off-by: David Goulet <dgoulet@torproject.org>
2016-12-02Merge remote-tracking branch 'teor/bug20667'Nick Mathewson
2016-12-02Merge branch 'maint-0.2.9'Nick Mathewson
2016-12-02Merge branch 'bug20716_026' into maint-0.2.9Nick Mathewson
2016-12-01Fix memory leak in bug 20716overcaffeinated
newconn->address is strdup'ed twice when new_type == CONN_TYPE_AP and conn->socket_family == AF_UNIX. Whilst here, juggle code to make sure newconn->port is assigned from an initialised value in the above case.
2016-12-01Stop ignoring misconfigured hidden servicesteor
Instead, refuse to start tor until the misconfigurations have been corrected. Fixes bug 20559; bugfix on multiple commits in 0.2.7.1-alpha and earlier.
2016-12-01Refactor rend_service_list substitute list selection codeteor
Remove duplicate code. No behaviour change.
2016-12-01Merge branch 'maint-0.2.9'Nick Mathewson
2016-12-01Merge branch 'bug20638_029_v2_squashed' into maint-0.2.9Nick Mathewson
2016-12-01Stop ignoring hidden service key anonymity when first starting torteor
Instead, refuse to start tor if any hidden service key has been used in a different hidden service anonymity mode. Fixes bug 20638; bugfix on 17178 in 0.2.9.3-alpha; reported by ahf. The original single onion service poisoning code checked poisoning state in options_validate, and poisoned in options_act. This was problematic, because the global array of hidden services had not been populated in options_validate (and there were ordrering issues with hidden service directory creation). This patch fixes this issue in rend_service_check_dir_and_add, which: * creates the directory, or checks permissions on an existing directory, then * checks the poisoning state of the directory, then * poisons the directory. When validating, only the permissions checks and the poisoning state checks are perfomed (the directory is not modified).
2016-12-01Update unit tests for 20484, 20529teor
Add extra logging and extra validity checks for hidden services.
2016-12-01Merge remote-tracking branch 'dgoulet/ticket20568_030_01'Nick Mathewson
2016-12-01Fix compilationNick Mathewson
2016-11-30Stop discarding downloaded full descriptors when using microdescs for circuitsteor
This affects clients with FetchUselessDescriptors 1. It might also cause subtle bugs on directory mirrors and authorities, causing them to consider all full descriptors as failed or old.
2016-11-30Remove an unneccessary FetchUselessDescriptors check in client_would_use_routerteor
2016-11-30Fetch unknown certificates if FetchUselessDescriptors is trueteor
2016-11-30Stop discarding consensus flavors and descriptors we wanted to fetchteor
Instead, fetch and store consensus flavors and descriptors we wanted to fetch. And serve them if we are a directory cache (or authority).
2016-11-27Improve log messages related to identity keys7r
Improve the messages logged when Tor wants or needs to load the master ed25519 identity key so the user is explicitly informed when further action is required or not. Fixes ticket #20650.
2016-11-21Merge branch 'maint-0.2.9'Nick Mathewson
2016-11-18Refactor rend_service_check_dir_and_addteor
Make the function flatter, and prepare for #20559. No behaviour change.
2016-11-18Refactor duplicate code out of rend_config_servicesteor
Put that code in rend_service_check_dir_and_add. No behaviour change. This is a defence in depth measure against similar bugs to 20529.
2016-11-18Create HS directories in rend_config_services, then check before useteor
(We only create HS directories if we are acting on the config.) Log a BUG warning if the directories aren't present immediately before they are used, then fail.
2016-11-17Merge remote-tracking branch 'dgoulet/bug20629_030_01'Nick Mathewson
2016-11-17Merge remote-tracking branch 'public/bug20558'Nick Mathewson
2016-11-17Merge remote-tracking branch 'public/bug20630'Nick Mathewson
2016-11-17Fix and simplify error handling code in rend_service_parse_port_config()Ivan Markin
2016-11-17Fix comment for rend_service_parse_port_config()Ivan Markin
2016-11-16don't attempt a resolve when the cached answer will doRoger Dingledine
For relays that don't know their own address, avoid attempting a local hostname resolve for each descriptor we download. Also cut down on the number of "Success: chose address 'x.x.x.x'" log lines. Fixes bugs 20423 and 20610; bugfix on 0.2.8.1-alpha.
2016-11-16refactor router_pick_published_address to have another argRoger Dingledine
no change in behavior except fewer log entries in the case where we use a cached result.
2016-11-14Fix a "shouldn't have reached this" warning in connection_edge.cNick Mathewson
This was bug 20630; bugfix on f3e158ed where I thought I was committing a documentation-only fix but instead messed up the control flow too.
2016-11-10hs: Remove pointless NULL check found by CoverityDavid Goulet
Signed-off-by: David Goulet <dgoulet@torproject.org>
2016-11-10fixup! Move encode_cert to torcert.c and rename it to tor_cert_encode_ed22519()David Goulet
2016-11-10Move encode_cert to torcert.c and rename it to tor_cert_encode_ed22519()Neel Chauhan
Signed-off-by: David Goulet <dgoulet@torproject.org>
2016-11-10Merge remote-tracking branch 'dgoulet/bug20567_030_01'Nick Mathewson
2016-11-10Merge remote-tracking branch 'public/feature20552'Nick Mathewson
2016-11-10Merge remote-tracking branch 'dgoulet/ticket19642_030_01'Nick Mathewson
2016-11-10Add "TByte" and "TBytes" units; also add "TBits" to man pageMatt Nordhoff
2016-11-10Merge branch 'maint-0.2.9'Nick Mathewson
2016-11-09Stop logging single onion and Tor2web long-term one-hop circuitsteor
Single onion services and Tor2web deliberately create long-term one-hop circuits to their intro and rend points, respectively. These log messages are intended to diagnose issue 8387, which relates to circuits hanging around forever for no reason. Fixes bug 20613; bugfix on 0.2.9.1-alpha. Reported by "pastly".
2016-11-09Call get_options() once at the top of circuit_log_ancient_one_hop_circuits()teor
Refactoring, no behaviour change.
2016-11-08Merge branch 'maint-0.2.9'Nick Mathewson
2016-11-08Merge remote-tracking branch 'public/bug20306_029' into maint-0.2.9Nick Mathewson
2016-11-08hs: Add single-onion-service line to v3 descriptorDavid Goulet
This field indicates if the service is a Single Onion Service if present in the descriptor. Closes #19642 Signed-off-by: David Goulet <dgoulet@torproject.org>
2016-11-08Merge branch 'maint-0.2.9'Nick Mathewson
2016-11-08When using exponential backoff in test networks, use a lower exponentteor
Lower exponents mean that delays do not vary as much. This helps test networks bootstrap consistently. Bugfix on 20499.
2016-11-07Merge branch 'maint-0.2.9'Nick Mathewson
Conflicts: src/or/rendservice.c