gowin32: github.com/winlabs/gowin32 Index | Files | Directories

package gowin32

import "github.com/winlabs/gowin32"

Index

Package Files

adspn.go adsysinfo.go adtranslate.go bstr.go cmdline.go comerror.go cominit.go console.go critsect.go diskperf.go diskspace.go environment.go error.go eventlog.go file.go fileop.go fileversion.go findfile.go firewall.go fqdn.go geometry.go installer.go internet.go iphlp.go job.go memory.go module.go netstat.go nls.go nterror.go permissions.go policy.go process.go registry.go resource.go security.go service.go shell.go socket.go symlink.go sysdir.go sysinfo.go system.go tempfile.go time.go version.go volume.go window.go wts.go

Constants

const (
    ErrorFileNotFound        = wrappers.ERROR_FILE_NOT_FOUND
    ErrorAccessDenied        = wrappers.ERROR_ACCESS_DENIED
    ErrorGeneralFailure      = wrappers.ERROR_GEN_FAILURE
    ErrorSharingViolation    = wrappers.ERROR_SHARING_VIOLATION
    ErrorInvalidParameter    = wrappers.ERROR_INVALID_PARAMETER
    ErrorBrokenPipe          = wrappers.ERROR_BROKEN_PIPE
    ErrorServiceDoesNotExist = wrappers.ERROR_SERVICE_DOES_NOT_EXIST
)
const (
    MaximumVolumeGUIDPath = 50
)

Variables

var (
    COMErrorNoneMapped           = COMError(wrappers.HRESULT_FROM_WIN32(wrappers.ERROR_NONE_MAPPED))
    COMErrorCantAccessDomainInfo = COMError(wrappers.HRESULT_FROM_WIN32(wrappers.ERROR_CANT_ACCESS_DOMAIN_INFO))
    COMErrorNoSuchDomain         = COMError(wrappers.HRESULT_FROM_WIN32(wrappers.ERROR_NO_SUCH_DOMAIN))
)
var (
    LanguageSystemDefault = Language(wrappers.LANG_SYSTEM_DEFAULT)
    LanguageUserDefault   = Language(wrappers.LANG_USER_DEFAULT)
)
var (
    LocaleSystemDefault     = Locale(wrappers.LOCALE_SYSTEM_DEFAULT)
    LocaleUserDefault       = Locale(wrappers.LOCALE_USER_DEFAULT)
    LocaleCustomDefault     = Locale(wrappers.LOCALE_CUSTOM_DEFAULT)
    LocaleCustomUnspecified = Locale(wrappers.LOCALE_CUSTOM_UNSPECIFIED)
    LocaleCustomUIDefault   = Locale(wrappers.LOCALE_CUSTOM_UI_DEFAULT)
    LocaleNeutral           = Locale(wrappers.LOCALE_NEUTRAL)
    LocaleInvariant         = Locale(wrappers.LOCALE_INVARIANT)
)
var (
    KnownFolderNetworkFolder          = KnownFolder(wrappers.FOLDERID_NetworkFolder)
    KnownFolderComputerFolder         = KnownFolder(wrappers.FOLDERID_ComputerFolder)
    KnownFolderInternetFolder         = KnownFolder(wrappers.FOLDERID_InternetFolder)
    KnownFolderControlPanelFolder     = KnownFolder(wrappers.FOLDERID_ControlPanelFolder)
    KnownFolderPrintersFolder         = KnownFolder(wrappers.FOLDERID_PrintersFolder)
    KnownFolderSyncManagerFolder      = KnownFolder(wrappers.FOLDERID_SyncManagerFolder)
    KnownFolderSyncSetupFolder        = KnownFolder(wrappers.FOLDERID_SyncSetupFolder)
    KnownFolderConflictFolder         = KnownFolder(wrappers.FOLDERID_ConflictFolder)
    KnownFolderSyncResultsFolder      = KnownFolder(wrappers.FOLDERID_SyncResultsFolder)
    KnownFolderRecycleBinFolder       = KnownFolder(wrappers.FOLDERID_RecycleBinFolder)
    KnownFolderConnectionsFolder      = KnownFolder(wrappers.FOLDERID_ConnectionsFolder)
    KnownFolderFonts                  = KnownFolder(wrappers.FOLDERID_Fonts)
    KnownFolderDesktop                = KnownFolder(wrappers.FOLDERID_Desktop)
    KnownFolderStartup                = KnownFolder(wrappers.FOLDERID_Startup)
    KnownFolderPrograms               = KnownFolder(wrappers.FOLDERID_Programs)
    KnownFolderStartMenu              = KnownFolder(wrappers.FOLDERID_StartMenu)
    KnownFolderRecent                 = KnownFolder(wrappers.FOLDERID_Recent)
    KnownFolderSendTo                 = KnownFolder(wrappers.FOLDERID_SendTo)
    KnownFolderDocuments              = KnownFolder(wrappers.FOLDERID_Documents)
    KnownFolderFavorites              = KnownFolder(wrappers.FOLDERID_Favorites)
    KnownFolderNetHood                = KnownFolder(wrappers.FOLDERID_NetHood)
    KnownFolderPrintHood              = KnownFolder(wrappers.FOLDERID_PrintHood)
    KnownFolderTemplates              = KnownFolder(wrappers.FOLDERID_Templates)
    KnownFolderCommonStartup          = KnownFolder(wrappers.FOLDERID_CommonStartup)
    KnownFolderCommonPrograms         = KnownFolder(wrappers.FOLDERID_CommonPrograms)
    KnownFolderCommonStartMenu        = KnownFolder(wrappers.FOLDERID_CommonStartMenu)
    KnownFolderPublicDesktop          = KnownFolder(wrappers.FOLDERID_PublicDesktop)
    KnownFolderProgramData            = KnownFolder(wrappers.FOLDERID_ProgramData)
    KnownFolderCommonTemplates        = KnownFolder(wrappers.FOLDERID_CommonTemplates)
    KnownFolderPublicDocuments        = KnownFolder(wrappers.FOLDERID_PublicDocuments)
    KnownFolderRoamingAppData         = KnownFolder(wrappers.FOLDERID_RoamingAppData)
    KnownFolderLocalAppData           = KnownFolder(wrappers.FOLDERID_LocalAppData)
    KnownFolderLocalAppDataLow        = KnownFolder(wrappers.FOLDERID_LocalAppDataLow)
    KnownFolderInternetCache          = KnownFolder(wrappers.FOLDERID_InternetCache)
    KnownFolderCookies                = KnownFolder(wrappers.FOLDERID_Cookies)
    KnownFolderHistory                = KnownFolder(wrappers.FOLDERID_History)
    KnownFolderSystem                 = KnownFolder(wrappers.FOLDERID_System)
    KnownFolderSystemX86              = KnownFolder(wrappers.FOLDERID_SystemX86)
    KnownFolderWindows                = KnownFolder(wrappers.FOLDERID_Windows)
    KnownFolderProfile                = KnownFolder(wrappers.FOLDERID_Profile)
    KnownFolderPictures               = KnownFolder(wrappers.FOLDERID_Pictures)
    KnownFolderProgramFilesX86        = KnownFolder(wrappers.FOLDERID_ProgramFilesX86)
    KnownFolderProgramFilesCommonX86  = KnownFolder(wrappers.FOLDERID_ProgramFilesCommonX86)
    KnownFolderProgramFilesX64        = KnownFolder(wrappers.FOLDERID_ProgramFilesX64)
    KnownFolderProgramFilesCommonX64  = KnownFolder(wrappers.FOLDERID_ProgramFilesCommonX64)
    KnownFolderProgramFiles           = KnownFolder(wrappers.FOLDERID_ProgramFiles)
    KnownFolderProgramFilesCommon     = KnownFolder(wrappers.FOLDERID_ProgramFilesCommon)
    KnownFolderUserProgramFiles       = KnownFolder(wrappers.FOLDERID_UserProgramFiles)
    KnownFolderUserProgramFilesCommon = KnownFolder(wrappers.FOLDERID_UserProgramFilesCommon)
    KnownFolderAdminTools             = KnownFolder(wrappers.FOLDERID_AdminTools)
    KnownFolderCommonAdminTools       = KnownFolder(wrappers.FOLDERID_CommonAdminTools)
    KnownFolderMusic                  = KnownFolder(wrappers.FOLDERID_Music)
    KnownFolderVideos                 = KnownFolder(wrappers.FOLDERID_Videos)
    KnownFolderRingtones              = KnownFolder(wrappers.FOLDERID_Ringtones)
    KnownFolderPublicPictures         = KnownFolder(wrappers.FOLDERID_PublicPictures)
    KnownFolderPublicMusic            = KnownFolder(wrappers.FOLDERID_PublicMusic)
    KnownFolderPublicVideos           = KnownFolder(wrappers.FOLDERID_PublicVideos)
    KnownFolderPublicRingtones        = KnownFolder(wrappers.FOLDERID_PublicRingtones)
    KnownFolderResourceDir            = KnownFolder(wrappers.FOLDERID_ResourceDir)
    KnownFolderLocalizedResourcesDir  = KnownFolder(wrappers.FOLDERID_LocalizedResourcesDir)
    KnownFolderCommonOEMLinks         = KnownFolder(wrappers.FOLDERID_CommonOEMLinks)
    KnownFolderCDBurning              = KnownFolder(wrappers.FOLDERID_CDBurning)
    KnownFolderUserProfiles           = KnownFolder(wrappers.FOLDERID_UserProfiles)
    KnownFolderPlaylists              = KnownFolder(wrappers.FOLDERID_Playlists)
    KnownFolderSamplePlaylists        = KnownFolder(wrappers.FOLDERID_SamplePlaylists)
    KnownFolderSampleMusic            = KnownFolder(wrappers.FOLDERID_SampleMusic)
    KnownFolderSamplePictures         = KnownFolder(wrappers.FOLDERID_SamplePictures)
    KnownFolderSampleVideos           = KnownFolder(wrappers.FOLDERID_SampleVideos)
    KnownFolderPhotoAlbums            = KnownFolder(wrappers.FOLDERID_PhotoAlbums)
    KnownFolderPublic                 = KnownFolder(wrappers.FOLDERID_Public)
    KnownFolderChangeRemovePrograms   = KnownFolder(wrappers.FOLDERID_ChangeRemovePrograms)
    KnownFolderAppUpdates             = KnownFolder(wrappers.FOLDERID_AppUpdates)
    KnownFolderAddNewPrograms         = KnownFolder(wrappers.FOLDERID_AddNewPrograms)
    KnownFolderDownloads              = KnownFolder(wrappers.FOLDERID_Downloads)
    KnownFolderPublicDownloads        = KnownFolder(wrappers.FOLDERID_PublicDownloads)
    KnownFolderSavedSearches          = KnownFolder(wrappers.FOLDERID_SavedSearches)
    KnownFolderQuickLaunch            = KnownFolder(wrappers.FOLDERID_QuickLaunch)
    KnownFolderContacts               = KnownFolder(wrappers.FOLDERID_Contacts)
    KnownFolderSidebarParts           = KnownFolder(wrappers.FOLDERID_SidebarParts)
    KnownFolderSidebarDefaultParts    = KnownFolder(wrappers.FOLDERID_SidebarDefaultParts)
    KnownFolderPublicGameTasks        = KnownFolder(wrappers.FOLDERID_PublicGameTasks)
    KnownFolderGameTasks              = KnownFolder(wrappers.FOLDERID_GameTasks)
    KnownFolderSavedGames             = KnownFolder(wrappers.FOLDERID_SavedGames)
    KnownFolderGames                  = KnownFolder(wrappers.FOLDERID_Games)
    KnownFolderSearchMAPI             = KnownFolder(wrappers.FOLDERID_SEARCH_MAPI)
    KnownFolderSearchCSC              = KnownFolder(wrappers.FOLDERID_SEARCH_CSC)
    KnownFolderLinks                  = KnownFolder(wrappers.FOLDERID_Links)
    KnownFolderUserLinks              = KnownFolder(wrappers.FOLDERID_UserLinks)
    KnownFolderUserLibraries          = KnownFolder(wrappers.FOLDERID_UserLibraries)
    KnownFolderSearchHome             = KnownFolder(wrappers.FOLDERID_SearchHome)
    KnownFolderOriginalImages         = KnownFolder(wrappers.FOLDERID_OriginalImages)
    KnownFolderDocumentsLibrary       = KnownFolder(wrappers.FOLDERID_DocumentsLibrary)
    KnownFolderMusicLibrary           = KnownFolder(wrappers.FOLDERID_MusicLibrary)
    KnownFolderPicturesLibrary        = KnownFolder(wrappers.FOLDERID_PicturesLibrary)
    KnownFolderVideosLibrary          = KnownFolder(wrappers.FOLDERID_VideosLibrary)
    KnownFolderRecordedTVLibrary      = KnownFolder(wrappers.FOLDERID_RecordedTVLibrary)
    KnownFolderHomeGroup              = KnownFolder(wrappers.FOLDERID_HomeGroup)
    KnownFolderDeviceMetadataStore    = KnownFolder(wrappers.FOLDERID_DeviceMetadataStore)
    KnownFolderLibraries              = KnownFolder(wrappers.FOLDERID_Libraries)
    KnownFolderPublicLibraries        = KnownFolder(wrappers.FOLDERID_PublicLibraries)
    KnownFolderUserPinned             = KnownFolder(wrappers.FOLDERID_UserPinned)
    KnownFolderImplicitAppShortcuts   = KnownFolder(wrappers.FOLDERID_ImplicitAppShortcuts)
)

func BeginImpersonateSelf Uses

func BeginImpersonateSelf() error

func BstrToString Uses

func BstrToString(bstr *uint16) string

func CompareFileVersionNumbers Uses

func CompareFileVersionNumbers(v1, v2 FileVersionNumber) int

func ConfigureInstalledProduct Uses

func ConfigureInstalledProduct(productCode string, installLevel InstallLevel, installState InstallState, commandLine string) error

func Copy Uses

func Copy(oldFileName string, newFileName string, overwrite bool) error

func Delete Uses

func Delete(fileName string) error

func DeleteRegValue Uses

func DeleteRegValue(root RegRoot, subKey string, valueName string) error

func DisableInstallerLog Uses

func DisableInstallerLog() error

func EnableInstallerLog Uses

func EnableInstallerLog(logMode InstallLogMode, logFile string, logAttributes InstallLogAttributes) error

func EnableVTSequences Uses

func EnableVTSequences() error

func EndImpersonate Uses

func EndImpersonate() error

func ExpandEnvironment Uses

func ExpandEnvironment(text string) (string, error)

func FileExists Uses

func FileExists(fileName string) (bool, error)

func GenerateTempFileName Uses

func GenerateTempFileName(pathName string, prefixString string, unique uint) (string, uint, error)

func GetAllEnvironment Uses

func GetAllEnvironment() (map[string]string, error)

func GetAvailableDiskSpace Uses

func GetAvailableDiskSpace(root string) (uint64, error)

func GetCompressedSize Uses

func GetCompressedSize(fileName string) (uint64, error)

func GetCurrentExePath Uses

func GetCurrentExePath() (string, error)

func GetDirectorySize Uses

func GetDirectorySize(dirName string) (uint64, error)

func GetDirectorySizeOnDisk Uses

func GetDirectorySizeOnDisk(dirName string) (uint64, error)

func GetEnvironment Uses

func GetEnvironment(name string) (string, error)

func GetFQDN Uses

func GetFQDN() (string, error)

func GetFinalPathName Uses

func GetFinalPathName(fileName string, openFlags uint32, finalPathFlags uint32) (result string, err error)

func GetFinalPathNameAsDOSName Uses

func GetFinalPathNameAsDOSName(fileName string) (string, error)

GetFinalPathNameAsDOSName returns symlik target in "DOS" format (c:\dir\name) or source fileName if fileName is normal, not symlinked file

func GetFreeDiskSpace Uses

func GetFreeDiskSpace(root string) (uint64, error)

func GetInstalledProductProperty Uses

func GetInstalledProductProperty(productCode string, property InstallProperty) (string, error)

func GetInstalledProductsByUpgradeCode Uses

func GetInstalledProductsByUpgradeCode(upgradeCode string) ([]string, error)

func GetKnownFolderPath Uses

func GetKnownFolderPath(folder KnownFolder) (string, error)

func GetLocalAccountByName Uses

func GetLocalAccountByName(accountName string) (SecurityID, string, SecurityIDType, error)

func GetNetBIOSName Uses

func GetNetBIOSName() (string, error)

func GetProcessCommandLine Uses

func GetProcessCommandLine(pid uint) (string, error)

func GetProcessFullPathName Uses

