Forge documentation
Library referenceGo

github.com/l1fe-labs/forge-go/identity

Go identity package.

Go identity package.

Package contract

FieldValue
Languagego
Source versionmodule source snapshot
Manifestforge-go/go.mod
Source files5
EvidenceSource reference; registry publication and runtime conformance are separate checks

Import boundary

import "github.com/l1fe-labs/forge-go/identity"

Use a source checkout or your verified private registry. Manifest coordinates identify the package; they do not establish that a public registry release exists.

Source reference

Download package reference JSON. Each original source file and generated declaration artifact has its own SHA-256 digest. Function bodies and constant values are omitted from downloads. These are source declaration inventories, not compiler-resolved rustdoc, TypeDoc, DocC, or Dokka output. Private modules can contain public declarations that are not reachable through the package boundary; consult the entry point before importing.

glyph.go

Read declaration text · 13 declaration entries

type GlyphEntityKind string

const (
GlyphEntityKindHmr   GlyphEntityKind;

func ParseGlyphEntityKind(s string) (GlyphEntityKind, bool)

func (k GlyphEntityKind) AsU8() uint8

func GlyphEntityKindFromU8(v uint8) (GlyphEntityKind, bool)

type GlyphDescriptor struct

type GlyphRenderTarget string

const (
// GlyphRenderTargetWeb produces a self-contained SVG string.
GlyphRenderTargetWeb GlyphRenderTarget;

type GlyphRenderOptions struct

type GlyphColor struct

type GlyphPalette struct

type GlyphRenderFormat string

const (
GlyphRenderFormatSvg       GlyphRenderFormat;

type GlyphRenderResult struct

func (r *GlyphRenderResult) SvgData() (string, bool)

func RenderGlyph(desc *GlyphDescriptor, opts *GlyphRenderOptions) (*GlyphRenderResult, error)

identity.go

Read declaration text · 17 declaration entries

const DefaultMaxLineageDepth;

type IdentityKind string

const (
// KindHMR is a Human Root identity.
KindHMR IdentityKind;

type ForgeAgentIdentity struct

func (id *ForgeAgentIdentity) DID() core.AgentDID

func (id *ForgeAgentIdentity) Kind() IdentityKind

func (id *ForgeAgentIdentity) PublicKey() []byte

func (id *ForgeAgentIdentity) LineageDepth() int

func (id *ForgeAgentIdentity) CreatedAt() time.Time

func (id *ForgeAgentIdentity) Sign(message []byte) ([]byte, error)

func (id *ForgeAgentIdentity) Verify(message, signature []byte) bool

func (id *ForgeAgentIdentity) String() string

func CreateHMRIdentity(namespace string) (*ForgeAgentIdentity, error)

func CreateHMRIdentityWithIdentifier(namespace, identifier string) (*ForgeAgentIdentity, error)

func CreateMHRIdentity(namespace string) (*ForgeAgentIdentity, error)

func CreateMHRIdentityWithIdentifier(namespace, identifier string) (*ForgeAgentIdentity, error)

func DeriveAgentIdentity(parent *ForgeAgentIdentity, label, namespace string) (*ForgeAgentIdentity, error)

func VerifyLineageChain(chain []*ForgeAgentIdentity) error

lineage.go

Read declaration text · 9 declaration entries

type LineageProof struct

func CreateLineageProof(parent, child *ForgeAgentIdentity, label string) (*LineageProof, error)

func VerifyLineageProof(proof *LineageProof, parent *ForgeAgentIdentity) bool

type LineageChainBuilder struct

func NewLineageChainBuilder(root *ForgeAgentIdentity) *LineageChainBuilder

func (b *LineageChainBuilder) Derive(label, namespace string) (*LineageChainBuilder, error)

func (b *LineageChainBuilder) Identities() []*ForgeAgentIdentity

func (b *LineageChainBuilder) Proofs() []*LineageProof

func (b *LineageChainBuilder) Leaf() *ForgeAgentIdentity

local_dev.go

Read declaration text · 10 declaration entries

const ForgeDevMethod;

func ForgeDevDID(machineID, kind, identifier string) string

func DeriveMachineID(profileName string) string

func DeriveMachineIDFromParts(hostname, username, profileName string) string

func ValidateForgeDevDID(did string) error

type LocalDevProfile struct

func NewLocalDevProfile(profileName string) *LocalDevProfile

type ForgeDevIdentity struct

type LocalOrg struct

func NewLocalOrg(name string) LocalOrg

persistence.go

Read declaration text · 7 declaration entries

type ProtectedPrivateKey struct

type IdentityKeyProtector interface

type SerializedIdentity struct

func Serialize(id *ForgeAgentIdentity, protector IdentityKeyProtector) (*SerializedIdentity, error)

func Deserialize(s *SerializedIdentity, protector IdentityKeyProtector) (*ForgeAgentIdentity, error)

func MarshalJSON(id *ForgeAgentIdentity, protector IdentityKeyProtector) ([]byte, error)

func UnmarshalJSON(data []byte, protector IdentityKeyProtector) (*ForgeAgentIdentity, error)

Continue

On this page