package path

import "github.com/containers/storage/pkg/chunked/internal/path"

Index

Functions

func CleanAbsPath

func CleanAbsPath(path string) string

CleanAbsPath removes any ".." and "." from the path and ensures it starts with a "/". If the path refers to the root directory, it returns "/".

func RegularFilePathForValidatedDigest

func RegularFilePathForValidatedDigest(d digest.Digest) (string, error)

RegularFilePath returns the path used in the composefs backing store for a regular file with the provided content digest.

The caller MUST ensure d is a valid digest (in particular, that it contains no path separators or .. entries)

Source Files

path.go

Version
v1.59.0 (latest)
Published
Jul 14, 2025
Platform
linux/amd64
Imports
3 packages
Last checked
3 hours ago

Tools for package owners.