summaryrefslogtreecommitdiffstats
path: root/vendor/golang.org/x/sys/windows
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/golang.org/x/sys/windows')
-rw-r--r--vendor/golang.org/x/sys/windows/asm_windows_amd64.s2
-rw-r--r--vendor/golang.org/x/sys/windows/security_windows.go4
-rw-r--r--vendor/golang.org/x/sys/windows/service.go1
-rw-r--r--vendor/golang.org/x/sys/windows/types_windows.go32
-rw-r--r--vendor/golang.org/x/sys/windows/zsyscall_windows.go15
5 files changed, 45 insertions, 9 deletions
diff --git a/vendor/golang.org/x/sys/windows/asm_windows_amd64.s b/vendor/golang.org/x/sys/windows/asm_windows_amd64.s
index 4d025ab55..5bfdf7974 100644
--- a/vendor/golang.org/x/sys/windows/asm_windows_amd64.s
+++ b/vendor/golang.org/x/sys/windows/asm_windows_amd64.s
@@ -9,5 +9,5 @@
TEXT ·getprocaddress(SB), 7, $0-32
JMP syscall·getprocaddress(SB)
-TEXT ·loadlibrary(SB), 7, $0-8
+TEXT ·loadlibrary(SB), 7, $0-24
JMP syscall·loadlibrary(SB)
diff --git a/vendor/golang.org/x/sys/windows/security_windows.go b/vendor/golang.org/x/sys/windows/security_windows.go
index f1ec5dc4e..4f17a3331 100644
--- a/vendor/golang.org/x/sys/windows/security_windows.go
+++ b/vendor/golang.org/x/sys/windows/security_windows.go
@@ -296,6 +296,7 @@ const (
TOKEN_ADJUST_PRIVILEGES
TOKEN_ADJUST_GROUPS
TOKEN_ADJUST_DEFAULT
+ TOKEN_ADJUST_SESSIONID
TOKEN_ALL_ACCESS = STANDARD_RIGHTS_REQUIRED |
TOKEN_ASSIGN_PRIMARY |
@@ -305,7 +306,8 @@ const (
TOKEN_QUERY_SOURCE |
TOKEN_ADJUST_PRIVILEGES |
TOKEN_ADJUST_GROUPS |
- TOKEN_ADJUST_DEFAULT
+ TOKEN_ADJUST_DEFAULT |
+ TOKEN_ADJUST_SESSIONID
TOKEN_READ = STANDARD_RIGHTS_READ | TOKEN_QUERY
TOKEN_WRITE = STANDARD_RIGHTS_WRITE |
TOKEN_ADJUST_PRIVILEGES |
diff --git a/vendor/golang.org/x/sys/windows/service.go b/vendor/golang.org/x/sys/windows/service.go
index a500dd7df..24aa90bbb 100644
--- a/vendor/golang.org/x/sys/windows/service.go
+++ b/vendor/golang.org/x/sys/windows/service.go
@@ -162,3 +162,4 @@ type ENUM_SERVICE_STATUS_PROCESS struct {
//sys ChangeServiceConfig2(service Handle, infoLevel uint32, info *byte) (err error) = advapi32.ChangeServiceConfig2W
//sys QueryServiceConfig2(service Handle, infoLevel uint32, buff *byte, buffSize uint32, bytesNeeded *uint32) (err error) = advapi32.QueryServiceConfig2W
//sys EnumServicesStatusEx(mgr Handle, infoLevel uint32, serviceType uint32, serviceState uint32, services *byte, bufSize uint32, bytesNeeded *uint32, servicesReturned *uint32, resumeHandle *uint32, groupName *uint16) (err error) = advapi32.EnumServicesStatusExW
+//sys QueryServiceStatusEx(service Handle, infoLevel uint32, buff *byte, buffSize uint32, bytesNeeded *uint32) (err error) = advapi32.QueryServiceStatusEx
diff --git a/vendor/golang.org/x/sys/windows/types_windows.go b/vendor/golang.org/x/sys/windows/types_windows.go
index 52c2037b6..b4e424788 100644
--- a/vendor/golang.org/x/sys/windows/types_windows.go
+++ b/vendor/golang.org/x/sys/windows/types_windows.go
@@ -312,6 +312,14 @@ var (
OID_SGC_NETSCAPE = []byte("2.16.840.1.113730.4.1\x00")
)
+// Pointer represents a pointer to an arbitrary Windows type.
+//
+// Pointer-typed fields may point to one of many different types. It's
+// up to the caller to provide a pointer to the appropriate type, cast
+// to Pointer. The caller must obey the unsafe.Pointer rules while
+// doing so.
+type Pointer *struct{}
+
// Invented values to support what package os expects.
type Timeval struct {
Sec int32
@@ -880,11 +888,15 @@ type MibIfRow struct {
Descr [MAXLEN_IFDESCR]byte
}
+type CertInfo struct {
+ // Not implemented
+}
+
type CertContext struct {
EncodingType uint32
EncodedCert *byte
Length uint32
- CertInfo uintptr
+ CertInfo *CertInfo
Store Handle
}
@@ -899,12 +911,16 @@ type CertChainContext struct {
RevocationFreshnessTime uint32
}
+type CertTrustListInfo struct {
+ // Not implemented
+}
+
type CertSimpleChain struct {
Size uint32
TrustStatus CertTrustStatus
NumElements uint32
Elements **CertChainElement
- TrustListInfo uintptr
+ TrustListInfo *CertTrustListInfo
HasRevocationFreshnessTime uint32
RevocationFreshnessTime uint32
}
@@ -919,14 +935,18 @@ type CertChainElement struct {
ExtendedErrorInfo *uint16
}
+type CertRevocationCrlInfo struct {
+ // Not implemented
+}
+
type CertRevocationInfo struct {
Size uint32
RevocationResult uint32
RevocationOid *byte
- OidSpecificInfo uintptr
+ OidSpecificInfo Pointer
HasFreshnessTime uint32
FreshnessTime uint32
- CrlInfo uintptr // *CertRevocationCrlInfo
+ CrlInfo *CertRevocationCrlInfo
}
type CertTrustStatus struct {
@@ -957,7 +977,7 @@ type CertChainPara struct {
type CertChainPolicyPara struct {
Size uint32
Flags uint32
- ExtraPolicyPara uintptr
+ ExtraPolicyPara Pointer
}
type SSLExtraCertChainPolicyPara struct {
@@ -972,7 +992,7 @@ type CertChainPolicyStatus struct {
Error uint32
ChainIndex uint32
ElementIndex uint32
- ExtraPolicyStatus uintptr
+ ExtraPolicyStatus Pointer
}
const (
diff --git a/vendor/golang.org/x/sys/windows/zsyscall_windows.go b/vendor/golang.org/x/sys/windows/zsyscall_windows.go
index c7b3b15ea..fc56aec03 100644
--- a/vendor/golang.org/x/sys/windows/zsyscall_windows.go
+++ b/vendor/golang.org/x/sys/windows/zsyscall_windows.go
@@ -1,4 +1,4 @@
-// MACHINE GENERATED BY 'go generate' COMMAND; DO NOT EDIT
+// Code generated by 'go generate'; DO NOT EDIT.
package windows
@@ -65,6 +65,7 @@ var (
procChangeServiceConfig2W = modadvapi32.NewProc("ChangeServiceConfig2W")
procQueryServiceConfig2W = modadvapi32.NewProc("QueryServiceConfig2W")
procEnumServicesStatusExW = modadvapi32.NewProc("EnumServicesStatusExW")
+ procQueryServiceStatusEx = modadvapi32.NewProc("QueryServiceStatusEx")
procGetLastError = modkernel32.NewProc("GetLastError")
procLoadLibraryW = modkernel32.NewProc("LoadLibraryW")
procLoadLibraryExW = modkernel32.NewProc("LoadLibraryExW")
@@ -472,6 +473,18 @@ func EnumServicesStatusEx(mgr Handle, infoLevel uint32, serviceType uint32, serv
return
}
+func QueryServiceStatusEx(service Handle, infoLevel uint32, buff *byte, buffSize uint32, bytesNeeded *uint32) (err error) {
+ r1, _, e1 := syscall.Syscall6(procQueryServiceStatusEx.Addr(), 5, uintptr(service), uintptr(infoLevel), uintptr(unsafe.Pointer(buff)), uintptr(buffSize), uintptr(unsafe.Pointer(bytesNeeded)), 0)
+ if r1 == 0 {
+ if e1 != 0 {
+ err = errnoErr(e1)
+ } else {
+ err = syscall.EINVAL
+ }
+ }
+ return
+}
+
func GetLastError() (lasterr error) {
r0, _, _ := syscall.Syscall(procGetLastError.Addr(), 0, 0, 0, 0)
if r0 != 0 {