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

[tor-commits] [tor/maint-0.3.5] Restore proper behavior of netinfo skew check



commit cd6cb453720a5300d00d7996c5b3a03f054cd293
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Thu Aug 8 09:15:42 2019 -0400

    Restore proper behavior of netinfo skew check
    
    My previous fix removed a comparison, which would have caused us to
    warn about every skew instead of skews of over an hour.
---
 src/or/channeltls.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/or/channeltls.c b/src/or/channeltls.c
index ea69792f1..d44f71913 100644
--- a/src/or/channeltls.c
+++ b/src/or/channeltls.c
@@ -1721,7 +1721,7 @@ channel_tls_process_netinfo_cell(cell_t *cell, channel_tls_t *chan)
   /* Act on apparent skew. */
   /** Warn when we get a netinfo skew with at least this value. */
 #define NETINFO_NOTICE_SKEW 3600
-  if (time_abs(apparent_skew) &&
+  if (time_abs(apparent_skew) > NETINFO_NOTICE_SKEW &&
       router_get_by_id_digest(chan->conn->identity_digest)) {
     int trusted = router_digest_is_trusted_dir(chan->conn->identity_digest);
     clock_skew_warning(TO_CONN(chan->conn), apparent_skew, trusted, LD_GENERAL,



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