substratex509

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2026 License: Apache-2.0 Imports: 6 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package substratex509 contains routines for creating and parsing x509 certificates that embed Substrate-specific X.509 extensions communicating the identity of a given workload. It is modeled on the upstream Kubernetes component-helpers/kubernetesx509 package, but encodes extension values as JSON instead of ASN.1.

Index

Constants

This section is empty.

Variables

View Source
var (
	// GoogleSubstratePEN is the ASN.1 Private Enterprise Number arc used to
	// name X.509 extensions that communicate Substrate-specific concepts.
	GoogleSubstratePEN = asn1.ObjectIdentifier{1, 3, 6, 1, 4, 1, 11129, 2, 12}
)

Functions

func AddActorIdentityToCertificate

func AddActorIdentityToCertificate(actor *ActorIdentity, template *x509.Certificate) error

func AddPodIdentityToCertificate

func AddPodIdentityToCertificate(pod *PodIdentity, template *x509.Certificate) error

Types

type ActorIdentity

type ActorIdentity struct {
	Atespace  string
	ActorName string
	ActorUid  string
}

ActorIdentity is the Substrate Actor Identity of an Actor, as embedded in the oidActorIdentity extension of its certificate.

func ActorIdentityFromCertificate

func ActorIdentityFromCertificate(cert *x509.Certificate) (*ActorIdentity, error)

type PodIdentity

type PodIdentity struct {
	Namespace          string
	ServiceAccountName string
	ServiceAccountUID  string
	PodName            string
	PodUID             string
	NodeName           string
	NodeUID            string
}

PodIdentity is the Kubernetes Pod Identity of a pod, as embedded in the oidPodIdentity extension of its certificate.

func PodIdentityFromCertificate

func PodIdentityFromCertificate(cert *x509.Certificate) (*PodIdentity, error)

Jump to

Keyboard shortcuts

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