<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/arti.git/crates/tor-netdir/src/hsdir_params.rs, branch arti-v1.2.7</title>
<subtitle>mirror of https://gitlab.torproject.org/tpo/core/arti
</subtitle>
<id>http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v1.2.7</id>
<link rel='self' href='http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v1.2.7'/>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/'/>
<updated>2024-03-13T16:30:53Z</updated>
<entry>
<title>Run maint/add_warning.</title>
<updated>2024-03-13T16:30:53Z</updated>
<author>
<name>Nick Mathewson</name>
<email>nickm@torproject.org</email>
</author>
<published>2024-03-13T16:30:53Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=c0c9bd15d42897825dd0ab3d3b8dd1c17bd6320c'/>
<id>urn:sha1:c0c9bd15d42897825dd0ab3d3b8dd1c17bd6320c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix typos in doc comments</title>
<updated>2024-03-06T19:52:42Z</updated>
<author>
<name>Tobias Stoeckmann</name>
<email>tobias@stoeckmann.org</email>
</author>
<published>2024-03-06T19:05:17Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=18db641cca83fa707b3a97fa2975f99063f08875'/>
<id>urn:sha1:18db641cca83fa707b3a97fa2975f99063f08875</id>
<content type='text'>
</content>
</entry>
<entry>
<title>tor-netdir: Add a unit test for HsDirParams::offset_within_srv_period.</title>
<updated>2024-01-24T16:42:43Z</updated>
<author>
<name>Gabriela Moldovan</name>
<email>gabi@torproject.org</email>
</author>
<published>2024-01-24T16:42:43Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=14445e8bb0f3daa9420a3330614eeb4874bf881d'/>
<id>urn:sha1:14445e8bb0f3daa9420a3330614eeb4874bf881d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>tor-hsservice: Make offset_within_srv_period() work with timestamps from newer periods.</title>
<updated>2024-01-24T15:58:55Z</updated>
<author>
<name>Gabriela Moldovan</name>
<email>gabi@torproject.org</email>
</author>
<published>2024-01-24T15:51:31Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=5050e8c367ba0fb09552d93d3878a193f45678f2'/>
<id>urn:sha1:5050e8c367ba0fb09552d93d3878a193f45678f2</id>
<content type='text'>
This fixes a bug where `offset_within_srv_period()` returns `None`,
instead of the offset of `when` from the start of the SRV of the
previous time period:

```
2024-01-24T15:24:46Z ERROR tor_hsservice::svc::publish::reactor: descriptor upload failed for HS service
allium-cepa2 and time period TimePeriod { interval_num: 19745, length: IntegerMinutes { value: 1440 },
epoch_offset_in_sec: 43200 }: error: Programming error: internal error (bug) at
/../arti/crates/tor-hsservice/src/svc/publish/reactor.rs:218:13: current wallclock time not within
SRV range?! (now=SystemTime { tv_sec: 1706109886, tv_nsec: 246572852 },
SRV_start=SystemTime { tv_sec: 1705968000, tv_nsec: 0 })
```

We need to be able to calculate this offset even if `now` is not within
the SRV range (because we upload the descriptor to the HsDirs of the
*previous* time period too).

Note a similar bug exited in `offset_within_period()` (which no longer
exists) too! That one was fixed in !1744:

```
Hidden services can have multiple "active" time periods for which they
generate descriptors. We need to be able to compute the offset of a
timestamp from the start of a given time period, even if that timestamp
falls within the "next" time period (for example, when publishing
descriptors for the "previous" time period, the `when` timestamp will
fall outside the `(start, end)` range of the "previous" time period).
```
</content>
</entry>
<entry>
<title>tor-netdir, tor-hscrypto: Add function for computing SRV period offset.</title>
<updated>2024-01-24T11:22:53Z</updated>
<author>
<name>Gabriela Moldovan</name>
<email>gabi@torproject.org</email>
</author>
<published>2024-01-23T19:05:33Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=b487b7e8d6dfaaf7c65ea2ea30083d87dd1e785c'/>
<id>urn:sha1:b487b7e8d6dfaaf7c65ea2ea30083d87dd1e785c</id>
<content type='text'>
Part of #1166
</content>
</entry>
<entry>
<title>Expose HsDirParams, and give it accessors.</title>
<updated>2024-01-23T13:57:16Z</updated>
<author>
<name>Nick Mathewson</name>
<email>nickm@torproject.org</email>
</author>
<published>2024-01-23T13:40:59Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=188e201622e345c220de77bf0edd006804271932'/>
<id>urn:sha1:188e201622e345c220de77bf0edd006804271932</id>
<content type='text'>
</content>
</entry>
<entry>
<title>hsservice: Make HsDirParams include the SRV lifespan.</title>
<updated>2024-01-23T13:34:29Z</updated>
<author>
<name>Nick Mathewson</name>
<email>nickm@torproject.org</email>
</author>
<published>2024-01-23T13:31:48Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=712a29e7c260d2dbabbf3f9a0dc3f4e8c956cc83'/>
<id>urn:sha1:712a29e7c260d2dbabbf3f9a0dc3f4e8c956cc83</id>
<content type='text'>
This is part of #1254.
</content>
</entry>
<entry>
<title>Run maint/add_warning to add lint block everywhere</title>
<updated>2023-08-23T09:34:00Z</updated>
<author>
<name>Ian Jackson</name>
<email>ijackson@chiark.greenend.org.uk</email>
</author>
<published>2023-08-22T14:28:12Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=42df88d6bf6dbb460d2e5e1cd4838aafaffbe9ac'/>
<id>urn:sha1:42df88d6bf6dbb460d2e5e1cd4838aafaffbe9ac</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Run maint/add_warning to actually apply new lint allows</title>
<updated>2023-07-10T12:49:51Z</updated>
<author>
<name>Ian Jackson</name>
<email>ijackson@chiark.greenend.org.uk</email>
</author>
<published>2023-07-10T11:19:32Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=473447a82e099fd52a674c28f5bc24b3e05208c0'/>
<id>urn:sha1:473447a82e099fd52a674c28f5bc24b3e05208c0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Downgrade TODO HS on HsDirParams::compute().expect()</title>
<updated>2023-06-29T12:19:37Z</updated>
<author>
<name>Nick Mathewson</name>
<email>nickm@torproject.org</email>
</author>
<published>2023-06-26T18:12:55Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=c565a67689ba6d2b8b3f59448c66e9b4bf34e072'/>
<id>urn:sha1:c565a67689ba6d2b8b3f59448c66e9b4bf34e072</id>
<content type='text'>
(Adding comments explaining that these errors are really
unlikely to occur, unless there is a bug in our code or in Rust's
time handling.)
</content>
</entry>
</feed>
