Help us shape the future of Go! Take the 2026 Go Developer Survey

keyctl

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KEYCTL_PERM_VIEW    = uint32(1 << 0)
	KEYCTL_PERM_READ    = uint32(1 << 1)
	KEYCTL_PERM_WRITE   = uint32(1 << 2)
	KEYCTL_PERM_SEARCH  = uint32(1 << 3)
	KEYCTL_PERM_LINK    = uint32(1 << 4)
	KEYCTL_PERM_SETATTR = uint32(1 << 5)
	KEYCTL_PERM_ALL     = uint32((1 << 6) - 1)

	KEYCTL_PERM_OTHERS  = 0
	KEYCTL_PERM_GROUP   = 8
	KEYCTL_PERM_USER    = 16
	KEYCTL_PERM_PROCESS = 24
)
View Source
const KeyCtlBackend = keyring.KeyCtlBackend

Variables

View Source
var (
	ErrKeyNotFound          = keyring.ErrKeyNotFound
	ErrMetadataNotSupported = keyring.ErrMetadataNotSupported
	ErrUnavailable          = keyring.ErrUnavailable
)

Functions

func GetKeyringIDForScope

func GetKeyringIDForScope(scope string) (int32, error)

GetKeyringIDForScope get the keyring ID for a given scope.

func GetPermissions

func GetPermissions(process, user, group, others uint32) uint32

GetPermissions constructs the permission mask from the elements.

func Provider

func Provider(opts ...Option) keyring.Provider

Types

type Config

type Config struct {
	ServiceName string
	KeyCtlScope string
	KeyCtlPerm  uint32
}

type Item

type Item = keyring.Item

type Metadata

type Metadata = keyring.Metadata

type Option

type Option func(*Config)

func Perm

func Perm(perm uint32) Option

func Scope

func Scope(scope string) Option

Jump to

Keyboard shortcuts

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