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

fix(deps): update module github.com/lestrrat-go/jwx to v2 - autoclosed #1134

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion api/types/oidc.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ package types

import (
"github.com/golang-jwt/jwt/v5"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"
)

// OpenIDConfig is a struct that represents the OpenID Connect configuration.
Expand Down
2 changes: 1 addition & 1 deletion database/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

"github.com/adhocore/gronx"
"github.com/google/go-cmp/cmp"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

api "github.com/go-vela/server/api/types"
"github.com/go-vela/server/api/types/settings"
Expand All @@ -30,7 +30,7 @@
"github.com/go-vela/server/database/service"
dbSettings "github.com/go-vela/server/database/settings"
"github.com/go-vela/server/database/step"
"github.com/go-vela/server/database/testutils"

Check failure on line 33 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L33

could not import github.com/go-vela/server/database/testutils (-: # github.com/go-vela/server/database/testutils
Raw output
database/integration_test.go:33:2: could not import github.com/go-vela/server/database/testutils (-: # github.com/go-vela/server/database/testutils
"github.com/go-vela/server/database/user"
"github.com/go-vela/server/database/worker"
"github.com/go-vela/types/constants"
Expand Down Expand Up @@ -878,18 +878,18 @@
}

for i := 0; i < resources.JWKs.Len(); i++ {
jk, _ := resources.JWKs.Get(i)

Check failure on line 881 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L881

cannot use i (variable of type int) as string value in argument to resources.JWKs.Get (typecheck)
Raw output
database/integration_test.go:881:31: cannot use i (variable of type int) as string value in argument to resources.JWKs.Get (typecheck)
		jk, _ := resources.JWKs.Get(i)
		                            ^

jkPub, _ := jk.(jwk.RSAPublicKey)

err := db.CreateJWK(context.TODO(), jkPub)

Check failure on line 885 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L885

db.CreateJWK undefined (type Interface has no field or method CreateJWK) (typecheck)
Raw output
database/integration_test.go:885:13: db.CreateJWK undefined (type Interface has no field or method CreateJWK) (typecheck)
		err := db.CreateJWK(context.TODO(), jkPub)
		          ^
if err != nil {
t.Errorf("unable to create jwk %s: %v", jkPub.KeyID(), err)
}
}
methods["CreateJWK"] = true

list, err := db.ListJWKs(context.TODO())

Check failure on line 892 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L892

db.ListJWKs undefined (type Interface has no field or method ListJWKs) (typecheck)
Raw output
database/integration_test.go:892:18: db.ListJWKs undefined (type Interface has no field or method ListJWKs) (typecheck)
	list, err := db.ListJWKs(context.TODO())
	                ^
if err != nil {
t.Errorf("unable to list jwks: %v", err)
}
Expand All @@ -901,11 +901,11 @@
methods["ListJWKs"] = true

for i := 0; i < resources.JWKs.Len(); i++ {
jk, _ := resources.JWKs.Get(i)

Check failure on line 904 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L904

cannot use i (variable of type int) as string value in argument to resources.JWKs.Get (typecheck)
Raw output
database/integration_test.go:904:31: cannot use i (variable of type int) as string value in argument to resources.JWKs.Get (typecheck)
		jk, _ := resources.JWKs.Get(i)
		                            ^

jkPub, _ := jk.(jwk.RSAPublicKey)

got, err := db.GetActiveJWK(context.TODO(), jkPub.KeyID())

Check failure on line 908 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L908

db.GetActiveJWK undefined (type Interface has no field or method GetActiveJWK) (typecheck)
Raw output
database/integration_test.go:908:18: db.GetActiveJWK undefined (type Interface has no field or method GetActiveJWK) (typecheck)
		got, err := db.GetActiveJWK(context.TODO(), jkPub.KeyID())
		               ^
if err != nil {
t.Errorf("unable to get jwk %s: %v", jkPub.KeyID(), err)
}
Expand All @@ -917,17 +917,17 @@

methods["GetActiveJWK"] = true

err = db.RotateKeys(context.TODO())

Check failure on line 920 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L920

db.RotateKeys undefined (type Interface has no field or method RotateKeys) (typecheck)
Raw output
database/integration_test.go:920:11: db.RotateKeys undefined (type Interface has no field or method RotateKeys) (typecheck)
	err = db.RotateKeys(context.TODO())
	         ^
if err != nil {
t.Errorf("unable to rotate keys: %v", err)
}

for i := 0; i < resources.JWKs.Len(); i++ {
jk, _ := resources.JWKs.Get(i)

Check failure on line 926 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L926

cannot use i (variable of type int) as string value in argument to resources.JWKs.Get (typecheck)
Raw output
database/integration_test.go:926:31: cannot use i (variable of type int) as string value in argument to resources.JWKs.Get (typecheck)
		jk, _ := resources.JWKs.Get(i)
		                            ^

jkPub, _ := jk.(jwk.RSAPublicKey)

_, err := db.GetActiveJWK(context.TODO(), jkPub.KeyID())

Check failure on line 930 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L930

db.GetActiveJWK undefined (type Interface has no field or method GetActiveJWK) (typecheck)
Raw output
database/integration_test.go:930:16: db.GetActiveJWK undefined (type Interface has no field or method GetActiveJWK) (typecheck)
		_, err := db.GetActiveJWK(context.TODO(), jkPub.KeyID())
		             ^
if err == nil {
t.Errorf("GetActiveJWK() should return err after rotation")
}
Expand Down Expand Up @@ -2576,8 +2576,8 @@
jwkTwo := testutils.JWK()

jwkSet := jwk.NewSet()
jwkSet.Add(jwkOne)

Check failure on line 2579 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L2579

jwkSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
Raw output
database/integration_test.go:2579:9: jwkSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
	jwkSet.Add(jwkOne)
	       ^
jwkSet.Add(jwkTwo)

Check failure on line 2580 in database/integration_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/integration_test.go#L2580

jwkSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
Raw output
database/integration_test.go:2580:9: jwkSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
	jwkSet.Add(jwkTwo)
	       ^

logServiceOne := new(library.Log)
logServiceOne.SetID(1)
Expand Down
2 changes: 1 addition & 1 deletion database/jwk/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"context"
"database/sql"

"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"
"github.com/sirupsen/logrus"

"github.com/go-vela/server/constants"
Expand Down
2 changes: 1 addition & 1 deletion database/jwk/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package jwk
import (
"context"

"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

"github.com/go-vela/server/constants"
"github.com/go-vela/server/database/types"
Expand Down
2 changes: 1 addition & 1 deletion database/jwk/get_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (

"github.com/DATA-DOG/go-sqlmock"
"github.com/google/go-cmp/cmp"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

"github.com/go-vela/server/database/testutils"
)
Expand Down
2 changes: 1 addition & 1 deletion database/jwk/interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package jwk
import (
"context"

"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"
)

// JWKInterface represents the Vela interface for JWK
Expand Down
2 changes: 1 addition & 1 deletion database/jwk/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import (
"context"

"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

"github.com/go-vela/server/constants"
"github.com/go-vela/server/database/types"
Expand Down Expand Up @@ -33,7 +33,7 @@
tmp := key

// convert query result to API type
keySet.Add(tmp.ToAPI())

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/jwk/list.go#L36

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)) (typecheck)
Raw output
database/jwk/list.go:36:10: keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)) (typecheck)
	"github.com/go-vela/server/database/jwk"
	^

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/jwk/list.go#L36

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
Raw output
database/jwk/list.go:36:10: keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
		keySet.Add(tmp.ToAPI())
		       ^

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / build

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / build

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / validate

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / validate

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / database_sql

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / test

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / test

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / database_postgres (postgres:15-alpine)

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / database_postgres (postgres:16-alpine)

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)