func GetProcessFullPathName(pid uint, flags ProcessNameFlags) (string, error)

func GetRegValueDWORD Uses

func GetRegValueDWORD(root RegRoot, subKey string, valueName string) (uint32, error)

func GetRegValueString Uses

func GetRegValueString(root RegRoot, subKey string, valueName string) (string, error)

func GetSectorsAndClusters Uses

func GetSectorsAndClusters(root string) (uint32, uint32, uint32, uint32, error)

func GetSharedWindowsPath Uses

func GetSharedWindowsPath() (string, error)

func GetSpecialFolderPath Uses

func GetSpecialFolderPath(folder SpecialFolder) (string, error)

func GetTempFilePath Uses

func GetTempFilePath() (string, error)

func GetTimeCounter Uses

func GetTimeCounter() uint64

func GetTotalDiskSpace Uses

func GetTotalDiskSpace(root string) (uint64, error)

func GetVolumeNameFromMountPoint Uses

func GetVolumeNameFromMountPoint(volumeMountPoint string) (string, error)

func GetVolumePath Uses

func GetVolumePath(fileName string) (string, error)

func GetWindowProcessID Uses

func GetWindowProcessID(hwnd syscall.Handle) (uint, error)

func GetWindowText Uses

func GetWindowText(hwnd syscall.Handle) (string, error)

func GetWindowThreadID Uses

func GetWindowThreadID(hwnd syscall.Handle) (uint, error)

func GetWindowsPath Uses

func GetWindowsPath() (string, error)

func GetWindowsSystemPath Uses

func GetWindowsSystemPath() (string, error)

func GetWindowsSystemWOW64Path Uses

func GetWindowsSystemWOW64Path() (string, error)

func InitializeCOM Uses

func InitializeCOM(flags COMInitFlags) error

func InitiateSystemShutdown Uses

func InitiateSystemShutdown(machineName string, message string, timeout int, forceAppsClosed bool, rebootAfterShutdown bool) error

func InstallProduct Uses

func InstallProduct(packagePath string, commandLine string) error

func IsAdmin Uses

func IsAdmin() (bool, error)

func IsProcessRunning Uses

func IsProcessRunning(pid uint) (bool, error)

func IsServiceRunning Uses

func IsServiceRunning(serviceName string) (bool, error)

func IsWindows10OrGreater Uses

func IsWindows10OrGreater() (bool, error)

func IsWindows7OrGreater Uses

func IsWindows7OrGreater() (bool, error)

func IsWindows7SP1OrGreater Uses

func IsWindows7SP1OrGreater() (bool, error)

func IsWindows8OrGreater Uses

func IsWindows8OrGreater() (bool, error)

func IsWindows8Point1OrGreater Uses

func IsWindows8Point1OrGreater() (bool, error)

func IsWindowsVersionOrGreater Uses

func IsWindowsVersionOrGreater(majorVersion uint, minorVersion uint, servicePackMajor uint) (bool, error)

func IsWindowsVistaOrGreater Uses

func IsWindowsVistaOrGreater() (bool, error)

func IsWindowsVistaSP1OrGreater Uses

func IsWindowsVistaSP1OrGreater() (bool, error)

func IsWindowsVistaSP2OrGreater Uses

func IsWindowsVistaSP2OrGreater() (bool, error)

func IsWindowsXP Uses

func IsWindowsXP() (bool, error)

func IsWindowsXPOrGreater Uses

func IsWindowsXPOrGreater() (bool, error)

func IsWindowsXPSP1OrGreater Uses

func IsWindowsXPSP1OrGreater() (bool, error)

func IsWindowsXPSP2OrGreater Uses

func IsWindowsXPSP2OrGreater() (bool, error)

func IsWindowsXPSP3OrGreater Uses

func IsWindowsXPSP3OrGreater() (bool, error)

func KillProcess Uses

func KillProcess(pid uint, exitCode uint) error

func LpstrToString Uses

func LpstrToString(lpstr *uint16) string

func MakeDoubleNullTerminatedLpstr Uses

func MakeDoubleNullTerminatedLpstr(items ...string) *uint16
func MakeSymbolicLink(symlinkPath string, targetPath string, isDirectory bool) error

func Move Uses

func Move(oldFileName string, newFileName string, overwrite bool) error

func OpenWindowsFile Uses

func OpenWindowsFile(fileName string, readWrite bool, shareMode FileShareMode, creationDisposition FileCreationDisposition, attributes FileAttributes, flags FileFlags) (*os.File, error)

func ParseCommandLine Uses

func ParseCommandLine(commandLine string) ([]string, error)

func ReadFileContents Uses

func ReadFileContents(fileName string) (string, error)

func RegisterADServerSPN Uses

func RegisterADServerSPN(operation ADSPNOperation, serviceClass string, userObjectDN string) error

func SendARP Uses

func SendARP(destIP, srcIP net.IP) (net.HardwareAddr, error)

SendARP sends an ARP request. srcIP can be nil

func SetAttributes Uses

func SetAttributes(fileName string, attributes FileAttributes) error

func SetEnvironment Uses

func SetEnvironment(name string, value string) error

func SetFileOwner Uses

func SetFileOwner(path string, sid SecurityID) error

func SetFilePermissions Uses

func SetFilePermissions(fileName string, permissions []PermissionEntry) error

func SetRegValueDWORD Uses

func SetRegValueDWORD(root RegRoot, subKey string, valueName string, data uint32) error

func SetRegValueString Uses

func SetRegValueString(root RegRoot, subKey string, valueName string, data string) error

func ShellCopy Uses

func ShellCopy(source string, destination string) error

func ShellDelete Uses

func ShellDelete(fileSpec string) error

func SignalProcessAndWait Uses

func SignalProcessAndWait(pid uint, timeout time.Duration) error

func TouchFile Uses

func TouchFile(f *os.File) error

func TranslateADName Uses

func TranslateADName(name string, fromType ADNameType, toType ADNameType) (string, error)

func UninitializeCOM Uses

func UninitializeCOM()

func UninstallProduct Uses

func UninstallProduct(productCode string) error

func VerifyInstallerPackage Uses

func VerifyInstallerPackage(packagePath string) (bool, error)

type ADNameType Uses

type ADNameType int32
const (
    ADNameType1779                 ADNameType = wrappers.ADS_NAME_TYPE_1779
    ADNameTypeCanonical            ADNameType = wrappers.ADS_NAME_TYPE_CANONICAL
    ADNameTypeNT4                  ADNameType = wrappers.ADS_NAME_TYPE_NT4
    ADNameTypeDisplay              ADNameType = wrappers.ADS_NAME_TYPE_DISPLAY
    ADNameTypeDomainSimple         ADNameType = wrappers.ADS_NAME_TYPE_DOMAIN_SIMPLE
    ADNameTypeEnterpriseSimple     ADNameType = wrappers.ADS_NAME_TYPE_ENTERPRISE_SIMPLE
    ADNameTypeGUID                 ADNameType = wrappers.ADS_NAME_TYPE_GUID
    ADNameTypeUnknown              ADNameType = wrappers.ADS_NAME_TYPE_UNKNOWN
    ADNameTypeUserPrincipalName    ADNameType = wrappers.ADS_NAME_TYPE_USER_PRINCIPAL_NAME
    ADNameTypeCanonicalEx          ADNameType = wrappers.ADS_NAME_TYPE_CANONICAL_EX
    ADNameTypeServicePrincipalName ADNameType = wrappers.ADS_NAME_TYPE_SERVICE_PRINCIPAL_NAME
    ADNameTypeSIDOrSIDHistoryName  ADNameType = wrappers.ADS_NAME_TYPE_SID_OR_SID_HISTORY_NAME
)

type ADSPNOperation Uses

type ADSPNOperation int32
const (
    ADSPNOperationAdd     ADSPNOperation = wrappers.DS_SPN_ADD_SPN_OP
    ADSPNOperationReplace ADSPNOperation = wrappers.DS_SPN_REPLACE_SPN_OP
    ADSPNOperationDelete  ADSPNOperation = wrappers.DS_SPN_DELETE_SPN_OP
)

type ADSystemInfo Uses

type ADSystemInfo struct {
    // contains filtered or unexported fields
}

func NewADSystemInfo Uses

func NewADSystemInfo() (*ADSystemInfo, error)

func (*ADSystemInfo) Close Uses

func (self *ADSystemInfo) Close() error

func (*ADSystemInfo) GetComputerName Uses

func (self *ADSystemInfo) GetComputerName() (string, error)

func (*ADSystemInfo) GetDomainDNSName Uses

func (self *ADSystemInfo) GetDomainDNSName() (string, error)

func (*ADSystemInfo) GetDomainShortName Uses

func (self *ADSystemInfo) GetDomainShortName() (string, error)

func (*ADSystemInfo) GetUserName Uses

func (self *ADSystemInfo) GetUserName() (string, error)

type ADWinNTSystemInfo Uses

type ADWinNTSystemInfo struct {
    // contains filtered or unexported fields
}

func NewADWinNTSystemInfo Uses

func NewADWinNTSystemInfo() (*ADWinNTSystemInfo, error)

func (*ADWinNTSystemInfo) Close Uses

func (self *ADWinNTSystemInfo) Close() error

func (*ADWinNTSystemInfo) GetComputerName Uses

func (self *ADWinNTSystemInfo) GetComputerName() (string, error)

func (*ADWinNTSystemInfo) GetDomainName Uses

func (self *ADWinNTSystemInfo) GetDomainName() (string, error)

func (*ADWinNTSystemInfo) GetUserName Uses

func (self *ADWinNTSystemInfo) GetUserName() (string, error)

type AccessMode Uses

type AccessMode int32
const (
    AccessNotUsed      AccessMode = wrappers.NOT_USED_ACCESS
    AccessGrant        AccessMode = wrappers.GRANT_ACCESS
    AccessSet          AccessMode = wrappers.SET_ACCESS
    AccessDeny         AccessMode = wrappers.DENY_ACCESS
    AccessRevoke       AccessMode = wrappers.REVOKE_ACCESS
    AccessAuditSuccess AccessMode = wrappers.SET_AUDIT_SUCCESS
    AccessAuditFailure AccessMode = wrappers.SET_AUDIT_FAILURE
)

type AccountRightName Uses

type AccountRightName string
const (
    AccountRightInteractiveLogon           AccountRightName = wrappers.SE_INTERACTIVE_LOGON_NAME
    AccountRightNetworkLogon               AccountRightName = wrappers.SE_NETWORK_LOGON_NAME
    AccountRightBatchLogon                 AccountRightName = wrappers.SE_BATCH_LOGON_NAME
    AccountRightServiceLogon               AccountRightName = wrappers.SE_SERVICE_LOGON_NAME
    AccountRightDenyInteractiveLogon       AccountRightName = wrappers.SE_DENY_INTERACTIVE_LOGON_NAME
    AccountRightDenyNetworkLogon           AccountRightName = wrappers.SE_DENY_NETWORK_LOGON_NAME
    AccountRightDenyBatchLogon             AccountRightName = wrappers.SE_DENY_BATCH_LOGON_NAME
    AccountRightDenyServiceLogon           AccountRightName = wrappers.SE_DENY_SERVICE_LOGON_NAME
    AccountRightRemoteInteractiveLogon     AccountRightName = wrappers.SE_REMOTE_INTERACTIVE_LOGON_NAME
    AccountRightDenyRemoteInteractiveLogon AccountRightName = wrappers.SE_DENY_REMOTE_INTERACTIVE_LOGON_NAME
)

type AddressFamily Uses

type AddressFamily uint32
const (
    AddressFamilyUnspecified AddressFamily = wrappers.AF_UNSPEC
    AddressFamilyIP          AddressFamily = wrappers.AF_INET
    AddressFamilyIPX         AddressFamily = wrappers.AF_IPX
    AddressFamilyAppleTalk   AddressFamily = wrappers.AF_APPLETALK
    AddressFamilyNetBIOS     AddressFamily = wrappers.AF_NETBIOS
    AddressFamilyIPv6        AddressFamily = wrappers.AF_INET6
    AddressFamilyIrDA        AddressFamily = wrappers.AF_IRDA
    AddressFamilyBluetooth   AddressFamily = wrappers.AF_BTH
)

type COMError Uses

type COMError uint32
const (
    COMErrorUnexpected      COMError = wrappers.E_UNEXPECTED
    COMErrorNotImplemented  COMError = wrappers.E_NOTIMPL
    COMErrorOutOfMemory     COMError = wrappers.E_OUTOFMEMORY
    COMErrorInvalidArgument COMError = wrappers.E_INVALIDARG
    COMErrorNoInterface     COMError = wrappers.E_NOINTERFACE
    COMErrorPointer         COMError = wrappers.E_POINTER
    COMErrorHandle          COMError = wrappers.E_HANDLE
    COMErrorAbort           COMError = wrappers.E_ABORT
    COMErrorFail            COMError = wrappers.E_FAIL
    COMErrorAccessDenied    COMError = wrappers.E_ACCESSDENIED
    COMErrorPending         COMError = wrappers.E_PENDING
)

func (COMError) Error Uses

func (self COMError) Error() string

func (COMError) GetCode Uses

func (self COMError) GetCode() uint16

func (COMError) GetFacility Uses

func (self COMError) GetFacility() Facility

type COMInitFlags Uses

type COMInitFlags uint32
const (
    COMInitApartmentThreaded COMInitFlags = wrappers.COINIT_APARTMENTTHREADED
    COMInitMultithreaded     COMInitFlags = wrappers.COINIT_MULTITHREADED
    COMInitDisableOLE1DDE    COMInitFlags = wrappers.COINIT_DISABLE_OLE1DDE
    COMInitSpeedOverMemory   COMInitFlags = wrappers.COINIT_SPEED_OVER_MEMORY
)

type CriticalSection Uses

type CriticalSection struct {
    // contains filtered or unexported fields
}

func NewCriticalSection Uses

func NewCriticalSection() *CriticalSection

func (*CriticalSection) Close Uses

func (self *CriticalSection) Close() error

func (*CriticalSection) Lock Uses

func (self *CriticalSection) Lock()

func (*CriticalSection) TryLock Uses

func (self *CriticalSection) TryLock() bool

func (*CriticalSection) Unlock Uses

func (self *CriticalSection) Unlock()

type DiskPerformanceInfo Uses

type DiskPerformanceInfo struct {
    BytesRead           int64
    BytesWritten        int64
    ReadTime            int64
    WriteTime           int64
    IdleTime            int64
    ReadCount           uint
    WriteCount          uint
    QueueDepth          uint
    SplitCount          uint
    QueryTime           int64
    StorageDeviceNumber uint
    StorageManagerName  string
}

func GetDiskPerformanceInfo Uses

func GetDiskPerformanceInfo(rootPathName string) (*DiskPerformanceInfo, error)

type DisplayDevice Uses

type DisplayDevice struct {
    DeviceName   string
    DeviceString string
    StateFlags   DisplayDeviceStateFlags
    DeviceID     string
    DeviceKey    string
}

func GetAllDisplayDevices Uses

func GetAllDisplayDevices() []DisplayDevice

type DisplayDeviceStateFlags Uses

type DisplayDeviceStateFlags uint32
const (
    DisplayDeviceActive          DisplayDeviceStateFlags = wrappers.DISPLAY_DEVICE_ACTIVE
    DisplayDevicePrimaryDevice   DisplayDeviceStateFlags = wrappers.DISPLAY_DEVICE_PRIMARY_DEVICE
    DisplayDeviceMirroringDriver DisplayDeviceStateFlags = wrappers.DISPLAY_DEVICE_MIRRORING_DRIVER
    DisplayDeviceVGACompatible   DisplayDeviceStateFlags = wrappers.DISPLAY_DEVICE_VGA_COMPATIBLE
    DisplayDeviceRemovable       DisplayDeviceStateFlags = wrappers.DISPLAY_DEVICE_REMOVABLE
    DisplayDeviceModeSpruned     DisplayDeviceStateFlags = wrappers.DISPLAY_DEVICE_MODESPRUNED
)

type DisplayMonitorInfo Uses

type DisplayMonitorInfo struct {
    Handle        syscall.Handle
    DeviceContext syscall.Handle
    Rectangle     Rectangle
}

func GetAllDisplayMonitors Uses

func GetAllDisplayMonitors() []DisplayMonitorInfo

type DriveType Uses

