frameworks

package
v0.64.27 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package frameworks holds the process-global registry of compliance framework factories. Each in-tree framework (soc2, iso27001, …) registers its Factory from package init(); commands look the factory up by the configured framework ID and never branch on it directly.

This mirrors the source-plugin (internal/sources) and vault-backend (internal/vault) factory models: adding a framework is dropping a package under internal/frameworks/<id>/ with an init() that calls RegisterFactory, then adding one blank import to internal/frameworks/builtin. cmd/sigcomply needs no change.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IDs

func IDs() []string

IDs returns the sorted list of registered framework IDs, used for error messages that enumerate supported frameworks.

func RegisterFactory

func RegisterFactory(id string, f Factory)

RegisterFactory adds a framework factory under id. Intended to be called from a framework package's init(). Panics on duplicate or empty id — a programming error that must fail loudly at startup.

Types

type Factory

type Factory struct {
	Register      func(*registry.Set) error
	ManualCatalog func() map[string]manual.CatalogEntry
	// ManualCatalogExport returns the descriptive, presentation-facing
	// manual-evidence catalog for `sigcomply evidence catalog` (consumed
	// by the Evidence SPA). Nil when the framework has no manual policies.
	ManualCatalogExport func() manualcatalog.Catalog
}

Factory wires one framework into a run. Register populates the framework, rule, and policy registries (it is the framework's own Register function). ManualCatalog returns the framework's manual-evidence catalog — an empty map when the framework has no manual policies.

func Lookup

func Lookup(id string) (Factory, bool)

Lookup returns the factory registered for id.

Directories

Path Synopsis
Package builtin imports every in-tree framework for the side effect of running its init() — which registers a Factory with the frameworks registry.
Package builtin imports every in-tree framework for the side effect of running its init() — which registers a Factory with the frameworks registry.
Package iso27001 is the ISO/IEC 27001:2022 framework: the Annex A control catalog, the automated technological-control policies in the pass_when: DSL, and the manual-evidence policies across the organizational, people, physical, and technological themes.
Package iso27001 is the ISO/IEC 27001:2022 framework: the Annex A control catalog, the automated technological-control policies in the pass_when: DSL, and the manual-evidence policies across the organizational, people, physical, and technological themes.
Package soc2 is the SOC 2 (TSC 2017) framework: the control catalog, the automated policy library expressed in the pass_when: DSL, and the manual-evidence policies.
Package soc2 is the SOC 2 (TSC 2017) framework: the control catalog, the automated policy library expressed in the pass_when: DSL, and the manual-evidence policies.

Jump to

Keyboard shortcuts

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