Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Arch ¶
func Arch() string
Arch returns the kernel architecture value, often used within the kernel `include/arch` directory.
func GetMountPoint ¶
GetMountPoint returns the mount point of the given path
func IsDebugFSMounted ¶
IsDebugFSMounted would test the existence of file /sys/kernel/debug/tracing/kprobe_events to determine if debugfs is mounted or not returns a boolean and a possible error message
func IsIPv6Enabled ¶
func IsIPv6Enabled() bool
IsIPv6Enabled returns whether or not IPv6 has been enabled on the host
func MountInfoPidPath ¶
MountInfoPidPath returns the path to the mountinfo file of a pid in /proc
Types ¶
type HeaderFetchResult ¶
type HeaderFetchResult int
HeaderFetchResult enumerates kernel header fetching success & failure modes
const ( // NotAttempted represents the case where runtime compilation fails prior to attempting to // fetch kernel headers NotAttempted HeaderFetchResult = iota )
func GetKernelHeaders ¶
func GetKernelHeaders(headerDirs []string, headerDownloadDir, aptConfigDir, yumReposDir, zypperReposDir string) ([]string, HeaderFetchResult, error)
GetKernelHeaders attempts to find kernel headers on the host, and if they cannot be found it will attempt to download them to headerDownloadDir
type LockdownMode ¶
type LockdownMode string
LockdownMode defines a lockdown type
const ( // None mode None LockdownMode = "none" // Integrity mode Integrity LockdownMode = "integrity" // Confidentiality mode Confidentiality LockdownMode = "confidentiality" // Unknown mode Unknown LockdownMode = "unknown" )
type Version ¶
type Version uint32
Version is a numerical representation of a kernel version
func HostVersion ¶
HostVersion returns the running kernel version of the host
func ParseVersion ¶
ParseVersion parses a string in the format of x.x.x to a Version
func VersionCode ¶
VersionCode returns a Version computed from the individual parts of a x.x.x version