type DriveType uint32
const (
    DriveTypeUnknown DriveType = wrappers.DRIVE_UNKNOWN
    DriveNoRootDir   DriveType = wrappers.DRIVE_NO_ROOT_DIR
    DriveRemovable   DriveType = wrappers.DRIVE_REMOVABLE
    DriveFixed       DriveType = wrappers.DRIVE_FIXED
    DriveRemote      DriveType = wrappers.DRIVE_REMOTE
    DriveCDROM       DriveType = wrappers.DRIVE_CDROM
    DriveRAMDisk     DriveType = wrappers.DRIVE_RAMDISK
)

func GetVolumeDriveType Uses

func GetVolumeDriveType(rootPathName string) DriveType

type EventLogEvent Uses

type EventLogEvent struct {
    Type     EventType
    Category uint
    EventID  uint
    Strings  []string
    Data     []byte
}

type EventSource Uses

type EventSource struct {
    // contains filtered or unexported fields
}

func NewEventSource Uses

func NewEventSource(sourceName string) (*EventSource, error)

func (*EventSource) Close Uses

func (self *EventSource) Close() error

func (*EventSource) Error Uses

func (self *EventSource) Error(eventID uint, strings ...string) error

func (*EventSource) Info Uses

func (self *EventSource) Info(eventID uint, strings ...string) error

func (*EventSource) Report Uses

func (self *EventSource) Report(event *EventLogEvent) error

func (*EventSource) Warning Uses

func (self *EventSource) Warning(eventID uint, strings ...string) error

type EventSourceRegistration Uses

type EventSourceRegistration struct {
    SourceName           string
    CategoryCount        uint
    CategoryMessageFile  string
    EventMessageFile     string
    ParameterMessageFile string
    TypesSupported       EventType
}

func (*EventSourceRegistration) Install Uses

func (self *EventSourceRegistration) Install() error

type EventType Uses

type EventType uint32
const (
    EventTypeSuccess      EventType = wrappers.EVENTLOG_SUCCESS
    EventTypeError        EventType = wrappers.EVENTLOG_ERROR_TYPE
    EventTypeWarning      EventType = wrappers.EVENTLOG_WARNING_TYPE
    EventTypeInformation  EventType = wrappers.EVENTLOG_INFORMATION_TYPE
    EventTypeAuditSuccess EventType = wrappers.EVENTLOG_AUDIT_SUCCESS
    EventTypeAuditFailure EventType = wrappers.EVENTLOG_AUDIT_FAILURE
)

type Facility Uses

type Facility uint16
const (
    FacilityNull     Facility = wrappers.FACILITY_NULL
    FacilityRPC      Facility = wrappers.FACILITY_RPC
    FacilityDispatch Facility = wrappers.FACILITY_DISPATCH
    FacilityStorage  Facility = wrappers.FACILITY_STORAGE
    FacilityITF      Facility = wrappers.FACILITY_ITF
    FacilityWin32    Facility = wrappers.FACILITY_WIN32
    FacilityWindows  Facility = wrappers.FACILITY_WINDOWS
)

type FileAttributes Uses

type FileAttributes uint32
const (
    FileAttributeReadOnly          FileAttributes = wrappers.FILE_ATTRIBUTE_READONLY
    FileAttributeHidden            FileAttributes = wrappers.FILE_ATTRIBUTE_HIDDEN
    FileAttributeSystem            FileAttributes = wrappers.FILE_ATTRIBUTE_SYSTEM
    FileAttributeDirectory         FileAttributes = wrappers.FILE_ATTRIBUTE_DIRECTORY
    FileAttributeArchive           FileAttributes = wrappers.FILE_ATTRIBUTE_ARCHIVE
    FileAttributeDevice            FileAttributes = wrappers.FILE_ATTRIBUTE_DEVICE
    FileAttributeNormal            FileAttributes = wrappers.FILE_ATTRIBUTE_NORMAL
    FileAttributeTemporary         FileAttributes = wrappers.FILE_ATTRIBUTE_TEMPORARY
    FileAttributeSparseFile        FileAttributes = wrappers.FILE_ATTRIBUTE_SPARSE_FILE
    FileAttributeReparsePoint      FileAttributes = wrappers.FILE_ATTRIBUTE_REPARSE_POINT
    FileAttributeCompressed        FileAttributes = wrappers.FILE_ATTRIBUTE_COMPRESSED
    FileAttributeOffline           FileAttributes = wrappers.FILE_ATTRIBUTE_OFFLINE
    FileAttributeNotContentIndexed FileAttributes = wrappers.FILE_ATTRIBUTE_NOT_CONTENT_INDEXED
    FileAttributeEncrypted         FileAttributes = wrappers.FILE_ATTRIBUTE_ENCRYPTED
    FileAttributeVirtual           FileAttributes = wrappers.FILE_ATTRIBUTE_VIRTUAL
)

func GetAttributes Uses

func GetAttributes(fileName string) (FileAttributes, error)

type FileCreationDisposition Uses

type FileCreationDisposition uint32
const (
    FileCreateNew        FileCreationDisposition = wrappers.CREATE_NEW
    FileCreateAlways     FileCreationDisposition = wrappers.CREATE_ALWAYS
    FileOpenExisting     FileCreationDisposition = wrappers.OPEN_EXISTING
    FileOpenAlways       FileCreationDisposition = wrappers.OPEN_ALWAYS
    FileTruncateExisting FileCreationDisposition = wrappers.TRUNCATE_EXISTING
)

type FileFlags Uses

type FileFlags uint32
const (
    FileFlagWriteThrough      FileFlags = wrappers.FILE_FLAG_WRITE_THROUGH
    FileFlagOverlapped        FileFlags = wrappers.FILE_FLAG_OVERLAPPED
    FileFlagNoBuffering       FileFlags = wrappers.FILE_FLAG_NO_BUFFERING
    FileFlagRandomAccess      FileFlags = wrappers.FILE_FLAG_RANDOM_ACCESS
    FileFlagSequentialScan    FileFlags = wrappers.FILE_FLAG_SEQUENTIAL_SCAN
    FileFlagDeleteOnClose     FileFlags = wrappers.FILE_FLAG_DELETE_ON_CLOSE
    FileFlagBackupSemantics   FileFlags = wrappers.FILE_FLAG_BACKUP_SEMANTICS
    FileFlagPOSIXSemantics    FileFlags = wrappers.FILE_FLAG_POSIX_SEMANTICS
    FileFlagOpenReparsePoint  FileFlags = wrappers.FILE_FLAG_OPEN_REPARSE_POINT
    FileFlagOpenNoRecall      FileFlags = wrappers.FILE_FLAG_OPEN_NO_RECALL
    FileFlagFirstPipeInstance FileFlags = wrappers.FILE_FLAG_FIRST_PIPE_INSTANCE
)

type FileShareMode Uses

type FileShareMode uint32
const (
    FileShareExclusive FileShareMode = 0
    FileShareRead      FileShareMode = wrappers.FILE_SHARE_READ
    FileShareWrite     FileShareMode = wrappers.FILE_SHARE_WRITE
    FileShareDelete    FileShareMode = wrappers.FILE_SHARE_DELETE
)

type FileSystemFlags Uses

type FileSystemFlags uint32
const (
    FileSystemCaseSensitiveSearch        FileSystemFlags = wrappers.FILE_CASE_SENSITIVE_SEARCH
    FileSystemCasePreservedNames         FileSystemFlags = wrappers.FILE_CASE_PRESERVED_NAMES
    FileSystemUnicodeOnDisk              FileSystemFlags = wrappers.FILE_UNICODE_ON_DISK
    FileSystemPersistentACLs             FileSystemFlags = wrappers.FILE_PERSISTENT_ACLS
    FileSystemFileCompression            FileSystemFlags = wrappers.FILE_FILE_COMPRESSION
    FileSystemVolumeQuotas               FileSystemFlags = wrappers.FILE_VOLUME_QUOTAS
    FileSystemSupportsSparseFiles        FileSystemFlags = wrappers.FILE_SUPPORTS_SPARSE_FILES
    FileSystemSupportsReparsePoints      FileSystemFlags = wrappers.FILE_SUPPORTS_REPARSE_POINTS
    FileSystemSupportsRemoteStorage      FileSystemFlags = wrappers.FILE_SUPPORTS_REMOTE_STORAGE
    FileSystemVolumeIsCompressed         FileSystemFlags = wrappers.FILE_VOLUME_IS_COMPRESSED
    FileSystemSupportsObjectIDs          FileSystemFlags = wrappers.FILE_SUPPORTS_OBJECT_IDS
    FileSystemSupportsEncryption         FileSystemFlags = wrappers.FILE_SUPPORTS_ENCRYPTION
    FileSystemNamedStreams               FileSystemFlags = wrappers.FILE_NAMED_STREAMS
    FileSystemReadOnlyVolume             FileSystemFlags = wrappers.FILE_READ_ONLY_VOLUME
    FileSystemSequentialWriteOnce        FileSystemFlags = wrappers.FILE_SEQUENTIAL_WRITE_ONCE
    FileSystemSupportsTransactions       FileSystemFlags = wrappers.FILE_SUPPORTS_TRANSACTIONS
    FileSystemSupportsHardLinks          FileSystemFlags = wrappers.FILE_SUPPORTS_HARD_LINKS
    FileSystemSupportsExtendedAttributes FileSystemFlags = wrappers.FILE_SUPPORTS_EXTENDED_ATTRIBUTES
    FileSystemSupportsOpenByFileID       FileSystemFlags = wrappers.FILE_SUPPORTS_OPEN_BY_FILE_ID
    FileSystemSupportsUSNJournal         FileSystemFlags = wrappers.FILE_SUPPORTS_USN_JOURNAL
)

type FileVersion Uses

type FileVersion struct {
    // contains filtered or unexported fields
}

func GetFileVersion Uses

func GetFileVersion(filename string) (*FileVersion, error)

func (*FileVersion) GetFixedFileInfo Uses

func (self *FileVersion) GetFixedFileInfo() (*FixedFileInfo, error)

type FileVersionNumber Uses

type FileVersionNumber struct {
    Major    uint
    Minor    uint
    Build    uint
    Revision uint
}

func StringToFileVersionNumber Uses

func StringToFileVersionNumber(s string) (FileVersionNumber, error)

func (*FileVersionNumber) String Uses

func (self *FileVersionNumber) String() string

type FindFile Uses

type FindFile struct {
    // contains filtered or unexported fields
}

func OpenFindFile Uses

func OpenFindFile(fileName string) *FindFile

func (*FindFile) Close Uses

func (self *FindFile) Close() error

func (*FindFile) Current Uses

func (self *FindFile) Current() FindFileItem

func (*FindFile) Next Uses

func (self *FindFile) Next() (bool, error)

type FindFileItem Uses

type FindFileItem struct {
    FileAttributes    FileAttributes
    CreationTime      time.Time
    LastAccessTime    time.Time
    LastWriteTime     time.Time
    FileSize          uint64
    ReparseTag        ReparseTag
    FileName          string
    AlternateFileName string
}

func GetFilesInfo Uses

func GetFilesInfo(dirName, mask string, recursive bool) ([]FindFileItem, error)

GetFilesInfo returns all files from dirName that matches a specific file mask (for example *.txt) This function can search files recursively and process symlinked directories. If file exists in directory and also in symlinked directory it will be present in result array only one time In result array file names are returned with full path

func GetSubdirsInfo Uses

func GetSubdirsInfo(dirName string) ([]FindFileItem, error)

GetSubdirsInfo returns information about all subdirectories of the directory

type FirewallAction Uses

type FirewallAction int32
const (
    FirewallBlock FirewallAction = wrappers.NET_FW_ACTION_BLOCK
    FirewallAllow FirewallAction = wrappers.NET_FW_ACTION_ALLOW
)

type FirewallDirection Uses

type FirewallDirection int32
const (
    FirewallInbound  FirewallDirection = wrappers.NET_FW_RULE_DIR_IN
    FirewallOutbound FirewallDirection = wrappers.NET_FW_RULE_DIR_OUT
)

type FirewallIPVersion Uses

type FirewallIPVersion int32
const (
    FirewallIPV4         FirewallIPVersion = wrappers.NET_FW_IP_VERSION_V4
    FirewallIPV6         FirewallIPVersion = wrappers.NET_FW_IP_VERSION_V6
    FirewallAnyIPVersion FirewallIPVersion = wrappers.NET_FW_IP_VERSION_ANY
)

type FirewallManager Uses

type FirewallManager struct {
    // contains filtered or unexported fields
}

func NewFirewallManager Uses

func NewFirewallManager() (*FirewallManager, error)

func (*FirewallManager) Close Uses

func (self *FirewallManager) Close() error

func (*FirewallManager) IsPortAllowed Uses

func (self *FirewallManager) IsPortAllowed(imageFileName string, ipVersion FirewallIPVersion, portNumber int, localAddress string, ipProtocol FirewallProtocol) (allowed bool, restricted bool, err error)

type FirewallPolicy Uses

type FirewallPolicy struct {
    // contains filtered or unexported fields
}

func NewFirewallPolicy Uses

func NewFirewallPolicy() (*FirewallPolicy, error)

func (*FirewallPolicy) Close Uses

func (self *FirewallPolicy) Close() error

func (*FirewallPolicy) GetRules Uses

func (self *FirewallPolicy) GetRules() (*FirewallRuleCollection, error)

type FirewallProtocol Uses

type FirewallProtocol int32
const (
    FirewallTCP         FirewallProtocol = wrappers.NET_FW_PROTOCOL_TCP
    FirewallUDP         FirewallProtocol = wrappers.NET_FW_PROTOCOL_UDP
    FirewallAnyProtocol FirewallProtocol = wrappers.NET_FW_PROTOCOL_ANY
)

type FirewallRule Uses

type FirewallRule struct {
    // contains filtered or unexported fields
}

func NewFirewallRule Uses

func NewFirewallRule() (*FirewallRule, error)

func (*FirewallRule) Close Uses

func (self *FirewallRule) Close() error

func (*FirewallRule) GetAction Uses

func (self *FirewallRule) GetAction() (FirewallAction, error)

func (*FirewallRule) GetApplicationName Uses

func (self *FirewallRule) GetApplicationName() (string, error)

func (*FirewallRule) GetDescription Uses

func (self *FirewallRule) GetDescription() (string, error)

func (*FirewallRule) GetDirection Uses

func (self *FirewallRule) GetDirection() (FirewallDirection, error)

func (*FirewallRule) GetEdgeTraversal Uses

func (self *FirewallRule) GetEdgeTraversal() (bool, error)

func (*FirewallRule) GetEnabled Uses

func (self *FirewallRule) GetEnabled() (bool, error)

func (*FirewallRule) GetGrouping Uses

func (self *FirewallRule) GetGrouping() (string, error)

func (*FirewallRule) GetIcmpTypesAndCodes Uses

func (self *FirewallRule) GetIcmpTypesAndCodes() (string, error)

func (*FirewallRule) GetInterfaceTypes Uses

func (self *FirewallRule) GetInterfaceTypes() (string, error)

func (*FirewallRule) GetLocalAddresses Uses

func (self *FirewallRule) GetLocalAddresses() (string, error)

func (*FirewallRule) GetLocalPorts Uses

func (self *FirewallRule) GetLocalPorts() (string, error)

func (*FirewallRule) GetName Uses

func (self *FirewallRule) GetName() (string, error)

func (*FirewallRule) GetProtocol Uses

func (self *FirewallRule) GetProtocol() (FirewallProtocol, error)

func (*FirewallRule) GetRemoteAddresses Uses

func (self *FirewallRule) GetRemoteAddresses() (string, error)

func (*FirewallRule) GetRemotePorts Uses

func (self *FirewallRule) GetRemotePorts() (string, error)

func (*FirewallRule) GetServiceName Uses

func (self *FirewallRule) GetServiceName() (string, error)

func (*FirewallRule) SetAction Uses

func (self *FirewallRule) SetAction(action FirewallAction) error

func (*FirewallRule) SetApplicationName Uses

func (self *FirewallRule) SetApplicationName(imageFileName string) error

func (*FirewallRule) SetDescription Uses

func (self *FirewallRule) SetDescription(desc string) error

func (*FirewallRule) SetDirection Uses

func (self *FirewallRule) SetDirection(dir FirewallDirection) error

func (*FirewallRule) SetEdgeTraversal Uses

func (self *FirewallRule) SetEdgeTraversal(enabled bool) error

func (*FirewallRule) SetEnabled Uses

func (self *FirewallRule) SetEnabled(enabled bool) error

func (*FirewallRule) SetGrouping Uses

func (self *FirewallRule) SetGrouping(context string) error

func (*FirewallRule) SetIcmpTypesAndCodes Uses

func (self *FirewallRule) SetIcmpTypesAndCodes(icmpTypesAndCodes string) error

func (*FirewallRule) SetInterfaceTypes Uses

