pem

package
v0.26.21 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package pem wraps encoding/pem as a codec.Codec implementation. PEM is block-structured: each wire message is a typed block ("CERTIFICATE", "PRIVATE KEY", etc.), so the codec operates on *pem.Block values.

Index

Constants

This section is empty.

Variables

View Source
var (
	//: register the singleton and expose it as a typed package var.
	Codec codec.Codec = codec.Register(&pemCodec{extensions: extensions})
)

Package-level state: the codec singleton, built with its hoisted extension table — the initialiser names the table, which is what orders it before Register reads it (see core/data/codec.Register) —, the cached promotion fast-path markers, and the Marshal-buffer pool.

Functions

func New

func New() codec.Codec

New returns a PEM codec instance.

Types

type Block

type Block = stdpem.Block

Block re-exports encoding/pem.Block so consumers do not need to import the stdlib package directly.

Jump to

Keyboard shortcuts

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