Documentation
¶
Overview ¶
Package security implements the SSH security configuration feature
Index ¶
- type Feature
- func (f *Feature) Description() string
- func (f *Feature) DetectCurrentState(ctx *features.ExecutionContext) (map[string]any, error)
- func (f *Feature) DisplayCurrentState(ctx *features.ExecutionContext, state map[string]any)
- func (f *Feature) Execute(ctx *features.ExecutionContext) error
- func (f *Feature) Flags() []features.Flag
- func (f *Feature) Name() string
- func (f *Feature) Priority() int
- func (f *Feature) ShouldActivate(options map[string]any) bool
- func (f *Feature) ShouldPromptUser(ctx *features.ExecutionContext, state map[string]any) bool
- func (f *Feature) ValidateOptions(options map[string]any) error
- type SSHSecurityOptions
- type SSHSettingResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Feature ¶
type Feature struct {
// contains filtered or unexported fields
}
Feature implements the SSH security configuration feature
func (*Feature) Description ¶
Description returns the feature description
func (*Feature) DetectCurrentState ¶
DetectCurrentState detects and returns the current state of the security feature
func (*Feature) DisplayCurrentState ¶
func (f *Feature) DisplayCurrentState(ctx *features.ExecutionContext, state map[string]any)
DisplayCurrentState displays the current state of the security feature
func (*Feature) Execute ¶
func (f *Feature) Execute(ctx *features.ExecutionContext) error
Execute executes the feature functionality
func (*Feature) ShouldActivate ¶
ShouldActivate determines if the feature should be activated
func (*Feature) ShouldPromptUser ¶
ShouldPromptUser determines if the user should be prompted for input
type SSHSecurityOptions ¶ added in v0.2.2
type SSHSecurityOptions struct {
RootLoginAction string // "enable", "disable", or "keep"
PasswordAuthAction string // "enable", "disable", or "keep"
}
SSHSecurityOptions represents the parsed SSH security configuration
type SSHSettingResult ¶ added in v0.2.2
type SSHSettingResult struct {
EffectiveValue string // The effective value (what SSH actually uses)
IsExplicit bool // Whether the setting is explicitly configured
Source string // Source of the value: "explicit", "default", or "commented"
}
SSHSettingResult represents the result of parsing an SSH setting
Click to show internal directories.
Click to hide internal directories.