New alpha release: Tor 0.4.5.1-alpha

There's a new alpha release available for download. If you build Tor from source, you can download the source code for Tor 0.4.5.1-alpha from the download page on the website. Packages should be available over the coming weeks, with a new alpha Tor Browser release some time this month, assuming we get #40172 figured out.

Remember, this is an alpha release: you should only run this if you'd like to find and report more bugs than usual. We'll be trying to put out putting out stable backport releases in the next week or so.

Tor 0.4.5.1-alpha is the first alpha release in the 0.4.5.x series. It improves support for IPv6, address discovery and self-testing, code metrics and tracing.

This release also fixes TROVE-2020-005, a security issue that could be used, under certain cases, by an adversary to observe traffic patterns on a limited number of circuits intended for a different relay. To mount this attack, the adversary would need to actively extend circuits to an incorrect address, as well as compromise a relay's legacy RSA-1024 key. We'll be backporting this fix to other release series soon, after it has had some testing.

Here are the changes since 0.4.4.5.

Changes in version 0.4.5.1-alpha - 2020-11-01

  • Major features (build):
    • When building Tor, first link all object files into a single static library. This may help with embedding Tor in other programs. Note that most Tor functions do not constitute a part of a stable or supported API: only those functions in tor_api.h should be used if embedding Tor. Closes ticket 40127.
  • Major features (metrics):
    • Introduce a new MetricsPort which exposes, through an HTTP interface, a series of metrics that tor collects at runtime. At the moment, the only supported output format is Prometheus data model. Closes ticket 40063. See the manual page for more information and security considerations.

 

  • Major features (relay, IPv6):
    • The torrc option Address now supports IPv6. This unifies our address discovery interface to support IPv4, IPv6, and hostnames. Closes ticket 33233.
    • Launch IPv4 and IPv6 ORPort self-test circuits on relays and bridges. Closes ticket 33222.
    • Relays now automatically bind on IPv6 for their ORPort, unless specified otherwise with the IPv4Only flag. Closes ticket 33246.
    • When a relay with IPv6 support is told to open a connection to another relay, and the extend cell lists both IPv4 and IPv6 addresses, the first relay now picks randomly which address to use. Closes ticket 33220.
    • Relays now track their IPv6 ORPort reachability separately from the reachability of their IPv4 ORPort. They will not publish a descriptor unless _both_ ports appear to be externally reachable. Closes ticket 34067.
  • Major features (tracing):
    • Add event-tracing library support for USDT and LTTng-UST, and a few tracepoints in the circuit subsystem. More will come incrementally. This feature is compiled out by default: it needs to be enabled at configure time. See documentation in doc/HACKING/Tracing.md. Closes ticket 32910.
  • Major bugfixes (security):
    • When completing a channel, relays now check more thoroughly to make sure that it matches any pending circuits before attaching those circuits. Previously, address correctness and Ed25519 identities were not checked in this case, but only when extending circuits on an existing channel. Fixes bug 40080; bugfix on 0.2.7.2-alpha. Resolves TROVE-2020-005.
  • Major bugfixes (TLS, buffer):
    • When attempting to read N bytes on a TLS connection, really try to read all N bytes. Previously, Tor would stop reading after the first TLS record, which can be smaller than the N bytes requested, and not check for more data until the next mainloop event. Fixes bug 40006; bugfix on 0.1.0.5-rc.
  • Minor features (address discovery):
    • If no Address statements are found, relays now prioritize guessing their address by looking at the local interface instead of the local hostname. If the interface address can't be found, the local hostname is used. Closes ticket 33238.
  • Minor features (admin tools):
    • Add a new --format argument to -key-expiration option to allow specifying the time format of the expiration date. Adds Unix timestamp format support. Patch by Daniel Pinto. Closes ticket 30045.
  • Minor features (bootstrap reporting):
    • When reporting bootstrapping status on a relay, do not consider connections that have never been the target of an origin circuit. Previously, all connection failures were treated as potential bootstrapping failures, including connections that had been opened because of client requests. Closes ticket 25061.
  • Minor features (build):
    • When running the configure script, try to detect version mismatches between the OpenSSL headers and libraries, and suggest that the user should try "--with-openssl-dir". Closes 40138.
    • If the configure script has given any warnings, remind the user about them at the end of the script. Related to 40138.
  • Minor features (configuration):
    • Allow using wildcards (* and ?) with the %include option on configuration files. Closes ticket 25140. Patch by Daniel Pinto.
    • Allow the configuration options EntryNodes, ExcludeNodes, ExcludeExitNodes, ExitNodes, MiddleNodes, HSLayer2Nodes and HSLayer3Nodes to be specified multiple times. Closes ticket 28361. Patch by Daniel Pinto.
  • Minor features (control port):
    • Add a DROPTIMEOUTS command to drop circuit build timeout history and reset the current timeout. Closes ticket 40002.
    • When a stream enters the AP_CONN_STATE_CONTROLLER_WAIT status, send a control port event. Closes ticket 32190. Patch by Neel Chauhan.
    • Introduce GETINFO "stats/ntor/{assigned/requested}" and "stats/tap/{assigned/requested}" to get the NTor and TAP circuit onion handshake counts respectively. Closes ticket 28279. Patch by Neel Chauhan.
  • Minor features (control port, IPv6):
    • Tor relays now try to report to the controller when they are launching an IPv6 self-test. Closes ticket 34068.
    • Introduce "GETINFO address/v4" and "GETINFO address/v6" in the control port to fetch the Tor host's respective IPv4 or IPv6 address. We keep "GETINFO address" for backwards-compatibility. Closes ticket 40039. Patch by Neel Chauhan.
  • Minor features (directory authorities):
    • Authorities now list a different set of protocols as required and recommended. These lists have been chosen so that only truly recommended and/or required protocols are included, and so that clients using 0.2.9 or later will continue to work (even though they are not supported), whereas only relays running 0.3.5 or later will meet the requirements. Closes ticket 40162.
    • Add a new consensus method 30 that removes the unnecessary "=" padding from ntor-onion-key. Closes ticket 7869. Patch by Daniel Pinto.
    • Directory authorities now reject descriptors from relays running Tor versions from the obsolete 0.4.1 series. Resolves ticket 34357. Patch by Neel Chauhan.
    • Make it possible to specify multiple ConsensusParams torrc lines. Now directory authority operators can for example put the main ConsensusParams config in one torrc file and then add to it from a different torrc file. Closes ticket 40164.
    • The AssumeReachable option no longer stops directory authorities from checking whether other relays are running. A new AuthDirTestReachability option can be used to disable these checks. Closes ticket 34445.
    • When looking for possible Sybil attacks, also consider IPv6 addresses. Two routers are considered to have "the same" address by this metric if they are in the same /64 network. Patch from Maurice Pibouin. Closes ticket 7193.
  • Minor features (directory authorities, IPv6):
    • Make authorities add their IPv6 ORPort (if any) to the trusted servers list. Authorities previously added only their IPv4 addresses. Closes ticket 32822.
  • Minor features (ed25519, relay):
    • Save a relay's base64-encoded ed25519 identity key to the data directory in a file named fingerprint-ed25519. Closes ticket 30642. Patch by Neel Chauhan.
  • Minor features (heartbeat):
    • Include the total number of inbound and outbound IPv4 and IPv6 connections in the heartbeat message. Closes ticket 29113.
  • Minor features (IPv6, ExcludeNodes):
    • Handle IPv6 addresses in ExcludeNodes; previously they were ignored. Closes ticket 34065. Patch by Neel Chauhan.
  • Minor features (logging):
    • Add the running glibc version to the log, and the compiled glibc version to the library list returned when using --library-versions. Patch from Daniel Pinto. Closes ticket 40047.
    • Consider an HTTP 301 response to be an error (like a 404) when processing a directory response. Closes ticket 40053.
    • Log directory fetch statistics as a single line. Closes ticket 40159.
    • Provide more complete descriptions of our connections when logging about them. Closes ticket 40041.
    • When describing a relay in the logs, we now include its ed25519 identity. Closes ticket 22668.
  • Minor features (onion services):
    • Only overwrite an onion service's existing hostname file if its contents are wrong. This enables read-only onion-service directories. Resolves ticket 40062. Patch by Neel Chauhan.
  • Minor features (pluggable transports):
    • Add an OutboundBindAddressPT option to allow users to specify which IPv4 and IPv6 address pluggable transports should use for outgoing IP packets. Tor does not have a way to enforce that the pluggable transport honors this option, so each pluggable transport needs to implement support on its own. Closes ticket 5304.
  • Minor features (relay address tracking):
    • We now store relay addresses for OR connections in a more logical way. Previously we would sometimes overwrite the actual address of a connection with a "canonical address", and then store the "real address" elsewhere to remember it. We now track the "canonical address" elsewhere for the cases where we need it, and leave the connection's address alone. Closes ticket 33898.
  • Minor features (relay):
    • If a relay is unable to discover its address, attempt to learn it from the NETINFO cell. Closes ticket 40022.
    • Log immediately when launching a relay self-check. Previously we would try to log before launching checks, or approximately when we intended to launch checks, but this tended to be error-prone. Closes ticket 34137.
  • Minor features (relay, address discovery):
    • If Address option is not found in torrc, attempt to learn our address with the configured ORPort address if any. Closes ticket 33236.
  • Minor features (relay, IPv6):
    • Add an AssumeReachableIPv6 option to disable self-checking IPv6 reachability. Closes part of ticket 33224.
    • Add new "assume-reachable" and "assume-reachable-ipv6" consensus parameters to be used in an emergency to tell relays that they should publish even if they cannot complete their ORPort self- checks. Closes ticket 34064 and part of 33224.
    • Allow relays to send IPv6-only extend cells. Closes ticket 33222.
    • Declare support for the Relay=3 subprotocol version. Closes ticket 33226.
    • When launching IPv6 ORPort self-test circuits, make sure that the second-last hop can initiate an IPv6 extend. Closes ticket 33222.
  • Minor features (specification update):
    • Several fields in microdescriptors, router descriptors, and consensus documents that were formerly optional are now required. Implements proposal 315; closes ticket 40132.
  • Minor features (state management):
    • When loading the state file, remove entries from the statefile that have been obsolete for a long time. Ordinarily Tor preserves unrecognized entries in order to keep forward-compatibility, but these entries have not actually been used in any release since before 0.3.5.x. Closes ticket 40137.
  • Minor features (statistics, ipv6):
    • Relays now publish IPv6-specific counts of single-direction versus bidirectional relay connections. Closes ticket 33264.
    • Relays now publish their IPv6 read and write statistics over time, if statistics are enabled. Closes ticket 33263.
  • Minor features (subprotocol versions):
    • Tor no longer allows subprotocol versions larger than 63. Previously version numbers up to UINT32_MAX were allowed, which significantly complicated our code. Implements proposal 318; closes ticket 40133.
    • Use the new limitations on subprotocol versions due to proposal 318 to simplify our implementation. Part of ticket 40133.
  • Minor features (testing configuration):
    • The TestingTorNetwork option no longer implicitly sets AssumeReachable to 1. This change allows us to test relays' self- testing mechanisms, and to test authorities' relay-testing functionality. Closes ticket 34446.
  • Minor features (testing):
    • Added unit tests for channel_matches_target_addr_for_extend(). Closes Ticket 33919. Patch by MrSquanchee.
  • Minor features (tests, v2 onion services):
    • Fix a rendezvous cache unit test that was triggering an underflow on the global rend cache allocation. Fixes bug 40125; bugfix on 0.2.8.1-alpha.
    • Fix another rendezvous cache unit test that was triggering an underflow on the global rend cache allocation. Fixes bug 40126; bugfix on 0.2.8.1-alpha.
  • Minor bugfixes (circuit padding):
    • When circpad_send_padding_cell_for_callback is called, `is_padding_timer_scheduled` flag was not reset. Now it is set to 0 at the top of that function. Fixes bug 32671; bugfix on 0.4.0.1-alpha.
    • Add a per-circuit padding machine instance counter, so we can differentiate between shutdown requests for old machines on a circuit. Fixes bug 30992; bugfix on 0.4.1.1-alpha.
    • Add the ability to keep circuit padding machines if they match a set of circuit states or purposes. This allows us to have machines that start up under some conditions but don't shut down under others. We now use this mask to avoid starting up introduction circuit padding again after the machines have already completed. Fixes bug 32040; bugfix on 0.4.1.1-alpha.
  • Minor bugfixes (compatibility):
    • Strip '\r' characters when reading text files on Unix platforms. This should resolve an issue where a relay operator migrates a relay from Windows to Unix, but does not change the line ending of Tor's various state files to match the platform, and the CRLF line endings from Windows end up leaking into other files such as the extra-info document. Fixes bug 33781; bugfix on 0.0.9pre5.
  • Minor bugfixes (compilation):
    • Fix compiler warnings that would occur when building with "--enable-all-bugs-are-fatal" and "--disable-module-relay" at the same time. Fixes bug 40129; bugfix on 0.4.4.1-alpha.
    • Resolve a compilation warning that could occur in test_connection.c. Fixes bug 40113; bugfix on 0.2.9.3-alpha.
  • Minor bugfixes (configuration):
    • Fix bug where %including a pattern ending with */ would include files and folders (instead of folders only) in versions of glibc < 2.19. Fixes bug 40141; bugfix on 0.4.5.0-alpha-dev. Patch by Daniel Pinto.
  • Minor bugfixes (control port):
    • Make sure we send the SOCKS request address in relay begin cells when a stream is attached with the purpose CIRCUIT_PURPOSE_CONTROLLER. Fixes bug 33124; bugfix on 0.0.5. Patch by Neel Chauhan.
  • Minor bugfixes (logging):
    • Remove a debug logging statement that uselessly spammed the logs. Fixes bug 40135; bugfix on 0.3.5.0-alpha.
    • When logging a rate-limited message about how many messages have been suppressed in the last N seconds, give an accurate value for N, rounded up to the nearest minute. Previously we would report the size of the rate-limiting interval, regardless of when the messages started to occur. Fixes bug 19431; bugfix on 0.2.2.16-alpha.
  • Minor bugfixes (relay configuration, crash):
    • Avoid a fatal assert() when failing to create a listener connection for an address that was in use. Fixes bug 40073; bugfix on 0.3.5.1-alpha.
  • Minor bugfixes (rust, protocol versions):
    • Declare support for the onion service introduction point denial of service extensions when building with Rust. Fixes bug 34248; bugfix on 0.4.2.1-alpha.
    • Make Rust protocol version support checks consistent with the undocumented error behavior of the corresponding C code. Fixes bug 34251; bugfix on 0.3.3.5-rc.
  • Minor bugfixes (self-testing):
    • When receiving an incoming circuit, only accept it as evidence that we are reachable if the declared address of its channel is the same address we think that we have. Otherwise, it could be evidence that we're reachable on some other address. Fixes bug 20165; bugfix on 0.1.0.1-rc.
  • Minor bugfixes (spec conformance):
    • Use the correct key type when generating signing->link certificates. Fixes bug 40124; bugfix on 0.2.7.2-alpha.
  • Minor bugfixes (subprotocol versions):
    • Consistently reject extra commas, instead of only rejecting leading commas. Fixes bug 27194; bugfix on 0.2.9.4-alpha.
    • In summarize_protover_flags(), treat empty strings the same as NULL. This prevents protocols_known from being set. Previously, we treated empty strings as normal strings, which led to protocols_known being set. Fixes bug 34232; bugfix on 0.3.3.2-alpha. Patch by Neel Chauhan.
  • Minor bugfixes (v2 onion services):
    • For HSFETCH commands on v2 onion services addresses, check the length of bytes decoded, not the base32 length. Fixes bug 34400; bugfix on 0.4.1.1-alpha. Patch by Neel Chauhan.
  • Code simplification and refactoring:
    • Add and use a set of functions to perform down-casts on constant connection and channel pointers. Closes ticket 40046.
    • Refactor our code that logs descriptions of connections, channels, and the peers on them, to use a single call path. This change enables us to refactor the data types that they use, and eliminates many confusing usages of those types. Closes ticket 40041.
    • Refactor some common node selection code into a single function. Closes ticket 34200.
    • Remove the now-redundant 'outbuf_flushlen' field from our connection type. It was previously used for an older version of our rate-limiting logic. Closes ticket 33097.
    • Rename "fascist_firewall_*" identifiers to "reachable_addr_*" instead, for consistency with other code. Closes ticket 18106.
    • Rename functions about "advertised" ports which are not in fact guaranteed to return the ports that have been advertised. Closes ticket 40055.
    • Split implementation of several command line options from options_init_from_torrc into smaller isolated functions. Patch by Daniel Pinto. Closes ticket 40102.
    • When an extend cell is missing an IPv4 or IPv6 address, fill in the address from the extend info. This is similar to what was done in ticket 33633 for ed25519 keys. Closes ticket 33816. Patch by Neel Chauhan.
  • Deprecated features:
    • The "non-builtin" argument to the "--dump-config" command is now deprecated. When it works, it behaves the same as "short", which you should use instead. Closes ticket 33398.
  • Documentation:
    • Replace URLs from our old bugtracker so that they refer to the new bugtracker and wiki. Closes ticket 40101.
  • Removed features:
    • We no longer ship or build a "tor.service" file for use with systemd. No distribution included this script unmodified, and we don't have the expertise ourselves to maintain this in a way that all the various systemd-based distributions can use. Closes ticket 30797.
    • We no longer ship support for the Android logging API. Modern versions of Android can use the syslog API instead. Closes ticket 32181.
    • The "optimistic data" feature is now always on; there is no longer an option to disable it from the torrc file or from the consensus directory. Closes part of 40139.
    • The "usecreatefast" network parameter is now removed; there is no longer an option for authorities to turn it off. Closes part of 40139.
  • Testing:
    • Add unit tests for bandwidth statistics manipulation functions. Closes ticket 33812. Patch by MrSquanchee.
  • Code simplification and refactoring (autoconf):
    • Remove autoconf checks for unused funcs and headers. Closes ticket 31699; Patch by @bduszel
  • Code simplification and refactoring (maintainer scripts):
    • Disable by default the pre-commit hook. Use the environment variable TOR_EXTRA_PRE_COMMIT_CHECKS in order to run it. Furthermore, stop running practracker in the pre-commit hook and make check-local. Closes ticket 40019.
  • Code simplification and refactoring (relay address):
    • Most of IPv4 representation was using "uint32_t". It has now been moved to use the internal "tor_addr_t" interface instead. This is so we can properly integrate IPv6 along IPv4 with common interfaces. Closes ticket 40043.
  • Documentation (manual page):
    • Move them from doc/ to doc/man/. Closes ticket 40044.
    • Describe the status of the "Sandbox" option more accurately. It is no longer "experimental", but it _is_ dependent on kernel and libc versions. Closes ticket 23378.
  • Documentation (tracing):
    • Document in depth the circuit subsystem trace events in the new doc/tracing/EventsCircuit.md. Closes ticket 40036.