Check failure on line 36 in database/jwk/list.go

View workflow job for this annotation

GitHub Actions / Analyze (go)

keySet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add)
}

return keySet, nil
Expand Down
2 changes: 1 addition & 1 deletion database/jwk/list_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"testing"

"github.com/DATA-DOG/go-sqlmock"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

"github.com/go-vela/server/database/testutils"
)
Expand Down Expand Up @@ -54,8 +54,8 @@
}

wantSet := jwk.NewSet()
wantSet.Add(_jwkOne)

Check failure on line 57 in database/jwk/list_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/jwk/list_test.go#L57

wantSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
Raw output
database/jwk/list_test.go:57:10: wantSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
	wantSet.Add(_jwkOne)
	        ^
wantSet.Add(_jwkTwo)

Check failure on line 58 in database/jwk/list_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/jwk/list_test.go#L58

wantSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
Raw output
database/jwk/list_test.go:58:10: wantSet.Add undefined (type "github.com/lestrrat-go/jwx/v2/jwk".Set has no field or method Add) (typecheck)
	wantSet.Add(_jwkTwo)
	        ^

// setup tests
tests := []struct {
Expand Down
2 changes: 1 addition & 1 deletion database/testutils/api_resources.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// SPDX-License-Identifier: Apache-2.0

Check failure on line 1 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/testutils/api_resources.go#L1

: # github.com/go-vela/server/database/testutils
Raw output
database/testutils/api_resources.go:1: : # github.com/go-vela/server/database/testutils

package testutils

Expand All @@ -7,7 +7,7 @@
"crypto/rsa"

"github.com/google/uuid"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

api "github.com/go-vela/server/api/types"
"github.com/go-vela/server/api/types/actions"
Expand Down Expand Up @@ -288,7 +288,7 @@
return nil
}