func (self *FirewallRule) SetInterfaceTypes(interfaceTypes string) error

func (*FirewallRule) SetLocalAddresses Uses

func (self *FirewallRule) SetLocalAddresses(localAddrs string) error

func (*FirewallRule) SetLocalPorts Uses

func (self *FirewallRule) SetLocalPorts(portNumbers string) error

func (*FirewallRule) SetName Uses

func (self *FirewallRule) SetName(name string) error

func (*FirewallRule) SetProtocol Uses

func (self *FirewallRule) SetProtocol(protocol FirewallProtocol) error

func (*FirewallRule) SetRemoteAddresses Uses

func (self *FirewallRule) SetRemoteAddresses(remoteAddrs string) error

func (*FirewallRule) SetRemotePorts Uses

func (self *FirewallRule) SetRemotePorts(portNumbers string) error

func (*FirewallRule) SetServiceName Uses

func (self *FirewallRule) SetServiceName(serviceName string) error

type FirewallRuleCollection Uses

type FirewallRuleCollection struct {
    // contains filtered or unexported fields
}

func (*FirewallRuleCollection) Add Uses

func (self *FirewallRuleCollection) Add(rule *FirewallRule) error

func (*FirewallRuleCollection) Close Uses

func (self *FirewallRuleCollection) Close() error

func (*FirewallRuleCollection) GetCount Uses

func (self *FirewallRuleCollection) GetCount() (int, error)

func (*FirewallRuleCollection) Item Uses

func (self *FirewallRuleCollection) Item(name string) (*FirewallRule, error)

func (*FirewallRuleCollection) NewEnumerator Uses

func (self *FirewallRuleCollection) NewEnumerator() (*FirewallRuleEnumerator, error)

func (*FirewallRuleCollection) Remove Uses

func (self *FirewallRuleCollection) Remove(name string) error

type FirewallRuleEnumerator Uses

type FirewallRuleEnumerator struct {
    // contains filtered or unexported fields
}

func (*FirewallRuleEnumerator) Close Uses

func (self *FirewallRuleEnumerator) Close() error

func (*FirewallRuleEnumerator) Next Uses

func (self *FirewallRuleEnumerator) Next() (*FirewallRule, error)

func (*FirewallRuleEnumerator) Reset Uses

func (self *FirewallRuleEnumerator) Reset() error

func (*FirewallRuleEnumerator) Skip Uses

func (self *FirewallRuleEnumerator) Skip(count uint) error

type FixedFileInfo Uses

type FixedFileInfo struct {
    FileVersion    FileVersionNumber
    ProductVersion FileVersionNumber
    FileFlags      VerFileFlags
    FileOS         VerFileOS
    FileType       VerFileType
    FileSubtype    VerFileSubtype
}

type HTTPRequest Uses

type HTTPRequest struct {
    InternetFile
}

func (*HTTPRequest) GetStatusCode Uses

func (self *HTTPRequest) GetStatusCode() (HTTPStatusCode, error)

func (*HTTPRequest) Send Uses

func (self *HTTPRequest) Send(headers string, optional []byte) error

type HTTPRequestFlags Uses

type HTTPRequestFlags uint32
const (
    HTTPRequestCacheIfNetFail        HTTPRequestFlags = wrappers.INTERNET_FLAG_CACHE_IF_NET_FAIL
    HTTPRequestHyperlink             HTTPRequestFlags = wrappers.INTERNET_FLAG_HYPERLINK
    HTTPRequestIgnoreCertCNInvalid   HTTPRequestFlags = wrappers.INTERNET_FLAG_IGNORE_CERT_CN_INVALID
    HTTPRequestIgnoreCertDateInvalid HTTPRequestFlags = wrappers.INTERNET_FLAG_IGNORE_CERT_DATE_INVALID
    HTTPRequestIgnoreRedirectToHTTP  HTTPRequestFlags = wrappers.INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTP
    HTTPRequestIgnoreRedirectToHTTPS HTTPRequestFlags = wrappers.INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTPS
    HTTPRequestKeepConnection        HTTPRequestFlags = wrappers.INTERNET_FLAG_KEEP_CONNECTION
    HTTPRequestNeedFile              HTTPRequestFlags = wrappers.INTERNET_FLAG_NEED_FILE
    HTTPRequestNoAuth                HTTPRequestFlags = wrappers.INTERNET_FLAG_NO_AUTH
    HTTPRequestNoAutoRedirect        HTTPRequestFlags = wrappers.INTERNET_FLAG_NO_AUTO_REDIRECT
    HTTPRequestNoCacheWrite          HTTPRequestFlags = wrappers.INTERNET_FLAG_NO_CACHE_WRITE
    HTTPRequestNoCookies             HTTPRequestFlags = wrappers.INTERNET_FLAG_NO_COOKIES
    HTTPRequestNoUI                  HTTPRequestFlags = wrappers.INTERNET_FLAG_NO_UI
    HTTPRequestPragmaNoCache         HTTPRequestFlags = wrappers.INTERNET_FLAG_PRAGMA_NOCACHE
    HTTPRequestReload                HTTPRequestFlags = wrappers.INTERNET_FLAG_RELOAD
    HTTPRequestResynchronize         HTTPRequestFlags = wrappers.INTERNET_FLAG_RESYNCHRONIZE
    HTTPRequestSecure                HTTPRequestFlags = wrappers.INTERNET_FLAG_SECURE
)

type HTTPStatusCode Uses

type HTTPStatusCode uint32
const (
    HTTPStatusContinue            HTTPStatusCode = wrappers.HTTP_STATUS_CONTINUE
    HTTPStatusSwitchProtocols     HTTPStatusCode = wrappers.HTTP_STATUS_SWITCH_PROTOCOLS
    HTTPStatusOK                  HTTPStatusCode = wrappers.HTTP_STATUS_OK
    HTTPStatusCreated             HTTPStatusCode = wrappers.HTTP_STATUS_CREATED
    HTTPStatusAccepted            HTTPStatusCode = wrappers.HTTP_STATUS_ACCEPTED
    HTTPStatusPartial             HTTPStatusCode = wrappers.HTTP_STATUS_PARTIAL
    HTTPStatusNoContent           HTTPStatusCode = wrappers.HTTP_STATUS_NO_CONTENT
    HTTPStatusResetContent        HTTPStatusCode = wrappers.HTTP_STATUS_RESET_CONTENT
    HTTPStatusPartialContent      HTTPStatusCode = wrappers.HTTP_STATUS_PARTIAL_CONTENT
    HTTPStatusAmbiguous           HTTPStatusCode = wrappers.HTTP_STATUS_AMBIGUOUS
    HTTPStatusMoved               HTTPStatusCode = wrappers.HTTP_STATUS_MOVED
    HTTPStatusRedirect            HTTPStatusCode = wrappers.HTTP_STATUS_REDIRECT
    HTTPStatusRedirectMethod      HTTPStatusCode = wrappers.HTTP_STATUS_REDIRECT_METHOD
    HTTPStatusNotModified         HTTPStatusCode = wrappers.HTTP_STATUS_NOT_MODIFIED
    HTTPStatusUseProxy            HTTPStatusCode = wrappers.HTTP_STATUS_USE_PROXY
    HTTPStatusRedirectKeepVerb    HTTPStatusCode = wrappers.HTTP_STATUS_REDIRECT_KEEP_VERB
    HTTPStatusBadRequest          HTTPStatusCode = wrappers.HTTP_STATUS_BAD_REQUEST
    HTTPStatusDenied              HTTPStatusCode = wrappers.HTTP_STATUS_DENIED
    HTTPStatusPaymentRequired     HTTPStatusCode = wrappers.HTTP_STATUS_PAYMENT_REQ
    HTTPStatusForbidden           HTTPStatusCode = wrappers.HTTP_STATUS_FORBIDDEN
    HTTPStatusNotFound            HTTPStatusCode = wrappers.HTTP_STATUS_NOT_FOUND
    HTTPStatusBadMethod           HTTPStatusCode = wrappers.HTTP_STATUS_BAD_METHOD
    HTTPStatusNoneAcceptable      HTTPStatusCode = wrappers.HTTP_STATUS_NONE_ACCEPTABLE
    HTTPStatusProxyAuthRequired   HTTPStatusCode = wrappers.HTTP_STATUS_PROXY_AUTH_REQ
    HTTPStatusRequestTimeout      HTTPStatusCode = wrappers.HTTP_STATUS_REQUEST_TIMEOUT
    HTTPStatusConflict            HTTPStatusCode = wrappers.HTTP_STATUS_CONFLICT
    HTTPStatusGone                HTTPStatusCode = wrappers.HTTP_STATUS_GONE
    HTTPStatusLengthRequired      HTTPStatusCode = wrappers.HTTP_STATUS_LENGTH_REQUIRED
    HTTPStatusPreconditionFailed  HTTPStatusCode = wrappers.HTTP_STATUS_PRECOND_FAILED
    HTTPStatusRequestTooLarge     HTTPStatusCode = wrappers.HTTP_STATUS_REQUEST_TOO_LARGE
    HTTPStatusURITooLong          HTTPStatusCode = wrappers.HTTP_STATUS_URI_TOO_LONG
    HTTPStatusUnsupportedMedia    HTTPStatusCode = wrappers.HTTP_STATUS_UNSUPPORTED_MEDIA
    HTTPStatusRetryWith           HTTPStatusCode = wrappers.HTTP_STATUS_RETRY_WITH
    HTTPStatusServerError         HTTPStatusCode = wrappers.HTTP_STATUS_SERVER_ERROR
    HTTPStatusNotSupported        HTTPStatusCode = wrappers.HTTP_STATUS_NOT_SUPPORTED
    HTTPStatusBadGateway          HTTPStatusCode = wrappers.HTTP_STATUS_BAD_GATEWAY
    HTTPStatusServiceUnavailable  HTTPStatusCode = wrappers.HTTP_STATUS_SERVICE_UNAVAIL
    HTTPStatusGatewayTimeout      HTTPStatusCode = wrappers.HTTP_STATUS_GATEWAY_TIMEOUT
    HTTPStatusVersionNotSupported HTTPStatusCode = wrappers.HTTP_STATUS_VERSION_NOT_SUP
)

type InstallLevel Uses

type InstallLevel int32
const (
    InstallLevelDefault InstallLevel = wrappers.INSTALLLEVEL_DEFAULT
    InstallLevelMinimum InstallLevel = wrappers.INSTALLLEVEL_MINIMUM
    InstallLevelMaximum InstallLevel = wrappers.INSTALLLEVEL_MAXIMUM
)

type InstallLogAttributes Uses

type InstallLogAttributes uint32
const (
    InstallLogAttributesAppend        InstallLogAttributes = wrappers.INSTALLLOGATTRIBUTES_APPEND
    InstallLogAttributesFlushEachLine InstallLogAttributes = wrappers.INSTALLLOGATTRIBUTES_FLUSHEACHLINE
)

type InstallLogMode Uses

type InstallLogMode uint32
const (
    InstallLogModeFatalExit      InstallLogMode = wrappers.INSTALLLOGMODE_FATALEXIT
    InstallLogModeError          InstallLogMode = wrappers.INSTALLLOGMODE_ERROR
    InstallLogModeWarning        InstallLogMode = wrappers.INSTALLLOGMODE_WARNING
    InstallLogModeUser           InstallLogMode = wrappers.INSTALLLOGMODE_USER
    InstallLogModeInfo           InstallLogMode = wrappers.INSTALLLOGMODE_INFO
    InstallLogModeResolveSource  InstallLogMode = wrappers.INSTALLLOGMODE_RESOLVESOURCE
    InstallLogModeOutOfDiskSpace InstallLogMode = wrappers.INSTALLLOGMODE_OUTOFDISKSPACE
    InstallLogModeActionStart    InstallLogMode = wrappers.INSTALLLOGMODE_ACTIONSTART
    InstallLogModeActionData     InstallLogMode = wrappers.INSTALLLOGMODE_ACTIONDATA
    InstallLogModeCommonData     InstallLogMode = wrappers.INSTALLLOGMODE_COMMONDATA
    InstallLogModePropertyDump   InstallLogMode = wrappers.INSTALLLOGMODE_PROPERTYDUMP
    InstallLogModeVerbose        InstallLogMode = wrappers.INSTALLLOGMODE_VERBOSE
    InstallLogModeExtraDebug     InstallLogMode = wrappers.INSTALLLOGMODE_EXTRADEBUG
    InstallLogModeLogOnlyOnError InstallLogMode = wrappers.INSTALLLOGMODE_LOGONLYONERROR
    InstallLogModeProgress       InstallLogMode = wrappers.INSTALLLOGMODE_PROGRESS
    InstallLogModeInitialize     InstallLogMode = wrappers.INSTALLLOGMODE_INITIALIZE
    InstallLogModeTerminate      InstallLogMode = wrappers.INSTALLLOGMODE_TERMINATE
    InstallLogModeShowDialog     InstallLogMode = wrappers.INSTALLLOGMODE_SHOWDIALOG
    InstallLogModeFilesInUse     InstallLogMode = wrappers.INSTALLLOGMODE_FILESINUSE
    InstallLogModeRMFilesInUse   InstallLogMode = wrappers.INSTALLLOGMODE_RMFILESINUSE
    InstallLogModeInstallStart   InstallLogMode = wrappers.INSTALLLOGMODE_INSTALLSTART
    InstallLogModeInstallEnd     InstallLogMode = wrappers.INSTALLLOGMODE_INSTALLEND
)

type InstallProperty Uses

type InstallProperty string
const (
    InstallPropertyPackageName          InstallProperty = wrappers.INSTALLPROPERTY_PACKAGENAME
    InstallPropertyTransforms           InstallProperty = wrappers.INSTALLPROPERTY_TRANSFORMS
    InstallPropertyLanguage             InstallProperty = wrappers.INSTALLPROPERTY_LANGUAGE
    InstallPropertyProductName          InstallProperty = wrappers.INSTALLPROPERTY_PRODUCTNAME
    InstallPropertyAssignmentType       InstallProperty = wrappers.INSTALLPROPERTY_ASSIGNMENTTYPE
    InstallPropertyInstanceType         InstallProperty = wrappers.INSTALLPROPERTY_INSTANCETYPE
    InstallPropertyAuthorizedLUAApp     InstallProperty = wrappers.INSTALLPROPERTY_AUTHORIZED_LUA_APP
    InstallPropertyPackageCode          InstallProperty = wrappers.INSTALLPROPERTY_PACKAGECODE
    InstallPropertyVersion              InstallProperty = wrappers.INSTALLPROPERTY_VERSION
    InstallPropertyProductIcon          InstallProperty = wrappers.INSTALLPROPERTY_PRODUCTICON
    InstallPropertyInstalledProductName InstallProperty = wrappers.INSTALLPROPERTY_INSTALLEDPRODUCTNAME
    InstallPropertyVersionString        InstallProperty = wrappers.INSTALLPROPERTY_VERSIONSTRING
    InstallPropertyHelpLink             InstallProperty = wrappers.INSTALLPROPERTY_HELPLINK
    InstallPropertyHelpTelephone        InstallProperty = wrappers.INSTALLPROPERTY_HELPTELEPHONE
    InstallPropertyInstallLocation      InstallProperty = wrappers.INSTALLPROPERTY_INSTALLLOCATION
    InstallPropertyInstallSource        InstallProperty = wrappers.INSTALLPROPERTY_INSTALLSOURCE
    InstallPropertyInstallDate          InstallProperty = wrappers.INSTALLPROPERTY_INSTALLDATE
    InstallPropertyPublisher            InstallProperty = wrappers.INSTALLPROPERTY_PUBLISHER
    InstallPropertyLocalPackage         InstallProperty = wrappers.INSTALLPROPERTY_LOCALPACKAGE
    InstallPropertyURLInfoAbout         InstallProperty = wrappers.INSTALLPROPERTY_URLINFOABOUT
    InstallPropertyURLUpdateInfo        InstallProperty = wrappers.INSTALLPROPERTY_URLUPDATEINFO
    InstallPropertyVersionMinor         InstallProperty = wrappers.INSTALLPROPERTY_VERSIONMINOR
    InstallPropertyVersionMajor         InstallProperty = wrappers.INSTALLPROPERTY_VERSIONMAJOR
    InstallPropertyProductID            InstallProperty = wrappers.INSTALLPROPERTY_PRODUCTID
    InstallPropertyRegCompany           InstallProperty = wrappers.INSTALLPROPERTY_REGCOMPANY
    InstallPropertyRegOwner             InstallProperty = wrappers.INSTALLPROPERTY_REGOWNER
    InstallPropertyInstalledLanguage    InstallProperty = wrappers.INSTALLPROPERTY_INSTALLEDLANGUAGE
)