Anonymous

November 01, 2020

Permalink

Regarding ticket 7193:

An IPv4 /32 is the same as an IPv6 /128, not /64. And if that's not convincing enough, DigitalOcean only hands out /124, which means you've just lumped together all the relays on DO as one. The equivalent analogy in IPv4-speak would be that you've lumped all /24 IPs together.

Heading the argument off at the pass, no, it doesn't violate RFCs, because the /64 delineation is meant to summarize global routing tables, not dictate what a provider does inside their own network (handing out IPs via DHCP, for instance). These IPs get summarized when they hit the AS routers, and the RFCs are satisfied.

Since this affects my relays directly, I'd appreciate and am voting for 7193 be changed to /128. Thank you.

> An IPv4 /32 is the same as an IPv6 /128, not /64

That depends. My residential ISP hands out /64's by default, or even /60's with a Prefix Delegation Hint. Doesn't that mean I could singlehandedly mount a Sybil attack against a /128-based rule?

> lumped together all the relays on DO as one

Isn't that kind of the point? The point of Sybil protection is to ensure diversity of the nodes in a given circuit. To most people, that means at most one node from any single entity. If we changed the rule to /128, clients could easily select three nodes hosted on DO, perhaps even the same customer, making a timing attack trivial. This has nothing to do with RFCs.

> Since this affects my relays directly, I'd appreciate and am voting for 7193 be changed to /128.

I'm curious why this is important to you. What actual problem is it causing for you? Why do you want clients to use more than one of your relays in the same circuit? And, aren't you specifying them as part of the same Family anyway? If you are hosting a lot of relays in the same /64... have you thought about hosting fewer relays and spreading them out across different networks?

Not arguing, just asking.

Join the discussion...

We encourage respectful, on-topic comments. Comments that violate our Code of Conduct will be deleted. Off-topic comments may be deleted at the discretion of the post moderator. Please do not comment as a way to receive support or report bugs on a post unrelated to a release. If you are looking for support, please see our support portal or ways to get in touch with us.

This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.

17 + 3 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.