Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

all: merge upstream changes #11

Merged
merged 114 commits into from
Jan 8, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
114 commits
Select commit Hold shift + click to select a range
ae2d966
ocsp: add Response.Raw
rolandshoemaker Mar 2, 2022
5352b09
acme/autocert: support External Account Binding (EAB) tokens
benburkert Oct 6, 2021
7b82a4e
all: gofmt
rsc Apr 11, 2022
eb4f295
internal/wycheproof: add ECDH tests, including point decompression
FiloSottile Mar 27, 2022
2cf3ade
internal/wycheproof: skip truncated SHA-512 RSAPSS tests for boring
rolandshoemaker May 6, 2022
c6db032
acme/autocert/internal/acmetest: don't validate in goroutine
rolandshoemaker May 11, 2022
4661260
ssh/agent: fix non-RSA certificates
FiloSottile May 6, 2022
403b017
acme: add AccountKeyRollover
jason-baker May 13, 2022
85d78b3
curve25519/internal/field: update generator to avo v0.4.0
tklauser Mar 1, 2022
6f7dac9
acme: DeactivateReg fix panic
jason-baker May 17, 2022
793ad66
acme/autocert: properly clean DirCache paths
rolandshoemaker May 25, 2022
0559593
curve25519: remove dependency on fmt
aaqaishtyaq Sep 7, 2021
630584e
A+C: delete AUTHORS and CONTRIBUTORS
rsc Jul 22, 2022
04dced1
internal/subtle: rename to internal/alias
rsc Aug 16, 2022
bc19a97
acme: gofmt code with Go 1.19 gofmt
rsc Aug 16, 2022
5757bc0
cryptobyte: add ReadUint64 and AddUint64
hopehook Aug 3, 2022
bd7e27e
ssh/agent: match OpenSSH extensionAgentMsg, not IETF draft
edef1c Jun 14, 2022
c86fa9a
internal/wycheproof: add crypto/ecdh tests
rolandshoemaker Aug 16, 2022
35f4265
all: replace io/ioutil with io and os package
cuishuang Sep 16, 2022
4ba4fb4
acme/autocert: fix renewal timer issue
rolandshoemaker Sep 23, 2022
eccd636
acme/autocert: remove TestRenewFromCache skips
rolandshoemaker Sep 24, 2022
4161e89
all: replace bytes.Compare with bytes.Equal
cuishuang Oct 4, 2022
d6f0a8c
ssh: add ServerConfig.NoClientAuthCallback
bradfitz Mar 23, 2022
9be5aaa
all: fix a few function names on comments
cuishuang Oct 11, 2022
56aed06
all: use automatic RFC linking
Merovius Oct 11, 2022
642fcc3
go.mod: update golang.org/x dependencies
gopherbot Oct 19, 2022
a3485e1
all: use math/bits.RotateLeft
AlexanderYastrebov Oct 24, 2022
334521b
ssh: fix typo
ideapark Nov 3, 2022
183a9b7
go.mod: update golang.org/x dependencies
gopherbot Nov 8, 2022
21d60a1
all: remove redundant type conversion
cuishuang Sep 7, 2022
6fad3df
ssh: support rsa-sha2-256/512 on the server side
FiloSottile Nov 3, 2022
0ec7e83
internal/wycheproof: update Go 1.20 crypto/ecdh API
FiloSottile Nov 16, 2022
2c47667
cryptobyte: add support for ReadASN1Integer into []byte
FiloSottile Nov 17, 2022
eb2c406
go.mod: update golang.org/x dependencies
gopherbot Dec 6, 2022
f495dc3
acme: eliminate arbitrary timeouts in tests
Dec 8, 2022
23edec0
ssh: ensure that handshakeTransport goroutines have finished before C…
Dec 12, 2022
7e3ac20
internal/wycheproof: also use Verify in TestECDSA
rolandshoemaker Nov 28, 2022
bc7d1d1
bcrypt: reject passwords longer than 72 bytes
rolandshoemaker Nov 14, 2022
3d872d0
go.mod: update golang.org/x dependencies
gopherbot Jan 4, 2023
59ff472
all: fix some comments
cuishuang Jan 29, 2023
310bfa4
cryptobyte: reject negative Unwrite argument
AlexanderYastrebov Feb 1, 2023
a9f661c
go.mod: update golang.org/x dependencies
gopherbot Feb 8, 2023
ebe9262
ssh: add support for [email protected]
drakkan Feb 15, 2023
776e461
go.mod: update golang.org/x dependencies
gopherbot Mar 5, 2023
c6a20f9
ssh: document that ParseRawPrivateKey supports Ed25519 keys
nhooyr Jan 24, 2023
9cd0187
curve25519: use crypto/ecdh on Go 1.20
FiloSottile Nov 16, 2022
018c28f
all: fix some comments
cuishuang Mar 20, 2023
00fd4ff
go.mod: update golang.org/x dependencies
gopherbot Apr 6, 2023
1faeef9
cryptobyte: reject Object Identifiers with leading 0x80
mateusz834 Apr 12, 2023
7d6d3f5
ssh/test: skip TestValidTerminalMode on non-Bourne shells
Apr 17, 2023
a8cc953
ssh: skip unsupported tests on wasip1
tklauser Apr 18, 2023
3ef8056
ssh/test: enable on solaris
tklauser Apr 28, 2023
a4e9841
go.mod: update golang.org/x dependencies
gopherbot May 8, 2023
1622238
Add support for "[email protected]"
s-k2 Apr 2, 2020
d0b3160
x509roots: add new module
rolandshoemaker Jan 13, 2023
22c9997
go.mod: tell x repo tagging to ignore dep on net
heschi Jun 12, 2023
8e447d8
go.mod: update golang.org/x dependencies
gopherbot Jun 12, 2023
0ff6005
ssh/test: set a timeout and WaitDelay on sshd subcommands
May 22, 2023
0d502d7
x509roots: use "generate" build tag
rolandshoemaker Jun 20, 2023
043e94c
x509roots: fix generate script argument checking
rolandshoemaker Jun 20, 2023
5fe8145
x509roots: remove list hash and generation date, change ordering
rolandshoemaker Jun 20, 2023
64c3993
ssh: add hmac-sha2-512
stanhu Jun 7, 2023
a9e447d
x509roots/fallback: add //go:build go1.20 to bundle.go
dmitshur Jun 22, 2023
183630a
x509roots: generate a stable sort, for real this time
rolandshoemaker Jun 23, 2023
e984872
go.mod: update golang.org/x dependencies
gopherbot Jul 5, 2023
23b1b90
ssh: prefer sha256 based MAC algorithms
drakkan Jul 1, 2023
64e0e99
ssh: fix RSA certificate and public key authentication with older cli…
drakkan Jun 28, 2023
2e82bdd
fix TestValidTerminalMode: missing output from echo SHELL $SHELL
tg123 Jul 6, 2023
5df3b59
ssh: disable client agent tests on Windows
drakkan Jul 12, 2023
3f8f064
ssh: prefer sha256 based RSA key algorithms
drakkan Jul 1, 2023
12e1fcd
internal/wycheproof: skip all tests in short test mode
dmitshur Jul 18, 2023
d08e19b
x509roots/fallback: update bundle
gopherbot Jul 24, 2023
ddfa821
ssh: ignore invalid MACs and KEXs just like we do for ciphers
drakkan Jul 22, 2023
eab9315
ssh: add diffie-hellman-group16-sha512 kex
drakkan Jun 28, 2023
edc325d
ssh: fix call to Fatalf from a non-test goroutine
drakkan Jul 29, 2023
b4ddeed
go.mod: update golang.org/x dependencies
gopherbot Aug 4, 2023
0d375be
go.mod: update golang.org/x dependencies
gopherbot Sep 3, 2023
c5370d2
ssh: check the declared public key algo against decoded one
drakkan Jun 28, 2023
d359caa
ssh: support for marshaling keys using the OpenSSH format
maraino Feb 8, 2020
e90f1e1
cryptobyte: add uint48 methods
hasheddan Sep 6, 2023
3f0842a
sha3: have ShakeHash extend hash.Hash
mdempsky Sep 10, 2023
28c53ff
ssh: add MultiAlgorithmSigner
drakkan Jul 8, 2023
a1aeb9b
ssh: add test cases for compatibility with old (buggy) clients
drakkan Sep 5, 2023
b665ba6
all: use crypto/ed25519 instead of golang.org/x/crypto/ed25519
thaJeztah Sep 25, 2023
ec07f4e
chacha20: drop Go 1.10 compatibility for arm64
thaJeztah Nov 6, 2022
833695f
ssh: add server side support for [email protected] protocol extension
drakkan Aug 31, 2023
e3cc52e
go.mod: update golang.org/x dependencies
gopherbot Oct 5, 2023
2aeefc3
ssh: add support for SSH_AGENT_CONSTRAIN_EXTENSION with id 255
drakkan Sep 3, 2023
8779cbd
all: update go directive to 1.18
dmitshur Oct 10, 2023
1d57292
x509roots: check HTTP response status code and media type
dmitshur Oct 20, 2023
4f30245
x509roots: catch the zero-roots case when generating the bundle
rolandshoemaker Oct 18, 2023
cf8dcb0
ssh: add test case against ssh CLI
drakkan Jun 28, 2023
74c2ba9
crypto/hkdf: remove useless call to Reset
ericlagergren Aug 12, 2022
df0bc9e
chacha20poly1305: guard PSHUFB usage with GOAMD64_v2
mauri870 Nov 7, 2023
e668aa9
go.mod: update golang.org/x dependencies
gopherbot Nov 8, 2023
42c83ff
ssh: try harder to detect incorrect passwords for legacy PEM encryption
drakkan Oct 31, 2023
eb61739
ssh: allow to configure public key auth algorithms on the server side
drakkan Jul 18, 2023
ff15cd5
ssh: eliminate some goroutine leaks in tests and examples
Nov 9, 2023
a2edfb5
cryptobyte: fix ReadOptionalASN1Boolean
rolandshoemaker Nov 9, 2023
1cf1811
ssh: use the correct token from the client
bodgit Jan 25, 2021
270bf25
curve25519/internal/field/_asm: go mod tidy to fix x/sys version
thaJeztah Nov 9, 2023
1c17e20
ssh: fix certificate authentication with OpenSSH 7.2-7.7
drakkan Jul 16, 2023
b2d7c26
ssh: add (*Client).DialContext method
ydnar Jun 22, 2023
1eadac5
go.mod: update golang.org/x dependencies
gopherbot Nov 27, 2023
325b735
ssh/test: skip TestSSHCLIAuth on Windows
heschi Nov 27, 2023
bda2f3f
argon2: avoid clobbering BP
egonelbre Jul 1, 2021
7e6fbd8
ssh: wrap errors from client handshake
paxan Nov 27, 2023
b8ffc16
blake2b: drop Go 1.6, Go 1.8 compatibility
thaJeztah Nov 9, 2023
fdfe1f8
ssh: defer channel window adjustment
Dec 16, 2022
152cdb1
x509roots/fallback: update bundle
gopherbot Nov 20, 2023
4e5a261
ssh: close net.Conn on all NewServerConn errors
espadolini Dec 12, 2023
9d2ee97
ssh: implement strict KEX protocol changes
rolandshoemaker Nov 20, 2023
08396bb
internal/poly1305: drop Go 1.12 compatibility
thaJeztah Nov 27, 2023
0355684
Merge remote-tracking branch 'upstream/master' into awly/update-latest
awly Jan 3, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
x509roots/fallback: add //go:build go1.20 to bundle.go
Package fallback has no API; its only purpose is to automatically call
x509.SetFallbackRoots with a set of fallback roots. That API was added
in Go 1.20, hence the go1.20 build constraint in fallback.go.

