Pārlūkot izejas kodu

upgrade golang.org/x/crypto

tags/v2.3.0-rc1
Shivaram Lingamneni 3 gadus atpakaļ
vecāks
revīzija
08834ca511

+ 1
- 1
go.mod Parādīt failu

@@ -17,7 +17,7 @@ require (
17 17
 	github.com/stretchr/testify v1.4.0 // indirect
18 18
 	github.com/tidwall/buntdb v1.1.2
19 19
 	github.com/toorop/go-dkim v0.0.0-20200526084421-76378ae5207e
20
-	golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073
20
+	golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899
21 21
 	golang.org/x/sys v0.0.0-20200523222454-059865788121 // indirect
22 22
 	golang.org/x/text v0.3.2
23 23
 	gopkg.in/yaml.v2 v2.3.0

+ 2
- 0
go.sum Parādīt failu

@@ -59,6 +59,8 @@ github.com/toorop/go-dkim v0.0.0-20200526084421-76378ae5207e/go.mod h1:BzWtXXrXz
59 59
 golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
60 60
 golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073 h1:xMPOj6Pz6UipU1wXLkrtqpHbR0AVFnyPEQq/wRWz9lM=
61 61
 golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
62
+golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899 h1:DZhuSZLsGlFL4CmhA8BcRA0mnthyA/nZ00AqCUo7vHg=
63
+golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
62 64
 golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
63 65
 golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3 h1:0GoQqolDA55aaLxZyTzK/Y2ePZzZTUrRacwib7cNsYQ=
64 66
 golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=

+ 11
- 0
vendor/golang.org/x/crypto/sha3/xor_unaligned.go Parādīt failu

@@ -16,6 +16,17 @@ func (b *storageBuf) asBytes() *[maxRate]byte {
16 16
 	return (*[maxRate]byte)(unsafe.Pointer(b))
17 17
 }
18 18
 
19
+//go:nocheckptr
20
+//
21
+// xorInUnaligned intentionally reads the input buffer as an unaligned slice of
22
+// integers. The language spec is not clear on whether that is allowed.
23
+// See:
24
+// 	https://golang.org/issue/37644
25
+// 	https://golang.org/issue/37298
26
+// 	https://golang.org/issue/35381
27
+
28
+// xorInUnaligned uses unaligned reads and writes to update d.a to contain d.a
29
+// XOR buf.
19 30
 func xorInUnaligned(d *state, buf []byte) {
20 31
 	n := len(buf)
21 32
 	bw := (*[maxRate / 8]uint64)(unsafe.Pointer(&buf[0]))[: n/8 : n/8]

+ 8
- 0
vendor/golang.org/x/crypto/ssh/terminal/terminal.go Parādīt failu

@@ -113,6 +113,7 @@ func NewTerminal(c io.ReadWriter, prompt string) *Terminal {
113 113
 }
114 114
 
115 115
 const (
116
+	keyCtrlC     = 3
116 117
 	keyCtrlD     = 4
117 118
 	keyCtrlU     = 21
118 119
 	keyEnter     = '\r'
@@ -151,8 +152,12 @@ func bytesToKey(b []byte, pasteActive bool) (rune, []byte) {
151 152
 		switch b[0] {
152 153
 		case 1: // ^A
153 154
 			return keyHome, b[1:]
155
+		case 2: // ^B
156
+			return keyLeft, b[1:]
154 157
 		case 5: // ^E
155 158
 			return keyEnd, b[1:]
159
+		case 6: // ^F
160
+			return keyRight, b[1:]
156 161
 		case 8: // ^H
157 162
 			return keyBackspace, b[1:]
158 163
 		case 11: // ^K
@@ -738,6 +743,9 @@ func (t *Terminal) readLine() (line string, err error) {
738 743
 						return "", io.EOF
739 744
 					}
740 745
 				}
746
+				if key == keyCtrlC {
747
+					return "", io.EOF
748
+				}
741 749
 				if key == keyPasteStart {
742 750
 					t.pasteActive = true
743 751
 					if len(t.line) == 0 {

+ 1
- 1
vendor/modules.txt Parādīt failu

@@ -52,7 +52,7 @@ github.com/tidwall/tinyqueue
52 52
 # github.com/toorop/go-dkim v0.0.0-20200526084421-76378ae5207e
53 53
 ## explicit
54 54
 github.com/toorop/go-dkim
55
-# golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073
55
+# golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899
56 56
 ## explicit
57 57
 golang.org/x/crypto/bcrypt
58 58
 golang.org/x/crypto/blowfish

Notiek ielāde…
Atcelt
Saglabāt