forked from TrueCloudLab/rclone
vendor: update all dependencies
This commit is contained in:
parent
17b4058ee9
commit
abb9f89f65
443 changed files with 32118 additions and 18237 deletions
9
vendor/github.com/mattn/go-ieproxy/go.mod
generated
vendored
Normal file
9
vendor/github.com/mattn/go-ieproxy/go.mod
generated
vendored
Normal file
|
@ -0,0 +1,9 @@
|
|||
module github.com/mattn/go-ieproxy
|
||||
|
||||
go 1.14
|
||||
|
||||
require (
|
||||
golang.org/x/net v0.0.0-20191112182307-2180aed22343
|
||||
golang.org/x/sys v0.0.0-20191112214154-59a1497f0cea
|
||||
golang.org/x/text v0.3.2 // indirect
|
||||
)
|
11
vendor/github.com/mattn/go-ieproxy/go.sum
generated
vendored
Normal file
11
vendor/github.com/mattn/go-ieproxy/go.sum
generated
vendored
Normal file
|
@ -0,0 +1,11 @@
|
|||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/net v0.0.0-20191112182307-2180aed22343 h1:00ohfJ4K98s3m6BGUoBd8nyfp4Yl0GoIKvw5abItTjI=
|
||||
golang.org/x/net v0.0.0-20191112182307-2180aed22343/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20191112214154-59a1497f0cea h1:Mz1TMnfJDRJLk8S8OPCoJYgrsp/Se/2TBre2+vwX128=
|
||||
golang.org/x/sys v0.0.0-20191112214154-59a1497f0cea/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs=
|
||||
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
110
vendor/github.com/mattn/go-ieproxy/ieproxy_windows.go
generated
vendored
110
vendor/github.com/mattn/go-ieproxy/ieproxy_windows.go
generated
vendored
|
@ -25,33 +25,62 @@ func getConf() ProxyConf {
|
|||
}
|
||||
|
||||
func writeConf() {
|
||||
var (
|
||||
cfg *tWINHTTP_CURRENT_USER_IE_PROXY_CONFIG
|
||||
err error
|
||||
)
|
||||
proxy := ""
|
||||
proxyByPass := ""
|
||||
autoConfigUrl := ""
|
||||
autoDetect := false
|
||||
|
||||
if cfg, err = getUserConfigFromWindowsSyscall(); err != nil {
|
||||
// Try from IE first.
|
||||
if ieCfg, err := getUserConfigFromWindowsSyscall(); err == nil {
|
||||
defer globalFreeWrapper(ieCfg.lpszProxy)
|
||||
defer globalFreeWrapper(ieCfg.lpszProxyBypass)
|
||||
defer globalFreeWrapper(ieCfg.lpszAutoConfigUrl)
|
||||
|
||||
proxy = StringFromUTF16Ptr(ieCfg.lpszProxy)
|
||||
proxyByPass = StringFromUTF16Ptr(ieCfg.lpszProxyBypass)
|
||||
autoConfigUrl = StringFromUTF16Ptr(ieCfg.lpszAutoConfigUrl)
|
||||
autoDetect = ieCfg.fAutoDetect
|
||||
}
|
||||
|
||||
if proxy == "" { // <- new. Only fallback if we got NO proxy
|
||||
// Try WinHTTP default proxy.
|
||||
if defaultCfg, err := getDefaultProxyConfiguration(); err == nil {
|
||||
defer globalFreeWrapper(defaultCfg.lpszProxy)
|
||||
defer globalFreeWrapper(defaultCfg.lpszProxyBypass)
|
||||
|
||||
// Changed, next 2 lines, so if that if we always set both of these (they are a pair, it doesn't make sense to set one here and keep the value of the other from above)
|
||||
newProxy := StringFromUTF16Ptr(defaultCfg.lpszProxy)
|
||||
if proxy == "" {
|
||||
proxy = newProxy
|
||||
}
|
||||
|
||||
newProxyByPass := StringFromUTF16Ptr(defaultCfg.lpszProxyBypass)
|
||||
if proxyByPass == "" {
|
||||
proxyByPass = newProxyByPass
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if proxy == "" && !autoDetect {
|
||||
// Fall back to IE registry or manual detection if nothing is found there..
|
||||
regedit, _ := readRegedit() // If the syscall fails, backup to manual detection.
|
||||
windowsProxyConf = parseRegedit(regedit)
|
||||
return
|
||||
}
|
||||
|
||||
defer globalFreeWrapper(cfg.lpszProxy)
|
||||
defer globalFreeWrapper(cfg.lpszProxyBypass)
|
||||
defer globalFreeWrapper(cfg.lpszAutoConfigUrl)
|
||||
|
||||
// Setting the proxy settings.
|
||||
windowsProxyConf = ProxyConf{
|
||||
Static: StaticProxyConf{
|
||||
Active: cfg.lpszProxy != nil,
|
||||
Active: len(proxy) > 0,
|
||||
},
|
||||
Automatic: ProxyScriptConf{
|
||||
Active: cfg.lpszAutoConfigUrl != nil || cfg.fAutoDetect,
|
||||
Active: len(autoConfigUrl) > 0 || autoDetect,
|
||||
},
|
||||
}
|
||||
|
||||
if windowsProxyConf.Static.Active {
|
||||
protocol := make(map[string]string)
|
||||
for _, s := range strings.Split(StringFromUTF16Ptr(cfg.lpszProxy), ";") {
|
||||
for _, s := range strings.Split(proxy, ";") {
|
||||
s = strings.TrimSpace(s)
|
||||
if s == "" {
|
||||
continue
|
||||
|
@ -65,31 +94,38 @@ func writeConf() {
|
|||
}
|
||||
|
||||
windowsProxyConf.Static.Protocols = protocol
|
||||
if cfg.lpszProxyBypass != nil {
|
||||
windowsProxyConf.Static.NoProxy = strings.Replace(StringFromUTF16Ptr(cfg.lpszProxyBypass), ";", ",", -1)
|
||||
if len(proxyByPass) > 0 {
|
||||
windowsProxyConf.Static.NoProxy = strings.Replace(proxyByPass, ";", ",", -1)
|
||||
}
|
||||
}
|
||||
|
||||
if windowsProxyConf.Automatic.Active {
|
||||
windowsProxyConf.Automatic.PreConfiguredURL = StringFromUTF16Ptr(cfg.lpszAutoConfigUrl)
|
||||
windowsProxyConf.Automatic.PreConfiguredURL = autoConfigUrl
|
||||
}
|
||||
}
|
||||
|
||||
func getUserConfigFromWindowsSyscall() (*tWINHTTP_CURRENT_USER_IE_PROXY_CONFIG, error) {
|
||||
handle, _, err := winHttpOpen.Call(0, 0, 0, 0, 0)
|
||||
if handle == 0 {
|
||||
return &tWINHTTP_CURRENT_USER_IE_PROXY_CONFIG{}, err
|
||||
if err := winHttpGetIEProxyConfigForCurrentUser.Find(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
defer winHttpCloseHandle.Call(handle)
|
||||
|
||||
config := new(tWINHTTP_CURRENT_USER_IE_PROXY_CONFIG)
|
||||
|
||||
ret, _, err := winHttpGetIEProxyConfigForCurrentUser.Call(uintptr(unsafe.Pointer(config)))
|
||||
if ret > 0 {
|
||||
err = nil
|
||||
p := new(tWINHTTP_CURRENT_USER_IE_PROXY_CONFIG)
|
||||
r, _, err := winHttpGetIEProxyConfigForCurrentUser.Call(uintptr(unsafe.Pointer(p)))
|
||||
if rTrue(r) {
|
||||
return p, nil
|
||||
}
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return config, err
|
||||
func getDefaultProxyConfiguration() (*tWINHTTP_PROXY_INFO, error) {
|
||||
pInfo := new(tWINHTTP_PROXY_INFO)
|
||||
if err := winHttpGetDefaultProxyConfiguration.Find(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
r, _, err := winHttpGetDefaultProxyConfiguration.Call(uintptr(unsafe.Pointer(pInfo)))
|
||||
if rTrue(r) {
|
||||
return pInfo, nil
|
||||
}
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// OverrideEnvWithStaticProxy writes new values to the
|
||||
|
@ -135,7 +171,27 @@ func parseRegedit(regedit regeditValues) ProxyConf {
|
|||
}
|
||||
|
||||
func readRegedit() (values regeditValues, err error) {
|
||||
k, err := registry.OpenKey(registry.CURRENT_USER, `Software\Microsoft\Windows\CurrentVersion\Internet Settings`, registry.QUERY_VALUE)
|
||||
var proxySettingsPerUser uint64 = 1 // 1 is the default value to consider current user
|
||||
k, err := registry.OpenKey(registry.LOCAL_MACHINE, `Software\Policies\Microsoft\Windows\CurrentVersion\Internet Settings`, registry.QUERY_VALUE)
|
||||
if err == nil {
|
||||
//We had used the below variable tempPrxUsrSettings, because the Golang method GetIntegerValue
|
||||
//sets the value to zero even it fails.
|
||||
tempPrxUsrSettings, _, err := k.GetIntegerValue("ProxySettingsPerUser")
|
||||
if err == nil {
|
||||
//consider the value of tempPrxUsrSettings if it is a success
|
||||
proxySettingsPerUser = tempPrxUsrSettings
|
||||
}
|
||||
k.Close()
|
||||
}
|
||||
|
||||
var hkey registry.Key
|
||||
if proxySettingsPerUser == 0 {
|
||||
hkey = registry.LOCAL_MACHINE
|
||||
} else {
|
||||
hkey = registry.CURRENT_USER
|
||||
}
|
||||
|
||||
k, err = registry.OpenKey(hkey, `Software\Microsoft\Windows\CurrentVersion\Internet Settings`, registry.QUERY_VALUE)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
|
4
vendor/github.com/mattn/go-ieproxy/kernel32_data_windows.go
generated
vendored
4
vendor/github.com/mattn/go-ieproxy/kernel32_data_windows.go
generated
vendored
|
@ -13,3 +13,7 @@ func globalFreeWrapper(ptr *uint16) {
|
|||
_, _, _ = globalFree.Call(uintptr(unsafe.Pointer(ptr)))
|
||||
}
|
||||
}
|
||||
|
||||
func rTrue(r uintptr) bool {
|
||||
return r == 1
|
||||
}
|
||||
|
|
1
vendor/github.com/mattn/go-ieproxy/winhttp_data_windows.go
generated
vendored
1
vendor/github.com/mattn/go-ieproxy/winhttp_data_windows.go
generated
vendored
|
@ -7,6 +7,7 @@ var winHttpGetProxyForURL = winHttp.NewProc("WinHttpGetProxyForUrl")
|
|||
var winHttpOpen = winHttp.NewProc("WinHttpOpen")
|
||||
var winHttpCloseHandle = winHttp.NewProc("WinHttpCloseHandle")
|
||||
var winHttpGetIEProxyConfigForCurrentUser = winHttp.NewProc("WinHttpGetIEProxyConfigForCurrentUser")
|
||||
var winHttpGetDefaultProxyConfiguration = winHttp.NewProc("WinHttpGetDefaultProxyConfiguration")
|
||||
|
||||
type tWINHTTP_AUTOPROXY_OPTIONS struct {
|
||||
dwFlags autoProxyFlag
|
||||
|
|
15
vendor/github.com/mattn/go-isatty/.travis.yml
generated
vendored
15
vendor/github.com/mattn/go-isatty/.travis.yml
generated
vendored
|
@ -1,13 +1,14 @@
|
|||
language: go
|
||||
sudo: false
|
||||
go:
|
||||
- 1.13.x
|
||||
- tip
|
||||
|
||||
os:
|
||||
- linux
|
||||
- osx
|
||||
|
||||
before_install:
|
||||
- go get github.com/mattn/goveralls
|
||||
- go get golang.org/x/tools/cmd/cover
|
||||
- go get -t -v ./...
|
||||
|
||||
script:
|
||||
- $HOME/gopath/bin/goveralls -repotoken 3gHdORO5k5ziZcWMBxnd9LrMZaJs8m9x5
|
||||
- ./go.test.sh
|
||||
|
||||
after_success:
|
||||
- bash <(curl -s https://codecov.io/bash)
|
||||
|
|
2
vendor/github.com/mattn/go-isatty/README.md
generated
vendored
2
vendor/github.com/mattn/go-isatty/README.md
generated
vendored
|
@ -1,7 +1,7 @@
|
|||
# go-isatty
|
||||
|
||||
[](http://godoc.org/github.com/mattn/go-isatty)
|
||||
[](https://travis-ci.org/mattn/go-isatty)
|
||||
[](https://codecov.io/gh/mattn/go-isatty)
|
||||
[](https://coveralls.io/github/mattn/go-isatty?branch=master)
|
||||
[](https://goreportcard.com/report/mattn/go-isatty)
|
||||
|
||||
|
|
4
vendor/github.com/mattn/go-isatty/go.mod
generated
vendored
4
vendor/github.com/mattn/go-isatty/go.mod
generated
vendored
|
@ -1,3 +1,5 @@
|
|||
module github.com/mattn/go-isatty
|
||||
|
||||
require golang.org/x/sys v0.0.0-20191008105621-543471e840be
|
||||
go 1.12
|
||||
|
||||
require golang.org/x/sys v0.0.0-20200116001909-b77594299b42
|
||||
|
|
6
vendor/github.com/mattn/go-isatty/go.sum
generated
vendored
6
vendor/github.com/mattn/go-isatty/go.sum
generated
vendored
|
@ -1,4 +1,2 @@
|
|||
golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a h1:aYOabOQFp6Vj6W1F80affTUvO9UxmJRx8K0gsfABByQ=
|
||||
golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191008105621-543471e840be h1:QAcqgptGM8IQBC9K/RC4o+O9YmqEm0diQn9QmZw/0mU=
|
||||
golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20200116001909-b77594299b42 h1:vEOn+mP2zCOVzKckCZy6YsCtDblrpj/w7B9nxGNELpg=
|
||||
golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
|
|
12
vendor/github.com/mattn/go-isatty/go.test.sh
generated
vendored
Normal file
12
vendor/github.com/mattn/go-isatty/go.test.sh
generated
vendored
Normal file
|
@ -0,0 +1,12 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
set -e
|
||||
echo "" > coverage.txt
|
||||
|
||||
for d in $(go list ./... | grep -v vendor); do
|
||||
go test -race -coverprofile=profile.out -covermode=atomic "$d"
|
||||
if [ -f profile.out ]; then
|
||||
cat profile.out >> coverage.txt
|
||||
rm profile.out
|
||||
fi
|
||||
done
|
23
vendor/github.com/mattn/go-isatty/isatty_android.go
generated
vendored
23
vendor/github.com/mattn/go-isatty/isatty_android.go
generated
vendored
|
@ -1,23 +0,0 @@
|
|||
// +build android
|
||||
|
||||
package isatty
|
||||
|
||||
import (
|
||||
"syscall"
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
const ioctlReadTermios = syscall.TCGETS
|
||||
|
||||
// IsTerminal return true if the file descriptor is terminal.
|
||||
func IsTerminal(fd uintptr) bool {
|
||||
var termios syscall.Termios
|
||||
_, _, err := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&termios)), 0, 0, 0)
|
||||
return err == 0
|
||||
}
|
||||
|
||||
// IsCygwinTerminal return true if the file descriptor is a cygwin or msys2
|
||||
// terminal. This is also always false on this environment.
|
||||
func IsCygwinTerminal(fd uintptr) bool {
|
||||
return false
|
||||
}
|
12
vendor/github.com/mattn/go-isatty/isatty_bsd.go
generated
vendored
12
vendor/github.com/mattn/go-isatty/isatty_bsd.go
generated
vendored
|
@ -3,18 +3,12 @@
|
|||
|
||||
package isatty
|
||||
|
||||
import (
|
||||
"syscall"
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
const ioctlReadTermios = syscall.TIOCGETA
|
||||
import "golang.org/x/sys/unix"
|
||||
|
||||
// IsTerminal return true if the file descriptor is terminal.
|
||||
func IsTerminal(fd uintptr) bool {
|
||||
var termios syscall.Termios
|
||||
_, _, err := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&termios)), 0, 0, 0)
|
||||
return err == 0
|
||||
_, err := unix.IoctlGetTermios(int(fd), unix.TIOCGETA)
|
||||
return err == nil
|
||||
}
|
||||
|
||||
// IsCygwinTerminal return true if the file descriptor is a cygwin or msys2
|
||||
|
|
1
vendor/github.com/mattn/go-isatty/isatty_tcgets.go
generated
vendored
1
vendor/github.com/mattn/go-isatty/isatty_tcgets.go
generated
vendored
|
@ -1,6 +1,5 @@
|
|||
// +build linux aix
|
||||
// +build !appengine
|
||||
// +build !android
|
||||
|
||||
package isatty
|
||||
|
||||
|
|
8
vendor/github.com/mattn/go-isatty/renovate.json
generated
vendored
Normal file
8
vendor/github.com/mattn/go-isatty/renovate.json
generated
vendored
Normal file
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"extends": [
|
||||
"config:base"
|
||||
],
|
||||
"postUpdateOptions": [
|
||||
"gomodTidy"
|
||||
]
|
||||
}
|
14
vendor/github.com/mattn/go-runewidth/.travis.yml
generated
vendored
14
vendor/github.com/mattn/go-runewidth/.travis.yml
generated
vendored
|
@ -1,8 +1,16 @@
|
|||
language: go
|
||||
sudo: false
|
||||
go:
|
||||
- 1.13.x
|
||||
- tip
|
||||
|
||||
before_install:
|
||||
- go get github.com/mattn/goveralls
|
||||
- go get golang.org/x/tools/cmd/cover
|
||||
- go get -t -v ./...
|
||||
|
||||
script:
|
||||
- $HOME/gopath/bin/goveralls -repotoken lAKAWPzcGsD3A8yBX3BGGtRUdJ6CaGERL
|
||||
- go generate
|
||||
- git diff --cached --exit-code
|
||||
- ./go.test.sh
|
||||
|
||||
after_success:
|
||||
- bash <(curl -s https://codecov.io/bash)
|
||||
|
|
|
@ -2,7 +2,7 @@ go-runewidth
|
|||
============
|
||||
|
||||
[](https://travis-ci.org/mattn/go-runewidth)
|
||||
[](https://coveralls.io/r/mattn/go-runewidth?branch=HEAD)
|
||||
[](https://codecov.io/gh/mattn/go-runewidth)
|
||||
[](http://godoc.org/github.com/mattn/go-runewidth)
|
||||
[](https://goreportcard.com/report/github.com/mattn/go-runewidth)
|
||||
|
12
vendor/github.com/mattn/go-runewidth/go.test.sh
generated
vendored
Normal file
12
vendor/github.com/mattn/go-runewidth/go.test.sh
generated
vendored
Normal file
|
@ -0,0 +1,12 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
set -e
|
||||
echo "" > coverage.txt
|
||||
|
||||
for d in $(go list ./... | grep -v vendor); do
|
||||
go test -race -coverprofile=profile.out -covermode=atomic "$d"
|
||||
if [ -f profile.out ]; then
|
||||
cat profile.out >> coverage.txt
|
||||
rm profile.out
|
||||
fi
|
||||
done
|
1
vendor/github.com/mattn/go-runewidth/runewidth.go
generated
vendored
1
vendor/github.com/mattn/go-runewidth/runewidth.go
generated
vendored
|
@ -50,7 +50,6 @@ func inTables(r rune, ts ...table) bool {
|
|||
}
|
||||
|
||||
func inTable(r rune, t table) bool {
|
||||
// func (t table) IncludesRune(r rune) bool {
|
||||
if r < t[0].first {
|
||||
return false
|
||||
}
|
||||
|
|
2
vendor/github.com/mattn/go-runewidth/runewidth_table.go
generated
vendored
2
vendor/github.com/mattn/go-runewidth/runewidth_table.go
generated
vendored
|
@ -1,3 +1,5 @@
|
|||
// Code generated by script/generate.go. DO NOT EDIT.
|
||||
|
||||
package runewidth
|
||||
|
||||
var combining = table{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue