summaryrefslogtreecommitdiff
path: root/changes
AgeCommit message (Collapse)Author
2017-06-29Consider the exit family when applying guard restrictions.Nick Mathewson
When the new path selection logic went into place, I accidentally dropped the code that considered the _family_ of the exit node when deciding if the guard was usable, and we didn't catch that during code review. This patch makes the guard_restriction_t code consider the exit family as well, and adds some (hopefully redundant) checks for the case where we lack a node_t for a guard but we have a bridge_info_t for it. Fixes bug 22753; bugfix on 0.3.0.1-alpha. Tracked as TROVE-2016-006 and CVE-2017-0377.
2017-06-27Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-06-27Merge branch 'maint-0.2.8' into maint-0.2.9Nick Mathewson
2017-06-27Merge branch 'maint-0.2.7-redux' into maint-0.2.8Nick Mathewson
2017-06-27Merge branch 'maint-0.2.6' into maint-0.2.7-reduxNick Mathewson
2017-06-27Merge branch 'maint-0.2.5' into maint-0.2.6Nick Mathewson
2017-06-27Merge branch 'maint-0.2.4' into maint-0.2.5Nick Mathewson
2017-06-27Fix an errant memset() into the middle of a struct in cell_pack().Nick Mathewson
This mistake causes two possible bugs. I believe they are both harmless IRL. BUG 1: memory stomping When we call the memset, we are overwriting two 0 bytes past the end of packed_cell_t.body. But I think that's harmless in practice, because the definition of packed_cell_t is: // ... typedef struct packed_cell_t { TOR_SIMPLEQ_ENTRY(packed_cell_t) next; char body[CELL_MAX_NETWORK_SIZE]; uint32_t inserted_time; } packed_cell_t; So we will overwrite either two bytes of inserted_time, or two bytes of padding, depending on how the platform handles alignment. If we're overwriting padding, that's safe. If we are overwriting the inserted_time field, that's also safe: In every case where we call cell_pack() from connection_or.c, we ignore the inserted_time field. When we call cell_pack() from relay.c, we don't set or use inserted_time until right after we have called cell_pack(). SO I believe we're safe in that case too. BUG 2: memory exposure The original reason for this memset was to avoid the possibility of accidentally leaking uninitialized ram to the network. Now remember, if wide_circ_ids is false on a connection, we shouldn't actually be sending more than 512 bytes of packed_cell_t.body, so these two bytes can only leak to the network if there is another bug somewhere else in the code that sends more data than is correct. Fortunately, in relay.c, where we allocate packed_cell_t in packed_cell_new() , we allocate it with tor_malloc_zero(), which clears the RAM, right before we call cell_pack. So those packed_cell_t.body bytes can't leak any information. That leaves the two calls to cell_pack() in connection_or.c, which use stack-alocated packed_cell_t instances. In or_handshake_state_record_cell(), we pass the cell's contents to crypto_digest_add_bytes(). When we do so, we get the number of bytes to pass using the same setting of wide_circ_ids as we passed to cell_pack(). So I believe that's safe. In connection_or_write_cell_to_buf(), we also use the same setting of wide_circ_ids in both calls. So I believe that's safe too. I introduced this bug with 1c0e87f6d8c7a0abdadf1b5cd9082c10abc7f4e2 back in 0.2.4.11-alpha; it is bug 22737 and CID 1401591
2017-06-19Don't expand guard sample set unless consensus is "reasonably live"Nick Mathewson
Fixes what I think is the main root cause of 22400. Bugfix on 0.3.0.1-alpha.
2017-06-19Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-06-16Permit the fchmod system call.Nick Mathewson
Fixes bug 22516; bugfix on 0.2.5.4-alpha.
2017-06-09Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-06-09Merge branch 'maint-0.2.8' into maint-0.2.9Nick Mathewson
2017-06-09Merge branch 'maint-0.2.7-redux' into maint-0.2.8Nick Mathewson
2017-06-09Merge branch 'maint-0.2.6' into maint-0.2.7-reduxNick Mathewson
2017-06-09Merge branch 'maint-0.2.5' into maint-0.2.6Nick Mathewson
2017-06-09Merge branch 'maint-0.2.4' into maint-0.2.5Nick Mathewson
2017-06-09Update geoip and geoip6 to the June 8 2017 database.Karsten Loesing
2017-06-08bump to 0.3.0.8Nick Mathewson
2017-06-08Merge branch 'maint-0.2.7-redux' into maint-0.2.8Nick Mathewson
2017-06-08Merge branch 'maint-0.2.6' into maint-0.2.7-reduxNick Mathewson
2017-06-08Merge branch 'maint-0.2.5' into maint-0.2.6Nick Mathewson
2017-06-08Merge branch 'maint-0.2.4' into maint-0.2.5Nick Mathewson
2017-06-08Merge branch 'maint-0.2.8' into maint-0.2.9Nick Mathewson
2017-06-08Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-06-08TROVE-2017-005: Fix assertion failure in connection_edge_process_relay_cellDavid Goulet
On an hidden service rendezvous circuit, a BEGIN_DIR could be sent (maliciously) which would trigger a tor_assert() because connection_edge_process_relay_cell() thought that the circuit is an or_circuit_t but is an origin circuit in reality. Fixes #22494 Reported-by: Roger Dingledine <arma@torproject.org> Signed-off-by: David Goulet <dgoulet@torproject.org>
2017-06-08Another changes fix.Nick Mathewson
2017-06-08tweak changes file.Nick Mathewson
2017-06-08TROVE-2017-004: Fix assertion failure in relay_send_end_cell_from_edge_David Goulet
This fixes an assertion failure in relay_send_end_cell_from_edge_() when an origin circuit and a cpath_layer = NULL were passed. A service rendezvous circuit could do such a thing when a malformed BEGIN cell is received but shouldn't in the first place because the service needs to send an END cell on the circuit for which it can not do without a cpath_layer. Fixes #22493 Reported-by: Roger Dingledine <arma@torproject.org> Signed-off-by: David Goulet <dgoulet@torproject.org>
2017-06-05Merge branch 'bug22460_030_01' into maint-0.3.0Nick Mathewson
2017-06-05Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-06-05Merge branch 'bug22460_case2_029_01_squashed' into maint-0.2.9Nick Mathewson
2017-06-05Changes file for the x509 link certificate case of bug22460Nick Mathewson
2017-06-05Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-06-05Merge branch 'maint-0.2.8' into maint-0.2.9Nick Mathewson
2017-06-05Merge branch 'maint-0.2.7-redux' into maint-0.2.8Nick Mathewson
2017-06-05Merge branch 'maint-0.2.6' into maint-0.2.7-reduxNick Mathewson
2017-06-05Merge branch 'maint-0.2.5' into maint-0.2.6Nick Mathewson
2017-06-05Merge branch 'maint-0.2.4' into maint-0.2.5Nick Mathewson
2017-06-05Fix undefined behavior in geoip_parse_entry().Nick Mathewson
Fixes bug 22490; bugfix on 6a241ff3ffe7dc1 in 0.2.4.6-alpha. Found by teor using clang-5.0's AddressSanitizer stack-use-after-scope.
2017-06-01Regenerate RSA->ed25519 identity crosscertificate as neededNick Mathewson
2017-06-01Fix ed25519 link certificate race on tls context rotationNick Mathewson
Whenever we rotate our TLS context, we change our Ed25519 Signing->Link certificate. But if we've already started a TLS connection, then we've already sent the old X509 link certificate, so the new Ed25519 Signing->Link certificate won't match it. To fix this, we now store a copy of the Signing->Link certificate when we initialize the handshake state, and send that certificate as part of our CERTS cell. Fixes one case of bug22460; bugfix on 0.3.0.1-alpha.
2017-05-31Bugfix: Regenerate more certificates when appropriateNick Mathewson
Previously we could sometimes change our signing key, but not regenerate the certificates (signing->link and signing->auth) that were signed with it. Also, we would regularly replace our TLS x.509 link certificate (by rotating our TLS context) but not replace our signing->link ed25519 certificate. In both cases, the resulting inconsistency would make other relays reject our link handshakes. Fixes two cases of bug 22460; bugfix on 0.3.0.1-alpha.
2017-05-30hs: Correctly validate v3 descriptor encrypted lengthDavid Goulet
The encrypted_data_length_is_valid() function wasn't validating correctly the length of the encrypted data of a v3 descriptor. The side effect of this is that an HSDir was rejecting the descriptor and ultimately not storing it. Fixes #22447 Signed-off-by: David Goulet <dgoulet@torproject.org>
2017-05-25Merge branch 'maint-0.2.9' into maint-0.3.0Roger Dingledine
2017-05-25Stop leaking keypin-rejected routerinfos on directory authoritiesteor
When directory authorities reject a router descriptor due to keypinning, free the router descriptor rather than leaking the memory. Fixes bug 22370; bugfix on 0.2.7.2-alpha.
2017-05-22Merge branch 'maint-0.2.9' into maint-0.3.0Nick Mathewson
2017-05-22dir auths reject 0.2.9.x for x<5, due to bug 20499Roger Dingledine
Directory authorities now reject relays running versions 0.2.9.1-alpha through 0.2.9.4-alpha, because those relays suffer from bug 20499 and don't keep their consensus cache up-to-date. Resolves ticket 20509.
2017-05-18Merge branch 'bug22252_029' into maint-0.3.0Nick Mathewson
2017-05-16Fix crash when starting with LearnCircuitBuildTimeout 0.Nick Mathewson
Before we've set our options, we can neither call get_options() nor networkstatus_get_latest_consensus(). Fixes bug 22252; bugfix on 4d9d2553baa6856b1d85ec26baa1ac3d2c24832a in 0.2.9.3-alpha.