GLKFS append: refuse oversized files, NULL-safe CRC - #2
Closed
Pitchfork-and-Torch wants to merge 2 commits into
Closed
Pitchfork-and-Torch wants to merge 2 commits into
Pitchfork-and-Torch wants to merge 2 commits into
Conversation
…leton, observe-only Bench, host CI. Authorized research RTOS. MIT.
Check inode size before the fixed scratch read, and treat NULL write payloads as zero-fill for CRC so vault-sized appends fail closed.
Owner
Author
|
Folded into single-commit main (d6a9c20). Public product history stays one commit. Branch will be deleted. |
Pitchfork-and-Torch
force-pushed
the
main
branch
from
September 18, 2026 00:51
8aa65d6 to
d6a9c20
Compare
Pitchfork-and-Torch
deleted the
cursor/glkfs-append-truncation-guard
branch
September 18, 2026 00:51
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
glk_fs_appendread into a 2048-byte scratch buffer viaglk_fs_read, which silently caps. A larger file plus a zero-length append could rewrite a truncated copy.GLK_ERR_FULLinstead of truncating.crc32_bytestreats a NULL payload as zero-fill soglk_fs_write(name, NULL, n)matches the bytes on disk.Test plan
test_storage_v39(append of 2100-byte file returns FULL)ctest(10/10)