xccdf

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	XCCDFCaCNamespace    string = "xccdf_org.ssgproject.content"
	XCCDFNamespace       string = "complytime.openscapplugin"
	XCCDFTailoringSuffix string = "complytime"
)

Variables

This section is empty.

Functions

func GetDsProfile

func GetDsProfile(profileId string, dsPath string) (*xccdf.ProfileElement, error)

func PolicyToXML

func PolicyToXML(oscalPolicy policy.Policy, config *config.Config) (string, error)

func ResolveDsVariableOptions

func ResolveDsVariableOptions(profile *xccdf.ProfileElement, variables []DsVariables) (*xccdf.ProfileElement, error)

Types

type DsRules

type DsRules struct {
	ID          string `xml:"idref,attr"`
	Title       string `xml:",chardata"`
	Description string `xml:",chardata"`
	Selected    bool   `xml:"selected,attr"`
}

func GetDsRules

func GetDsRules(dsPath string) ([]DsRules, error)

type DsVariableOptions

type DsVariableOptions struct {
	Selector string `xml:"selector,attr"`
	Value    string `xml:",chardata"`
}

The following structs can later be proposed to compliance-operator/pkg/xccdf

type DsVariables

type DsVariables struct {
	ID          string `xml:"idref,attr"`
	Title       string `xml:",chardata"`
	Description string `xml:",chardata"`
	Options     []DsVariableOptions
}

func GetDsVariablesValues

func GetDsVariablesValues(dsPath string) ([]DsVariables, error)

Jump to

Keyboard shortcuts

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