type InstallState Uses

type InstallState int32
const (
    InstallStateBadConfig    InstallState = wrappers.INSTALLSTATE_BADCONFIG
    InstallStateIncomplete   InstallState = wrappers.INSTALLSTATE_INCOMPLETE
    InstallStateSourceAbsent InstallState = wrappers.INSTALLSTATE_SOURCEABSENT
    InstallStateMoreData     InstallState = wrappers.INSTALLSTATE_MOREDATA
    InstallStateInvalidArg   InstallState = wrappers.INSTALLSTATE_INVALIDARG
    InstallStateUnknown      InstallState = wrappers.INSTALLSTATE_UNKNOWN
    InstallStateBroken       InstallState = wrappers.INSTALLSTATE_BROKEN
    InstallStateAdvertised   InstallState = wrappers.INSTALLSTATE_ADVERTISED
    InstallStateAbsent       InstallState = wrappers.INSTALLSTATE_ABSENT
    InstallStateLocal        InstallState = wrappers.INSTALLSTATE_LOCAL
    InstallStateSource       InstallState = wrappers.INSTALLSTATE_SOURCE
    InstallStateDefault      InstallState = wrappers.INSTALLSTATE_DEFAULT
)

func GetInstalledComponentPath Uses

func GetInstalledComponentPath(productCode string, componentID string) (string, InstallState)

func GetInstalledProductState Uses

func GetInstalledProductState(productCode string) InstallState

type InstallUILevel Uses

type InstallUILevel int32
const (
    InstallUILevelNoChange      InstallUILevel = wrappers.INSTALLUILEVEL_NOCHANGE
    InstallUILevelDefault       InstallUILevel = wrappers.INSTALLUILEVEL_DEFAULT
    InstallUILevelNone          InstallUILevel = wrappers.INSTALLUILEVEL_NONE
    InstallUILevelBasic         InstallUILevel = wrappers.INSTALLUILEVEL_BASIC
    InstallUILevelReduced       InstallUILevel = wrappers.INSTALLUILEVEL_REDUCED
    InstallUILevelFull          InstallUILevel = wrappers.INSTALLUILEVEL_FULL
    InstallUILevelEndDialog     InstallUILevel = wrappers.INSTALLUILEVEL_ENDDIALOG
    InstallUILevelProgressOnly  InstallUILevel = wrappers.INSTALLUILEVEL_PROGRESSONLY
    InstallUILevelHideCancel    InstallUILevel = wrappers.INSTALLUILEVEL_HIDECANCEL
    InstallUILevelSourceResOnly InstallUILevel = wrappers.INSTALLUILEVEL_SOURCERESONLY
)

func SetInstallerInternalUI Uses

func SetInstallerInternalUI(uiLevel InstallUILevel) InstallUILevel

type InstallerPackage Uses

type InstallerPackage struct {
    // contains filtered or unexported fields
}

func OpenInstalledProduct Uses

func OpenInstalledProduct(productCode string) (*InstallerPackage, error)

func OpenInstallerPackage Uses

func OpenInstallerPackage(packagePath string) (*InstallerPackage, error)

func (*InstallerPackage) Close Uses

func (self *InstallerPackage) Close() error

func (*InstallerPackage) GetProductProperty Uses

func (self *InstallerPackage) GetProductProperty(property string) (string, error)

func (*InstallerPackage) GetProperty Uses

func (self *InstallerPackage) GetProperty(name string) (string, error)

type InternetConnection Uses

type InternetConnection struct {
    InternetObject
}

func (*InternetConnection) OpenHTTPRequest Uses

func (self *InternetConnection) OpenHTTPRequest(verb string, objectName string, version string, referer string, acceptTypes []string, flags HTTPRequestFlags) (*HTTPRequest, error)

type InternetFile Uses

type InternetFile struct {
    InternetObject
}

func (*InternetFile) GetBytesAvailable Uses

func (self *InternetFile) GetBytesAvailable() (int, error)

func (*InternetFile) Read Uses

func (self *InternetFile) Read(p []byte) (int, error)

type InternetObject Uses

type InternetObject struct {
    // contains filtered or unexported fields
}

func (*InternetObject) Close Uses

func (self *InternetObject) Close() error

type InternetOpenFlags Uses

type InternetOpenFlags uint32
const (
    InternetOpenAsync     InternetOpenFlags = wrappers.INTERNET_FLAG_ASYNC
    InternetOpenFromCache InternetOpenFlags = wrappers.INTERNET_FLAG_FROM_CACHE
    InternetOpenOffline   InternetOpenFlags = wrappers.INTERNET_FLAG_OFFLINE
)

type InternetOpenType Uses

type InternetOpenType uint32
const (
    InternetOpenDirect                   InternetOpenType = wrappers.INTERNET_OPEN_TYPE_DIRECT
    InternetOpenPreconfig                InternetOpenType = wrappers.INTERNET_OPEN_TYPE_PRECONFIG
    InternetOpenPreconfigWithNoAutoproxy InternetOpenType = wrappers.INTERNET_OPEN_TYPE_PRECONFIG_WITH_NO_AUTOPROXY
)

type InternetService Uses

type InternetService uint32
const (
    InternetServiceFTP  InternetService = wrappers.INTERNET_SERVICE_FTP
    InternetServiceHTTP InternetService = wrappers.INTERNET_SERVICE_HTTP
)

type InternetSession Uses

type InternetSession struct {
    InternetObject
}

func OpenInternetSession Uses

func OpenInternetSession(agent string, openType InternetOpenType, flags InternetOpenFlags) (*InternetSession, error)

func (*InternetSession) Connect Uses

func (self *InternetSession) Connect(serverName string, serverPort uint, service InternetService) (*InternetConnection, error)

func (*InternetSession) OpenURL Uses

func (self *InternetSession) OpenURL(url string, headers string, flags URLRequestFlags) (*InternetFile, error)

type Job Uses

type Job struct {
    // contains filtered or unexported fields
}

func NewJob Uses

func NewJob(name string) (*Job, error)

func OpenJob Uses

func OpenJob(name string) (*Job, error)

func (*Job) AssignProcess Uses

func (self *Job) AssignProcess(pid uint) error

func (*Job) Close Uses

func (self *Job) Close() error

func (*Job) GetBasicLimitInfo Uses

func (self *Job) GetBasicLimitInfo() (*JobBasicLimitInfo, error)

func (*Job) GetBasicUIRestrictions Uses

func (self *Job) GetBasicUIRestrictions() (JobUILimitFlags, error)

func (*Job) GetExtendedLimitInfo Uses

func (self *Job) GetExtendedLimitInfo() (*JobExtendedLimitInfo, error)

func (*Job) GetProcesses Uses

func (self *Job) GetProcesses() ([]uint, error)

func (*Job) ProcessInJob Uses

func (self *Job) ProcessInJob(pid uint) (bool, error)

func (*Job) SetBasicLimitInfo Uses

func (self *Job) SetBasicLimitInfo(info *JobBasicLimitInfo) error

func (*Job) SetBasicUIRestrictions Uses

func (self *Job) SetBasicUIRestrictions(flags JobUILimitFlags) error

func (*Job) SetExtendedLimitInfo Uses

func (self *Job) SetExtendedLimitInfo(info *JobExtendedLimitInfo) error

func (*Job) Terminate Uses

func (self *Job) Terminate(exitCode uint) error

type JobBasicLimitInfo Uses

type JobBasicLimitInfo struct {
    PerProcessUserTimeLimit int64
    PerJobUserTimeLimit     int64
    LimitFlags              JobLimitFlags
    MinimumWorkingSetSize   uintptr
    MaximumWorkingSetSize   uintptr
    ActiveProcessLimit      uint
    Affinity                uintptr
    PriorityClass           uint
    SchedulingClass         uint
}

type JobExtendedLimitInfo Uses

type JobExtendedLimitInfo struct {
    JobBasicLimitInfo
    ProcessMemoryLimit    uintptr
    JobMemoryLimit        uintptr
    PeakProcessMemoryUsed uintptr
    PeakJobMemoryUsed     uintptr
}

type JobLimitFlags Uses

type JobLimitFlags uint32
const (
    JobLimitWorkingSet              JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_WORKINGSET
    JobLimitProcessTime             JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_PROCESS_TIME
    JobLimitJobTime                 JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_JOB_TIME
    JobLimitActiveProcess           JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_ACTIVE_PROCESS
    JobLimitAffinity                JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_AFFINITY
    JobLimitPriorityClass           JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_PRIORITY_CLASS
    JobLimitPreserveJobTime         JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_PRESERVE_JOB_TIME
    JobLimitSchedulingClass         JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_SCHEDULING_CLASS
    JobLimitProcessMemory           JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_PROCESS_MEMORY
    JobLimitDieOnUnhandledException JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_DIE_ON_UNHANDLED_EXCEPTION
    JobLimitBreakawayOK             JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_BREAKAWAY_OK
    JobLimitSilentBreakawayOK       JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK
    JobLimitKillOnJobClose          JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE
    JobLimitSubsetAffinity          JobLimitFlags = wrappers.JOB_OBJECT_LIMIT_SUBSET_AFFINITY
)

type JobUILimitFlags Uses

type JobUILimitFlags uint32
const (
    JobUILimitHandles          JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_HANDLES
    JobUILimitReadClipboard    JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_READCLIPBOARD
    JobUILimitWriteClipboard   JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_WRITECLIPBOARD
    JobUILimitSystemParameters JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_SYSTEMPARAMETERS
    JobUILimitDisplaySettings  JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_DISPLAYSETTINGS
    JobUILimitGlobalAtoms      JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_GLOBALATOMS
    JobUILimitDesktop          JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_DESKTOP
    JobUILimitExitWindows      JobUILimitFlags = wrappers.JOB_OBJECT_UILIMIT_EXITWINDOWS
)

type KnownFolder Uses

type KnownFolder wrappers.GUID

type Language Uses

type Language uint16

type Locale Uses

type Locale uint32

func LocaleFromLocaleName Uses

func LocaleFromLocaleName(localeName string, flags LocaleNameFlags) (Locale, error)

func (Locale) Language Uses

func (locale Locale) Language() Language

type LocaleNameFlags Uses

type LocaleNameFlags uint32
const (
    LocaleNameAllowNeutralNames LocaleNameFlags = wrappers.LOCALE_ALLOW_NEUTRAL_NAMES
)

type MemoryStatus Uses

type MemoryStatus struct {
    MemoryLoad                    uint
    TotalPhysicalBytes            uint64
    AvailablePhysicalBytes        uint64
    TotalPageFileBytes            uint64
    AvailablePageFileBytes        uint64
    TotalVirtualBytes             uint64
    AvailableVirtualBytes         uint64
    AvailableExtendedVirtualBytes uint64
}

func GetMemoryStatus Uses

func GetMemoryStatus() (*MemoryStatus, error)

type ModuleInfo Uses

type ModuleInfo struct {
    ProcessID         uint
    ModuleBaseAddress *byte
    ModuleBaseSize    uint
    ModuleHandle      syscall.Handle
    ModuleName        string
    ExePath           string
}

func GetProcessModules Uses

func GetProcessModules(pid uint32) ([]ModuleInfo, error)

type NTError Uses

type NTError uint32

func (NTError) Error Uses

func (self NTError) Error() string

type NetstatEntry Uses

type NetstatEntry struct {
    State         NetstatTCPState
    LocalAddress  string
    LocalPort     uint
    RemoteAddress string
    RemotePort    uint
}

func Netstat Uses

func Netstat() ([]NetstatEntry, error)

type NetstatTCPState Uses

type NetstatTCPState uint32
const (
    NetstatClosed      NetstatTCPState = wrappers.MIB_TCP_STATE_CLOSED
    NetstatListen      NetstatTCPState = wrappers.MIB_TCP_STATE_LISTEN
    NetstatSYNSent     NetstatTCPState = wrappers.MIB_TCP_STATE_SYN_SENT
    NetstatSYNReceived NetstatTCPState = wrappers.MIB_TCP_STATE_SYN_RCVD
    NetstatEstablished NetstatTCPState = wrappers.MIB_TCP_STATE_ESTAB
    NetstatFINWait1    NetstatTCPState = wrappers.MIB_TCP_STATE_FIN_WAIT1
    NetstatFINWait2    NetstatTCPState = wrappers.MIB_TCP_STATE_FIN_WAIT2
    NetstatCloseWait   NetstatTCPState = wrappers.MIB_TCP_STATE_CLOSE_WAIT
    NetstatClosing     NetstatTCPState = wrappers.MIB_TCP_STATE_CLOSING
    NetstatLastACK     NetstatTCPState = wrappers.MIB_TCP_STATE_LAST_ACK
    NetstatTimeWait    NetstatTCPState = wrappers.MIB_TCP_STATE_TIME_WAIT
    NetstatDeleteTCB   NetstatTCPState = wrappers.MIB_TCP_STATE_DELETE_TCB
)

type OSVersionInfo Uses

type OSVersionInfo struct {
    MajorVersion     uint
    MinorVersion     uint
    BuildNumber      uint
    PlatformId       VerPlatform
    ServicePackName  string
    ServicePackMajor uint
    ServicePackMinor uint
    SuiteMask        VerSuite
    ProductType      VerProductType
}

func GetWindowsVersion Uses

func GetWindowsVersion() (*OSVersionInfo, error)

type Permission Uses

type Permission uint32
const (
    GenericRead            Permission = wrappers.GENERIC_READ
    GenericWrite           Permission = wrappers.GENERIC_WRITE
    GenericExecute         Permission = wrappers.GENERIC_EXECUTE
    GenericAll             Permission = wrappers.GENERIC_ALL
    FileReadData           Permission = wrappers.FILE_READ_DATA
    FileListDirectory      Permission = wrappers.FILE_LIST_DIRECTORY
    FileWriteData          Permission = wrappers.FILE_WRITE_DATA
    FileAddFile            Permission = wrappers.FILE_ADD_FILE
    FileAppendData         Permission = wrappers.FILE_APPEND_DATA
    FileAddSubdirectory    Permission = wrappers.FILE_ADD_SUBDIRECTORY
    FileCreatePipeInstance Permission = wrappers.FILE_CREATE_PIPE_INSTANCE
    FileReadEA             Permission = wrappers.FILE_READ_EA
    FileWriteEA            Permission = wrappers.FILE_WRITE_EA
    FileExecute            Permission = wrappers.FILE_EXECUTE
    FileTraverse           Permission = wrappers.FILE_TRAVERSE
    FileDeleteChild        Permission = wrappers.FILE_DELETE_CHILD
    FileReadAttributes     Permission = wrappers.FILE_READ_ATTRIBUTES
    FileWriteAttributes    Permission = wrappers.FILE_WRITE_ATTRIBUTES
    FileAllAccess          Permission = wrappers.FILE_ALL_ACCESS
    FileGenericRead        Permission = wrappers.FILE_GENERIC_READ
    FileGenericWrite       Permission = wrappers.FILE_GENERIC_WRITE
    FileGenericExecute     Permission = wrappers.FILE_GENERIC_EXECUTE
)

type PermissionEntry Uses

type PermissionEntry struct {
    TrusteeType TrusteeType
    Trustee     SecurityID
    Permissions Permission
    AccessMode  AccessMode
}

type Privilege Uses

type Privilege struct {
    // contains filtered or unexported fields
}

func GetPrivilege Uses

func GetPrivilege(name PrivilegeName) (*Privilege, error)

type PrivilegeName Uses

