mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-17 20:00:23 +00:00
rebase: Bump golang.org/x/net from 0.7.0 to 0.8.0
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.7.0 to 0.8.0. - [Release notes](https://github.com/golang/net/releases) - [Commits](https://github.com/golang/net/compare/v0.7.0...v0.8.0) --- updated-dependencies: - dependency-name: golang.org/x/net dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
parent
da57f929f9
commit
e3ae53f11d
8
go.mod
8
go.mod
@ -28,8 +28,8 @@ require (
|
||||
github.com/prometheus/client_golang v1.14.0
|
||||
github.com/stretchr/testify v1.8.1
|
||||
golang.org/x/crypto v0.6.0
|
||||
golang.org/x/net v0.7.0
|
||||
golang.org/x/sys v0.5.0
|
||||
golang.org/x/net v0.8.0
|
||||
golang.org/x/sys v0.6.0
|
||||
google.golang.org/grpc v1.53.0
|
||||
google.golang.org/protobuf v1.28.1
|
||||
k8s.io/api v0.26.1
|
||||
@ -138,8 +138,8 @@ require (
|
||||
go.uber.org/multierr v1.8.0 // indirect
|
||||
go.uber.org/zap v1.24.0 // indirect
|
||||
golang.org/x/oauth2 v0.4.0 // indirect
|
||||
golang.org/x/term v0.5.0 // indirect
|
||||
golang.org/x/text v0.7.0 // indirect
|
||||
golang.org/x/term v0.6.0 // indirect
|
||||
golang.org/x/text v0.8.0 // indirect
|
||||
golang.org/x/time v0.3.0 // indirect
|
||||
gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect
|
||||
google.golang.org/appengine v1.6.7 // indirect
|
||||
|
16
go.sum
16
go.sum
@ -1220,8 +1220,8 @@ golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su
|
||||
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco=
|
||||
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE=
|
||||
golang.org/x/net v0.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g=
|
||||
golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
|
||||
golang.org/x/net v0.8.0 h1:Zrh2ngAOFYneWTAIAPethzeaQLuHwhuBkuV6ZiRnUaQ=
|
||||
golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc=
|
||||
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
|
||||
golang.org/x/oauth2 v0.0.0-20181203162652-d668ce993890/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
|
||||
golang.org/x/oauth2 v0.0.0-20190130055435-99b60b757ec1/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
@ -1344,15 +1344,15 @@ golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBc
|
||||
golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU=
|
||||
golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.6.0 h1:MVltZSvRTcU2ljQOhs94SXPftV6DCNnZViHeQps87pQ=
|
||||
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
|
||||
golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
|
||||
golang.org/x/term v0.3.0/go.mod h1:q750SLmJuPmVoN1blW3UFBPREJfb1KmY3vwxfr+nFDA=
|
||||
golang.org/x/term v0.5.0 h1:n2a8QNdAb0sZNpU9R1ALUXBbY+w51fCQDN+7EdxNBsY=
|
||||
golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k=
|
||||
golang.org/x/term v0.6.0 h1:clScbb1cHjoCkyRbWwBEUZ5H/tIFu5TAXIqaZD0Gcjw=
|
||||
golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U=
|
||||
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
@ -1365,8 +1365,8 @@ golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
|
||||
golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
|
||||
golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
|
||||
golang.org/x/text v0.7.0 h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo=
|
||||
golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
|
||||
golang.org/x/text v0.8.0 h1:57P1ETyNKtuIjB4SRd15iJxuhj8Gc416Y78H3qgMh68=
|
||||
golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8=
|
||||
golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
|
15
vendor/golang.org/x/net/html/doc.go
generated
vendored
15
vendor/golang.org/x/net/html/doc.go
generated
vendored
@ -92,6 +92,21 @@ example, to process each anchor node in depth-first order:
|
||||
The relevant specifications include:
|
||||
https://html.spec.whatwg.org/multipage/syntax.html and
|
||||
https://html.spec.whatwg.org/multipage/syntax.html#tokenization
|
||||
|
||||
# Security Considerations
|
||||
|
||||
Care should be taken when parsing and interpreting HTML, whether full documents
|
||||
or fragments, within the framework of the HTML specification, especially with
|
||||
regard to untrusted inputs.
|
||||
|
||||
This package provides both a tokenizer and a parser. Only the parser constructs
|
||||
a DOM according to the HTML specification, resolving malformed and misplaced
|
||||
tags where appropriate. The tokenizer simply tokenizes the HTML presented to it,
|
||||
and as such does not resolve issues that may exist in the processed HTML,
|
||||
producing a literal interpretation of the input.
|
||||
|
||||
If your use case requires semantically well-formed HTML, as defined by the
|
||||
WHATWG specifiction, the parser should be used rather than the tokenizer.
|
||||
*/
|
||||
package html // import "golang.org/x/net/html"
|
||||
|
||||
|
81
vendor/golang.org/x/net/html/escape.go
generated
vendored
81
vendor/golang.org/x/net/html/escape.go
generated
vendored
@ -193,6 +193,87 @@ func lower(b []byte) []byte {
|
||||
return b
|
||||
}
|
||||
|
||||
// escapeComment is like func escape but escapes its input bytes less often.
|
||||
// Per https://github.com/golang/go/issues/58246 some HTML comments are (1)
|
||||
// meaningful and (2) contain angle brackets that we'd like to avoid escaping
|
||||
// unless we have to.
|
||||
//
|
||||
// "We have to" includes the '&' byte, since that introduces other escapes.
|
||||
//
|
||||
// It also includes those bytes (not including EOF) that would otherwise end
|
||||
// the comment. Per the summary table at the bottom of comment_test.go, this is
|
||||
// the '>' byte that, per above, we'd like to avoid escaping unless we have to.
|
||||
//
|
||||
// Studying the summary table (and T actions in its '>' column) closely, we
|
||||
// only need to escape in states 43, 44, 49, 51 and 52. State 43 is at the
|
||||
// start of the comment data. State 52 is after a '!'. The other three states
|
||||
// are after a '-'.
|
||||
//
|
||||
// Our algorithm is thus to escape every '&' and to escape '>' if and only if:
|
||||
// - The '>' is after a '!' or '-' (in the unescaped data) or
|
||||
// - The '>' is at the start of the comment data (after the opening "<!--").
|
||||
func escapeComment(w writer, s string) error {
|
||||
// When modifying this function, consider manually increasing the
|
||||
// maxSuffixLen constant in func TestComments, from 6 to e.g. 9 or more.
|
||||
// That increase should only be temporary, not committed, as it
|
||||
// exponentially affects the test running time.
|
||||
|
||||
if len(s) == 0 {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Loop:
|
||||
// - Grow j such that s[i:j] does not need escaping.
|
||||
// - If s[j] does need escaping, output s[i:j] and an escaped s[j],
|
||||
// resetting i and j to point past that s[j] byte.
|
||||
i := 0
|
||||
for j := 0; j < len(s); j++ {
|
||||
escaped := ""
|
||||
switch s[j] {
|
||||
case '&':
|
||||
escaped = "&"
|
||||
|
||||
case '>':
|
||||
if j > 0 {
|
||||
if prev := s[j-1]; (prev != '!') && (prev != '-') {
|
||||
continue
|
||||
}
|
||||
}
|
||||
escaped = ">"
|
||||
|
||||
default:
|
||||
continue
|
||||
}
|
||||
|
||||
if i < j {
|
||||
if _, err := w.WriteString(s[i:j]); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
if _, err := w.WriteString(escaped); err != nil {
|
||||
return err
|
||||
}
|
||||
i = j + 1
|
||||
}
|
||||
|
||||
if i < len(s) {
|
||||
if _, err := w.WriteString(s[i:]); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// escapeCommentString is to EscapeString as escapeComment is to escape.
|
||||
func escapeCommentString(s string) string {
|
||||
if strings.IndexAny(s, "&>") == -1 {
|
||||
return s
|
||||
}
|
||||
var buf bytes.Buffer
|
||||
escapeComment(&buf, s)
|
||||
return buf.String()
|
||||
}
|
||||
|
||||
const escapedChars = "&'<>\"\r"
|
||||
|
||||
func escape(w writer, s string) error {
|
||||
|
2
vendor/golang.org/x/net/html/render.go
generated
vendored
2
vendor/golang.org/x/net/html/render.go
generated
vendored
@ -85,7 +85,7 @@ func render1(w writer, n *Node) error {
|
||||
if _, err := w.WriteString("<!--"); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := escape(w, n.Data); err != nil {
|
||||
if err := escapeComment(w, n.Data); err != nil {
|
||||
return err
|
||||
}
|
||||
if _, err := w.WriteString("-->"); err != nil {
|
||||
|
10
vendor/golang.org/x/net/html/token.go
generated
vendored
10
vendor/golang.org/x/net/html/token.go
generated
vendored
@ -110,7 +110,7 @@ func (t Token) String() string {
|
||||
case SelfClosingTagToken:
|
||||
return "<" + t.tagString() + "/>"
|
||||
case CommentToken:
|
||||
return "<!--" + EscapeString(t.Data) + "-->"
|
||||
return "<!--" + escapeCommentString(t.Data) + "-->"
|
||||
case DoctypeToken:
|
||||
return "<!DOCTYPE " + EscapeString(t.Data) + ">"
|
||||
}
|
||||
@ -598,10 +598,10 @@ scriptDataDoubleEscapeEnd:
|
||||
// readComment reads the next comment token starting with "<!--". The opening
|
||||
// "<!--" has already been consumed.
|
||||
func (z *Tokenizer) readComment() {
|
||||
// When modifying this function, consider manually increasing the suffixLen
|
||||
// constant in func TestComments, from 6 to e.g. 9 or more. That increase
|
||||
// should only be temporary, not committed, as it exponentially affects the
|
||||
// test running time.
|
||||
// When modifying this function, consider manually increasing the
|
||||
// maxSuffixLen constant in func TestComments, from 6 to e.g. 9 or more.
|
||||
// That increase should only be temporary, not committed, as it
|
||||
// exponentially affects the test running time.
|
||||
|
||||
z.data.start = z.raw.end
|
||||
defer func() {
|
||||
|
15
vendor/golang.org/x/sys/cpu/hwcap_linux.go
generated
vendored
15
vendor/golang.org/x/sys/cpu/hwcap_linux.go
generated
vendored
@ -24,6 +24,21 @@ var hwCap uint
|
||||
var hwCap2 uint
|
||||
|
||||
func readHWCAP() error {
|
||||
// For Go 1.21+, get auxv from the Go runtime.
|
||||
if a := getAuxv(); len(a) > 0 {
|
||||
for len(a) >= 2 {
|
||||
tag, val := a[0], uint(a[1])
|
||||
a = a[2:]
|
||||
switch tag {
|
||||
case _AT_HWCAP:
|
||||
hwCap = val
|
||||
case _AT_HWCAP2:
|
||||
hwCap2 = val
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
buf, err := ioutil.ReadFile(procAuxv)
|
||||
if err != nil {
|
||||
// e.g. on android /proc/self/auxv is not accessible, so silently
|
||||
|
16
vendor/golang.org/x/sys/cpu/runtime_auxv.go
generated
vendored
Normal file
16
vendor/golang.org/x/sys/cpu/runtime_auxv.go
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
// Copyright 2023 The Go Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
package cpu
|
||||
|
||||
// getAuxvFn is non-nil on Go 1.21+ (via runtime_auxv_go121.go init)
|
||||
// on platforms that use auxv.
|
||||
var getAuxvFn func() []uintptr
|
||||
|
||||
func getAuxv() []uintptr {
|
||||
if getAuxvFn == nil {
|
||||
return nil
|
||||
}
|
||||
return getAuxvFn()
|
||||
}
|
19
vendor/golang.org/x/sys/cpu/runtime_auxv_go121.go
generated
vendored
Normal file
19
vendor/golang.org/x/sys/cpu/runtime_auxv_go121.go
generated
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
// Copyright 2023 The Go Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
//go:build go1.21
|
||||
// +build go1.21
|
||||
|
||||
package cpu
|
||||
|
||||
import (
|
||||
_ "unsafe" // for linkname
|
||||
)
|
||||
|
||||
//go:linkname runtime_getAuxv runtime.getAuxv
|
||||
func runtime_getAuxv() []uintptr
|
||||
|
||||
func init() {
|
||||
getAuxvFn = runtime_getAuxv
|
||||
}
|
17
vendor/golang.org/x/sys/unix/ioctl.go
generated
vendored
17
vendor/golang.org/x/sys/unix/ioctl.go
generated
vendored
@ -8,7 +8,6 @@
|
||||
package unix
|
||||
|
||||
import (
|
||||
"runtime"
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
@ -27,7 +26,7 @@ func IoctlSetInt(fd int, req uint, value int) error {
|
||||
// passing the integer value directly.
|
||||
func IoctlSetPointerInt(fd int, req uint, value int) error {
|
||||
v := int32(value)
|
||||
return ioctl(fd, req, uintptr(unsafe.Pointer(&v)))
|
||||
return ioctlPtr(fd, req, unsafe.Pointer(&v))
|
||||
}
|
||||
|
||||
// IoctlSetWinsize performs an ioctl on fd with a *Winsize argument.
|
||||
@ -36,9 +35,7 @@ func IoctlSetPointerInt(fd int, req uint, value int) error {
|
||||
func IoctlSetWinsize(fd int, req uint, value *Winsize) error {
|
||||
// TODO: if we get the chance, remove the req parameter and
|
||||
// hardcode TIOCSWINSZ.
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(value)))
|
||||
runtime.KeepAlive(value)
|
||||
return err
|
||||
return ioctlPtr(fd, req, unsafe.Pointer(value))
|
||||
}
|
||||
|
||||
// IoctlSetTermios performs an ioctl on fd with a *Termios.
|
||||
@ -46,9 +43,7 @@ func IoctlSetWinsize(fd int, req uint, value *Winsize) error {
|
||||
// The req value will usually be TCSETA or TIOCSETA.
|
||||
func IoctlSetTermios(fd int, req uint, value *Termios) error {
|
||||
// TODO: if we get the chance, remove the req parameter.
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(value)))
|
||||
runtime.KeepAlive(value)
|
||||
return err
|
||||
return ioctlPtr(fd, req, unsafe.Pointer(value))
|
||||
}
|
||||
|
||||
// IoctlGetInt performs an ioctl operation which gets an integer value
|
||||
@ -58,18 +53,18 @@ func IoctlSetTermios(fd int, req uint, value *Termios) error {
|
||||
// for those, IoctlRetInt should be used instead of this function.
|
||||
func IoctlGetInt(fd int, req uint) (int, error) {
|
||||
var value int
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return value, err
|
||||
}
|
||||
|
||||
func IoctlGetWinsize(fd int, req uint) (*Winsize, error) {
|
||||
var value Winsize
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return &value, err
|
||||
}
|
||||
|
||||
func IoctlGetTermios(fd int, req uint) (*Termios, error) {
|
||||
var value Termios
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return &value, err
|
||||
}
|
||||
|
8
vendor/golang.org/x/sys/unix/ioctl_zos.go
generated
vendored
8
vendor/golang.org/x/sys/unix/ioctl_zos.go
generated
vendored
@ -27,9 +27,7 @@ func IoctlSetInt(fd int, req uint, value int) error {
|
||||
func IoctlSetWinsize(fd int, req uint, value *Winsize) error {
|
||||
// TODO: if we get the chance, remove the req parameter and
|
||||
// hardcode TIOCSWINSZ.
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(value)))
|
||||
runtime.KeepAlive(value)
|
||||
return err
|
||||
return ioctlPtr(fd, req, unsafe.Pointer(value))
|
||||
}
|
||||
|
||||
// IoctlSetTermios performs an ioctl on fd with a *Termios.
|
||||
@ -51,13 +49,13 @@ func IoctlSetTermios(fd int, req uint, value *Termios) error {
|
||||
// for those, IoctlRetInt should be used instead of this function.
|
||||
func IoctlGetInt(fd int, req uint) (int, error) {
|
||||
var value int
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return value, err
|
||||
}
|
||||
|
||||
func IoctlGetWinsize(fd int, req uint) (*Winsize, error) {
|
||||
var value Winsize
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return &value, err
|
||||
}
|
||||
|
||||
|
6
vendor/golang.org/x/sys/unix/ptrace_darwin.go
generated
vendored
6
vendor/golang.org/x/sys/unix/ptrace_darwin.go
generated
vendored
@ -7,6 +7,12 @@
|
||||
|
||||
package unix
|
||||
|
||||
import "unsafe"
|
||||
|
||||
func ptrace(request int, pid int, addr uintptr, data uintptr) error {
|
||||
return ptrace1(request, pid, addr, data)
|
||||
}
|
||||
|
||||
func ptracePtr(request int, pid int, addr uintptr, data unsafe.Pointer) error {
|
||||
return ptrace1Ptr(request, pid, addr, data)
|
||||
}
|
||||
|
6
vendor/golang.org/x/sys/unix/ptrace_ios.go
generated
vendored
6
vendor/golang.org/x/sys/unix/ptrace_ios.go
generated
vendored
@ -7,6 +7,12 @@
|
||||
|
||||
package unix
|
||||
|
||||
import "unsafe"
|
||||
|
||||
func ptrace(request int, pid int, addr uintptr, data uintptr) (err error) {
|
||||
return ENOTSUP
|
||||
}
|
||||
|
||||
func ptracePtr(request int, pid int, addr uintptr, data unsafe.Pointer) (err error) {
|
||||
return ENOTSUP
|
||||
}
|
||||
|
5
vendor/golang.org/x/sys/unix/syscall_aix.go
generated
vendored
5
vendor/golang.org/x/sys/unix/syscall_aix.go
generated
vendored
@ -292,9 +292,7 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) {
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
bytes := (*[len(pp.Path)]byte)(unsafe.Pointer(&pp.Path[0]))[0:n]
|
||||
sa.Name = string(bytes)
|
||||
sa.Name = string(unsafe.Slice((*byte)(unsafe.Pointer(&pp.Path[0])), n))
|
||||
return sa, nil
|
||||
|
||||
case AF_INET:
|
||||
@ -411,6 +409,7 @@ func (w WaitStatus) CoreDump() bool { return w&0x80 == 0x80 }
|
||||
func (w WaitStatus) TrapCause() int { return -1 }
|
||||
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error)
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = ioctl
|
||||
|
||||
// fcntl must never be called with cmd=F_DUP2FD because it doesn't work on AIX
|
||||
// There is no way to create a custom fcntl and to keep //sys fcntl easily,
|
||||
|
3
vendor/golang.org/x/sys/unix/syscall_bsd.go
generated
vendored
3
vendor/golang.org/x/sys/unix/syscall_bsd.go
generated
vendored
@ -245,8 +245,7 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) {
|
||||
break
|
||||
}
|
||||
}
|
||||
bytes := (*[len(pp.Path)]byte)(unsafe.Pointer(&pp.Path[0]))[0:n]
|
||||
sa.Name = string(bytes)
|
||||
sa.Name = string(unsafe.Slice((*byte)(unsafe.Pointer(&pp.Path[0])), n))
|
||||
return sa, nil
|
||||
|
||||
case AF_INET:
|
||||
|
12
vendor/golang.org/x/sys/unix/syscall_darwin.go
generated
vendored
12
vendor/golang.org/x/sys/unix/syscall_darwin.go
generated
vendored
@ -14,7 +14,6 @@ package unix
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"runtime"
|
||||
"syscall"
|
||||
"unsafe"
|
||||
)
|
||||
@ -376,11 +375,10 @@ func Flistxattr(fd int, dest []byte) (sz int, err error) {
|
||||
func Kill(pid int, signum syscall.Signal) (err error) { return kill(pid, int(signum), 1) }
|
||||
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error)
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = SYS_IOCTL
|
||||
|
||||
func IoctlCtlInfo(fd int, ctlInfo *CtlInfo) error {
|
||||
err := ioctl(fd, CTLIOCGINFO, uintptr(unsafe.Pointer(ctlInfo)))
|
||||
runtime.KeepAlive(ctlInfo)
|
||||
return err
|
||||
return ioctlPtr(fd, CTLIOCGINFO, unsafe.Pointer(ctlInfo))
|
||||
}
|
||||
|
||||
// IfreqMTU is struct ifreq used to get or set a network device's MTU.
|
||||
@ -394,16 +392,14 @@ type IfreqMTU struct {
|
||||
func IoctlGetIfreqMTU(fd int, ifname string) (*IfreqMTU, error) {
|
||||
var ifreq IfreqMTU
|
||||
copy(ifreq.Name[:], ifname)
|
||||
err := ioctl(fd, SIOCGIFMTU, uintptr(unsafe.Pointer(&ifreq)))
|
||||
err := ioctlPtr(fd, SIOCGIFMTU, unsafe.Pointer(&ifreq))
|
||||
return &ifreq, err
|
||||
}
|
||||
|
||||
// IoctlSetIfreqMTU performs the SIOCSIFMTU ioctl operation on fd to set the MTU
|
||||
// of the network device specified by ifreq.Name.
|
||||
func IoctlSetIfreqMTU(fd int, ifreq *IfreqMTU) error {
|
||||
err := ioctl(fd, SIOCSIFMTU, uintptr(unsafe.Pointer(ifreq)))
|
||||
runtime.KeepAlive(ifreq)
|
||||
return err
|
||||
return ioctlPtr(fd, SIOCSIFMTU, unsafe.Pointer(ifreq))
|
||||
}
|
||||
|
||||
//sys sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) = SYS_SYSCTL
|
||||
|
1
vendor/golang.org/x/sys/unix/syscall_darwin_amd64.go
generated
vendored
1
vendor/golang.org/x/sys/unix/syscall_darwin_amd64.go
generated
vendored
@ -47,5 +47,6 @@ func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr,
|
||||
//sys getfsstat(buf unsafe.Pointer, size uintptr, flags int) (n int, err error) = SYS_GETFSSTAT64
|
||||
//sys Lstat(path string, stat *Stat_t) (err error) = SYS_LSTAT64
|
||||
//sys ptrace1(request int, pid int, addr uintptr, data uintptr) (err error) = SYS_ptrace
|
||||
//sys ptrace1Ptr(request int, pid int, addr unsafe.Pointer, data uintptr) (err error) = SYS_ptrace
|
||||
//sys Stat(path string, stat *Stat_t) (err error) = SYS_STAT64
|
||||
//sys Statfs(path string, stat *Statfs_t) (err error) = SYS_STATFS64
|
||||
|
1
vendor/golang.org/x/sys/unix/syscall_darwin_arm64.go
generated
vendored
1
vendor/golang.org/x/sys/unix/syscall_darwin_arm64.go
generated
vendored
@ -47,5 +47,6 @@ func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr,
|
||||
//sys getfsstat(buf unsafe.Pointer, size uintptr, flags int) (n int, err error) = SYS_GETFSSTAT
|
||||
//sys Lstat(path string, stat *Stat_t) (err error)
|
||||
//sys ptrace1(request int, pid int, addr uintptr, data uintptr) (err error) = SYS_ptrace
|
||||
//sys ptrace1Ptr(request int, pid int, addr unsafe.Pointer, data uintptr) (err error) = SYS_ptrace
|
||||
//sys Stat(path string, stat *Stat_t) (err error)
|
||||
//sys Statfs(path string, stat *Statfs_t) (err error)
|
||||
|
1
vendor/golang.org/x/sys/unix/syscall_dragonfly.go
generated
vendored
1
vendor/golang.org/x/sys/unix/syscall_dragonfly.go
generated
vendored
@ -172,6 +172,7 @@ func Getfsstat(buf []Statfs_t, flags int) (n int, err error) {
|
||||
}
|
||||
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error)
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = SYS_IOCTL
|
||||
|
||||
//sys sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) = SYS___SYSCTL
|
||||
|
||||
|
43
vendor/golang.org/x/sys/unix/syscall_freebsd.go
generated
vendored
43
vendor/golang.org/x/sys/unix/syscall_freebsd.go
generated
vendored
@ -161,7 +161,8 @@ func Getfsstat(buf []Statfs_t, flags int) (n int, err error) {
|
||||
return
|
||||
}
|
||||
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error)
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error) = SYS_IOCTL
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = SYS_IOCTL
|
||||
|
||||
//sys sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) = SYS___SYSCTL
|
||||
|
||||
@ -253,6 +254,7 @@ func Sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
}
|
||||
|
||||
//sys ptrace(request int, pid int, addr uintptr, data int) (err error)
|
||||
//sys ptracePtr(request int, pid int, addr unsafe.Pointer, data int) (err error) = SYS_PTRACE
|
||||
|
||||
func PtraceAttach(pid int) (err error) {
|
||||
return ptrace(PT_ATTACH, pid, 0, 0)
|
||||
@ -267,19 +269,36 @@ func PtraceDetach(pid int) (err error) {
|
||||
}
|
||||
|
||||
func PtraceGetFpRegs(pid int, fpregsout *FpReg) (err error) {
|
||||
return ptrace(PT_GETFPREGS, pid, uintptr(unsafe.Pointer(fpregsout)), 0)
|
||||
return ptracePtr(PT_GETFPREGS, pid, unsafe.Pointer(fpregsout), 0)
|
||||
}
|
||||
|
||||
func PtraceGetRegs(pid int, regsout *Reg) (err error) {
|
||||
return ptrace(PT_GETREGS, pid, uintptr(unsafe.Pointer(regsout)), 0)
|
||||
return ptracePtr(PT_GETREGS, pid, unsafe.Pointer(regsout), 0)
|
||||
}
|
||||
|
||||
func PtraceIO(req int, pid int, offs uintptr, out []byte, countin int) (count int, err error) {
|
||||
ioDesc := PtraceIoDesc{
|
||||
Op: int32(req),
|
||||
Offs: offs,
|
||||
}
|
||||
if countin > 0 {
|
||||
_ = out[:countin] // check bounds
|
||||
ioDesc.Addr = &out[0]
|
||||
} else if out != nil {
|
||||
ioDesc.Addr = (*byte)(unsafe.Pointer(&_zero))
|
||||
}
|
||||
ioDesc.SetLen(countin)
|
||||
|
||||
err = ptracePtr(PT_IO, pid, unsafe.Pointer(&ioDesc), 0)
|
||||
return int(ioDesc.Len), err
|
||||
}
|
||||
|
||||
func PtraceLwpEvents(pid int, enable int) (err error) {
|
||||
return ptrace(PT_LWP_EVENTS, pid, 0, enable)
|
||||
}
|
||||
|
||||
func PtraceLwpInfo(pid int, info uintptr) (err error) {
|
||||
return ptrace(PT_LWPINFO, pid, info, int(unsafe.Sizeof(PtraceLwpInfoStruct{})))
|
||||
func PtraceLwpInfo(pid int, info *PtraceLwpInfoStruct) (err error) {
|
||||
return ptracePtr(PT_LWPINFO, pid, unsafe.Pointer(info), int(unsafe.Sizeof(*info)))
|
||||
}
|
||||
|
||||
func PtracePeekData(pid int, addr uintptr, out []byte) (count int, err error) {
|
||||
@ -299,13 +318,25 @@ func PtracePokeText(pid int, addr uintptr, data []byte) (count int, err error) {
|
||||
}
|
||||
|
||||
func PtraceSetRegs(pid int, regs *Reg) (err error) {
|
||||
return ptrace(PT_SETREGS, pid, uintptr(unsafe.Pointer(regs)), 0)
|
||||
return ptracePtr(PT_SETREGS, pid, unsafe.Pointer(regs), 0)
|
||||
}
|
||||
|
||||
func PtraceSingleStep(pid int) (err error) {
|
||||
return ptrace(PT_STEP, pid, 1, 0)
|
||||
}
|
||||
|
||||
func Dup3(oldfd, newfd, flags int) error {
|
||||
if oldfd == newfd || flags&^O_CLOEXEC != 0 {
|
||||
return EINVAL
|
||||
}
|
||||
how := F_DUP2FD
|
||||
if flags&O_CLOEXEC != 0 {
|
||||
how = F_DUP2FD_CLOEXEC
|
||||
}
|
||||
_, err := fcntl(oldfd, how, newfd)
|
||||
return err
|
||||
}
|
||||
|
||||
/*
|
||||
* Exposed directly
|
||||
*/
|
||||
|
17
vendor/golang.org/x/sys/unix/syscall_freebsd_386.go
generated
vendored
17
vendor/golang.org/x/sys/unix/syscall_freebsd_386.go
generated
vendored
@ -42,6 +42,10 @@ func (cmsg *Cmsghdr) SetLen(length int) {
|
||||
cmsg.Len = uint32(length)
|
||||
}
|
||||
|
||||
func (d *PtraceIoDesc) SetLen(length int) {
|
||||
d.Len = uint32(length)
|
||||
}
|
||||
|
||||
func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) {
|
||||
var writtenOut uint64 = 0
|
||||
_, _, e1 := Syscall9(SYS_SENDFILE, uintptr(infd), uintptr(outfd), uintptr(*offset), uintptr((*offset)>>32), uintptr(count), 0, uintptr(unsafe.Pointer(&writtenOut)), 0, 0)
|
||||
@ -57,16 +61,5 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
|
||||
|
||||
func PtraceGetFsBase(pid int, fsbase *int64) (err error) {
|
||||
return ptrace(PT_GETFSBASE, pid, uintptr(unsafe.Pointer(fsbase)), 0)
|
||||
}
|
||||
|
||||
func PtraceIO(req int, pid int, offs uintptr, out []byte, countin int) (count int, err error) {
|
||||
ioDesc := PtraceIoDesc{
|
||||
Op: int32(req),
|
||||
Offs: offs,
|
||||
Addr: uintptr(unsafe.Pointer(&out[0])), // TODO(#58351): this is not safe.
|
||||
Len: uint32(countin),
|
||||
}
|
||||
err = ptrace(PT_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
|
||||
return int(ioDesc.Len), err
|
||||
return ptracePtr(PT_GETFSBASE, pid, unsafe.Pointer(fsbase), 0)
|
||||
}
|
||||
|
17
vendor/golang.org/x/sys/unix/syscall_freebsd_amd64.go
generated
vendored
17
vendor/golang.org/x/sys/unix/syscall_freebsd_amd64.go
generated
vendored
@ -42,6 +42,10 @@ func (cmsg *Cmsghdr) SetLen(length int) {
|
||||
cmsg.Len = uint32(length)
|
||||
}
|
||||
|
||||
func (d *PtraceIoDesc) SetLen(length int) {
|
||||
d.Len = uint64(length)
|
||||
}
|
||||
|
||||
func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) {
|
||||
var writtenOut uint64 = 0
|
||||
_, _, e1 := Syscall9(SYS_SENDFILE, uintptr(infd), uintptr(outfd), uintptr(*offset), uintptr(count), 0, uintptr(unsafe.Pointer(&writtenOut)), 0, 0, 0)
|
||||
@ -57,16 +61,5 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
|
||||
|
||||
func PtraceGetFsBase(pid int, fsbase *int64) (err error) {
|
||||
return ptrace(PT_GETFSBASE, pid, uintptr(unsafe.Pointer(fsbase)), 0)
|
||||
}
|
||||
|
||||
func PtraceIO(req int, pid int, offs uintptr, out []byte, countin int) (count int, err error) {
|
||||
ioDesc := PtraceIoDesc{
|
||||
Op: int32(req),
|
||||
Offs: offs,
|
||||
Addr: uintptr(unsafe.Pointer(&out[0])), // TODO(#58351): this is not safe.
|
||||
Len: uint64(countin),
|
||||
}
|
||||
err = ptrace(PT_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
|
||||
return int(ioDesc.Len), err
|
||||
return ptracePtr(PT_GETFSBASE, pid, unsafe.Pointer(fsbase), 0)
|
||||
}
|
||||
|
15
vendor/golang.org/x/sys/unix/syscall_freebsd_arm.go
generated
vendored
15
vendor/golang.org/x/sys/unix/syscall_freebsd_arm.go
generated
vendored
@ -42,6 +42,10 @@ func (cmsg *Cmsghdr) SetLen(length int) {
|
||||
cmsg.Len = uint32(length)
|
||||
}
|
||||
|
||||
func (d *PtraceIoDesc) SetLen(length int) {
|
||||
d.Len = uint32(length)
|
||||
}
|
||||
|
||||
func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) {
|
||||
var writtenOut uint64 = 0
|
||||
_, _, e1 := Syscall9(SYS_SENDFILE, uintptr(infd), uintptr(outfd), uintptr(*offset), uintptr((*offset)>>32), uintptr(count), 0, uintptr(unsafe.Pointer(&writtenOut)), 0, 0)
|
||||
@ -55,14 +59,3 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
}
|
||||
|
||||
func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
|
||||
|
||||
func PtraceIO(req int, pid int, offs uintptr, out []byte, countin int) (count int, err error) {
|
||||
ioDesc := PtraceIoDesc{
|
||||
Op: int32(req),
|
||||
Offs: offs,
|
||||
Addr: uintptr(unsafe.Pointer(&out[0])), // TODO(#58351): this is not safe.
|
||||
Len: uint32(countin),
|
||||
}
|
||||
err = ptrace(PT_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
|
||||
return int(ioDesc.Len), err
|
||||
}
|
||||
|
15
vendor/golang.org/x/sys/unix/syscall_freebsd_arm64.go
generated
vendored
15
vendor/golang.org/x/sys/unix/syscall_freebsd_arm64.go
generated
vendored
@ -42,6 +42,10 @@ func (cmsg *Cmsghdr) SetLen(length int) {
|
||||
cmsg.Len = uint32(length)
|
||||
}
|
||||
|
||||
func (d *PtraceIoDesc) SetLen(length int) {
|
||||
d.Len = uint64(length)
|
||||
}
|
||||
|
||||
func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) {
|
||||
var writtenOut uint64 = 0
|
||||
_, _, e1 := Syscall9(SYS_SENDFILE, uintptr(infd), uintptr(outfd), uintptr(*offset), uintptr(count), 0, uintptr(unsafe.Pointer(&writtenOut)), 0, 0, 0)
|
||||
@ -55,14 +59,3 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
}
|
||||
|
||||
func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
|
||||
|
||||
func PtraceIO(req int, pid int, offs uintptr, out []byte, countin int) (count int, err error) {
|
||||
ioDesc := PtraceIoDesc{
|
||||
Op: int32(req),
|
||||
Offs: offs,
|
||||
Addr: uintptr(unsafe.Pointer(&out[0])), // TODO(#58351): this is not safe.
|
||||
Len: uint64(countin),
|
||||
}
|
||||
err = ptrace(PT_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
|
||||
return int(ioDesc.Len), err
|
||||
}
|
||||
|
15
vendor/golang.org/x/sys/unix/syscall_freebsd_riscv64.go
generated
vendored
15
vendor/golang.org/x/sys/unix/syscall_freebsd_riscv64.go
generated
vendored
@ -42,6 +42,10 @@ func (cmsg *Cmsghdr) SetLen(length int) {
|
||||
cmsg.Len = uint32(length)
|
||||
}
|
||||
|
||||
func (d *PtraceIoDesc) SetLen(length int) {
|
||||
d.Len = uint64(length)
|
||||
}
|
||||
|
||||
func sendfile(outfd int, infd int, offset *int64, count int) (written int, err error) {
|
||||
var writtenOut uint64 = 0
|
||||
_, _, e1 := Syscall9(SYS_SENDFILE, uintptr(infd), uintptr(outfd), uintptr(*offset), uintptr(count), 0, uintptr(unsafe.Pointer(&writtenOut)), 0, 0, 0)
|
||||
@ -55,14 +59,3 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
}
|
||||
|
||||
func Syscall9(num, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno)
|
||||
|
||||
func PtraceIO(req int, pid int, offs uintptr, out []byte, countin int) (count int, err error) {
|
||||
ioDesc := PtraceIoDesc{
|
||||
Op: int32(req),
|
||||
Offs: offs,
|
||||
Addr: uintptr(unsafe.Pointer(&out[0])), // TODO(#58351): this is not safe.
|
||||
Len: uint64(countin),
|
||||
}
|
||||
err = ptrace(PT_IO, pid, uintptr(unsafe.Pointer(&ioDesc)), 0)
|
||||
return int(ioDesc.Len), err
|
||||
}
|
||||
|
8
vendor/golang.org/x/sys/unix/syscall_hurd.go
generated
vendored
8
vendor/golang.org/x/sys/unix/syscall_hurd.go
generated
vendored
@ -20,3 +20,11 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
r0, er := C.ioctl(C.int(fd), C.ulong(req), C.uintptr_t(uintptr(arg)))
|
||||
if r0 == -1 && er != nil {
|
||||
err = er
|
||||
}
|
||||
return
|
||||
}
|
||||
|
36
vendor/golang.org/x/sys/unix/syscall_linux.go
generated
vendored
36
vendor/golang.org/x/sys/unix/syscall_linux.go
generated
vendored
@ -1015,8 +1015,7 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) {
|
||||
for n < len(pp.Path) && pp.Path[n] != 0 {
|
||||
n++
|
||||
}
|
||||
bytes := (*[len(pp.Path)]byte)(unsafe.Pointer(&pp.Path[0]))[0:n]
|
||||
sa.Name = string(bytes)
|
||||
sa.Name = string(unsafe.Slice((*byte)(unsafe.Pointer(&pp.Path[0])), n))
|
||||
return sa, nil
|
||||
|
||||
case AF_INET:
|
||||
@ -1365,6 +1364,10 @@ func SetsockoptTCPRepairOpt(fd, level, opt int, o []TCPRepairOpt) (err error) {
|
||||
return setsockopt(fd, level, opt, unsafe.Pointer(&o[0]), uintptr(SizeofTCPRepairOpt*len(o)))
|
||||
}
|
||||
|
||||
func SetsockoptTCPMD5Sig(fd, level, opt int, s *TCPMD5Sig) error {
|
||||
return setsockopt(fd, level, opt, unsafe.Pointer(s), unsafe.Sizeof(*s))
|
||||
}
|
||||
|
||||
// Keyctl Commands (http://man7.org/linux/man-pages/man2/keyctl.2.html)
|
||||
|
||||
// KeyctlInt calls keyctl commands in which each argument is an int.
|
||||
@ -1579,6 +1582,7 @@ func BindToDevice(fd int, device string) (err error) {
|
||||
}
|
||||
|
||||
//sys ptrace(request int, pid int, addr uintptr, data uintptr) (err error)
|
||||
//sys ptracePtr(request int, pid int, addr uintptr, data unsafe.Pointer) (err error) = SYS_PTRACE
|
||||
|
||||
func ptracePeek(req int, pid int, addr uintptr, out []byte) (count int, err error) {
|
||||
// The peek requests are machine-size oriented, so we wrap it
|
||||
@ -1596,7 +1600,7 @@ func ptracePeek(req int, pid int, addr uintptr, out []byte) (count int, err erro
|
||||
// boundary.
|
||||
n := 0
|
||||
if addr%SizeofPtr != 0 {
|
||||
err = ptrace(req, pid, addr-addr%SizeofPtr, uintptr(unsafe.Pointer(&buf[0])))
|
||||
err = ptracePtr(req, pid, addr-addr%SizeofPtr, unsafe.Pointer(&buf[0]))
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
@ -1608,7 +1612,7 @@ func ptracePeek(req int, pid int, addr uintptr, out []byte) (count int, err erro
|
||||
for len(out) > 0 {
|
||||
// We use an internal buffer to guarantee alignment.
|
||||
// It's not documented if this is necessary, but we're paranoid.
|
||||
err = ptrace(req, pid, addr+uintptr(n), uintptr(unsafe.Pointer(&buf[0])))
|
||||
err = ptracePtr(req, pid, addr+uintptr(n), unsafe.Pointer(&buf[0]))
|
||||
if err != nil {
|
||||
return n, err
|
||||
}
|
||||
@ -1640,7 +1644,7 @@ func ptracePoke(pokeReq int, peekReq int, pid int, addr uintptr, data []byte) (c
|
||||
n := 0
|
||||
if addr%SizeofPtr != 0 {
|
||||
var buf [SizeofPtr]byte
|
||||
err = ptrace(peekReq, pid, addr-addr%SizeofPtr, uintptr(unsafe.Pointer(&buf[0])))
|
||||
err = ptracePtr(peekReq, pid, addr-addr%SizeofPtr, unsafe.Pointer(&buf[0]))
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
@ -1667,7 +1671,7 @@ func ptracePoke(pokeReq int, peekReq int, pid int, addr uintptr, data []byte) (c
|
||||
// Trailing edge.
|
||||
if len(data) > 0 {
|
||||
var buf [SizeofPtr]byte
|
||||
err = ptrace(peekReq, pid, addr+uintptr(n), uintptr(unsafe.Pointer(&buf[0])))
|
||||
err = ptracePtr(peekReq, pid, addr+uintptr(n), unsafe.Pointer(&buf[0]))
|
||||
if err != nil {
|
||||
return n, err
|
||||
}
|
||||
@ -1696,11 +1700,11 @@ func PtracePokeUser(pid int, addr uintptr, data []byte) (count int, err error) {
|
||||
}
|
||||
|
||||
func PtraceGetRegs(pid int, regsout *PtraceRegs) (err error) {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
func PtraceSetRegs(pid int, regs *PtraceRegs) (err error) {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
||||
func PtraceSetOptions(pid int, options int) (err error) {
|
||||
@ -1709,7 +1713,7 @@ func PtraceSetOptions(pid int, options int) (err error) {
|
||||
|
||||
func PtraceGetEventMsg(pid int) (msg uint, err error) {
|
||||
var data _C_long
|
||||
err = ptrace(PTRACE_GETEVENTMSG, pid, 0, uintptr(unsafe.Pointer(&data)))
|
||||
err = ptracePtr(PTRACE_GETEVENTMSG, pid, 0, unsafe.Pointer(&data))
|
||||
msg = uint(data)
|
||||
return
|
||||
}
|
||||
@ -2154,6 +2158,14 @@ func isGroupMember(gid int) bool {
|
||||
return false
|
||||
}
|
||||
|
||||
func isCapDacOverrideSet() bool {
|
||||
hdr := CapUserHeader{Version: LINUX_CAPABILITY_VERSION_3}
|
||||
data := [2]CapUserData{}
|
||||
err := Capget(&hdr, &data[0])
|
||||
|
||||
return err == nil && data[0].Effective&(1<<CAP_DAC_OVERRIDE) != 0
|
||||
}
|
||||
|
||||
//sys faccessat(dirfd int, path string, mode uint32) (err error)
|
||||
//sys Faccessat2(dirfd int, path string, mode uint32, flags int) (err error)
|
||||
|
||||
@ -2189,6 +2201,12 @@ func Faccessat(dirfd int, path string, mode uint32, flags int) (err error) {
|
||||
var uid int
|
||||
if flags&AT_EACCESS != 0 {
|
||||
uid = Geteuid()
|
||||
if uid != 0 && isCapDacOverrideSet() {
|
||||
// If CAP_DAC_OVERRIDE is set, file access check is
|
||||
// done by the kernel in the same way as for root
|
||||
// (see generic_permission() in the Linux sources).
|
||||
uid = 0
|
||||
}
|
||||
} else {
|
||||
uid = Getuid()
|
||||
}
|
||||
|
5
vendor/golang.org/x/sys/unix/syscall_netbsd.go
generated
vendored
5
vendor/golang.org/x/sys/unix/syscall_netbsd.go
generated
vendored
@ -13,7 +13,6 @@
|
||||
package unix
|
||||
|
||||
import (
|
||||
"runtime"
|
||||
"syscall"
|
||||
"unsafe"
|
||||
)
|
||||
@ -178,13 +177,13 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
|
||||
}
|
||||
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error)
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = SYS_IOCTL
|
||||
|
||||
//sys sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) = SYS___SYSCTL
|
||||
|
||||
func IoctlGetPtmget(fd int, req uint) (*Ptmget, error) {
|
||||
var value Ptmget
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
runtime.KeepAlive(value)
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return &value, err
|
||||
}
|
||||
|
||||
|
1
vendor/golang.org/x/sys/unix/syscall_openbsd.go
generated
vendored
1
vendor/golang.org/x/sys/unix/syscall_openbsd.go
generated
vendored
@ -152,6 +152,7 @@ func Getfsstat(buf []Statfs_t, flags int) (n int, err error) {
|
||||
}
|
||||
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error)
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = SYS_IOCTL
|
||||
|
||||
//sys sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) = SYS___SYSCTL
|
||||
|
||||
|
21
vendor/golang.org/x/sys/unix/syscall_solaris.go
generated
vendored
21
vendor/golang.org/x/sys/unix/syscall_solaris.go
generated
vendored
@ -408,8 +408,7 @@ func anyToSockaddr(fd int, rsa *RawSockaddrAny) (Sockaddr, error) {
|
||||
for n < len(pp.Path) && pp.Path[n] != 0 {
|
||||
n++
|
||||
}
|
||||
bytes := (*[len(pp.Path)]byte)(unsafe.Pointer(&pp.Path[0]))[0:n]
|
||||
sa.Name = string(bytes)
|
||||
sa.Name = string(unsafe.Slice((*byte)(unsafe.Pointer(&pp.Path[0])), n))
|
||||
return sa, nil
|
||||
|
||||
case AF_INET:
|
||||
@ -547,21 +546,25 @@ func Minor(dev uint64) uint32 {
|
||||
*/
|
||||
|
||||
//sys ioctlRet(fd int, req uint, arg uintptr) (ret int, err error) = libc.ioctl
|
||||
//sys ioctlPtrRet(fd int, req uint, arg unsafe.Pointer) (ret int, err error) = libc.ioctl
|
||||
|
||||
func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
_, err = ioctlRet(fd, req, arg)
|
||||
return err
|
||||
}
|
||||
|
||||
func IoctlSetTermio(fd int, req uint, value *Termio) error {
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(value)))
|
||||
runtime.KeepAlive(value)
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, err = ioctlPtrRet(fd, req, arg)
|
||||
return err
|
||||
}
|
||||
|
||||
func IoctlSetTermio(fd int, req uint, value *Termio) error {
|
||||
return ioctlPtr(fd, req, unsafe.Pointer(value))
|
||||
}
|
||||
|
||||
func IoctlGetTermio(fd int, req uint) (*Termio, error) {
|
||||
var value Termio
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&value)))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&value))
|
||||
return &value, err
|
||||
}
|
||||
|
||||
@ -1084,7 +1087,7 @@ func IoctlSetIntRetInt(fd int, req uint, arg int) (int, error) {
|
||||
func IoctlSetString(fd int, req uint, val string) error {
|
||||
bs := make([]byte, len(val)+1)
|
||||
copy(bs[:len(bs)-1], val)
|
||||
err := ioctl(fd, req, uintptr(unsafe.Pointer(&bs[0])))
|
||||
err := ioctlPtr(fd, req, unsafe.Pointer(&bs[0]))
|
||||
runtime.KeepAlive(&bs[0])
|
||||
return err
|
||||
}
|
||||
@ -1118,7 +1121,7 @@ func (l *Lifreq) GetLifruUint() uint {
|
||||
}
|
||||
|
||||
func IoctlLifreq(fd int, req uint, l *Lifreq) error {
|
||||
return ioctl(fd, req, uintptr(unsafe.Pointer(l)))
|
||||
return ioctlPtr(fd, req, unsafe.Pointer(l))
|
||||
}
|
||||
|
||||
// Strioctl Helpers
|
||||
@ -1129,5 +1132,5 @@ func (s *Strioctl) SetInt(i int) {
|
||||
}
|
||||
|
||||
func IoctlSetStrioctlRetInt(fd int, req uint, s *Strioctl) (int, error) {
|
||||
return ioctlRet(fd, req, uintptr(unsafe.Pointer(s)))
|
||||
return ioctlPtrRet(fd, req, unsafe.Pointer(s))
|
||||
}
|
||||
|
4
vendor/golang.org/x/sys/unix/syscall_zos_s390x.go
generated
vendored
4
vendor/golang.org/x/sys/unix/syscall_zos_s390x.go
generated
vendored
@ -139,8 +139,7 @@ func anyToSockaddr(_ int, rsa *RawSockaddrAny) (Sockaddr, error) {
|
||||
for n < int(pp.Len) && pp.Path[n] != 0 {
|
||||
n++
|
||||
}
|
||||
bytes := (*[len(pp.Path)]byte)(unsafe.Pointer(&pp.Path[0]))[0:n]
|
||||
sa.Name = string(bytes)
|
||||
sa.Name = string(unsafe.Slice((*byte)(unsafe.Pointer(&pp.Path[0])), n))
|
||||
return sa, nil
|
||||
|
||||
case AF_INET:
|
||||
@ -214,6 +213,7 @@ func (cmsg *Cmsghdr) SetLen(length int) {
|
||||
//sys mmap(addr uintptr, length uintptr, prot int, flag int, fd int, pos int64) (ret uintptr, err error) = SYS_MMAP
|
||||
//sys munmap(addr uintptr, length uintptr) (err error) = SYS_MUNMAP
|
||||
//sys ioctl(fd int, req uint, arg uintptr) (err error) = SYS_IOCTL
|
||||
//sys ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) = SYS_IOCTL
|
||||
|
||||
//sys Access(path string, mode uint32) (err error) = SYS___ACCESS_A
|
||||
//sys Chdir(path string) (err error) = SYS___CHDIR_A
|
||||
|
10
vendor/golang.org/x/sys/unix/zerrors_linux.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zerrors_linux.go
generated
vendored
@ -70,6 +70,7 @@ const (
|
||||
ALG_SET_DRBG_ENTROPY = 0x6
|
||||
ALG_SET_IV = 0x2
|
||||
ALG_SET_KEY = 0x1
|
||||
ALG_SET_KEY_BY_KEY_SERIAL = 0x7
|
||||
ALG_SET_OP = 0x3
|
||||
ANON_INODE_FS_MAGIC = 0x9041934
|
||||
ARPHRD_6LOWPAN = 0x339
|
||||
@ -774,6 +775,8 @@ const (
|
||||
DEVLINK_GENL_MCGRP_CONFIG_NAME = "config"
|
||||
DEVLINK_GENL_NAME = "devlink"
|
||||
DEVLINK_GENL_VERSION = 0x1
|
||||
DEVLINK_PORT_FN_CAP_MIGRATABLE = 0x2
|
||||
DEVLINK_PORT_FN_CAP_ROCE = 0x1
|
||||
DEVLINK_SB_THRESHOLD_TO_ALPHA_MAX = 0x14
|
||||
DEVLINK_SUPPORTED_FLASH_OVERWRITE_SECTIONS = 0x3
|
||||
DEVMEM_MAGIC = 0x454d444d
|
||||
@ -1262,6 +1265,8 @@ const (
|
||||
FSCRYPT_MODE_AES_256_CTS = 0x4
|
||||
FSCRYPT_MODE_AES_256_HCTR2 = 0xa
|
||||
FSCRYPT_MODE_AES_256_XTS = 0x1
|
||||
FSCRYPT_MODE_SM4_CTS = 0x8
|
||||
FSCRYPT_MODE_SM4_XTS = 0x7
|
||||
FSCRYPT_POLICY_FLAGS_PAD_16 = 0x2
|
||||
FSCRYPT_POLICY_FLAGS_PAD_32 = 0x3
|
||||
FSCRYPT_POLICY_FLAGS_PAD_4 = 0x0
|
||||
@ -1280,8 +1285,6 @@ const (
|
||||
FS_ENCRYPTION_MODE_AES_256_GCM = 0x2
|
||||
FS_ENCRYPTION_MODE_AES_256_XTS = 0x1
|
||||
FS_ENCRYPTION_MODE_INVALID = 0x0
|
||||
FS_ENCRYPTION_MODE_SPECK128_256_CTS = 0x8
|
||||
FS_ENCRYPTION_MODE_SPECK128_256_XTS = 0x7
|
||||
FS_IOC_ADD_ENCRYPTION_KEY = 0xc0506617
|
||||
FS_IOC_GET_ENCRYPTION_KEY_STATUS = 0xc080661a
|
||||
FS_IOC_GET_ENCRYPTION_POLICY_EX = 0xc0096616
|
||||
@ -1770,6 +1773,7 @@ const (
|
||||
LANDLOCK_ACCESS_FS_REFER = 0x2000
|
||||
LANDLOCK_ACCESS_FS_REMOVE_DIR = 0x10
|
||||
LANDLOCK_ACCESS_FS_REMOVE_FILE = 0x20
|
||||
LANDLOCK_ACCESS_FS_TRUNCATE = 0x4000
|
||||
LANDLOCK_ACCESS_FS_WRITE_FILE = 0x2
|
||||
LANDLOCK_CREATE_RULESET_VERSION = 0x1
|
||||
LINUX_REBOOT_CMD_CAD_OFF = 0x0
|
||||
@ -1809,6 +1813,7 @@ const (
|
||||
LWTUNNEL_IP_OPT_GENEVE_MAX = 0x3
|
||||
LWTUNNEL_IP_OPT_VXLAN_MAX = 0x1
|
||||
MADV_COLD = 0x14
|
||||
MADV_COLLAPSE = 0x19
|
||||
MADV_DODUMP = 0x11
|
||||
MADV_DOFORK = 0xb
|
||||
MADV_DONTDUMP = 0x10
|
||||
@ -2163,6 +2168,7 @@ const (
|
||||
PACKET_FANOUT_DATA = 0x16
|
||||
PACKET_FANOUT_EBPF = 0x7
|
||||
PACKET_FANOUT_FLAG_DEFRAG = 0x8000
|
||||
PACKET_FANOUT_FLAG_IGNORE_OUTGOING = 0x4000
|
||||
PACKET_FANOUT_FLAG_ROLLOVER = 0x1000
|
||||
PACKET_FANOUT_FLAG_UNIQUEID = 0x2000
|
||||
PACKET_FANOUT_HASH = 0x0
|
||||
|
8
vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zptrace_armnn_linux.go
generated
vendored
@ -15,12 +15,12 @@ type PtraceRegsArm struct {
|
||||
|
||||
// PtraceGetRegsArm fetches the registers used by arm binaries.
|
||||
func PtraceGetRegsArm(pid int, regsout *PtraceRegsArm) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsArm sets the registers used by arm binaries.
|
||||
func PtraceSetRegsArm(pid int, regs *PtraceRegsArm) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
||||
// PtraceRegsArm64 is the registers used by arm64 binaries.
|
||||
@ -33,10 +33,10 @@ type PtraceRegsArm64 struct {
|
||||
|
||||
// PtraceGetRegsArm64 fetches the registers used by arm64 binaries.
|
||||
func PtraceGetRegsArm64(pid int, regsout *PtraceRegsArm64) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsArm64 sets the registers used by arm64 binaries.
|
||||
func PtraceSetRegsArm64(pid int, regs *PtraceRegsArm64) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
4
vendor/golang.org/x/sys/unix/zptrace_linux_arm64.go
generated
vendored
4
vendor/golang.org/x/sys/unix/zptrace_linux_arm64.go
generated
vendored
@ -7,11 +7,11 @@ import "unsafe"
|
||||
// PtraceGetRegSetArm64 fetches the registers used by arm64 binaries.
|
||||
func PtraceGetRegSetArm64(pid, addr int, regsout *PtraceRegsArm64) error {
|
||||
iovec := Iovec{(*byte)(unsafe.Pointer(regsout)), uint64(unsafe.Sizeof(*regsout))}
|
||||
return ptrace(PTRACE_GETREGSET, pid, uintptr(addr), uintptr(unsafe.Pointer(&iovec)))
|
||||
return ptracePtr(PTRACE_GETREGSET, pid, uintptr(addr), unsafe.Pointer(&iovec))
|
||||
}
|
||||
|
||||
// PtraceSetRegSetArm64 sets the registers used by arm64 binaries.
|
||||
func PtraceSetRegSetArm64(pid, addr int, regs *PtraceRegsArm64) error {
|
||||
iovec := Iovec{(*byte)(unsafe.Pointer(regs)), uint64(unsafe.Sizeof(*regs))}
|
||||
return ptrace(PTRACE_SETREGSET, pid, uintptr(addr), uintptr(unsafe.Pointer(&iovec)))
|
||||
return ptracePtr(PTRACE_SETREGSET, pid, uintptr(addr), unsafe.Pointer(&iovec))
|
||||
}
|
||||
|
8
vendor/golang.org/x/sys/unix/zptrace_mipsnn_linux.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zptrace_mipsnn_linux.go
generated
vendored
@ -21,12 +21,12 @@ type PtraceRegsMips struct {
|
||||
|
||||
// PtraceGetRegsMips fetches the registers used by mips binaries.
|
||||
func PtraceGetRegsMips(pid int, regsout *PtraceRegsMips) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsMips sets the registers used by mips binaries.
|
||||
func PtraceSetRegsMips(pid int, regs *PtraceRegsMips) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
||||
// PtraceRegsMips64 is the registers used by mips64 binaries.
|
||||
@ -42,10 +42,10 @@ type PtraceRegsMips64 struct {
|
||||
|
||||
// PtraceGetRegsMips64 fetches the registers used by mips64 binaries.
|
||||
func PtraceGetRegsMips64(pid int, regsout *PtraceRegsMips64) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsMips64 sets the registers used by mips64 binaries.
|
||||
func PtraceSetRegsMips64(pid int, regs *PtraceRegsMips64) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
8
vendor/golang.org/x/sys/unix/zptrace_mipsnnle_linux.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zptrace_mipsnnle_linux.go
generated
vendored
@ -21,12 +21,12 @@ type PtraceRegsMipsle struct {
|
||||
|
||||
// PtraceGetRegsMipsle fetches the registers used by mipsle binaries.
|
||||
func PtraceGetRegsMipsle(pid int, regsout *PtraceRegsMipsle) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsMipsle sets the registers used by mipsle binaries.
|
||||
func PtraceSetRegsMipsle(pid int, regs *PtraceRegsMipsle) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
||||
// PtraceRegsMips64le is the registers used by mips64le binaries.
|
||||
@ -42,10 +42,10 @@ type PtraceRegsMips64le struct {
|
||||
|
||||
// PtraceGetRegsMips64le fetches the registers used by mips64le binaries.
|
||||
func PtraceGetRegsMips64le(pid int, regsout *PtraceRegsMips64le) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsMips64le sets the registers used by mips64le binaries.
|
||||
func PtraceSetRegsMips64le(pid int, regs *PtraceRegsMips64le) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
8
vendor/golang.org/x/sys/unix/zptrace_x86_linux.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zptrace_x86_linux.go
generated
vendored
@ -31,12 +31,12 @@ type PtraceRegs386 struct {
|
||||
|
||||
// PtraceGetRegs386 fetches the registers used by 386 binaries.
|
||||
func PtraceGetRegs386(pid int, regsout *PtraceRegs386) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegs386 sets the registers used by 386 binaries.
|
||||
func PtraceSetRegs386(pid int, regs *PtraceRegs386) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
||||
// PtraceRegsAmd64 is the registers used by amd64 binaries.
|
||||
@ -72,10 +72,10 @@ type PtraceRegsAmd64 struct {
|
||||
|
||||
// PtraceGetRegsAmd64 fetches the registers used by amd64 binaries.
|
||||
func PtraceGetRegsAmd64(pid int, regsout *PtraceRegsAmd64) error {
|
||||
return ptrace(PTRACE_GETREGS, pid, 0, uintptr(unsafe.Pointer(regsout)))
|
||||
return ptracePtr(PTRACE_GETREGS, pid, 0, unsafe.Pointer(regsout))
|
||||
}
|
||||
|
||||
// PtraceSetRegsAmd64 sets the registers used by amd64 binaries.
|
||||
func PtraceSetRegsAmd64(pid int, regs *PtraceRegsAmd64) error {
|
||||
return ptrace(PTRACE_SETREGS, pid, 0, uintptr(unsafe.Pointer(regs)))
|
||||
return ptracePtr(PTRACE_SETREGS, pid, 0, unsafe.Pointer(regs))
|
||||
}
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc.go
generated
vendored
@ -223,6 +223,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
r0, er := C.ioctl(C.int(fd), C.int(req), C.uintptr_t(uintptr(arg)))
|
||||
if r0 == -1 && er != nil {
|
||||
err = er
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func FcntlInt(fd uintptr, cmd int, arg int) (r int, err error) {
|
||||
r0, er := C.fcntl(C.uintptr_t(fd), C.int(cmd), C.uintptr_t(arg))
|
||||
r = int(r0)
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64.go
generated
vendored
@ -103,6 +103,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, e1 := callioctl_ptr(fd, int(req), arg)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func FcntlInt(fd uintptr, cmd int, arg int) (r int, err error) {
|
||||
r0, e1 := callfcntl(fd, cmd, uintptr(arg))
|
||||
r = int(r0)
|
||||
|
7
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gc.go
generated
vendored
7
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gc.go
generated
vendored
@ -423,6 +423,13 @@ func callioctl(fd int, req int, arg uintptr) (r1 uintptr, e1 Errno) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func callioctl_ptr(fd int, req int, arg unsafe.Pointer) (r1 uintptr, e1 Errno) {
|
||||
r1, _, e1 = syscall6(uintptr(unsafe.Pointer(&libc_ioctl)), 3, uintptr(fd), uintptr(req), uintptr(arg), 0, 0, 0)
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func callfcntl(fd uintptr, cmd int, arg uintptr) (r1 uintptr, e1 Errno) {
|
||||
r1, _, e1 = syscall6(uintptr(unsafe.Pointer(&libc_fcntl)), 3, fd, uintptr(cmd), arg, 0, 0, 0)
|
||||
return
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gccgo.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_aix_ppc64_gccgo.go
generated
vendored
@ -191,6 +191,14 @@ func callioctl(fd int, req int, arg uintptr) (r1 uintptr, e1 Errno) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func callioctl_ptr(fd int, req int, arg unsafe.Pointer) (r1 uintptr, e1 Errno) {
|
||||
r1 = uintptr(C.ioctl(C.int(fd), C.int(req), C.uintptr_t(uintptr(arg))))
|
||||
e1 = syscall.GetErrno()
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func callfcntl(fd uintptr, cmd int, arg uintptr) (r1 uintptr, e1 Errno) {
|
||||
r1 = uintptr(C.fcntl(C.uintptr_t(fd), C.int(cmd), C.uintptr_t(arg)))
|
||||
e1 = syscall.GetErrno()
|
||||
|
16
vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go
generated
vendored
16
vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go
generated
vendored
@ -725,6 +725,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "/usr/lib/libSystem.B.dylib"
|
||||
@ -2502,6 +2510,14 @@ func ptrace1(request int, pid int, addr uintptr, data uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ptrace1Ptr(request int, pid int, addr uintptr, data unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall6(libc_ptrace_trampoline_addr, uintptr(request), uintptr(pid), addr, uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ptrace_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ptrace ptrace "/usr/lib/libSystem.B.dylib"
|
||||
|
16
vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go
generated
vendored
16
vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go
generated
vendored
@ -725,6 +725,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "/usr/lib/libSystem.B.dylib"
|
||||
@ -2502,6 +2510,14 @@ func ptrace1(request int, pid int, addr uintptr, data uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ptrace1Ptr(request int, pid int, addr uintptr, data unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall6(libc_ptrace_trampoline_addr, uintptr(request), uintptr(pid), addr, uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ptrace_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ptrace ptrace "/usr/lib/libSystem.B.dylib"
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_dragonfly_amd64.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_dragonfly_amd64.go
generated
vendored
@ -436,6 +436,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
|
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_386.go
generated
vendored
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_386.go
generated
vendored
@ -388,6 +388,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
@ -414,6 +424,16 @@ func ptrace(request int, pid int, addr uintptr, data int) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ptracePtr(request int, pid int, addr unsafe.Pointer, data int) (err error) {
|
||||
_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func Access(path string, mode uint32) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(path)
|
||||
|
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_amd64.go
generated
vendored
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_amd64.go
generated
vendored
@ -388,6 +388,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
@ -414,6 +424,16 @@ func ptrace(request int, pid int, addr uintptr, data int) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ptracePtr(request int, pid int, addr unsafe.Pointer, data int) (err error) {
|
||||
_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func Access(path string, mode uint32) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(path)
|
||||
|
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_arm.go
generated
vendored
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_arm.go
generated
vendored
@ -388,6 +388,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
@ -414,6 +424,16 @@ func ptrace(request int, pid int, addr uintptr, data int) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ptracePtr(request int, pid int, addr unsafe.Pointer, data int) (err error) {
|
||||
_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func Access(path string, mode uint32) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(path)
|
||||
|
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_arm64.go
generated
vendored
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_arm64.go
generated
vendored
@ -388,6 +388,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
@ -414,6 +424,16 @@ func ptrace(request int, pid int, addr uintptr, data int) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ptracePtr(request int, pid int, addr unsafe.Pointer, data int) (err error) {
|
||||
_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func Access(path string, mode uint32) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(path)
|
||||
|
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_riscv64.go
generated
vendored
20
vendor/golang.org/x/sys/unix/zsyscall_freebsd_riscv64.go
generated
vendored
@ -388,6 +388,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
@ -414,6 +424,16 @@ func ptrace(request int, pid int, addr uintptr, data int) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ptracePtr(request int, pid int, addr unsafe.Pointer, data int) (err error) {
|
||||
_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func Access(path string, mode uint32) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(path)
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_linux.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_linux.go
generated
vendored
@ -379,6 +379,16 @@ func ptrace(request int, pid int, addr uintptr, data uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ptracePtr(request int, pid int, addr uintptr, data unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall6(SYS_PTRACE, uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func reboot(magic1 uint, magic2 uint, cmd int, arg string) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(arg)
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_386.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_386.go
generated
vendored
@ -405,6 +405,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_amd64.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_amd64.go
generated
vendored
@ -405,6 +405,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm.go
generated
vendored
@ -405,6 +405,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm64.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_netbsd_arm64.go
generated
vendored
@ -405,6 +405,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := Syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
|
||||
var _p0 unsafe.Pointer
|
||||
if len(mib) > 0 {
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.go
generated
vendored
8
vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.go
generated
vendored
@ -527,6 +527,14 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(libc_ioctl_trampoline_addr, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
var libc_ioctl_trampoline_addr uintptr
|
||||
|
||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_solaris_amd64.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_solaris_amd64.go
generated
vendored
@ -657,6 +657,17 @@ func ioctlRet(fd int, req uint, arg uintptr) (ret int, err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtrRet(fd int, req uint, arg unsafe.Pointer) (ret int, err error) {
|
||||
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procioctl)), 3, uintptr(fd), uintptr(req), uintptr(arg), 0, 0, 0)
|
||||
ret = int(r0)
|
||||
if e1 != 0 {
|
||||
err = e1
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func poll(fds *PollFd, nfds int, timeout int) (n int, err error) {
|
||||
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procpoll)), 3, uintptr(unsafe.Pointer(fds)), uintptr(nfds), uintptr(timeout), 0, 0, 0)
|
||||
n = int(r0)
|
||||
|
10
vendor/golang.org/x/sys/unix/zsyscall_zos_s390x.go
generated
vendored
10
vendor/golang.org/x/sys/unix/zsyscall_zos_s390x.go
generated
vendored
@ -267,6 +267,16 @@ func ioctl(fd int, req uint, arg uintptr) (err error) {
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
|
||||
_, _, e1 := syscall_syscall(SYS_IOCTL, uintptr(fd), uintptr(req), uintptr(arg))
|
||||
if e1 != 0 {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||
|
||||
func Access(path string, mode uint32) (err error) {
|
||||
var _p0 *byte
|
||||
_p0, err = BytePtrFromString(path)
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_386.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_386.go
generated
vendored
@ -362,7 +362,7 @@ type FpExtendedPrecision struct{}
|
||||
type PtraceIoDesc struct {
|
||||
Op int32
|
||||
Offs uintptr
|
||||
Addr uintptr
|
||||
Addr *byte
|
||||
Len uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_amd64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_amd64.go
generated
vendored
@ -367,7 +367,7 @@ type FpExtendedPrecision struct{}
|
||||
type PtraceIoDesc struct {
|
||||
Op int32
|
||||
Offs uintptr
|
||||
Addr uintptr
|
||||
Addr *byte
|
||||
Len uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_arm.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_arm.go
generated
vendored
@ -350,7 +350,7 @@ type FpExtendedPrecision struct {
|
||||
type PtraceIoDesc struct {
|
||||
Op int32
|
||||
Offs uintptr
|
||||
Addr uintptr
|
||||
Addr *byte
|
||||
Len uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_arm64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_arm64.go
generated
vendored
@ -347,7 +347,7 @@ type FpExtendedPrecision struct{}
|
||||
type PtraceIoDesc struct {
|
||||
Op int32
|
||||
Offs uintptr
|
||||
Addr uintptr
|
||||
Addr *byte
|
||||
Len uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_riscv64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_freebsd_riscv64.go
generated
vendored
@ -348,7 +348,7 @@ type FpExtendedPrecision struct{}
|
||||
type PtraceIoDesc struct {
|
||||
Op int32
|
||||
Offs uintptr
|
||||
Addr uintptr
|
||||
Addr *byte
|
||||
Len uint64
|
||||
}
|
||||
|
||||
|
80
vendor/golang.org/x/sys/unix/ztypes_linux.go
generated
vendored
80
vendor/golang.org/x/sys/unix/ztypes_linux.go
generated
vendored
@ -486,6 +486,30 @@ type TCPInfo struct {
|
||||
Rcv_rtt uint32
|
||||
Rcv_space uint32
|
||||
Total_retrans uint32
|
||||
Pacing_rate uint64
|
||||
Max_pacing_rate uint64
|
||||
Bytes_acked uint64
|
||||
Bytes_received uint64
|
||||
Segs_out uint32
|
||||
Segs_in uint32
|
||||
Notsent_bytes uint32
|
||||
Min_rtt uint32
|
||||
Data_segs_in uint32
|
||||
Data_segs_out uint32
|
||||
Delivery_rate uint64
|
||||
Busy_time uint64
|
||||
Rwnd_limited uint64
|
||||
Sndbuf_limited uint64
|
||||
Delivered uint32
|
||||
Delivered_ce uint32
|
||||
Bytes_sent uint64
|
||||
Bytes_retrans uint64
|
||||
Dsack_dups uint32
|
||||
Reord_seen uint32
|
||||
Rcv_ooopack uint32
|
||||
Snd_wnd uint32
|
||||
Rcv_wnd uint32
|
||||
Rehash uint32
|
||||
}
|
||||
|
||||
type CanFilter struct {
|
||||
@ -528,7 +552,7 @@ const (
|
||||
SizeofIPv6MTUInfo = 0x20
|
||||
SizeofICMPv6Filter = 0x20
|
||||
SizeofUcred = 0xc
|
||||
SizeofTCPInfo = 0x68
|
||||
SizeofTCPInfo = 0xf0
|
||||
SizeofCanFilter = 0x8
|
||||
SizeofTCPRepairOpt = 0x8
|
||||
)
|
||||
@ -1043,6 +1067,7 @@ const (
|
||||
PerfBitCommExec = CBitFieldMaskBit24
|
||||
PerfBitUseClockID = CBitFieldMaskBit25
|
||||
PerfBitContextSwitch = CBitFieldMaskBit26
|
||||
PerfBitWriteBackward = CBitFieldMaskBit27
|
||||
)
|
||||
|
||||
const (
|
||||
@ -1239,7 +1264,7 @@ type TCPMD5Sig struct {
|
||||
Flags uint8
|
||||
Prefixlen uint8
|
||||
Keylen uint16
|
||||
_ uint32
|
||||
Ifindex int32
|
||||
Key [80]uint8
|
||||
}
|
||||
|
||||
@ -1939,7 +1964,11 @@ const (
|
||||
NFT_MSG_GETOBJ = 0x13
|
||||
NFT_MSG_DELOBJ = 0x14
|
||||
NFT_MSG_GETOBJ_RESET = 0x15
|
||||
NFT_MSG_MAX = 0x19
|
||||
NFT_MSG_NEWFLOWTABLE = 0x16
|
||||
NFT_MSG_GETFLOWTABLE = 0x17
|
||||
NFT_MSG_DELFLOWTABLE = 0x18
|
||||
NFT_MSG_GETRULE_RESET = 0x19
|
||||
NFT_MSG_MAX = 0x1a
|
||||
NFTA_LIST_UNSPEC = 0x0
|
||||
NFTA_LIST_ELEM = 0x1
|
||||
NFTA_HOOK_UNSPEC = 0x0
|
||||
@ -2443,9 +2472,11 @@ const (
|
||||
SOF_TIMESTAMPING_OPT_STATS = 0x1000
|
||||
SOF_TIMESTAMPING_OPT_PKTINFO = 0x2000
|
||||
SOF_TIMESTAMPING_OPT_TX_SWHW = 0x4000
|
||||
SOF_TIMESTAMPING_BIND_PHC = 0x8000
|
||||
SOF_TIMESTAMPING_OPT_ID_TCP = 0x10000
|
||||
|
||||
SOF_TIMESTAMPING_LAST = 0x8000
|
||||
SOF_TIMESTAMPING_MASK = 0xffff
|
||||
SOF_TIMESTAMPING_LAST = 0x10000
|
||||
SOF_TIMESTAMPING_MASK = 0x1ffff
|
||||
|
||||
SCM_TSTAMP_SND = 0x0
|
||||
SCM_TSTAMP_SCHED = 0x1
|
||||
@ -3265,7 +3296,7 @@ const (
|
||||
DEVLINK_ATTR_LINECARD_SUPPORTED_TYPES = 0xae
|
||||
DEVLINK_ATTR_NESTED_DEVLINK = 0xaf
|
||||
DEVLINK_ATTR_SELFTESTS = 0xb0
|
||||
DEVLINK_ATTR_MAX = 0xb0
|
||||
DEVLINK_ATTR_MAX = 0xb3
|
||||
DEVLINK_DPIPE_FIELD_MAPPING_TYPE_NONE = 0x0
|
||||
DEVLINK_DPIPE_FIELD_MAPPING_TYPE_IFINDEX = 0x1
|
||||
DEVLINK_DPIPE_MATCH_TYPE_FIELD_EXACT = 0x0
|
||||
@ -3281,7 +3312,8 @@ const (
|
||||
DEVLINK_PORT_FUNCTION_ATTR_HW_ADDR = 0x1
|
||||
DEVLINK_PORT_FN_ATTR_STATE = 0x2
|
||||
DEVLINK_PORT_FN_ATTR_OPSTATE = 0x3
|
||||
DEVLINK_PORT_FUNCTION_ATTR_MAX = 0x3
|
||||
DEVLINK_PORT_FN_ATTR_CAPS = 0x4
|
||||
DEVLINK_PORT_FUNCTION_ATTR_MAX = 0x4
|
||||
)
|
||||
|
||||
type FsverityDigest struct {
|
||||
@ -3572,7 +3604,8 @@ const (
|
||||
ETHTOOL_MSG_MODULE_SET = 0x23
|
||||
ETHTOOL_MSG_PSE_GET = 0x24
|
||||
ETHTOOL_MSG_PSE_SET = 0x25
|
||||
ETHTOOL_MSG_USER_MAX = 0x25
|
||||
ETHTOOL_MSG_RSS_GET = 0x26
|
||||
ETHTOOL_MSG_USER_MAX = 0x26
|
||||
ETHTOOL_MSG_KERNEL_NONE = 0x0
|
||||
ETHTOOL_MSG_STRSET_GET_REPLY = 0x1
|
||||
ETHTOOL_MSG_LINKINFO_GET_REPLY = 0x2
|
||||
@ -3611,7 +3644,8 @@ const (
|
||||
ETHTOOL_MSG_MODULE_GET_REPLY = 0x23
|
||||
ETHTOOL_MSG_MODULE_NTF = 0x24
|
||||
ETHTOOL_MSG_PSE_GET_REPLY = 0x25
|
||||
ETHTOOL_MSG_KERNEL_MAX = 0x25
|
||||
ETHTOOL_MSG_RSS_GET_REPLY = 0x26
|
||||
ETHTOOL_MSG_KERNEL_MAX = 0x26
|
||||
ETHTOOL_A_HEADER_UNSPEC = 0x0
|
||||
ETHTOOL_A_HEADER_DEV_INDEX = 0x1
|
||||
ETHTOOL_A_HEADER_DEV_NAME = 0x2
|
||||
@ -3679,7 +3713,8 @@ const (
|
||||
ETHTOOL_A_LINKSTATE_SQI_MAX = 0x4
|
||||
ETHTOOL_A_LINKSTATE_EXT_STATE = 0x5
|
||||
ETHTOOL_A_LINKSTATE_EXT_SUBSTATE = 0x6
|
||||
ETHTOOL_A_LINKSTATE_MAX = 0x6
|
||||
ETHTOOL_A_LINKSTATE_EXT_DOWN_CNT = 0x7
|
||||
ETHTOOL_A_LINKSTATE_MAX = 0x7
|
||||
ETHTOOL_A_DEBUG_UNSPEC = 0x0
|
||||
ETHTOOL_A_DEBUG_HEADER = 0x1
|
||||
ETHTOOL_A_DEBUG_MSGMASK = 0x2
|
||||
@ -4409,7 +4444,7 @@ const (
|
||||
NL80211_ATTR_MAC_HINT = 0xc8
|
||||
NL80211_ATTR_MAC_MASK = 0xd7
|
||||
NL80211_ATTR_MAX_AP_ASSOC_STA = 0xca
|
||||
NL80211_ATTR_MAX = 0x140
|
||||
NL80211_ATTR_MAX = 0x141
|
||||
NL80211_ATTR_MAX_CRIT_PROT_DURATION = 0xb4
|
||||
NL80211_ATTR_MAX_CSA_COUNTERS = 0xce
|
||||
NL80211_ATTR_MAX_MATCH_SETS = 0x85
|
||||
@ -4552,6 +4587,7 @@ const (
|
||||
NL80211_ATTR_SUPPORT_MESH_AUTH = 0x73
|
||||
NL80211_ATTR_SURVEY_INFO = 0x54
|
||||
NL80211_ATTR_SURVEY_RADIO_STATS = 0xda
|
||||
NL80211_ATTR_TD_BITMAP = 0x141
|
||||
NL80211_ATTR_TDLS_ACTION = 0x88
|
||||
NL80211_ATTR_TDLS_DIALOG_TOKEN = 0x89
|
||||
NL80211_ATTR_TDLS_EXTERNAL_SETUP = 0x8c
|
||||
@ -5752,3 +5788,25 @@ const (
|
||||
AUDIT_NLGRP_NONE = 0x0
|
||||
AUDIT_NLGRP_READLOG = 0x1
|
||||
)
|
||||
|
||||
const (
|
||||
TUN_F_CSUM = 0x1
|
||||
TUN_F_TSO4 = 0x2
|
||||
TUN_F_TSO6 = 0x4
|
||||
TUN_F_TSO_ECN = 0x8
|
||||
TUN_F_UFO = 0x10
|
||||
)
|
||||
|
||||
const (
|
||||
VIRTIO_NET_HDR_F_NEEDS_CSUM = 0x1
|
||||
VIRTIO_NET_HDR_F_DATA_VALID = 0x2
|
||||
VIRTIO_NET_HDR_F_RSC_INFO = 0x4
|
||||
)
|
||||
|
||||
const (
|
||||
VIRTIO_NET_HDR_GSO_NONE = 0x0
|
||||
VIRTIO_NET_HDR_GSO_TCPV4 = 0x1
|
||||
VIRTIO_NET_HDR_GSO_UDP = 0x3
|
||||
VIRTIO_NET_HDR_GSO_TCPV6 = 0x4
|
||||
VIRTIO_NET_HDR_GSO_ECN = 0x80
|
||||
)
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_386.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_386.go
generated
vendored
@ -414,7 +414,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [122]int8
|
||||
Data [122]byte
|
||||
_ uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_amd64.go
generated
vendored
@ -427,7 +427,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_arm.go
generated
vendored
@ -405,7 +405,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [122]uint8
|
||||
Data [122]byte
|
||||
_ uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_arm64.go
generated
vendored
@ -406,7 +406,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_loong64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_loong64.go
generated
vendored
@ -407,7 +407,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
generated
vendored
@ -410,7 +410,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [122]int8
|
||||
Data [122]byte
|
||||
_ uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
generated
vendored
@ -409,7 +409,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
generated
vendored
@ -409,7 +409,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
generated
vendored
@ -410,7 +410,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [122]int8
|
||||
Data [122]byte
|
||||
_ uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_ppc.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_ppc.go
generated
vendored
@ -417,7 +417,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [122]uint8
|
||||
Data [122]byte
|
||||
_ uint32
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_ppc64.go
generated
vendored
@ -416,7 +416,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]uint8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_ppc64le.go
generated
vendored
@ -416,7 +416,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]uint8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go
generated
vendored
@ -434,7 +434,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]uint8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_s390x.go
generated
vendored
@ -429,7 +429,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
2
vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
generated
vendored
2
vendor/golang.org/x/sys/unix/ztypes_linux_sparc64.go
generated
vendored
@ -411,7 +411,7 @@ const (
|
||||
|
||||
type SockaddrStorage struct {
|
||||
Family uint16
|
||||
_ [118]int8
|
||||
Data [118]byte
|
||||
_ uint64
|
||||
}
|
||||
|
||||
|
6
vendor/golang.org/x/sys/windows/syscall_windows.go
generated
vendored
6
vendor/golang.org/x/sys/windows/syscall_windows.go
generated
vendored
@ -824,6 +824,9 @@ const socket_error = uintptr(^uint32(0))
|
||||
//sys WSAStartup(verreq uint32, data *WSAData) (sockerr error) = ws2_32.WSAStartup
|
||||
//sys WSACleanup() (err error) [failretval==socket_error] = ws2_32.WSACleanup
|
||||
//sys WSAIoctl(s Handle, iocc uint32, inbuf *byte, cbif uint32, outbuf *byte, cbob uint32, cbbr *uint32, overlapped *Overlapped, completionRoutine uintptr) (err error) [failretval==socket_error] = ws2_32.WSAIoctl
|
||||
//sys WSALookupServiceBegin(querySet *WSAQUERYSET, flags uint32, handle *Handle) (err error) [failretval==socket_error] = ws2_32.WSALookupServiceBeginW
|
||||
//sys WSALookupServiceNext(handle Handle, flags uint32, size *int32, querySet *WSAQUERYSET) (err error) [failretval==socket_error] = ws2_32.WSALookupServiceNextW
|
||||
//sys WSALookupServiceEnd(handle Handle) (err error) [failretval==socket_error] = ws2_32.WSALookupServiceEnd
|
||||
//sys socket(af int32, typ int32, protocol int32) (handle Handle, err error) [failretval==InvalidHandle] = ws2_32.socket
|
||||
//sys sendto(s Handle, buf []byte, flags int32, to unsafe.Pointer, tolen int32) (err error) [failretval==socket_error] = ws2_32.sendto
|
||||
//sys recvfrom(s Handle, buf []byte, flags int32, from *RawSockaddrAny, fromlen *int32) (n int32, err error) [failretval==-1] = ws2_32.recvfrom
|
||||
@ -1019,8 +1022,7 @@ func (rsa *RawSockaddrAny) Sockaddr() (Sockaddr, error) {
|
||||
for n < len(pp.Path) && pp.Path[n] != 0 {
|
||||
n++
|
||||
}
|
||||
bytes := (*[len(pp.Path)]byte)(unsafe.Pointer(&pp.Path[0]))[0:n]
|
||||
sa.Name = string(bytes)
|
||||
sa.Name = string(unsafe.Slice((*byte)(unsafe.Pointer(&pp.Path[0])), n))
|
||||
return sa, nil
|
||||
|
||||
case AF_INET:
|
||||
|
85
vendor/golang.org/x/sys/windows/types_windows.go
generated
vendored
85
vendor/golang.org/x/sys/windows/types_windows.go
generated
vendored
@ -1243,6 +1243,51 @@ const (
|
||||
DnsSectionAdditional = 0x0003
|
||||
)
|
||||
|
||||
const (
|
||||
// flags of WSALookupService
|
||||
LUP_DEEP = 0x0001
|
||||
LUP_CONTAINERS = 0x0002
|
||||
LUP_NOCONTAINERS = 0x0004
|
||||
LUP_NEAREST = 0x0008
|
||||
LUP_RETURN_NAME = 0x0010
|
||||
LUP_RETURN_TYPE = 0x0020
|
||||
LUP_RETURN_VERSION = 0x0040
|
||||
LUP_RETURN_COMMENT = 0x0080
|
||||
LUP_RETURN_ADDR = 0x0100
|
||||
LUP_RETURN_BLOB = 0x0200
|
||||
LUP_RETURN_ALIASES = 0x0400
|
||||
LUP_RETURN_QUERY_STRING = 0x0800
|
||||
LUP_RETURN_ALL = 0x0FF0
|
||||
LUP_RES_SERVICE = 0x8000
|
||||
|
||||
LUP_FLUSHCACHE = 0x1000
|
||||
LUP_FLUSHPREVIOUS = 0x2000
|
||||
|
||||
LUP_NON_AUTHORITATIVE = 0x4000
|
||||
LUP_SECURE = 0x8000
|
||||
LUP_RETURN_PREFERRED_NAMES = 0x10000
|
||||
LUP_DNS_ONLY = 0x20000
|
||||
|
||||
LUP_ADDRCONFIG = 0x100000
|
||||
LUP_DUAL_ADDR = 0x200000
|
||||
LUP_FILESERVER = 0x400000
|
||||
LUP_DISABLE_IDN_ENCODING = 0x00800000
|
||||
LUP_API_ANSI = 0x01000000
|
||||
|
||||
LUP_RESOLUTION_HANDLE = 0x80000000
|
||||
)
|
||||
|
||||
const (
|
||||
// values of WSAQUERYSET's namespace
|
||||
NS_ALL = 0
|
||||
NS_DNS = 12
|
||||
NS_NLA = 15
|
||||
NS_BTH = 16
|
||||
NS_EMAIL = 37
|
||||
NS_PNRPNAME = 38
|
||||
NS_PNRPCLOUD = 39
|
||||
)
|
||||
|
||||
type DNSSRVData struct {
|
||||
Target *uint16
|
||||
Priority uint16
|
||||
@ -3258,3 +3303,43 @@ const (
|
||||
DWMWA_TEXT_COLOR = 36
|
||||
DWMWA_VISIBLE_FRAME_BORDER_THICKNESS = 37
|
||||
)
|
||||
|
||||
type WSAQUERYSET struct {
|
||||
Size uint32
|
||||
ServiceInstanceName *uint16
|
||||
ServiceClassId *GUID
|
||||
Version *WSAVersion
|
||||
Comment *uint16
|
||||
NameSpace uint32
|
||||
NSProviderId *GUID
|
||||
Context *uint16
|
||||
NumberOfProtocols uint32
|
||||
AfpProtocols *AFProtocols
|
||||
QueryString *uint16
|
||||
NumberOfCsAddrs uint32
|
||||
SaBuffer *CSAddrInfo
|
||||
OutputFlags uint32
|
||||
Blob *BLOB
|
||||
}
|
||||
|
||||
type WSAVersion struct {
|
||||
Version uint32
|
||||
EnumerationOfComparison int32
|
||||
}
|
||||
|
||||
type AFProtocols struct {
|
||||
AddressFamily int32
|
||||
Protocol int32
|
||||
}
|
||||
|
||||
type CSAddrInfo struct {
|
||||
LocalAddr SocketAddress
|
||||
RemoteAddr SocketAddress
|
||||
SocketType int32
|
||||
Protocol int32
|
||||
}
|
||||
|
||||
type BLOB struct {
|
||||
Size uint32
|
||||
BlobData *byte
|
||||
}
|
||||
|
27
vendor/golang.org/x/sys/windows/zsyscall_windows.go
generated
vendored
27
vendor/golang.org/x/sys/windows/zsyscall_windows.go
generated
vendored
@ -474,6 +474,9 @@ var (
|
||||
procWSAEnumProtocolsW = modws2_32.NewProc("WSAEnumProtocolsW")
|
||||
procWSAGetOverlappedResult = modws2_32.NewProc("WSAGetOverlappedResult")
|
||||
procWSAIoctl = modws2_32.NewProc("WSAIoctl")
|
||||
procWSALookupServiceBeginW = modws2_32.NewProc("WSALookupServiceBeginW")
|
||||
procWSALookupServiceEnd = modws2_32.NewProc("WSALookupServiceEnd")
|
||||
procWSALookupServiceNextW = modws2_32.NewProc("WSALookupServiceNextW")
|
||||
procWSARecv = modws2_32.NewProc("WSARecv")
|
||||
procWSARecvFrom = modws2_32.NewProc("WSARecvFrom")
|
||||
procWSASend = modws2_32.NewProc("WSASend")
|
||||
@ -4067,6 +4070,30 @@ func WSAIoctl(s Handle, iocc uint32, inbuf *byte, cbif uint32, outbuf *byte, cbo
|
||||
return
|
||||
}
|
||||
|
||||
func WSALookupServiceBegin(querySet *WSAQUERYSET, flags uint32, handle *Handle) (err error) {
|
||||
r1, _, e1 := syscall.Syscall(procWSALookupServiceBeginW.Addr(), 3, uintptr(unsafe.Pointer(querySet)), uintptr(flags), uintptr(unsafe.Pointer(handle)))
|
||||
if r1 == socket_error {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func WSALookupServiceEnd(handle Handle) (err error) {
|
||||
r1, _, e1 := syscall.Syscall(procWSALookupServiceEnd.Addr(), 1, uintptr(handle), 0, 0)
|
||||
if r1 == socket_error {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func WSALookupServiceNext(handle Handle, flags uint32, size *int32, querySet *WSAQUERYSET) (err error) {
|
||||
r1, _, e1 := syscall.Syscall6(procWSALookupServiceNextW.Addr(), 4, uintptr(handle), uintptr(flags), uintptr(unsafe.Pointer(size)), uintptr(unsafe.Pointer(querySet)), 0, 0)
|
||||
if r1 == socket_error {
|
||||
err = errnoErr(e1)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func WSARecv(s Handle, bufs *WSABuf, bufcnt uint32, recvd *uint32, flags *uint32, overlapped *Overlapped, croutine *byte) (err error) {
|
||||
r1, _, e1 := syscall.Syscall9(procWSARecv.Addr(), 7, uintptr(s), uintptr(unsafe.Pointer(bufs)), uintptr(bufcnt), uintptr(unsafe.Pointer(recvd)), uintptr(unsafe.Pointer(flags)), uintptr(unsafe.Pointer(overlapped)), uintptr(unsafe.Pointer(croutine)), 0, 0)
|
||||
if r1 == socket_error {
|
||||
|
2
vendor/golang.org/x/text/encoding/internal/internal.go
generated
vendored
2
vendor/golang.org/x/text/encoding/internal/internal.go
generated
vendored
@ -64,7 +64,7 @@ func (e FuncEncoding) NewEncoder() *encoding.Encoder {
|
||||
// byte.
|
||||
type RepertoireError byte
|
||||
|
||||
// Error implements the error interrface.
|
||||
// Error implements the error interface.
|
||||
func (r RepertoireError) Error() string {
|
||||
return "encoding: rune not supported by encoding."
|
||||
}
|
||||
|
2
vendor/golang.org/x/text/unicode/norm/forminfo.go
generated
vendored
2
vendor/golang.org/x/text/unicode/norm/forminfo.go
generated
vendored
@ -13,7 +13,7 @@ import "encoding/binary"
|
||||
// a rune to a uint16. The values take two forms. For v >= 0x8000:
|
||||
// bits
|
||||
// 15: 1 (inverse of NFD_QC bit of qcInfo)
|
||||
// 13..7: qcInfo (see below). isYesD is always true (no decompostion).
|
||||
// 13..7: qcInfo (see below). isYesD is always true (no decomposition).
|
||||
// 6..0: ccc (compressed CCC value).
|
||||
// For v < 0x8000, the respective rune has a decomposition and v is an index
|
||||
// into a byte array of UTF-8 decomposition sequences and additional info and
|
||||
|
8
vendor/modules.txt
vendored
8
vendor/modules.txt
vendored
@ -559,7 +559,7 @@ golang.org/x/crypto/pbkdf2
|
||||
golang.org/x/crypto/scrypt
|
||||
golang.org/x/crypto/ssh
|
||||
golang.org/x/crypto/ssh/internal/bcrypt_pbkdf
|
||||
# golang.org/x/net v0.7.0
|
||||
# golang.org/x/net v0.8.0
|
||||
## explicit; go 1.17
|
||||
golang.org/x/net/context
|
||||
golang.org/x/net/context/ctxhttp
|
||||
@ -578,7 +578,7 @@ golang.org/x/net/trace
|
||||
## explicit; go 1.17
|
||||
golang.org/x/oauth2
|
||||
golang.org/x/oauth2/internal
|
||||
# golang.org/x/sys v0.5.0
|
||||
# golang.org/x/sys v0.6.0
|
||||
## explicit; go 1.17
|
||||
golang.org/x/sys/cpu
|
||||
golang.org/x/sys/internal/unsafeheader
|
||||
@ -586,10 +586,10 @@ golang.org/x/sys/plan9
|
||||
golang.org/x/sys/unix
|
||||
golang.org/x/sys/windows
|
||||
golang.org/x/sys/windows/registry
|
||||
# golang.org/x/term v0.5.0
|
||||
# golang.org/x/term v0.6.0
|
||||
## explicit; go 1.17
|
||||
golang.org/x/term
|
||||
# golang.org/x/text v0.7.0
|
||||
# golang.org/x/text v0.8.0
|
||||
## explicit; go 1.17
|
||||
golang.org/x/text/cases
|
||||
golang.org/x/text/encoding
|
||||
|
Loading…
Reference in New Issue
Block a user