Skip to content

fix: v0.9.1 download directory hardening - #38

Merged
drptbl merged 3 commits into
mainfrom
fix/download-hardening
Nov 15, 2026
Merged

drptbl merged 3 commits into
mainfrom
fix/download-hardening

Conversation

@drptbl

@drptbl drptbl commented Nov 15, 2026

Copy link
Copy Markdown
Owner

Hardening for the download directory every home shares since v0.9.0.

changes:

  • each install now checks and installs a copy of its own (a hard link to the kept package, or its download), so another home renaming a file into place between the SHA-256 check and logosctl package install can't swap what gets installed
  • a package the catalog gives no SHA-256 for is installed from its own download and never kept, instead of reusing whatever file was there
  • downloads clean up temp files a crashed run left, once they're a day old, judged by the newest file in them and matched by exact name
  • temp names carry the time as well as the process id, so a reused pid can't collide
  • bumped the version to 0.9.1

Every home shares the download directory, so temp downloads from a crashed run would pile up. Each download now removes ones a day old, matched by exact name and judged by the newest file in them, and temp names carry the time so a reused process id can't collide.
Another home could rename different bytes onto a shared package between the SHA-256 check and the install. Each install now checks and installs a hard link or download of its own, and a package the catalog gives no SHA-256 for is never kept.
@drptbl
drptbl merged commit 1cacdb9 into main Nov 15, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant