Documentation
¶
Overview ¶
Package pathutil provides shared relative-path validation for the sync tree.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanRel ¶
CleanRel validates and normalizes a slash-separated relative path for use as an index key and os.Root name. It rejects empty, absolute, non-local, and "." paths, and any reserved path component.
CleanRel does not bind to a root directory; callers that need escape checks against a concrete Dir should join and re-validate with filepath.Rel.
func IsReservedComponent ¶
IsReservedComponent reports whether a single path component is reserved for tailsync state. Scan skips these directories; peer path validation rejects any path that contains them so StateDir (Dir/.tailsync) cannot be targeted.
Types ¶
This section is empty.