j := jwk.NewRSAPublicKey()

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/testutils/api_resources.go#L291

undefined: jwk.NewRSAPublicKey (typecheck)
Raw output
database/testutils/api_resources.go:291:11: undefined: jwk.NewRSAPublicKey (typecheck)
// SPDX-License-Identifier: Apache-2.0

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/testutils/api_resources.go#L291

undefined: jwk.NewRSAPublicKey) (typecheck)
Raw output
database/testutils/api_resources.go:291:11: undefined: jwk.NewRSAPublicKey) (typecheck)
	"github.com/go-vela/server/database/testutils"
	^

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/testutils/api_resources.go#L291

undefined: jwk.NewRSAPublicKey) (typecheck)
Raw output
database/testutils/api_resources.go:291:11: undefined: jwk.NewRSAPublicKey) (typecheck)
	"github.com/go-vela/server/database/testutils"
	^

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] database/testutils/api_resources.go#L291

undefined: jwk.NewRSAPublicKey) (typecheck)
Raw output
database/testutils/api_resources.go:291:11: undefined: jwk.NewRSAPublicKey) (typecheck)
	"github.com/go-vela/server/database/testutils"
	^

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / validate

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / validate

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / database_sql

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / test

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / test

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / database_postgres (postgres:15-alpine)

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / database_postgres (postgres:16-alpine)

undefined: jwk.NewRSAPublicKey

Check failure on line 291 in database/testutils/api_resources.go

View workflow job for this annotation

GitHub Actions / Analyze (go)

undefined: jwk.NewRSAPublicKey
_ = j.FromRaw(&privateRSAKey.PublicKey)

_ = j.Set(jwk.KeyIDKey, kid.String())
Expand Down
2 changes: 1 addition & 1 deletion database/testutils/mock_args.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"time"

"github.com/google/go-cmp/cmp"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"
)

// This will be used with the github.com/DATA-DOG/go-sqlmock library to compare values
Expand Down
2 changes: 1 addition & 1 deletion database/types/jwk.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"errors"

"github.com/google/uuid"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"
)

