[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-dev] Timers in Arti?
- To: tor-dev@xxxxxxxxxxxxxxxxxxxx
- Subject: Re: [tor-dev] Timers in Arti?
- From: Micah Elizabeth Scott <beth@xxxxxxxxxxxxxx>
- Date: Mon, 8 Jan 2024 13:01:04 -0800
- Autocrypt: addr=beth@xxxxxxxxxxxxxx; keydata= xsFNBGOk0k4BEADMmqJPFcteTrlYYgKDLdD4jmYgFQbb3B9WPrlDymAuMCsyMgxiYkyaP6bU C/VsAcUp5UVpWWkE66hqsqkJsrrEPC96YdlqWvkHOHyxyRQq731d80TFARhhkWH+w1XEzMPe qASy6bvPFNRba5ZCO4WHKG7KU5IM9fKxjmVmfSUl0jjaI+qmkr6h1kht/ywjp2lj3PKqEhiy wRBilR6XU+zQ1rJjFhSb5IkhB5Nw9T4kOsOzP//j2p0al2ZnN6BI/3ZTUGwkRWnsd2nVcgsb eMUcuwAWuAbH1yIxrw82FeOk3qskU00TwBvLzfBtQ8HLio5MXHloMD5omBIAbodj9kF8+RMk PQNPgSJ5s8oB/yTjgyw5ZIjd8HhjqKTcgXj/MurKja0tAZJ8v8EGEQB8ZVrL9XPdwawK4TG0 NAyp1jAlXSHr5jPiJd2Tg/uKF2tBD2hb3qOEa4+mUgh3m0rRMdYKH9UUw5VwtGi+tng2ORaF ULLVKZUWS1cE/7N8Tqn2BCUd+4LpDdvjcEzheSqsCNDjMEz5WtQjkbIdukcEoVB6UlFctBIU pmdxp1yszgxaAz73wBRSnGRFOWXA2T/FH6F4Z2XIIZlxM0RkLXGCOVdSGlkhmRxY7jrBvQ9h TMPRlqg7FSzibfRUqLZKUq/iXx7UMZjFjjRb9fSZrJV34RzVOwARAQABzStNaWNhaCBFbGl6 YWJldGggU2NvdHQgPGJldGhAdG9ycHJvamVjdC5vcmc+wsGOBBMBCgA4FiEECfIdYFIjkh9/ bu/67jR5N4i4MYMFAmOk0k4CGwMFCwkIBwIGFQoJCAsCBBYCAwEC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JQTSeUfb7vBRK8zgytkfAm2cg==
- Delivered-to: archiver@xxxxxxxx
- Delivery-date: Mon, 08 Jan 2024 16:01:22 -0500
- Dkim-signature: v=1; a=rsa-sha256; c=simple/simple; d=torproject.org; s=2022-eugeni; t=1704747675; bh=fgYxOpKDB/6JK0kz/5As3WwiwQEPvnpGjUCpI4BKFzM=; h=Date:To:References:From:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: Reply-To:From; b=t6t3b7G1Blyw9nz0JYMqlwWqK30ZtQ8mC1MpHFuD/CO0bl24sYgJdsKZOQvCqOfY4 Afu/lG8igYpF/9UFlbHw4Wf6Mba6cGfvxs6yl4w2DO4aujtTC2P431znW0zIHZDwL5 cdr/FHnVtkrgJuFX+VcudP5l+S7EEbLQD2h76300gv/P/N/VvoaxdR+06dhgK54xWE shUwkUTJGJnRJ8P1T090Gb/ILHgJWVLc0Pdfg8JjhPLUuL5SrYRv3/2LgJ2WlXR/T8 o46Qyfd/vq1yoTn8WVHHcfSmgjCUW0bzH/bp77htwRJ3YyXiXVvxc1M3r/67u9D6Tr Giv2r6qtNsAjA==
- In-reply-to: <00360392-fb4f-4436-8543-5c0d36e137e3@briarproject.org>
- List-archive: <http://lists.torproject.org/pipermail/tor-dev/>
- List-help: <mailto:tor-dev-request@lists.torproject.org?subject=help>
- List-id: discussion regarding Tor development <tor-dev.lists.torproject.org>
- List-post: <mailto:tor-dev@lists.torproject.org>
- List-subscribe: <https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-dev>, <mailto:tor-dev-request@lists.torproject.org?subject=subscribe>
- List-unsubscribe: <https://lists.torproject.org/cgi-bin/mailman/options/tor-dev>, <mailto:tor-dev-request@lists.torproject.org?subject=unsubscribe>
- References: <00360392-fb4f-4436-8543-5c0d36e137e3@briarproject.org>
- Reply-to: tor-dev@xxxxxxxxxxxxxxxxxxxx
- Sender: "tor-dev" <tor-dev-bounces@xxxxxxxxxxxxxxxxxxxx>
A variety of timers are needed on the relay side; on the client side
though, aren't you mostly limited by the requirement of keeping a TCP
connection open?
Really deep sleep would involve avoiding any protocol-level keepalives
as well as TCP keepalives. This seems a lot like just shutting down the
connection to the guard when sleeping; but of course that's got a
latency penalty and it's visible to anyone who can see network activity.
-beth
On 1/4/24 04:48, Michael Rogers wrote:
Hi,
If I understand right, the C implementation of Tor has various state
machines that are driven by local libevent timers as well as events
from the network. For example, when building a circuit, if there
hasn't been any progress for a certain amount of time then a timer
fires to handle the timeout.
When running Tor on Android, we need to prevent the OS from suspending
so that these timers fire when they're supposed to. This uses a lot of
battery, because normally the OS would spend most of its time
suspended. Unlike a laptop, an Android device with its screen turned
off is constantly dipping in an out of suspension, and a lot of the
platform's power optimisations are aimed at batching whatever work
needs to be done so that the periods of suspension can be longer.
If we allowed the OS to suspend then the timers would fire with
arbitrary delays, and I don't really know what impact that would have:
I'd speculate that there might be connectivity problems (eg dead
circuits not being detected and replaced) and/or network-visible
changes in the behaviour of circuits that could affect anonymity.
So I've had a longstanding but not-very-hopeful request that maybe
Tor's reliance on timers could be reduced, or at least clarified, so
that we could either allow the OS to suspend without breaking
anything, or at least know what was likely to break.
And basically I'd just like to renew that request for Arti. Could
anyone give me an overview of how these local timers are handled in
Arti, or any information about what's likely to happen if the timers
are arbitrarily delayed?
Thanks,
Michael
_______________________________________________
tor-dev mailing list
tor-dev@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-dev
_______________________________________________
tor-dev mailing list
tor-dev@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-dev