Documentation
¶
Index ¶
- type ArchitectureRule
- func (r ArchitectureRule) Category() string
- func (r ArchitectureRule) Description() string
- func (r ArchitectureRule) ID() string
- func (r ArchitectureRule) Name() string
- func (r ArchitectureRule) Run(_ context.Context, rctx Context) ([]report.Finding, error)
- func (r ArchitectureRule) Severity() report.Severity
- type Context
- type DockerRule
- type EnvFileRule
- type GitRule
- type GoModRule
- type GoVersionRule
- type GracefulShutdownRule
- func (GracefulShutdownRule) Category() string
- func (GracefulShutdownRule) Description() string
- func (GracefulShutdownRule) ID() string
- func (GracefulShutdownRule) Name() string
- func (GracefulShutdownRule) Run(_ context.Context, rctx Context) ([]report.Finding, error)
- func (GracefulShutdownRule) Severity() report.Severity
- type Registry
- type Rule
- type SecurityCORSRule
- func (SecurityCORSRule) Category() string
- func (SecurityCORSRule) Description() string
- func (SecurityCORSRule) ID() string
- func (SecurityCORSRule) Name() string
- func (r SecurityCORSRule) Run(_ context.Context, rctx Context) ([]report.Finding, error)
- func (SecurityCORSRule) Severity() report.Severity
- type SecuritySecretsRule
- func (SecuritySecretsRule) Category() string
- func (SecuritySecretsRule) Description() string
- func (SecuritySecretsRule) ID() string
- func (SecuritySecretsRule) Name() string
- func (r SecuritySecretsRule) Run(_ context.Context, rctx Context) ([]report.Finding, error)
- func (SecuritySecretsRule) Severity() report.Severity
- type SecuritySensitiveFilesRule
- func (SecuritySensitiveFilesRule) Category() string
- func (SecuritySensitiveFilesRule) Description() string
- func (SecuritySensitiveFilesRule) ID() string
- func (SecuritySensitiveFilesRule) Name() string
- func (SecuritySensitiveFilesRule) Run(_ context.Context, rctx Context) ([]report.Finding, error)
- func (SecuritySensitiveFilesRule) Severity() report.Severity
- type StaticConfigLoader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArchitectureRule ¶
type ArchitectureRule struct {
Rules []config.ArchitectureRule
}
ArchitectureRule checks layer import violations.
func (ArchitectureRule) Category ¶
func (r ArchitectureRule) Category() string
func (ArchitectureRule) Description ¶
func (r ArchitectureRule) Description() string
func (ArchitectureRule) ID ¶
func (r ArchitectureRule) ID() string
func (ArchitectureRule) Name ¶
func (r ArchitectureRule) Name() string
func (ArchitectureRule) Severity ¶
func (r ArchitectureRule) Severity() report.Severity
type DockerRule ¶
type DockerRule struct{}
func (DockerRule) Category ¶
func (DockerRule) Category() string
func (DockerRule) Description ¶
func (DockerRule) Description() string
func (DockerRule) ID ¶
func (DockerRule) ID() string
func (DockerRule) Name ¶
func (DockerRule) Name() string
func (DockerRule) Severity ¶
func (DockerRule) Severity() report.Severity
type EnvFileRule ¶
type EnvFileRule struct{}
func (EnvFileRule) Category ¶
func (EnvFileRule) Category() string
func (EnvFileRule) Description ¶
func (EnvFileRule) Description() string
func (EnvFileRule) ID ¶
func (EnvFileRule) ID() string
func (EnvFileRule) Name ¶
func (EnvFileRule) Name() string
func (EnvFileRule) Severity ¶
func (EnvFileRule) Severity() report.Severity
type GoVersionRule ¶
type GoVersionRule struct{}
func (GoVersionRule) Category ¶
func (GoVersionRule) Category() string
func (GoVersionRule) Description ¶
func (GoVersionRule) Description() string
func (GoVersionRule) ID ¶
func (GoVersionRule) ID() string
func (GoVersionRule) Name ¶
func (GoVersionRule) Name() string
func (GoVersionRule) Severity ¶
func (GoVersionRule) Severity() report.Severity
type GracefulShutdownRule ¶
type GracefulShutdownRule struct{}
func (GracefulShutdownRule) Category ¶
func (GracefulShutdownRule) Category() string
func (GracefulShutdownRule) Description ¶
func (GracefulShutdownRule) Description() string
func (GracefulShutdownRule) ID ¶
func (GracefulShutdownRule) ID() string
func (GracefulShutdownRule) Name ¶
func (GracefulShutdownRule) Name() string
func (GracefulShutdownRule) Severity ¶
func (GracefulShutdownRule) Severity() report.Severity
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry holds ordered rules.
func AnalyzeRules ¶
func AnalyzeRules(cfg configLoader) *Registry
func CheckRules ¶
func CheckRules(cfg configLoader) *Registry
func DoctorRules ¶
func DoctorRules() *Registry
func NewRegistry ¶
type Rule ¶
type Rule interface {
ID() string
Name() string
Description() string
Category() string
Severity() report.Severity
Run(ctx context.Context, rctx Context) ([]report.Finding, error)
}
Rule is a pluggable diagnostic rule.
type SecurityCORSRule ¶
type SecurityCORSRule struct{}
SecurityCORSRule detects permissive CORS patterns in source.
func (SecurityCORSRule) Category ¶
func (SecurityCORSRule) Category() string
func (SecurityCORSRule) Description ¶
func (SecurityCORSRule) Description() string
func (SecurityCORSRule) ID ¶
func (SecurityCORSRule) ID() string
func (SecurityCORSRule) Name ¶
func (SecurityCORSRule) Name() string
func (SecurityCORSRule) Severity ¶
func (SecurityCORSRule) Severity() report.Severity
type SecuritySecretsRule ¶
type SecuritySecretsRule struct{}
SecuritySecretsRule detects potential hardcoded secrets. Limit: heuristic only — many false positives possible on placeholders.
func (SecuritySecretsRule) Category ¶
func (SecuritySecretsRule) Category() string
func (SecuritySecretsRule) Description ¶
func (SecuritySecretsRule) Description() string
func (SecuritySecretsRule) ID ¶
func (SecuritySecretsRule) ID() string
func (SecuritySecretsRule) Name ¶
func (SecuritySecretsRule) Name() string
func (SecuritySecretsRule) Severity ¶
func (SecuritySecretsRule) Severity() report.Severity
type SecuritySensitiveFilesRule ¶
type SecuritySensitiveFilesRule struct{}
SecuritySensitiveFilesRule warns when sensitive files may be committed.
func (SecuritySensitiveFilesRule) Category ¶
func (SecuritySensitiveFilesRule) Category() string
func (SecuritySensitiveFilesRule) Description ¶
func (SecuritySensitiveFilesRule) Description() string
func (SecuritySensitiveFilesRule) ID ¶
func (SecuritySensitiveFilesRule) ID() string
func (SecuritySensitiveFilesRule) Name ¶
func (SecuritySensitiveFilesRule) Name() string
func (SecuritySensitiveFilesRule) Severity ¶
func (SecuritySensitiveFilesRule) Severity() report.Severity
type StaticConfigLoader ¶
type StaticConfigLoader struct {
Rules []config.ArchitectureRule
}
StaticConfigLoader wraps fixed rules for tests.
func (StaticConfigLoader) ArchitectureRules ¶
func (s StaticConfigLoader) ArchitectureRules() []config.ArchitectureRule
Click to show internal directories.
Click to hide internal directories.