type PrivilegeName string
const (
    PrivilegeCreateToken          PrivilegeName = wrappers.SE_CREATE_TOKEN_NAME
    PrivilegeAssignPrimaryToken   PrivilegeName = wrappers.SE_ASSIGNPRIMARYTOKEN_NAME
    PrivilegeLockMemory           PrivilegeName = wrappers.SE_LOCK_MEMORY_NAME
    PrivilegeIncreaseQuota        PrivilegeName = wrappers.SE_INCREASE_QUOTA_NAME
    PrivilegeUnsolicitedInput     PrivilegeName = wrappers.SE_UNSOLICITED_INPUT_NAME
    PrivilegeMachineAccount       PrivilegeName = wrappers.SE_MACHINE_ACCOUNT_NAME
    PrivilegeTCB                  PrivilegeName = wrappers.SE_TCB_NAME
    PrivilegeSecurity             PrivilegeName = wrappers.SE_SECURITY_NAME
    PrivilegeTakeOwnership        PrivilegeName = wrappers.SE_TAKE_OWNERSHIP_NAME
    PrivilegeLoadDriver           PrivilegeName = wrappers.SE_LOAD_DRIVER_NAME
    PrivilegeSystemProfile        PrivilegeName = wrappers.SE_SYSTEM_PROFILE_NAME
    PrivilegeSystemTime           PrivilegeName = wrappers.SE_SYSTEMTIME_NAME
    PrivilegeProfileSingleProcess PrivilegeName = wrappers.SE_PROF_SINGLE_PROCESS_NAME
    PrivilegeIncreaseBasePriority PrivilegeName = wrappers.SE_INC_BASE_PRIORITY_NAME
    PrivilegeCreatePagefile       PrivilegeName = wrappers.SE_CREATE_PAGEFILE_NAME
    PrivilegeCreatePermanent      PrivilegeName = wrappers.SE_CREATE_PERMANENT_NAME
    PrivilegeBackup               PrivilegeName = wrappers.SE_BACKUP_NAME
    PrivilegeRestore              PrivilegeName = wrappers.SE_RESTORE_NAME
    PrivilegeShutdown             PrivilegeName = wrappers.SE_SHUTDOWN_NAME
    PrivilegeDebug                PrivilegeName = wrappers.SE_DEBUG_NAME
    PrivilegeAudit                PrivilegeName = wrappers.SE_AUDIT_NAME
    PrivilegeSystemEnvironment    PrivilegeName = wrappers.SE_SYSTEM_ENVIRONMENT_NAME
    PrivilegeChangeNotify         PrivilegeName = wrappers.SE_CHANGE_NOTIFY_NAME
    PrivilegeRemoteShutdown       PrivilegeName = wrappers.SE_REMOTE_SHUTDOWN_NAME
    PrivilegeUndock               PrivilegeName = wrappers.SE_UNDOCK_NAME
    PrivilegeSyncAgent            PrivilegeName = wrappers.SE_SYNC_AGENT_NAME
    PrivilegeEnableDelegation     PrivilegeName = wrappers.SE_ENABLE_DELEGATION_NAME
    PrivilegeManageVolume         PrivilegeName = wrappers.SE_MANAGE_VOLUME_NAME
    PrivilegeImpersonate          PrivilegeName = wrappers.SE_IMPERSONATE_NAME
    PrivilegeCreateGlobal         PrivilegeName = wrappers.SE_CREATE_GLOBAL_NAME
    PrivilegeTrustedCredManAccess PrivilegeName = wrappers.SE_TRUSTED_CREDMAN_ACCESS_NAME
    PrivilegeRelabel              PrivilegeName = wrappers.SE_RELABEL_NAME
    PrivilegeIncreaseWorkingSet   PrivilegeName = wrappers.SE_INC_WORKING_SET_NAME
    PrivilegeTimeZone             PrivilegeName = wrappers.SE_TIME_ZONE_NAME
    PrivilegeCreateSymbolicLink   PrivilegeName = wrappers.SE_CREATE_SYMBOLIC_LINK_NAME
)

type ProcessInfo Uses

type ProcessInfo struct {
    ProcessID       uint
    Threads         uint
    ParentProcessID uint
    BasePriority    int
    ExeFile         string
}

func GetProcesses Uses

func GetProcesses() ([]ProcessInfo, error)

type ProcessNameFlags Uses

type ProcessNameFlags uint32
const (
    ProcessNameNative ProcessNameFlags = wrappers.PROCESS_NAME_NATIVE
)

type ProcessTimeCounters Uses

type ProcessTimeCounters struct {
    Creation uint64
    Exit     uint64
    Kernel   uint64
    User     uint64
}

func GetProcessTimeCounters Uses

func GetProcessTimeCounters(pid uint) (*ProcessTimeCounters, error)

type ProcessorArchitecture Uses

type ProcessorArchitecture uint16
const (
    ProcessorArchitectureIntel   ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_INTEL
    ProcessorArchitectureMIPS    ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_MIPS
    ProcessorArchitectureAlpha   ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_ALPHA
    ProcessorArchitecturePowerPC ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_PPC
    ProcessorArchitectureARM     ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_ARM
    ProcessorArchitectureIA64    ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_IA64
    ProcessorArchitectureAMD64   ProcessorArchitecture = wrappers.PROCESSOR_ARCHITECTURE_AMD64
)

type ProcessorInfo Uses

type ProcessorInfo struct {
    ProcessorArchitecture ProcessorArchitecture
    NumberOfProcessors    uint
    ProcessorLevel        uint
    ProcessorRevision     uint
}

func GetProcessorInfo Uses

func GetProcessorInfo() *ProcessorInfo

type Rectangle Uses

type Rectangle struct {
    Left   int
    Top    int
    Right  int
    Bottom int
}

type RegKey Uses

type RegKey struct {
    // contains filtered or unexported fields
}

func CreateRegKey Uses

func CreateRegKey(root RegRoot, subKey string) (*RegKey, error)

func OpenRegKey Uses

func OpenRegKey(root RegRoot, subKey string, readWrite bool) (*RegKey, error)

func (*RegKey) Close Uses

func (self *RegKey) Close() error

func (*RegKey) CreateSubKey Uses

func (self *RegKey) CreateSubKey(subKey string) (*RegKey, error)

func (*RegKey) DeleteSubKey Uses

func (self *RegKey) DeleteSubKey(subKey string) error

func (*RegKey) DeleteValue Uses

func (self *RegKey) DeleteValue(valueName string) error

func (*RegKey) GetSubKeys Uses

func (self *RegKey) GetSubKeys() ([]string, error)

func (*RegKey) GetValueBinary Uses

func (self *RegKey) GetValueBinary(valueName string) ([]byte, error)

func (*RegKey) GetValueDWORD Uses

func (self *RegKey) GetValueDWORD(valueName string) (uint32, error)

func (*RegKey) GetValueQWORD Uses

func (self *RegKey) GetValueQWORD(valueName string) (uint64, error)

func (*RegKey) GetValueString Uses

func (self *RegKey) GetValueString(valueName string) (string, error)

func (*RegKey) GetValues Uses

func (self *RegKey) GetValues() ([]string, error)

func (*RegKey) OpenSubKey Uses

func (self *RegKey) OpenSubKey(subKey string, readWrite bool) (*RegKey, error)

func (*RegKey) SetValueBinary Uses

func (self *RegKey) SetValueBinary(valueName string, data []byte) error

func (*RegKey) SetValueDWORD Uses

func (self *RegKey) SetValueDWORD(valueName string, data uint32) error

func (*RegKey) SetValueQWORD Uses

func (self *RegKey) SetValueQWORD(valueName string, data uint64) error

func (*RegKey) SetValueString Uses

func (self *RegKey) SetValueString(valueName string, data string) error

type RegRoot Uses

type RegRoot syscall.Handle
const (
    RegRootHKCR RegRoot = wrappers.HKEY_CLASSES_ROOT
    RegRootHKCU RegRoot = wrappers.HKEY_CURRENT_USER
    RegRootHKLM RegRoot = wrappers.HKEY_LOCAL_MACHINE
    RegRootHKU  RegRoot = wrappers.HKEY_USERS
    RegRootHKPD RegRoot = wrappers.HKEY_PERFORMANCE_DATA
    RegRootHKCC RegRoot = wrappers.HKEY_CURRENT_CONFIG
    RegRootHKDD RegRoot = wrappers.HKEY_DYN_DATA
)

type ReparseTag Uses

type ReparseTag uint32
const (
    ReparseTagMountPoint   ReparseTag = wrappers.IO_REPARSE_TAG_MOUNT_POINT
    ReparseTagHSM          ReparseTag = wrappers.IO_REPARSE_TAG_HSM
    ReparseTagHSM2         ReparseTag = wrappers.IO_REPARSE_TAG_HSM2
    ReparseTagSIS          ReparseTag = wrappers.IO_REPARSE_TAG_SIS
    ReparseTagCSV          ReparseTag = wrappers.IO_REPARSE_TAG_CSV
    ReparseTagDFS          ReparseTag = wrappers.IO_REPARSE_TAG_DFS
    ReparseTagSymbolicLink ReparseTag = wrappers.IO_REPARSE_TAG_SYMLINK
    ReparseTagDFSR         ReparseTag = wrappers.IO_REPARSE_TAG_DFSR
)

type ResourceId Uses

type ResourceId uintptr

func IntResourceId Uses

func IntResourceId(resourceId uint) ResourceId

func StringResourceId Uses

func StringResourceId(resourceId string) ResourceId

type ResourceType Uses

type ResourceType uintptr
var (
    ResourceTypeCursor        ResourceType = ResourceType(wrappers.RT_CURSOR)
    ResourceTypeBitmap        ResourceType = ResourceType(wrappers.RT_BITMAP)
    ResourceTypeIcon          ResourceType = ResourceType(wrappers.RT_ICON)
    ResourceTypeMenu          ResourceType = ResourceType(wrappers.RT_MENU)
    ResourceTypeDialog        ResourceType = ResourceType(wrappers.RT_DIALOG)
    ResourceTypeString        ResourceType = ResourceType(wrappers.RT_STRING)
    ResourceTypeFontDir       ResourceType = ResourceType(wrappers.RT_FONTDIR)
    ResourceTypeFont          ResourceType = ResourceType(wrappers.RT_FONT)
    ResourceTypeAccelerator   ResourceType = ResourceType(wrappers.RT_ACCELERATOR)
    ResourceTypeRCData        ResourceType = ResourceType(wrappers.RT_RCDATA)
    ResourceTypeMessageTable  ResourceType = ResourceType(wrappers.RT_MESSAGETABLE)
    ResourceTypeGroupCursor   ResourceType = ResourceType(wrappers.RT_GROUP_CURSOR)
    ResourceTypeGroupIcon     ResourceType = ResourceType(wrappers.RT_GROUP_ICON)
    ResourceTypeVersion       ResourceType = ResourceType(wrappers.RT_VERSION)
    ResourceTypeDialogInclude ResourceType = ResourceType(wrappers.RT_DLGINCLUDE)
    ResourceTypePlugPlay      ResourceType = ResourceType(wrappers.RT_PLUGPLAY)
    ResourceTypeVxD           ResourceType = ResourceType(wrappers.RT_VXD)
    ResourceTypeAniCursor     ResourceType = ResourceType(wrappers.RT_ANICURSOR)
    ResourceTypeAniIcon       ResourceType = ResourceType(wrappers.RT_ANIICON)
    ResourceTypeHTML          ResourceType = ResourceType(wrappers.RT_HTML)
    ResourceTypeManifest      ResourceType = ResourceType(wrappers.RT_MANIFEST)
)

func CustomResourceType Uses

func CustomResourceType(resourceTypeName string) ResourceType

type ResourceUpdate Uses

type ResourceUpdate struct {
    // contains filtered or unexported fields
}

func NewResourceUpdate Uses

func NewResourceUpdate(fileName string, deleteExistingResources bool) (*ResourceUpdate, error)

func (*ResourceUpdate) Close Uses

func (self *ResourceUpdate) Close() error

func (*ResourceUpdate) Delete Uses

func (self *ResourceUpdate) Delete(resourceType ResourceType, resourceId ResourceId, language Language) error

func (*ResourceUpdate) Save Uses

func (self *ResourceUpdate) Save() error

func (*ResourceUpdate) Update Uses

func (self *ResourceUpdate) Update(resourceType ResourceType, resourceId ResourceId, language Language, data []byte) error

type SCManager Uses

type SCManager struct {
    // contains filtered or unexported fields
}

func OpenLocalSCManager Uses

func OpenLocalSCManager() (*SCManager, error)

func (*SCManager) Close Uses

func (self *SCManager) Close() error

func (*SCManager) CreateService Uses

func (self *SCManager) CreateService(serviceName string, config *ServiceConfig, mask ServiceConfigMask) (*Service, error)

func (*SCManager) GetServices Uses

func (self *SCManager) GetServices(serviceType ServiceType, serviceState ServiceEnumState) ([]ServiceInfo, error)

func (*SCManager) OpenService Uses

func (self *SCManager) OpenService(serviceName string) (*Service, error)

type SecurityID Uses

type SecurityID struct {
    // contains filtered or unexported fields
}

func GetFileOwner Uses

func GetFileOwner(path string) (SecurityID, error)

func GetWellKnownSecurityID Uses

func GetWellKnownSecurityID(wellKnownType WellKnownSecurityIDType) (SecurityID, error)

func (SecurityID) Copy Uses

func (self SecurityID) Copy() (SecurityID, error)

func (SecurityID) Equal Uses

func (self SecurityID) Equal(other SecurityID) bool

func (SecurityID) GetLength Uses

func (self SecurityID) GetLength() uint

func (SecurityID) String Uses

func (self SecurityID) String() (string, error)

type SecurityIDType Uses

type SecurityIDType int32
const (
    SecurityIDTypeUser           SecurityIDType = wrappers.SidTypeUser
    SecurityIDTypeGroup          SecurityIDType = wrappers.SidTypeGroup
    SecurityIDTypeDomain         SecurityIDType = wrappers.SidTypeDomain
    SecurityIDTypeAlias          SecurityIDType = wrappers.SidTypeAlias
    SecurityIDTypeWellKnownGroup SecurityIDType = wrappers.SidTypeWellKnownGroup
    SecurityIDTypeDeletedAccount SecurityIDType = wrappers.SidTypeDeletedAccount
    SecurityIDTypeInvalid        SecurityIDType = wrappers.SidTypeInvalid
    SecurityIDTypeUnknown        SecurityIDType = wrappers.SidTypeUnknown
    SecurityIDTypeComputer       SecurityIDType = wrappers.SidTypeComputer
    SecurityIDTypeLabel          SecurityIDType = wrappers.SidTypeLabel
)

type SecurityPolicy Uses

type SecurityPolicy struct {
    // contains filtered or unexported fields
}

func OpenLocalSecurityPolicy Uses

func OpenLocalSecurityPolicy() (*SecurityPolicy, error)

func (*SecurityPolicy) AddAccountRight Uses

func (self *SecurityPolicy) AddAccountRight(sid SecurityID, right AccountRightName) error

func (*SecurityPolicy) Close Uses

func (self *SecurityPolicy) Close() error

func (*SecurityPolicy) GetAccountRights Uses

func (self *SecurityPolicy) GetAccountRights(sid SecurityID) ([]AccountRightName, error)

func (*SecurityPolicy) RemoveAccountRight Uses

func (self *SecurityPolicy) RemoveAccountRight(sid SecurityID, right AccountRightName) error

func (*SecurityPolicy) RemoveAllAccountRights Uses

func (self *SecurityPolicy) RemoveAllAccountRights(sid SecurityID) error

type Service Uses

type Service struct {
    // contains filtered or unexported fields
}

func (*Service) Close Uses

func (self *Service) Close() error

func (*Service) Control Uses

func (self *Service) Control(control ServiceControl) (*ServiceStatusInfo, error)

func (*Service) Delete Uses

func (self *Service) Delete() error

func (*Service) GetConfig Uses

func (self *Service) GetConfig() (*ServiceConfig, error)

func (*Service) GetDescription Uses

func (self *Service) GetDescription() (string, error)

func (*Service) GetProcessID Uses

func (self *Service) GetProcessID() (uint, error)

func (*Service) GetStatus Uses

func (self *Service) GetStatus() (*ServiceStatusInfo, error)

func (*Service) SetConfig Uses

func (self *Service) SetConfig(config *ServiceConfig, mask ServiceConfigMask) error

func (*Service) SetDescription Uses

func (self *Service) SetDescription(description string) error

func (*Service) Start Uses

func (self *Service) Start(args []string) error

type ServiceConfig Uses

type ServiceConfig struct {
    ServiceType      ServiceType
    StartType        ServiceStartType
    ErrorControl     ServiceErrorControl
    BinaryPathName   string
    LoadOrderGroup   string
    TagId            uint32
    Dependencies     string
    ServiceStartName string
    Password         string
    DisplayName      string
}

type ServiceConfigMask Uses

type ServiceConfigMask uint32
const (
    ServiceConfigServiceType      ServiceConfigMask = 0x00000001
    ServiceConfigStartType        ServiceConfigMask = 0x00000002
    ServiceConfigErrorControl     ServiceConfigMask = 0x00000004
    ServiceConfigBinaryPathName   ServiceConfigMask = 0x00000008
    ServiceConfigLoadOrderGroup   ServiceConfigMask = 0x00000010
    ServiceConfigTagId            ServiceConfigMask = 0x00000020
    ServiceConfigDependencies     ServiceConfigMask = 0x00000040
    ServiceConfigServiceStartName ServiceConfigMask = 0x00000080
    ServiceConfigPassword         ServiceConfigMask = 0x00000100
    ServiceConfigDisplayName      ServiceConfigMask = 0x00000200
)

