windows

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2022 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Rendered for windows/amd64

Index

Constants

View Source
const (
	ServiceBoot = iota
	ServiceSystem
	ServiceAutomatic
	ServiceManual
	ServiceDisabled
)

Service Startup codes

View Source
const (
	ServiceStateContinuePending = "ContinuePending"
	ServiceStatePausePending    = "PausePending"
	ServiceStatePaused          = "Paused"
	ServiceStateRunning         = "Running"
	ServiceStateStartPending    = "StartPending"
	ServiceStateStopPending     = "StopPending"
	ServiceStateStopped         = "Stopped"
)

Service state descriptions

Variables

This section is empty.

Functions

func NewHostinfoPlugin

func NewHostinfoPlugin(id ids.PluginID, ctx agent.AgentContext, cloudHarvester cloud.Harvester) agent.Plugin

func NewServicesPlugin

func NewServicesPlugin(id ids.PluginID, ctx agent.AgentContext) agent.Plugin

func NewUpdatesPlugin

func NewUpdatesPlugin(id ids.PluginID, ctx agent.AgentContext) agent.Plugin

Types

type HostinfoData

type HostinfoData struct {
	System              string `json:"id"`
	WindowsPlatform     string `json:"windows_platform"`
	WindowsFamily       string `json:"windows_family"`
	WindowsVersion      string `json:"windows_version"`
	HostType            string `json:"host_type"`
	CpuName             string `json:"cpu_name"`
	CpuNum              string `json:"cpu_num"`
	TotalCpu            string `json:"total_cpu"`
	Ram                 string `json:"ram"`
	UpSince             string `json:"boot_timestamp"`
	AgentVersion        string `json:"agent_version"`
	AgentName           string `json:"agent_name"`
	OperatingSystem     string `json:"operating_system"`
	RegionAWS           string `json:"aws_region,omitempty"`
	RegionAzure         string `json:"region_name,omitempty"`
	RegionGCP           string `json:"zone,omitempty"`
	RegionAlibaba       string `json:"region_id,omitempty"`
	AWSAccountID        string `json:"aws_account_id,omitempty"`
	AWSAvailabilityZone string `json:"aws_availability_zone,omitempty"`
	AWSImageID          string `json:"aws_image_id,omitempty"`
}

func (*HostinfoData) SortKey

func (self *HostinfoData) SortKey() string

type HostinfoPlugin

type HostinfoPlugin struct {
	agent.PluginCommon
	// contains filtered or unexported fields
}

func (*HostinfoPlugin) Data

func (*HostinfoPlugin) Run

func (self *HostinfoPlugin) Run()

type Output_Win32_Service

type Output_Win32_Service struct {
	Name        string `json:"id"`
	DisplayName string `json:"display_name"`
	State       string `json:"state"`
	ProcessId   string `json:"pid"`
}

All output must be strings, but WMI requires types to match its internal data formats so we have to do a translation struct with all strings.

func (Output_Win32_Service) SortKey

func (self Output_Win32_Service) SortKey() string

type ServicesPlugin

type ServicesPlugin struct {
	agent.PluginCommon
	// contains filtered or unexported fields
}

func (*ServicesPlugin) Run

func (self *ServicesPlugin) Run()

type UpdatesPlugin

type UpdatesPlugin struct {
	agent.PluginCommon
	// contains filtered or unexported fields
}

func (*UpdatesPlugin) Run

func (self *UpdatesPlugin) Run()

type Win32_QuickFixEngineering

type Win32_QuickFixEngineering struct {
	HotFixID    string `json:"id"`
	Description string `json:"description"`
	Caption     string `json:"knowledgebase_url"`
	InstalledOn string `json:"installed_time"`
}

See https://msdn.microsoft.com/en-us/library/aa394391(v=vs.85).aspx

func (Win32_QuickFixEngineering) SortKey

func (self Win32_QuickFixEngineering) SortKey() string

Jump to

Keyboard shortcuts

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