Skip to content

casync#9

Open
samcday wants to merge 2 commits intomainfrom
fastboop-casync
Open

casync#9
samcday wants to merge 2 commits intomainfrom
fastboop-casync

Conversation

@samcday
Copy link
Owner

@samcday samcday commented Feb 16, 2026

No description provided.

@samcday
Copy link
Owner Author

samcday commented Feb 16, 2026

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4a7857c271

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

fn decode_chunk_payload(encoded: &[u8]) -> GibbloxResult<Vec<u8>> {
validate_chunk_bounds(encoded.len())?;

match detect_compression(encoded) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Bypass compression sniffing for raw chunk fallback

This decoder path is used even after fetch_chunk_payload falls back from .cacnk to the raw chunk object, but decode_chunk_payload still guesses compression from magic bytes. Raw casync chunks are arbitrary bytes, so any raw chunk beginning with gzip/zstd/xz signatures will be misclassified as compressed and then fail decode (or decode to different bytes and fail digest verification), making valid chunks unreadable. This can break reconstruction on legitimate stores that include raw chunks for incompressible content.

Useful? React with 👍 / 👎.

Here's a whole bunch of machinery to handle fetching and parsing casync
indexes and chunks.

casync kinda breaks the nice compositional layers we were going for with
gibblox, but it's salvageable, maybe.

so first we land all this mess and see if we can actually get it to
work. if so, we'll see if anything needs to be rejiggered to enable
better sharing of the http read path and caching that gibblox-casync is
duplicating from gibblox-http + gibblox-cache

Signed-off-by: Sam Day <me@samcday.com>
Assisted-by: opencode:gpt-5.3-codex
Signed-off-by: Sam Day <me@samcday.com>
Assisted-by: opencode:gpt-5.3-codex
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

Comments