Expand description
Path validation and canonicalization utilities.
Provides security-critical path validation to prevent directory traversal attacks. All file access operations MUST validate paths before accessing filesystem resources.
Enums§
- Path
Validation Error - Error types for path validation.
Functions§
- canonicalize_
path - Canonicalize a path using std::fs::canonicalize.
- has_
suspicious_ traversal - Check for suspicious path traversal patterns.
- is_
safe_ symlink - Check if a symlink is safe (doesn’t escape project root).
- validate_
path_ within_ root - Validate that a path is within the given root directory.
- validate_
utf8_ path - Validate a UTF-8 path using camino’s Utf8Path.