Add that constraint to bundle.go too, so that it fails to build rather
than quietly being a no-op in Go 1.19.

Also simplify Write(fmt.Sprintf()) into fmt.Fprintf while here.

Add a temporary workaround for go.dev/issue/52287.
It has no effect on the public API in this module.

For golang/go#57792.
For golang/go#52287.

Change-Id: I1fe13f7d54b07b0b031e8bae685cffd7a8160165
Reviewed-on: https://go-review.googlesource.com/c/crypto/+/505578
Auto-Submit: Dmitri Shuralyov <[email protected]>
TryBot-Result: Gopher Robot <[email protected]>
Reviewed-by: Dmitri Shuralyov <[email protected]>
Reviewed-by: Roland Shoemaker <[email protected]>
Run-TryBot: Dmitri Shuralyov <[email protected]>
  • Loading branch information
dmitshur authored and gopherbot committed Jun 23, 2023
commit a9e447dde7f8f364232efb5072e3ff89b24308da
2 changes: 2 additions & 0 deletions x509roots/fallback/bundle.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion x509roots/fallback/fallback.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// license that can be found in the LICENSE file.

//go:build go1.20
// +build go1.20

// Package fallback embeds a set of fallback X.509 trusted roots in the
// application by automatically invoking [x509.SetFallbackRoots]. This allows
Expand Down
8 changes: 8 additions & 0 deletions x509roots/fallback/internal/goissue52287/goissue52287.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// 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 goissue52287 is an empty internal package.
// It exists only to work around go.dev/issue/52287 and
// can be removed after Go 1.19 stops being supported.
package goissue52287
14 changes: 8 additions & 6 deletions x509roots/gen_fallback_bundle.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ import (

const tmpl = `// Code generated by gen_fallback_bundle.go; DO NOT EDIT.

//go:build go1.20

package fallback

import "crypto/x509"
Expand All @@ -41,7 +43,7 @@ func mustParse(b []byte) []*x509.Certificate {
break
}
if block.Type != "CERTIFICATE" {
panic("unexpected PEM block type: "+block.Type)
panic("unexpected PEM block type: " + block.Type)
}
cert, err := x509.ParseCertificate(block.Bytes)
if err != nil {
Expand Down Expand Up @@ -97,9 +99,9 @@ func main() {
return string(certs[i].X509.RawSubjectPublicKeyInfo) < string(certs[j].X509.RawSubjectPublicKeyInfo)
})

b := bytes.NewBuffer(nil)
b.Write([]byte(tmpl))
b.Write([]byte("const pemRoots = `\n"))
b := new(bytes.Buffer)
b.WriteString(tmpl)
fmt.Fprintln(b, "const pemRoots = `")
for _, c := range certs {
if len(c.Constraints) > 0 {
// Until the constrained roots API lands, skip anything that has any
Expand All @@ -108,10 +110,10 @@ func main() {
// new version.
continue
}
b.Write([]byte(fmt.Sprintf("# %s\n# %x\n", c.X509.Subject.String(), sha256.Sum256(c.X509.Raw))))
fmt.Fprintf(b, "# %s\n# %x\n", c.X509.Subject.String(), sha256.Sum256(c.X509.Raw))
pem.Encode(b, &pem.Block{Type: "CERTIFICATE", Bytes: c.X509.Raw})
}
b.Write([]byte("`\n"))
fmt.Fprintln(b, "`")

formatted, err := format.Source(b.Bytes())
if err != nil {
Expand Down