windows_systemcalls

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Rendered for windows/amd64

Overview

Package windows_systemcalls provides Windows-specific system-call wrappers and type definitions used by GoScans modules (SMB, shell32 property store, NetAPI32, MPR).

Index

Constants

View Source
const GPS_DEFAULT = 0

Variables

View Source
var IPropertyStoreGuid = ole.NewGUID("886d8eeb-8cf2-4446-8d02-cdba1dbdcf99")

Functions

func NetDfsGetInfo

func NetDfsGetInfo(DfsEntryPath *uint16, ServerName *uint16, ShareName *uint16, Level uint32, Buffer **byte) (neterr error)

func NetShareEnum

func NetShareEnum(serverName *uint16, level uint32, buf **byte, prefMaxLen uint32, entriesRead *uint32, totalEntries *uint32, resumeHandle *uint32) (neterr error)

func NetShareGetInfo

func NetShareGetInfo(serverName *uint16, netName *uint16, level uint32, buf **byte) (neterr error)

func SHGetPropertyStoreFromParsingName

func SHGetPropertyStoreFromParsingName(pszPath *uint16, pbc *IBindCtx, flags uint32, riid *ole.GUID, obj interface{}) (err error)

func WNetAddConnection2

func WNetAddConnection2(netResource *Netresource, password *uint16, username *uint16, flags uint32) (neterr error)

func WNetCancelConnection2

func WNetCancelConnection2(name *uint16, flags uint32, force bool) (neterr error)

Types

type DFS_INFO_3

type DFS_INFO_3 struct {
	EntryPath        LPWSTR
	Comment          LPWSTR
	State            DWORD
	NumberOfStorages DWORD
	DfsStorageInfo   *DFS_STORAGE_INFO
}

type DFS_STORAGE_INFO

type DFS_STORAGE_INFO struct {
	State      ULONG
	ServerName LPWSTR
	ShareName  LPWSTR
}

type DWORD

type DWORD uint32 // go, medium, github w32, outside windows: uint32

type IBindCtx

type IBindCtx struct {
	ole.IUnknown
}

type IPropertyStore

type IPropertyStore struct {
	ole.IUnknown
}

func (*IPropertyStore) Commit

func (v *IPropertyStore) Commit() (err error)

func (*IPropertyStore) GetAt

func (v *IPropertyStore) GetAt(iProp uint32, pkey *PROPERTYKEY) error

func (*IPropertyStore) GetCount

func (v *IPropertyStore) GetCount(count *uint32) (err error)

func (*IPropertyStore) GetValue

func (v *IPropertyStore) GetValue(key *PROPERTYKEY, pv *PROPVARIANT) (err error)

func (*IPropertyStore) SetValue

func (v *IPropertyStore) SetValue() (err error)

func (*IPropertyStore) VTable

func (v *IPropertyStore) VTable() *IPropertyStoreVtbl

type IPropertyStoreVtbl

type IPropertyStoreVtbl struct {
	ole.IUnknownVtbl
	GetCount uintptr
	GetAt    uintptr
	GetValue uintptr
	SetValue uintptr
	Commit   uintptr
}

type LMSTR

type LMSTR *uint16 // Func: *uint16 NetshareAdd, Struct: go *uint16 (share_info_2) strings have to be converted to pointer and pointer have to be converted back to strings

type LPWSTR

type LPWSTR *uint16 // Struct go *uint16 StartupInfo(w)

type Netresource

type Netresource struct {
	Scope       DWORD
	Type        DWORD
	DisplayType DWORD
	Usage       DWORD
	LocalName   LPWSTR
	RemoteName  LPWSTR
	Comment     LPWSTR
	Provider    LPWSTR
}

type PROPERTYKEY

type PROPERTYKEY struct {
	ole.GUID
	PID uint32
}

type PROPVARIANT

type PROPVARIANT struct {
	ole.VARIANT
}

func (*PROPVARIANT) ValueExt

func (pv *PROPVARIANT) ValueExt() (interface{}, error)

ValueExt converts the value of the propvariant to a Go value. The conversion is not exhaustive and can be extended.

type SHARE_INFO_1

type SHARE_INFO_1 struct {
	Netname LMSTR
	Type    DWORD
	Remark  LMSTR
}

type SHARE_INFO_2

type SHARE_INFO_2 struct {
	Netname     *uint16
	Type        uint32
	Remark      *uint16
	Permissions uint32
	MaxUses     uint32
	CurrentUses uint32
	Path        *uint16
	Passwd      *uint16
}

type SHARE_INFO_1005

type SHARE_INFO_1005 struct {
	Flags DWORD
}

type ULONG

type ULONG uint32

Jump to

Keyboard shortcuts

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