<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/arti.git/crates/tor-consdiff/src/lib.rs, branch arti-v2.5.0</title>
<subtitle>mirror of https://gitlab.torproject.org/tpo/core/arti
</subtitle>
<id>http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v2.5.0</id>
<link rel='self' href='http://git.dilluti0n.com/mirrors/arti.git/atom?h=arti-v2.5.0'/>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/'/>
<updated>2026-06-10T15:34:39Z</updated>
<entry>
<title>consdiff: remove string slice usage</title>
<updated>2026-06-10T15:34:39Z</updated>
<author>
<name>Nick Mathewson</name>
<email>nickm@torproject.org</email>
</author>
<published>2026-06-10T15:34:39Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=ae3a3bfd4e3424b8c65f8a7bcaf03dd2951a54a0'/>
<id>urn:sha1:ae3a3bfd4e3424b8c65f8a7bcaf03dd2951a54a0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>everywhere: Add #[allow(clippy::string_slice)]</title>
<updated>2026-06-09T16:02:36Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-06-09T16:00:38Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=d0af4abbd7b371f1eade609202a730cd9a1c21d3'/>
<id>urn:sha1:d0af4abbd7b371f1eade609202a730cd9a1c21d3</id>
<content type='text'>
This commit adds #[allow(clippy::string_slice)] to all functions in the
code where string slices are used, alongside a TODO comment.

We do this add the function header to have it consistent, as things like
expression based allow's are still experimental.
</content>
</entry>
<entry>
<title>maint: Run maint/add_warning to deny string slices</title>
<updated>2026-06-09T15:36:01Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-06-09T15:36:01Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=9f5752a77fb57052c06ead0eeae606831f1e8e97'/>
<id>urn:sha1:9f5752a77fb57052c06ead0eeae606831f1e8e97</id>
<content type='text'>
This commit executes maint/add_warning with the just added change to
deny string slices except in tests.

I recommend auditing this by checking out the previous commit followed
by running the script yourself and then verifying that the diff is
identical to this commit.

This commit makes cargo clippy fail.  We will add exceptions in the next
commit.
</content>
</entry>
<entry>
<title>tor-consdiff: Apply comment suggestion</title>
<updated>2026-03-25T15:17:30Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-25T15:06:01Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=55bae2dbd87a741144a78e8c6445ac7e20ab6921'/>
<id>urn:sha1:55bae2dbd87a741144a78e8c6445ac7e20ab6921</id>
<content type='text'>
Co-authored-by: Ian Jackson</content>
</entry>
<entry>
<title>tor-consdiff: Prevent dotlines with WS tail</title>
<updated>2026-03-25T15:17:30Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-25T08:41:20Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=fe0fb0252b42185de5f4d69a84c7a82493f1de67'/>
<id>urn:sha1:fe0fb0252b42185de5f4d69a84c7a82493f1de67</id>
<content type='text'>
This commit modifies the dotline check to prevent generating lines that
consist of a single dot followed by an arbitrary amount of whitespace,
such as `.`, `. `, `. \t `, but not `. \t foo`.

It also adjusts the tests appropriately.
</content>
</entry>
<entry>
<title>tor-consdiff: Rename `.lno` to `.lno_for_error`</title>
<updated>2026-03-25T15:17:30Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-23T14:24:10Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=36033a42a8120a6bd12e4e819e0d29fa90d4d3ba'/>
<id>urn:sha1:36033a42a8120a6bd12e4e819e0d29fa90d4d3ba</id>
<content type='text'>
</content>
</entry>
<entry>
<title>tor-consdiff: Prevent dotlines properly</title>
<updated>2026-03-25T15:17:30Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-23T14:10:31Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=f516884cf05c8881122f70bf58c8bf19b66610f8'/>
<id>urn:sha1:f516884cf05c8881122f70bf58c8bf19b66610f8</id>
<content type='text'>
As pointed out by Diziet, our implementation does not reject dotlines
properly, due to our use of `trim_end()`.  This commit fixes this, by
just checking for `line == ".\n"`.  This is fine because we ensure Unix
line endings now anyways.
</content>
</entry>
<entry>
<title>tor-consdiff: Enforce Unix line endings</title>
<updated>2026-03-25T15:17:30Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-23T14:09:24Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=05bbdf523c1d72b10a4e2f4adb47279b9884634e'/>
<id>urn:sha1:05bbdf523c1d72b10a4e2f4adb47279b9884634e</id>
<content type='text'>
This commit changes the consdiff generation to enforce Unix line endings
and reject all other ones, including Windows line endings as well as no
line endings.  In other words, it checks for `\n` while forbidding
`\r\n`.

It also renames the relevant error variant to reflect this change
better.
</content>
</entry>
<entry>
<title>tor-consdiff: Justify our use of peek'ing</title>
<updated>2026-03-25T15:17:29Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-18T10:39:00Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=2244d3c286b4b8e095d394f2b8cd500334f0ce2b'/>
<id>urn:sha1:2244d3c286b4b8e095d394f2b8cd500334f0ce2b</id>
<content type='text'>
This is done to only get the first directory-signature.
</content>
</entry>
<entry>
<title>tor-consdiff: Refactor result composition</title>
<updated>2026-03-25T15:17:29Z</updated>
<author>
<name>Clara Engler</name>
<email>cve@cve.cx</email>
</author>
<published>2026-03-18T10:34:03Z</published>
<link rel='alternate' type='text/html' href='http://git.dilluti0n.com/mirrors/arti.git/commit/?id=de7663cd50e98fbe33fc9c47b493633ef1509963'/>
<id>urn:sha1:de7663cd50e98fbe33fc9c47b493633ef1509963</id>
<content type='text'>
This commit refactors the result composition by simply looping over
every line and checking whether it ends with a newline AND does not
consist of a single dot.
</content>
</entry>
</feed>
