security

package
v0.0.0-...-3434a82 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AdminPassword

func AdminPassword(user, secretName, namespace string, k *kube.Kubernetes, ctx context.Context) (string, error)

func CreateIdentitiesFor

func CreateIdentitiesFor(usr string, pass string) ([]byte, error)

CreateIdentitiesFor creates identities for a given username/password combination

func FindPassword

func FindPassword(usr string, descriptor []byte) (string, error)

FindPassword finds a user's password

func GenerateTruststore

func GenerateTruststore(pemFiles [][]byte, password string) ([]byte, error)

func GetAdminCredentials

func GetAdminCredentials(user string) ([]byte, error)

GetAdminCredentials get admin identities credentials in yaml format

func GetUserCredentials

func GetUserCredentials() ([]byte, error)

GetUserCredentials get identities credentials in yaml format

func IdentitiesCliFileFromSecret

func IdentitiesCliFileFromSecret(buf []byte, realm, usersFile, groupsFile string) (string, error)

func UserPassword

func UserPassword(user, secretName, namespace string, k *kube.Kubernetes, ctx context.Context) (string, error)

Types

type Credentials

type Credentials struct {
	Username string
	Password string
	Roles    []string
}

Credentials represent individual username/password combinations

type Identities

type Identities struct {
	Credentials []Credentials
}

Identities represent identities that can interact with server

type IdentitiesYaml

type IdentitiesYaml struct {
	Credentials []Credentials `yaml:"credentials"`
}

Jump to

Keyboard shortcuts

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