-
Notifications
You must be signed in to change notification settings - Fork 4.6k
[OSS] security: update go to 1.20.1 #16263
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
Changes from all commits
2a8cdf1
716d162
2c757fa
f81c5d4
ff4f059
31bbca9
2f54191
c263147
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| ```release-note:security | ||
| Upgrade to use Go 1.20.1. | ||
| This resolves vulnerabilities [CVE-2022-41724](https://go.dev/issue/58001) in `crypto/tls` and [CVE-2022-41723](https://go.dev/issue/57855) in `net/http`. | ||
| ``` |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,9 +1,9 @@ | ||
| package consul | ||
|
|
||
| import ( | ||
| "crypto/rand" | ||
| "encoding/base64" | ||
| "fmt" | ||
| "math/rand" | ||
|
||
| "os" | ||
| "strings" | ||
| "testing" | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -40,9 +40,9 @@ func TestCoordinate_Disabled_Response(t *testing.T) { | |
| req, _ := http.NewRequest("PUT", "/should/not/care", nil) | ||
| resp := httptest.NewRecorder() | ||
| obj, err := tt(resp, req) | ||
| if err, ok := err.(HTTPError); ok { | ||
| if err.StatusCode != 401 { | ||
| t.Fatalf("expected status 401 but got %d", err.StatusCode) | ||
| if httpErr, ok := err.(HTTPError); ok { | ||
| if httpErr.StatusCode != 401 { | ||
| t.Fatalf("expected status 401 but got %d", httpErr.StatusCode) | ||
|
||
| } | ||
| } else { | ||
| t.Fatalf("expected HTTP error but got %v", err) | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| ARG GOLANG_VERSION=1.19.2 | ||
| ARG GOLANG_VERSION=1.20.1 | ||
| FROM golang:${GOLANG_VERSION} | ||
|
|
||
| WORKDIR /consul |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -13,7 +13,6 @@ import ( | |
|
|
||
| "github.com/hashicorp/consul/agent" | ||
| consulapi "github.com/hashicorp/consul/api" | ||
| "github.com/hashicorp/consul/lib" | ||
| ) | ||
|
|
||
| // TODO(partitions): split these tests | ||
|
|
@@ -206,8 +205,6 @@ func zip(t *testing.T, k, v []string) map[string]string { | |
| } | ||
|
|
||
| func TestSortByMemberNamePartitionAndSegment(t *testing.T) { | ||
| lib.SeedMathRand() | ||
|
||
|
|
||
| // For the test data we'll give them names that would sort them backwards | ||
| // if we only sorted by name. | ||
| newData := func() []*consulapi.AgentMember { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated to be compatible with go 1.20