var (
Expand Down
5 changes: 3 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,12 @@ require (
github.com/cloudwego/iasm v0.2.0 // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect
github.com/go-jose/go-jose/v4 v4.0.1 // indirect
github.com/lestrrat-go/backoff/v2 v2.0.8 // indirect
github.com/lestrrat-go/blackmagic v1.0.2 // indirect
github.com/lestrrat-go/httpcc v1.0.1 // indirect
github.com/lestrrat-go/httprc v1.0.5 // indirect
github.com/lestrrat-go/iter v1.0.2 // indirect
github.com/lestrrat-go/option v1.0.1 // indirect
github.com/segmentio/asm v1.2.0 // indirect
)

require (
Expand Down Expand Up @@ -104,7 +105,7 @@ require (
github.com/klauspost/cpuid/v2 v2.2.7 // indirect
github.com/kr/text v0.2.0 // indirect
github.com/leodido/go-urn v1.4.0 // indirect
github.com/lestrrat-go/jwx v1.2.29
github.com/lestrrat-go/jwx/v2 v2.0.21
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mattn/go-sqlite3 v1.14.17 // indirect
github.com/mitchellh/copystructure v1.0.0 // indirect
Expand Down
30 changes: 6 additions & 24 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ3
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo=
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs=
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0=
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/rVNCu3HqELle0jiPLLBs70cWOduZpkS1E78=
Expand Down Expand Up @@ -183,17 +182,16 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/leodido/go-urn v1.4.0 h1:WT9HwE9SGECu3lg4d/dIA+jxlljEa1/ffXKmRjqdmIQ=
github.com/leodido/go-urn v1.4.0/go.mod h1:bvxc+MVxLKB4z00jd1z+Dvzr47oO32F/QSNjSBOlFxI=
github.com/lestrrat-go/backoff/v2 v2.0.8 h1:oNb5E5isby2kiro9AgdHLv5N5tint1AnDVVf2E2un5A=
github.com/lestrrat-go/backoff/v2 v2.0.8/go.mod h1:rHP/q/r9aT27n24JQLa7JhSQZCKBBOiM/uP402WwN8Y=
github.com/lestrrat-go/blackmagic v1.0.2 h1:Cg2gVSc9h7sz9NOByczrbUvLopQmXrfFx//N+AkAr5k=
github.com/lestrrat-go/blackmagic v1.0.2/go.mod h1:UrEqBzIR2U6CnzVyUtfM6oZNMt/7O7Vohk2J0OGSAtU=
github.com/lestrrat-go/httpcc v1.0.1 h1:ydWCStUeJLkpYyjLDHihupbn2tYmZ7m22BGkcvZZrIE=
github.com/lestrrat-go/httpcc v1.0.1/go.mod h1:qiltp3Mt56+55GPVCbTdM9MlqhvzyuL6W/NMDA8vA5E=
github.com/lestrrat-go/httprc v1.0.5 h1:bsTfiH8xaKOJPrg1R+E3iE/AWZr/x0Phj9PBTG/OLUk=
github.com/lestrrat-go/httprc v1.0.5/go.mod h1:mwwz3JMTPBjHUkkDv/IGJ39aALInZLrhBp0X7KGUZlo=
github.com/lestrrat-go/iter v1.0.2 h1:gMXo1q4c2pHmC3dn8LzRhJfP1ceCbgSiT9lUydIzltI=
github.com/lestrrat-go/iter v1.0.2/go.mod h1:Momfcq3AnRlRjI5b5O8/G5/BvpzrhoFTZcn06fEOPt4=
github.com/lestrrat-go/jwx v1.2.29 h1:QT0utmUJ4/12rmsVQrJ3u55bycPkKqGYuGT4tyRhxSQ=
github.com/lestrrat-go/jwx v1.2.29/go.mod h1:hU8k2l6WF0ncx20uQdOmik/Gjg6E3/wIRtXSNFeZuB8=
github.com/lestrrat-go/option v1.0.0/go.mod h1:5ZHFbivi4xwXxhxY9XHDe2FHo6/Z7WWmtT7T5nBBp3I=
github.com/lestrrat-go/jwx/v2 v2.0.21 h1:jAPKupy4uHgrHFEdjVjNkUgoBKtVDgrQPB/h55FHrR0=
github.com/lestrrat-go/jwx/v2 v2.0.21/go.mod h1:09mLW8zto6bWL9GbwnqAli+ArLf+5M33QLQPDggkUWM=
github.com/lestrrat-go/option v1.0.1 h1:oAzP2fvZGQKWkvHa1/SAcFolBEca1oN+mQ7eooNBEYU=
github.com/lestrrat-go/option v1.0.1/go.mod h1:5ZHFbivi4xwXxhxY9XHDe2FHo6/Z7WWmtT7T5nBBp3I=
github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw=
Expand Down Expand Up @@ -253,6 +251,8 @@ github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD
github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/ryanuber/go-glob v1.0.0 h1:iQh3xXAumdQ+4Ufa5b25cRpC5TYKlno6hsv6Cb3pkBk=
github.com/ryanuber/go-glob v1.0.0/go.mod h1:807d1WSdnB0XRJzKNil9Om6lcp/3a0v4qIHxIXzX/Yc=
github.com/segmentio/asm v1.2.0 h1:9BQrFxC+YOHJlTlHGkTrFWf59nbL3XnCoFLTwDCI7ys=
github.com/segmentio/asm v1.2.0/go.mod h1:BqMnlJP91P8d+4ibuonYZw9mfnzI9HfxselHZr5aAcs=
github.com/shopspring/decimal v1.2.0 h1:abSATXmQEYyShuxI4/vyW3tV1MrKAJzCZ/0zLUXYbsQ=
github.com/shopspring/decimal v1.2.0/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFRcu2hWCYk4o=
github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ=
Expand Down Expand Up @@ -301,14 +301,11 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.3.0/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4=
golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU=
golang.org/x/crypto v0.21.0/go.mod h1:0BP7YvVV9gBbVKyeTG0Gyn+gZm94bibOW5BjDEYAOMs=
golang.org/x/crypto v0.24.0 h1:mnl8DM0o513X8fdIkmyFE/5hTYxbwYOjDS/+rK6qpRI=
golang.org/x/crypto v0.24.0/go.mod h1:Z1PMYSOR5nyMcyAVAIQSKCDwalqy85Aqn1x3Ws4L5DM=
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4=
golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
Expand All @@ -317,9 +314,6 @@ golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwY
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY=
golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg=
golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44=
golang.org/x/net v0.25.0 h1:d/OCCoBEUq33pjydKrGQhw7IlUPI2Oylr+8qLx49kac=
golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM=
golang.org/x/oauth2 v0.21.0 h1:tsimM75w1tF/uws5rbeHzIWxEqElMehnc+iW793zsZs=
Expand All @@ -328,7 +322,6 @@ golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJ
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M=
golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
Expand All @@ -344,25 +337,15 @@ golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.21.0 h1:rF+pYz3DAGSQAxAu1CbC7catZg4ebC4UIeIhKxBZvws=
golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
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.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc=
golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k=
golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo=
golang.org/x/term v0.17.0/go.mod h1:lLRBjIVuehSbZlaOtGMbcMncT+aqLLLmKrsjNrUguwk=
golang.org/x/term v0.18.0/go.mod h1:ILwASektA3OnRv7amZ1xhE/KTR+u50pbXfZ03+6Nx58=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.3/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.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8=
golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU=
golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4=
golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI=
golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk=
Expand All @@ -372,7 +355,6 @@ golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtn
golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc=
golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
Expand Down
2 changes: 1 addition & 1 deletion internal/token/generate_rsa.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"crypto/rsa"

"github.com/google/uuid"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

"github.com/go-vela/server/database"
)
Expand All @@ -27,7 +27,7 @@
return err
}

j := jwk.NewRSAPublicKey()

Check failure on line 30 in internal/token/generate_rsa.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] internal/token/generate_rsa.go#L30

undefined: jwk.NewRSAPublicKey (typecheck)
Raw output
internal/token/generate_rsa.go:30:11: undefined: jwk.NewRSAPublicKey (typecheck)
	j := jwk.NewRSAPublicKey()
	         ^

err = j.FromRaw(&privateRSAKey.PublicKey)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion mock/server/authentication.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"net/http"

"github.com/gin-gonic/gin"
"github.com/lestrrat-go/jwx/jwk"
"github.com/lestrrat-go/jwx/v2/jwk"

api "github.com/go-vela/server/api/types"
"github.com/go-vela/types"
Expand Down
Loading