Skip to content

Commit

Permalink
Prepare for a new release
Browse files Browse the repository at this point in the history
  • Loading branch information
orlangure committed Aug 11, 2021
1 parent 80b3e57 commit 19e40ca
Show file tree
Hide file tree
Showing 16 changed files with 31 additions and 22 deletions.
2 changes: 1 addition & 1 deletion cmd/jwt/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"regexp"
"strings"

jwt "github.com/dgrijalva/jwt-go"
jwt "github.com/akeylesslabs/jwt-go/v3"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion ecdsa_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"
"testing"

"github.com/dgrijalva/jwt-go"
"github.com/akeylesslabs/jwt-go/v3"
)

var ecdsaTestData = []struct {
Expand Down
3 changes: 2 additions & 1 deletion example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@ package jwt_test

import (
"fmt"
"github.com/dgrijalva/jwt-go"
"time"

"github.com/akeylesslabs/jwt-go/v3"
)

// Example (atypical) using the StandardClaims type by itself to parse a token.
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/dgrijalva/jwt-go
module github.com/akeylesslabs/jwt-go/v3

go 1.15
go 1.16
Empty file added go.sum
Empty file.
5 changes: 3 additions & 2 deletions hmac_example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package jwt_test

import (
"fmt"
"github.com/dgrijalva/jwt-go"
"io/ioutil"
"time"

"github.com/akeylesslabs/jwt-go/v3"
)

// For HMAC signing method, the key can be any []byte. It is recommended to generate
Expand Down Expand Up @@ -51,7 +52,7 @@ func ExampleParse_hmac() {
if _, ok := token.Method.(*jwt.SigningMethodHMAC); !ok {
return nil, fmt.Errorf("Unexpected signing method: %v", token.Header["alg"])
}

// hmacSampleSecret is a []byte containing your secret, e.g. []byte("my_secret_key")
return hmacSampleSecret, nil
})
Expand Down
3 changes: 2 additions & 1 deletion hmac_test.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
package jwt_test

import (
"github.com/dgrijalva/jwt-go"
"io/ioutil"
"strings"
"testing"

"github.com/akeylesslabs/jwt-go/v3"
)

var hmacTestData = []struct {
Expand Down
5 changes: 3 additions & 2 deletions http_example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ import (
"bytes"
"crypto/rsa"
"fmt"
"github.com/dgrijalva/jwt-go"
"github.com/dgrijalva/jwt-go/request"
"io"
"io/ioutil"
"log"
Expand All @@ -17,6 +15,9 @@ import (
"net/url"
"strings"
"time"

"github.com/akeylesslabs/jwt-go/v3"
"github.com/akeylesslabs/jwt-go/v3/request"
)

// location of the files used for signing and verification
Expand Down
3 changes: 2 additions & 1 deletion none_test.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package jwt_test

import (
"github.com/dgrijalva/jwt-go"
"strings"
"testing"

"github.com/akeylesslabs/jwt-go/v3"
)

var noneTestData = []struct {
Expand Down
4 changes: 2 additions & 2 deletions parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"testing"
"time"

"github.com/dgrijalva/jwt-go"
"github.com/dgrijalva/jwt-go/test"
"github.com/akeylesslabs/jwt-go/v3"
"github.com/akeylesslabs/jwt-go/v3/test"
)

var keyFuncError error = fmt.Errorf("error loading key")
Expand Down
3 changes: 2 additions & 1 deletion request/request.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
package request

import (
"github.com/dgrijalva/jwt-go"
"net/http"

"github.com/akeylesslabs/jwt-go/v3"
)

// Extract and parse a JWT token from an HTTP request.
Expand Down
5 changes: 3 additions & 2 deletions request/request_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@ package request

import (
"fmt"
"github.com/dgrijalva/jwt-go"
"github.com/dgrijalva/jwt-go/test"
"net/http"
"net/url"
"reflect"
"strings"
"testing"

"github.com/akeylesslabs/jwt-go/v3"
"github.com/akeylesslabs/jwt-go/v3/test"
)

var requestTestData = []struct {
Expand Down
2 changes: 1 addition & 1 deletion rsa_pss.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ type SigningMethodRSAPSS struct {
// VerifyOptions is optional. If set overrides Options for rsa.VerifyPPS.
// Used to accept tokens signed with rsa.PSSSaltLengthAuto, what doesn't follow
// https://tools.ietf.org/html/rfc7518#section-3.5 but was used previously.
// See https://github.com/dgrijalva/jwt-go/issues/285#issuecomment-437451244 for details.
// See https://github.com/akeylesslabs/jwt-go/v3/issues/285#issuecomment-437451244 for details.
VerifyOptions *rsa.PSSOptions
}

Expand Down
6 changes: 3 additions & 3 deletions rsa_pss_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import (
"testing"
"time"

"github.com/dgrijalva/jwt-go"
"github.com/dgrijalva/jwt-go/test"
"github.com/akeylesslabs/jwt-go/v3"
"github.com/akeylesslabs/jwt-go/v3/test"
)

var rsaPSSTestData = []struct {
Expand Down Expand Up @@ -106,7 +106,7 @@ func TestRSAPSSSaltLengthCompatibility(t *testing.T) {
},
}

// Behaves as before https://github.com/dgrijalva/jwt-go/issues/285 fix.
// Behaves as before https://github.com/akeylesslabs/jwt-go/v3/issues/285 fix.
ps256SaltLengthAuto := &jwt.SigningMethodRSAPSS{
SigningMethodRSA: jwt.SigningMethodPS256.SigningMethodRSA,
Options: &rsa.PSSOptions{
Expand Down
3 changes: 2 additions & 1 deletion rsa_test.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
package jwt_test

import (
"github.com/dgrijalva/jwt-go"
"io/ioutil"
"strings"
"testing"

"github.com/akeylesslabs/jwt-go/v3"
)

var rsaTestData = []struct {
Expand Down
3 changes: 2 additions & 1 deletion test/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@ package test

import (
"crypto/rsa"
"github.com/dgrijalva/jwt-go"
"io/ioutil"

"github.com/akeylesslabs/jwt-go/v3"
)

func LoadRSAPrivateKeyFromDisk(location string) *rsa.PrivateKey {
Expand Down

0 comments on commit 19e40ca

Please sign in to comment.