feat: implement Go-native EROFS format parser, fsck validator, and compiler #12
All Vouch review confidence checks passed
Residual risk 0.25 = Change Risk (0.44) × (1 − Review Confidence (0.44)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.44 · 136 lines diff across 1 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 10%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.294
No Reviewer Assigned
no_reviewer_assigned
0.120
Real PR Conversation Timeline
1 comments
"Review active on #12"
general
weight: 0.35
codebot-robot
This PR implements a safe, highly robust Go-native implementation of the EROFS format for image layer verification and traversal.
Key Contributions:
1. pkg/erofs Package:
- Complete on-disk parser for Superblock, Compact/Extended Inodes, and Directory entries.
- Dynamic filename length calculations with support for trailing padding null-bytes on block-aligned filesystems.
- High-level
Readerfor easy traversal, metadata querying, and file content reading.- Deterministic EROFS image compiler (
WriteImage) that builds standard-compliant EROFS images from arbitrary virtual directory trees.2. Safe Fsck-Style Validation:
- A single-pass, recursive, depth-first
Fsckparser that guarantees image integrity and prevents malicious exploits.- Enforces loop/cycle detection, recursion depth capping (max 100), file path traversal boundaries (preventing
/, empty names, and\x00characters), and metadata block bounds auditing.3. Research Documentation:
- Comprehensive technical documentation added to
docs/research/erofs-format.md.Fixes #11