type ServiceControl Uses

type ServiceControl uint32
const (
    ServiceControlStop                  ServiceControl = wrappers.SERVICE_CONTROL_STOP
    ServiceControlPause                 ServiceControl = wrappers.SERVICE_CONTROL_PAUSE
    ServiceControlContinue              ServiceControl = wrappers.SERVICE_CONTROL_CONTINUE
    ServiceControlInterrogate           ServiceControl = wrappers.SERVICE_CONTROL_INTERROGATE
    ServiceControlShutdown              ServiceControl = wrappers.SERVICE_CONTROL_SHUTDOWN
    ServiceControlParamChange           ServiceControl = wrappers.SERVICE_CONTROL_PARAMCHANGE
    ServiceControlNetBindAdd            ServiceControl = wrappers.SERVICE_CONTROL_NETBINDADD
    ServiceControlNetBindRemove         ServiceControl = wrappers.SERVICE_CONTROL_NETBINDREMOVE
    ServiceControlNetBindEnable         ServiceControl = wrappers.SERVICE_CONTROL_NETBINDENABLE
    ServiceControlNetBindDisable        ServiceControl = wrappers.SERVICE_CONTROL_NETBINDDISABLE
    ServiceControlDeviceEvent           ServiceControl = wrappers.SERVICE_CONTROL_DEVICEEVENT
    ServiceControlHardwareProfileChange ServiceControl = wrappers.SERVICE_CONTROL_HARDWAREPROFILECHANGE
    ServiceControlPowerEvent            ServiceControl = wrappers.SERVICE_CONTROL_POWEREVENT
    ServiceControlSessionChange         ServiceControl = wrappers.SERVICE_CONTROL_SESSIONCHANGE
    ServiceControlPreshutdown           ServiceControl = wrappers.SERVICE_CONTROL_PRESHUTDOWN
    ServiceControlTimeChange            ServiceControl = wrappers.SERVICE_CONTROL_TIMECHANGE
    ServiceControlTriggerEvent          ServiceControl = wrappers.SERVICE_CONTROL_TRIGGEREVENT
)

type ServiceControlsAccepted Uses

type ServiceControlsAccepted uint32
const (
    ServiceAcceptStop                  ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_STOP
    ServiceAcceptPauseContinue         ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_PAUSE_CONTINUE
    ServiceAcceptShutdown              ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_SHUTDOWN
    ServiceAcceptParamChange           ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_PARAMCHANGE
    ServiceAcceptNetBindChange         ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_NETBINDCHANGE
    ServiceAcceptHardwareProfileChange ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_HARDWAREPROFILECHANGE
    ServiceAcceptPowerEvent            ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_POWEREVENT
    ServiceAcceptSessionChange         ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_SESSIONCHANGE
    ServiceAcceptPreshutdown           ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_PRESHUTDOWN
    ServiceAcceptTimeChange            ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_TIMECHANGE
    ServiceAcceptTriggerEvent          ServiceControlsAccepted = wrappers.SERVICE_ACCEPT_TRIGGEREVENT
)

type ServiceEnumState Uses

type ServiceEnumState uint32
const (
    ServiceEnumActive   ServiceEnumState = wrappers.SERVICE_ACTIVE
    ServiceEnumInactive ServiceEnumState = wrappers.SERVICE_INACTIVE
    ServiceEnumAll      ServiceEnumState = wrappers.SERVICE_STATE_ALL
)

type ServiceErrorControl Uses

type ServiceErrorControl uint32
const (
    ServiceErrorIgnore   ServiceErrorControl = wrappers.SERVICE_ERROR_IGNORE
    ServiceErrorNormal   ServiceErrorControl = wrappers.SERVICE_ERROR_NORMAL
    ServiceErrorSevere   ServiceErrorControl = wrappers.SERVICE_ERROR_SEVERE
    ServiceErrorCritical ServiceErrorControl = wrappers.SERVICE_ERROR_CRITICAL
)

type ServiceInfo Uses

type ServiceInfo struct {
    ServiceName   string
    DisplayName   string
    ServiceStatus ServiceStatusInfo
}

type ServiceStartType Uses

type ServiceStartType uint32
const (
    ServiceBootStart   ServiceStartType = wrappers.SERVICE_BOOT_START
    ServiceSystemStart ServiceStartType = wrappers.SERVICE_SYSTEM_START
    ServiceAutoStart   ServiceStartType = wrappers.SERVICE_AUTO_START
    ServiceDemandStart ServiceStartType = wrappers.SERVICE_DEMAND_START
    ServiceDisabled    ServiceStartType = wrappers.SERVICE_DISABLED
)

type ServiceState Uses

type ServiceState uint32
const (
    ServiceStopped         ServiceState = wrappers.SERVICE_STOPPED
    ServiceStartPending    ServiceState = wrappers.SERVICE_START_PENDING
    ServiceStopPending     ServiceState = wrappers.SERVICE_STOP_PENDING
    ServiceRunning         ServiceState = wrappers.SERVICE_RUNNING
    ServiceContinuePending ServiceState = wrappers.SERVICE_CONTINUE_PENDING
    ServicePausePending    ServiceState = wrappers.SERVICE_PAUSE_PENDING
    ServicePaused          ServiceState = wrappers.SERVICE_PAUSED
)

type ServiceStatusInfo Uses

type ServiceStatusInfo struct {
    ServiceType             ServiceType
    CurrentState            ServiceState
    ControlsAccepted        ServiceControlsAccepted
    Win32ExitCode           uint32
    ServiceSpecificExitCode uint32
    CheckPoint              uint32
    WaitHint                uint32
}

type ServiceType Uses

type ServiceType uint32
const (
    ServiceKernelDriver       ServiceType = wrappers.SERVICE_KERNEL_DRIVER
    ServiceFileSystemDriver   ServiceType = wrappers.SERVICE_FILE_SYSTEM_DRIVER
    ServiceAdapter            ServiceType = wrappers.SERVICE_ADAPTER
    ServiceRecognizerDriver   ServiceType = wrappers.SERVICE_RECOGNIZER_DRIVER
    ServiceDriver             ServiceType = wrappers.SERVICE_DRIVER
    ServiceWin32OwnProcess    ServiceType = wrappers.SERVICE_WIN32_OWN_PROCESS
    ServiceWin32ShareProcess  ServiceType = wrappers.SERVICE_WIN32_SHARE_PROCESS
    ServiceWin32              ServiceType = wrappers.SERVICE_WIN32
    ServiceInteractiveProcess ServiceType = wrappers.SERVICE_INTERACTIVE_PROCESS
)

type SpecialFolder Uses

type SpecialFolder uint32
const (
    FolderDesktop                SpecialFolder = wrappers.CSIDL_DESKTOP
    FolderInternet               SpecialFolder = wrappers.CSIDL_INTERNET
    FolderPrograms               SpecialFolder = wrappers.CSIDL_PROGRAMS
    FolderControls               SpecialFolder = wrappers.CSIDL_CONTROLS
    FolderPrinters               SpecialFolder = wrappers.CSIDL_PRINTERS
    FolderPersonal               SpecialFolder = wrappers.CSIDL_PERSONAL
    FolderFavorites              SpecialFolder = wrappers.CSIDL_FAVORITES
    FolderStartup                SpecialFolder = wrappers.CSIDL_STARTUP
    FolderRecent                 SpecialFolder = wrappers.CSIDL_RECENT
    FolderSendTo                 SpecialFolder = wrappers.CSIDL_SENDTO
    FolderBitBucket              SpecialFolder = wrappers.CSIDL_BITBUCKET
    FolderStartMenu              SpecialFolder = wrappers.CSIDL_STARTMENU
    FolderMyDocuments            SpecialFolder = wrappers.CSIDL_MYDOCUMENTS
    FolderMyMusic                SpecialFolder = wrappers.CSIDL_MYMUSIC
    FolderMyVideo                SpecialFolder = wrappers.CSIDL_MYVIDEO
    FolderDesktopDirectory       SpecialFolder = wrappers.CSIDL_DESKTOPDIRECTORY
    FolderDrives                 SpecialFolder = wrappers.CSIDL_DRIVES
    FolderNetwork                SpecialFolder = wrappers.CSIDL_NETWORK
    FolderNetHood                SpecialFolder = wrappers.CSIDL_NETHOOD
    FolderFonts                  SpecialFolder = wrappers.CSIDL_FONTS
    FolderTemplates              SpecialFolder = wrappers.CSIDL_TEMPLATES
    FolderCommonStartMenu        SpecialFolder = wrappers.CSIDL_COMMON_STARTMENU
    FolderCommonPrograms         SpecialFolder = wrappers.CSIDL_COMMON_PROGRAMS
    FolderCommonStartup          SpecialFolder = wrappers.CSIDL_COMMON_STARTUP
    FolderCommonDesktopDirectory SpecialFolder = wrappers.CSIDL_COMMON_DESKTOPDIRECTORY
    FolderAppData                SpecialFolder = wrappers.CSIDL_APPDATA
    FolderPrintHood              SpecialFolder = wrappers.CSIDL_PRINTHOOD
    FolderLocalAppData           SpecialFolder = wrappers.CSIDL_LOCAL_APPDATA
    FolderAltStartup             SpecialFolder = wrappers.CSIDL_ALTSTARTUP
    FolderCommonAltStartup       SpecialFolder = wrappers.CSIDL_COMMON_ALTSTARTUP
    FolderCommonFavorites        SpecialFolder = wrappers.CSIDL_COMMON_FAVORITES
    FolderInternetCache          SpecialFolder = wrappers.CSIDL_INTERNET_CACHE
    FolderCookies                SpecialFolder = wrappers.CSIDL_COOKIES
    FolderHistory                SpecialFolder = wrappers.CSIDL_HISTORY
    FolderCommonAppData          SpecialFolder = wrappers.CSIDL_COMMON_APPDATA
    FolderWindows                SpecialFolder = wrappers.CSIDL_WINDOWS
    FolderSystem                 SpecialFolder = wrappers.CSIDL_SYSTEM
    FolderProgramFiles           SpecialFolder = wrappers.CSIDL_PROGRAM_FILES
    FolderMyPictures             SpecialFolder = wrappers.CSIDL_MYPICTURES
    FolderProfile                SpecialFolder = wrappers.CSIDL_PROFILE
    FolderSystemX86              SpecialFolder = wrappers.CSIDL_SYSTEMX86
    FolderProgramFilesX86        SpecialFolder = wrappers.CSIDL_PROGRAM_FILESX86
    FolderProgramFilesCommon     SpecialFolder = wrappers.CSIDL_PROGRAM_FILES_COMMON
    FolderProgramFilesCommonX86  SpecialFolder = wrappers.CSIDL_PROGRAM_FILES_COMMONX86
    FolderCommonTemplates        SpecialFolder = wrappers.CSIDL_COMMON_TEMPLATES
    FolderCommonDocuments        SpecialFolder = wrappers.CSIDL_COMMON_DOCUMENTS
    FolderCommonAdminTools       SpecialFolder = wrappers.CSIDL_COMMON_ADMINTOOLS
    FolderAdminTools             SpecialFolder = wrappers.CSIDL_ADMINTOOLS
    FolderConnections            SpecialFolder = wrappers.CSIDL_CONNECTIONS
    FolderCommonMusic            SpecialFolder = wrappers.CSIDL_COMMON_MUSIC
    FolderCommonPictures         SpecialFolder = wrappers.CSIDL_COMMON_PICTURES
    FolderCommonVideo            SpecialFolder = wrappers.CSIDL_COMMON_VIDEO
    FolderResources              SpecialFolder = wrappers.CSIDL_RESOURCES
    FolderResourcesLocalized     SpecialFolder = wrappers.CSIDL_RESOURCES_LOCALIZED
    FolderCommonOEMLinks         SpecialFolder = wrappers.CSIDL_COMMON_OEM_LINKS
    FolderCDBurnArea             SpecialFolder = wrappers.CSIDL_CDBURN_AREA
    FolderComputersNearMe        SpecialFolder = wrappers.CSIDL_COMPUTERSNEARME
)

type SymbolicLinkData Uses

type SymbolicLinkData struct {
    SubstituteName string
    PrintName      string
    Relative       bool
}
func GetSymbolicLink(symlinkPath string) (*SymbolicLinkData, error)

type SystemTimeCounters Uses

type SystemTimeCounters struct {
    Idle   uint64
    Kernel uint64
    User   uint64
}

func GetSystemTimeCounters Uses

func GetSystemTimeCounters() (*SystemTimeCounters, error)

type Token Uses

type Token struct {
    // contains filtered or unexported fields
}

func OpenCurrentProcessToken Uses

func OpenCurrentProcessToken() (*Token, error)

func OpenCurrentProcessTokenWithAccess Uses

func OpenCurrentProcessTokenWithAccess(desiredAccess uint32) (*Token, error)

func OpenCurrentThreadToken Uses

func OpenCurrentThreadToken(openAsSelf bool) (*Token, error)

func OpenOtherProcessToken Uses

func OpenOtherProcessToken(pid uint) (*Token, error)

func (*Token) Close Uses

func (self *Token) Close() error

func (*Token) EnablePrivilege Uses

func (self *Token) EnablePrivilege(privilege *Privilege, enable bool) error

func (*Token) GetOwner Uses

func (self *Token) GetOwner() (SecurityID, error)

func (*Token) GetUser Uses

func (self *Token) GetUser() (SecurityID, error)

type TrusteeType Uses

type TrusteeType int32
const (
    TrusteeUnknown        TrusteeType = wrappers.TRUSTEE_IS_UNKNOWN
    TrusteeUser           TrusteeType = wrappers.TRUSTEE_IS_USER
    TrusteeGroup          TrusteeType = wrappers.TRUSTEE_IS_GROUP
    TrusteeDomain         TrusteeType = wrappers.TRUSTEE_IS_DOMAIN
    TrusteeAlias          TrusteeType = wrappers.TRUSTEE_IS_ALIAS
    TrusteeWellKnownGroup TrusteeType = wrappers.TRUSTEE_IS_WELL_KNOWN_GROUP
    TrusteeDeleted        TrusteeType = wrappers.TRUSTEE_IS_DELETED
    TrusteeInvalid        TrusteeType = wrappers.TRUSTEE_IS_INVALID
    TrusteeComputer       TrusteeType = wrappers.TRUSTEE_IS_COMPUTER
)

type URLRequestFlags Uses

type URLRequestFlags uint32
const (
    URLRequestExistingConnect       URLRequestFlags = wrappers.INTERNET_FLAG_EXISTING_CONNECT
    URLRequestHyperlink             URLRequestFlags = wrappers.INTERNET_FLAG_HYPERLINK
    URLRequestIgnoreCertCNInvalid   URLRequestFlags = wrappers.INTERNET_FLAG_IGNORE_CERT_CN_INVALID
    URLRequestIgnoreCertDateInvalid URLRequestFlags = wrappers.INTERNET_FLAG_IGNORE_CERT_DATE_INVALID
    URLRequestIgnoreRedirectToHTTP  URLRequestFlags = wrappers.INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTP
    URLRequestIgnoreRedirectToHTTPS URLRequestFlags = wrappers.INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTPS
    URLRequestKeepConnection        URLRequestFlags = wrappers.INTERNET_FLAG_KEEP_CONNECTION
    URLRequestNeedFile              URLRequestFlags = wrappers.INTERNET_FLAG_NEED_FILE
    URLRequestNoAuth                URLRequestFlags = wrappers.INTERNET_FLAG_NO_AUTH
    URLRequestNoAutoRedirect        URLRequestFlags = wrappers.INTERNET_FLAG_NO_AUTO_REDIRECT
    URLRequestNoCacheWrite          URLRequestFlags = wrappers.INTERNET_FLAG_NO_CACHE_WRITE
    URLRequestNoCookies             URLRequestFlags = wrappers.INTERNET_FLAG_NO_COOKIES
    URLRequestNoUI                  URLRequestFlags = wrappers.INTERNET_FLAG_NO_UI
    URLRequestPassive               URLRequestFlags = wrappers.INTERNET_FLAG_PASSIVE
    URLRequestPragmaNoCache         URLRequestFlags = wrappers.INTERNET_FLAG_PRAGMA_NOCACHE
    URLRequestRawData               URLRequestFlags = wrappers.INTERNET_FLAG_RAW_DATA
    URLRequestReload                URLRequestFlags = wrappers.INTERNET_FLAG_RELOAD
    URLRequestResynchronize         URLRequestFlags = wrappers.INTERNET_FLAG_RESYNCHRONIZE
    URLRequestSecure                URLRequestFlags = wrappers.INTERNET_FLAG_SECURE
)

