mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-28 06:13:31 +01:00
Only v1 authorities get hidden service descriptors with current protocol
svn:r5924
This commit is contained in:
parent
97bff8edaa
commit
50e1005327
@ -131,15 +131,20 @@ directory_post_to_dirservers(uint8_t purpose, const char *payload,
|
||||
{
|
||||
smartlist_t *dirservers;
|
||||
int post_via_tor;
|
||||
int post_to_v1_only;
|
||||
|
||||
router_get_trusted_dir_servers(&dirservers);
|
||||
tor_assert(dirservers);
|
||||
/* Only old dirservers handle rendezvous descriptor publishing. */
|
||||
post_to_v1_only = (purpose == DIR_PURPOSE_UPLOAD_RENDDESC);
|
||||
/* This tries dirservers which we believe to be down, but ultimately, that's
|
||||
* harmless, and we may as well err on the side of getting things uploaded.
|
||||
*/
|
||||
SMARTLIST_FOREACH(dirservers, trusted_dir_server_t *, ds,
|
||||
{
|
||||
routerstatus_t *rs = &(ds->fake_status);
|
||||
if (post_to_v1_only && !ds->is_v1_authority)
|
||||
continue;
|
||||
post_via_tor = purpose_is_private(purpose) ||
|
||||
!fascist_firewall_allows_address(ds->addr,ds->dir_port);
|
||||
directory_initiate_command_routerstatus(rs, purpose, post_via_tor,
|
||||
|
Loading…
Reference in New Issue
Block a user