Skip to main content

Module paths

Module paths 

Source
Expand description

Archive paths are labels, never destinations. They are normalised on the way in and validated again on the way out, so an archive can never write outside the target directory.

Constants§

MAX_DEPTH
Components a path may have (docs/V1-CONTRACT.md §4).

Functions§

normalize
Normalise a path for storage: NFC, forward slashes, relative, no ./.., no drive letters, no NUL/control characters, no : (NTFS alternate data streams), no Windows reserved names, no trailing spaces or dots in components, at most 4096 bytes.
safe_join
Join a validated archive path under root, component by component.