Documentation
¶
Overview ¶
Package securitybaseline renders the host security baseline script shared by legacy StackKit execution and architecture-v2 renderers.
Index ¶
Constants ¶
const ( EvidenceSchemaVersion = "stackkit.security-baseline/v1" EvidenceModePublicBeta = "public-beta" EvidenceSchemaVersionArchitectureV2 = "stackkit.security-baseline/v2" EvidenceModeArchitectureV2 = "architecture-v2-foundation" )
Variables ¶
This section is empty.
Functions ¶
func ContractHash ¶
ContractHash returns the canonical sha256-prefixed digest of an exact rendered policy. It can be stored directly alongside a render unit for drift detection.
func NormalizePermitRootLogin ¶
NormalizePermitRootLogin returns a safe sshd value or an empty string when the input must be replaced with the secure default.
func RenderV2HostPolicy ¶
RenderV2HostPolicy renders the canonical, self-contained architecture-v2 host policy. Renderers should use this convenience instead of constructing a v2 Config so the policy and its package-manager safety prelude cannot drift.
Types ¶
type Config ¶
type Config struct {
Mode Mode
SSHPort int
PermitRootLogin string
MaxAuthTries int
PackageManagerLockWaitScript string
}
Config contains inputs for rendering a security-baseline script. SSH fields are authoritative only for legacy-v1 and are ignored by Architecture-v2.