idmapper

package module
v0.0.0-...-ae0a138 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2025 License: Apache-2.0 Imports: 5 Imported by: 12

README

idmapper

Go Report Card Go Reference

idmapper is a package which will map a process to the highest usera id available.

Unlike the newuidmap and newgidmap commands found in Shadow, idmapper does not require this user to exist and will not check /etc/subuid for valid subuid ranges.

[!NOTE]

This repository should be imported as code.cloudfoundry.org/idmapper.

Contributing

See the Contributing.md for more information on how to contribute.

Working Group Charter

This repository is maintained by App Runtime Platform under Garden Containers area.

[!IMPORTANT]

Content in this file is managed by the CI task sync-readme and is generated by CI following a convention.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Max

func Max(a, b int) int

func Min

func Min(a, b int) int

func MustGetMaxValidGID

func MustGetMaxValidGID() int

func MustGetMaxValidUID

func MustGetMaxValidUID() int

Types

type IDMap

type IDMap string
const DefaultGIDMap IDMap = "/proc/self/gid_map"
const DefaultUIDMap IDMap = "/proc/self/uid_map"

func (IDMap) MaxValid

func (u IDMap) MaxValid() (int, error)

type MappingList

type MappingList []specs.LinuxIDMapping

func (MappingList) Map

func (m MappingList) Map(id int) int

func (MappingList) String

func (m MappingList) String() string

type ParseError

type ParseError struct {
	Line string
	Err  error
}

func (ParseError) Error

func (p ParseError) Error() string

Directories

Path Synopsis
cmd
integration

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL