Documentation
¶
Overview ¶
Package safepath provides root-anchored path joins that reject traversal. All operations are pure functions with no I/O side effects.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAbsolute = errors.New("safepath: name must not be absolute")
ErrAbsolute is returned when the name is an absolute path.
View Source
var ErrEmpty = errors.New("safepath: name must not be empty")
ErrEmpty is returned when the name is empty.
View Source
var ErrEscapesRoot = errors.New("safepath: path escapes root")
ErrEscapesRoot is returned when a name resolves to a path outside the root.
View Source
var ErrNUL = errors.New("safepath: name must not contain NUL")
ErrNUL is returned when the name contains a NUL byte.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.