type VerFileFlags Uses

type VerFileFlags uint32
const (
    VerFileDebug        VerFileFlags = wrappers.VS_FF_DEBUG
    VerFilePrerelease   VerFileFlags = wrappers.VS_FF_PRERELEASE
    VerFilePatched      VerFileFlags = wrappers.VS_FF_PATCHED
    VerFilePrivateBuild VerFileFlags = wrappers.VS_FF_PRIVATEBUILD
    VerFileInfoInferred VerFileFlags = wrappers.VS_FF_INFOINFERRED
    VerFileSpecialBuild VerFileFlags = wrappers.VS_FF_SPECIALBUILD
)

type VerFileOS Uses

type VerFileOS uint32
const (
    VerFileOSUnknown    VerFileOS = wrappers.VOS_UNKNOWN
    VerFileDOS          VerFileOS = wrappers.VOS_DOS
    VerFileOS216        VerFileOS = wrappers.VOS_OS216
    VerFileOS232        VerFileOS = wrappers.VOS_OS232
    VerFileNT           VerFileOS = wrappers.VOS_NT
    VerFileWindows16    VerFileOS = wrappers.VOS__WINDOWS16
    VerFilePM16         VerFileOS = wrappers.VOS__PM16
    VerFilePM32         VerFileOS = wrappers.VOS__PM32
    VerFileWindows32    VerFileOS = wrappers.VOS__WINDOWS32
    VerFileDOSWindows16 VerFileOS = wrappers.VOS_DOS_WINDOWS16
    VerFileDOSWindows32 VerFileOS = wrappers.VOS_DOS_WINDOWS32
    VerFileOS216PM16    VerFileOS = wrappers.VOS_OS216_PM16
    VerFileOS232PM32    VerFileOS = wrappers.VOS_OS232_PM32
    VerFileNTWindows32  VerFileOS = wrappers.VOS_NT_WINDOWS32
)

type VerFileSubtype Uses

type VerFileSubtype uint32
const (
    VerFileSubtypeUnknown         VerFileSubtype = wrappers.VFT2_UNKNOWN
    VerFileDriverPrinter          VerFileSubtype = wrappers.VFT2_DRV_PRINTER
    VerFileDriverKeyboard         VerFileSubtype = wrappers.VFT2_DRV_KEYBOARD
    VerFileDriverLanguage         VerFileSubtype = wrappers.VFT2_DRV_LANGUAGE
    VerFileDriverDisplay          VerFileSubtype = wrappers.VFT2_DRV_DISPLAY
    VerFileDriverMouse            VerFileSubtype = wrappers.VFT2_DRV_MOUSE
    VerFileDriverNetwork          VerFileSubtype = wrappers.VFT2_DRV_NETWORK
    VerFileDriverSystem           VerFileSubtype = wrappers.VFT2_DRV_SYSTEM
    VerFileDriverInstallable      VerFileSubtype = wrappers.VFT2_DRV_INSTALLABLE
    VerFileDriverSound            VerFileSubtype = wrappers.VFT2_DRV_SOUND
    VerFileDriverComm             VerFileSubtype = wrappers.VFT2_DRV_COMM
    VerFileDriverVersionedPrinter VerFileSubtype = wrappers.VFT2_DRV_VERSIONED_PRINTER
    VerFileFontRaster             VerFileSubtype = wrappers.VFT2_FONT_RASTER
    VerFileFontVector             VerFileSubtype = wrappers.VFT2_FONT_VECTOR
    VerFileFontTrueType           VerFileSubtype = wrappers.VFT2_FONT_TRUETYPE
)

type VerFileType Uses

type VerFileType uint32
const (
    VerFileTypeUnknown VerFileType = wrappers.VFT_UNKNOWN
    VerFileApp         VerFileType = wrappers.VFT_APP
    VerFileDLL         VerFileType = wrappers.VFT_DLL
    VerFileDriver      VerFileType = wrappers.VFT_DRV
    VerFileFont        VerFileType = wrappers.VFT_FONT
    VerFileVxD         VerFileType = wrappers.VFT_VXD
    VerFileStaticLib   VerFileType = wrappers.VFT_STATIC_LIB
)

type VerLogOp Uses

type VerLogOp uint8
const (
    VerAnd VerLogOp = wrappers.VER_AND
    VerOr  VerLogOp = wrappers.VER_OR
)

type VerPlatform Uses

type VerPlatform uint32
const (
    VerPlatformWin32s    VerPlatform = wrappers.VER_PLATFORM_WIN32s
    VerPlatformWindows9x VerPlatform = wrappers.VER_PLATFORM_WIN32_WINDOWS
    VerPlatformWindowsNT VerPlatform = wrappers.VER_PLATFORM_WIN32_NT
)

type VerProductType Uses

type VerProductType uint8
const (
    VerProductWorkstation      VerProductType = wrappers.VER_NT_WORKSTATION
    VerProductDomainController VerProductType = wrappers.VER_NT_DOMAIN_CONTROLLER
    VerProductServer           VerProductType = wrappers.VER_NT_SERVER
)

type VerRelOp Uses

type VerRelOp uint8
const (
    VerEqual        VerRelOp = wrappers.VER_EQUAL
    VerGreater      VerRelOp = wrappers.VER_GREATER
    VerGreaterEqual VerRelOp = wrappers.VER_GREATER_EQUAL
    VerLess         VerRelOp = wrappers.VER_LESS
    VerLessEqual    VerRelOp = wrappers.VER_LESS_EQUAL
)

type VerSuite Uses

type VerSuite uint16
const (
    VerSuiteSmallBusiness           VerSuite = wrappers.VER_SUITE_SMALLBUSINESS
    VerSuiteEnterprise              VerSuite = wrappers.VER_SUITE_ENTERPRISE
    VerSuiteBackOffice              VerSuite = wrappers.VER_SUITE_BACKOFFICE
    VerSuiteCommunications          VerSuite = wrappers.VER_SUITE_COMMUNICATIONS
    VerSuiteTerminal                VerSuite = wrappers.VER_SUITE_TERMINAL
    VerSuiteSmallBusinessRestricted VerSuite = wrappers.VER_SUITE_SMALLBUSINESS_RESTRICTED
    VerSuiteEmbeddedNT              VerSuite = wrappers.VER_SUITE_EMBEDDEDNT
    VerSuiteDataCenter              VerSuite = wrappers.VER_SUITE_DATACENTER
    VerSuiteSingleUserTS            VerSuite = wrappers.VER_SUITE_SINGLEUSERTS
    VerSuitePersonal                VerSuite = wrappers.VER_SUITE_PERSONAL
    VerSuiteBlade                   VerSuite = wrappers.VER_SUITE_BLADE
    VerSuiteEmbeddedRestricted      VerSuite = wrappers.VER_SUITE_EMBEDDED_RESTRICTED
    VerSuiteSecurityAppliance       VerSuite = wrappers.VER_SUITE_SECURITY_APPLIANCE
    VerSuiteStorageServer           VerSuite = wrappers.VER_SUITE_STORAGE_SERVER
    VerSuiteComputeServer           VerSuite = wrappers.VER_SUITE_COMPUTE_SERVER
    VerSuiteWHServer                VerSuite = wrappers.VER_SUITE_WH_SERVER
)

type VersionCheck Uses

type VersionCheck struct {
    // contains filtered or unexported fields
}

func (*VersionCheck) BuildNumber Uses

func (self *VersionCheck) BuildNumber(op VerRelOp, value uint)

func (*VersionCheck) MajorVersion Uses

func (self *VersionCheck) MajorVersion(op VerRelOp, value uint)

func (*VersionCheck) MinorVersion Uses

func (self *VersionCheck) MinorVersion(op VerRelOp, value uint)

func (*VersionCheck) Platform Uses

func (self *VersionCheck) Platform(op VerRelOp, value VerPlatform)

func (*VersionCheck) ProductType Uses

func (self *VersionCheck) ProductType(op VerRelOp, value VerProductType)

func (*VersionCheck) ServicePackMajor Uses

func (self *VersionCheck) ServicePackMajor(op VerRelOp, value uint)

func (*VersionCheck) ServicePackMinor Uses

func (self *VersionCheck) ServicePackMinor(op VerRelOp, value uint)

func (*VersionCheck) Suite Uses

func (self *VersionCheck) Suite(op VerLogOp, value VerSuite)

func (*VersionCheck) Verify Uses

func (self *VersionCheck) Verify() (bool, error)

type VolumeInfo Uses

type VolumeInfo struct {
    VolumeName             string
    VolumeSerialNumber     uint
    MaximumComponentLength uint
    FileSystemFlags        FileSystemFlags
    FileSystemName         string
}

func GetVolumeInfo Uses

func GetVolumeInfo(rootPathName string) (*VolumeInfo, error)

type WTSClientDisplay Uses

type WTSClientDisplay struct {
    HorizontalResolution uint
    VerticalResolution   uint
    ColorDepth           uint
}

WTSClientDisplay - go version of WTS_CLIENT_DISPLAY structure

type WTSClientInfo Uses

type WTSClientInfo struct {
    ClientName          string
    Domain              string
    UserName            string
    WorkDirectory       string
    InitialProgram      string
    EncryptionLevel     byte
    ClientAddressFamily AddressFamily

    HRes              uint
    VRes              uint
    ColorDepth        uint
    ClientDirectory   string
    ClientBuildNumber uint
    ClientHardwareId  uint
    ClientProductId   uint
    OutBufCountHost   uint
    OutBufCountClient uint
    OutBufLength      uint
    DeviceID          string
    // contains filtered or unexported fields
}

WTSClientInfo - go version of WTSCLIENT structure

func (*WTSClientInfo) ClientAddressToIP Uses

func (ci *WTSClientInfo) ClientAddressToIP() (net.IP, error)

type WTSClientProtocolType Uses

type WTSClientProtocolType uint32

WTSClientProtocolType enum type go version of WTSClientProtocolType

const (
    WTSClientProtocolConsoleSession WTSClientProtocolType = 0
    WTSClientProtocolInternal       WTSClientProtocolType = 1
    WTSClientProtocolRDP            WTSClientProtocolType = 2
)

type WTSConnectState Uses

type WTSConnectState uint32

WTSConnectState enum type - Go version of WTS_CONNECTSTATE_CLASS

const (
    WTSConnectStateActive       WTSConnectState = wrappers.WTSActive
    WTSConnectStateConnected    WTSConnectState = wrappers.WTSConnected
    WTSConnectStateConnectQuery WTSConnectState = wrappers.WTSConnectQuery
    WTSConnectStateShadow       WTSConnectState = wrappers.WTSShadow
    WTSConnectStateDisconnected WTSConnectState = wrappers.WTSDisconnected
    WTSConnectStateIdle         WTSConnectState = wrappers.WTSIdle
    WTSConnectStateListen       WTSConnectState = wrappers.WTSListen
    WTSConnectStateReset        WTSConnectState = wrappers.WTSReset
    WTSConnectStateDown         WTSConnectState = wrappers.WTSDown
    WTSConnectStateInit         WTSConnectState = wrappers.WTSInit
)

type WTSInfo Uses

type WTSInfo struct {
    State                   WTSConnectState
    SessionID               uint
    IncomingBytes           uint
    OutgoingBytes           uint
    IncomingFrames          uint
    OutgoingFrames          uint
    IncomingCompressedBytes uint
    OutgoingCompressedBytes uint
    WinStationName          string
    Domain                  string
    UserName                string
    ConnectTime             time.Time
    DisconnectTime          time.Time
    LastInputTime           time.Time
    LogonTime               time.Time
    CurrentTime             time.Time
}

Info - go version of WTSINFO structure

type WTSServer Uses

type WTSServer struct {
    // contains filtered or unexported fields
}

func OpenWTSServer Uses

func OpenWTSServer(serverName string) *WTSServer

func (*WTSServer) Close Uses

func (wts *WTSServer) Close()

func (*WTSServer) EnumerateSessions Uses

func (wts *WTSServer) EnumerateSessions() ([]WTSSessionInfo, error)

func (*WTSServer) LogoffSession Uses

func (wts *WTSServer) LogoffSession(sessionID uint, wait bool) error

func (*WTSServer) QuerySessionAddressV4 Uses

func (wts *WTSServer) QuerySessionAddressV4(sessionID uint) (wrappers.WTS_CLIENT_ADDRESS, error)

func (*WTSServer) QuerySessionApplicationName Uses

func (wts *WTSServer) QuerySessionApplicationName(sessionID uint) (string, error)

func (*WTSServer) QuerySessionClientAddress Uses

func (wts *WTSServer) QuerySessionClientAddress(sessionID uint) (net.IP, error)

func (*WTSServer) QuerySessionClientBuildNumber Uses

func (wts *WTSServer) QuerySessionClientBuildNumber(sessionID uint) (uint32, error)

func (*WTSServer) QuerySessionClientDirectory Uses

func (wts *WTSServer) QuerySessionClientDirectory(sessionID uint) (string, error)

func (*WTSServer) QuerySessionClientDisplay Uses

func (wts *WTSServer) QuerySessionClientDisplay(sessionID uint) (WTSClientDisplay, error)

func (*WTSServer) QuerySessionClientHardwareId Uses

func (wts *WTSServer) QuerySessionClientHardwareId(sessionID uint) (uint32, error)

func (*WTSServer) QuerySessionClientInfo Uses

func (wts *WTSServer) QuerySessionClientInfo(sessionID uint) (WTSClientInfo, error)

func (*WTSServer) QuerySessionClientName Uses

func (wts *WTSServer) QuerySessionClientName(sessionID uint) (string, error)

func (*WTSServer) QuerySessionClientProductId Uses

func (wts *WTSServer) QuerySessionClientProductId(sessionID uint) (uint16, error)

func (*WTSServer) QuerySessionClientProtocolType Uses

func (wts *WTSServer) QuerySessionClientProtocolType(sessionID uint) (WTSClientProtocolType, error)

func (*WTSServer) QuerySessionConnectState Uses

func (wts *WTSServer) QuerySessionConnectState(sessionID uint) (WTSConnectState, error)

func (*WTSServer) QuerySessionDomainName Uses

func (wts *WTSServer) QuerySessionDomainName(sessionID uint) (string, error)

func (*WTSServer) QuerySessionID Uses

func (wts *WTSServer) QuerySessionID(sessionID uint) (uint, error)

func (*WTSServer) QuerySessionInitialProgram Uses

func (wts *WTSServer) QuerySessionInitialProgram(sessionID uint) (string, error)

func (*WTSServer) QuerySessionIsRemoteSession Uses

func (wts *WTSServer) QuerySessionIsRemoteSession(sessionID uint) (bool, error)

func (*WTSServer) QuerySessionSesionInfo Uses

func (wts *WTSServer) QuerySessionSesionInfo(sessionID uint) (WTSInfo, error)

func (*WTSServer) QuerySessionUserName Uses

func (wts *WTSServer) QuerySessionUserName(sessionID uint) (string, error)

func (*WTSServer) QuerySessionWinStationName Uses

func (wts *WTSServer) QuerySessionWinStationName(sessionID uint) (string, error)

func (*WTSServer) QuerySessionWorkingDirectory Uses

func (wts *WTSServer) QuerySessionWorkingDirectory(sessionID uint) (string, error)

func (*WTSServer) QueryUserToken Uses

func (wts *WTSServer) QueryUserToken(sessionID uint) (*Token, error)

type WTSSessionInfo Uses

type WTSSessionInfo struct {
    SessionID      uint
    WinStationName string
    State          WTSConnectState
}

WTSSessionInfo - go version of WTS_SESSION_INFO structure

type WellKnownSecurityIDType Uses

type WellKnownSecurityIDType int32
const (
    WellKnownSecurityIDLocalSystem    WellKnownSecurityIDType = wrappers.WinLocalSystemSid
    WellKnownSecurityIDLocalService   WellKnownSecurityIDType = wrappers.WinLocalServiceSid
    WellKnownSecurityIDNetworkService WellKnownSecurityIDType = wrappers.WinNetworkServiceSid
)

type WindowsError Uses

type WindowsError struct {
    // contains filtered or unexported fields
}

func NewWindowsError Uses

func NewWindowsError(functionName string, innerError error) *WindowsError

func (*WindowsError) Error Uses

func (self *WindowsError) Error() string

func (*WindowsError) FunctionName Uses

func (self *WindowsError) FunctionName() string

func (*WindowsError) InnerError Uses

func (self *WindowsError) InnerError() error

Directories

PathSynopsis
wrappers

Package gowin32 imports 11 packages (graph) and is imported by 1 packages. Updated 2019-07-27. Refresh now. Tools for package owners.