Skip to content

Commit 60cd89e

Browse files
Bump golang.org/x/net from 0.37.0 to 0.38.0 (#26)
* Bump golang.org/x/net from 0.37.0 to 0.38.0 Bumps [golang.org/x/net](https://github.com/golang/net) from 0.37.0 to 0.38.0. - [Commits](golang/net@v0.37.0...v0.38.0) --- updated-dependencies: - dependency-name: golang.org/x/net dependency-version: 0.38.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * Bump dependencies --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: nhatthm <[email protected]>
1 parent 9601199 commit 60cd89e

File tree

5 files changed

+69
-51
lines changed

5 files changed

+69
-51
lines changed

.golangci.yaml

Lines changed: 53 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,71 @@
1-
# See https://github.com/golangci/golangci-lint/blob/master/.golangci.example.yml
1+
version: "2"
22
run:
33
tests: true
4-
5-
linters-settings:
6-
errcheck:
7-
check-type-assertions: true
8-
check-blank: true
9-
gocyclo:
10-
min-complexity: 20
11-
dupl:
12-
threshold: 100
13-
misspell:
14-
locale: US
15-
164
linters:
17-
enable-all: true
5+
default: all
186
disable:
197
- depguard
208
- exhaustruct
219
- forbidigo
22-
- gci
2310
- gochecknoglobals
2411
- ireturn
2512
- lll
2613
- mnd
27-
- nolintlint # https://github.com/golangci/golangci-lint/issues/3063
14+
- nolintlint
2815
- nonamedreturns
2916
- rowserrcheck
3017
- tagliatelle
31-
- tenv
3218
- testifylint
3319
- varnamelen
3420
- wastedassign
3521
- wrapcheck
36-
37-
issues:
38-
exclude-use-default: false
39-
exclude-files:
40-
- dummy_publicsuffix_test.go
41-
- example_test.go
42-
- jar.go
43-
- jar_test.go
44-
- punycode.go
45-
- punycode_test.go
46-
exclude-dirs:
47-
- internal/ascii
48-
exclude-rules:
49-
- linters:
50-
- dupl
51-
- err113
52-
- funlen
53-
- goconst
54-
- goerr113
55-
- mnd
56-
- noctx
57-
path: "_test.go"
22+
settings:
23+
dupl:
24+
threshold: 100
25+
errcheck:
26+
check-type-assertions: true
27+
check-blank: true
28+
gocyclo:
29+
min-complexity: 20
30+
misspell:
31+
locale: US
32+
exclusions:
33+
generated: lax
34+
rules:
35+
- linters:
36+
- dupl
37+
- err113
38+
- funlen
39+
- goconst
40+
- mnd
41+
- noctx
42+
path: _test.go
43+
paths:
44+
- dummy_publicsuffix_test.go
45+
- example_test.go
46+
- jar.go
47+
- jar_test.go
48+
- punycode.go
49+
- punycode_test.go
50+
- internal/ascii
51+
- third_party$
52+
- builtin$
53+
- examples$
54+
formatters:
55+
enable:
56+
- gofmt
57+
- gofumpt
58+
- goimports
59+
exclusions:
60+
generated: lax
61+
paths:
62+
- dummy_publicsuffix_test.go
63+
- example_test.go
64+
- jar.go
65+
- jar_test.go
66+
- punycode.go
67+
- punycode_test.go
68+
- internal/ascii
69+
- third_party$
70+
- builtin$
71+
- examples$

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ MODULE_NAME = cookiejar
33
VENDOR_DIR = vendor
44
GITHUB_OUTPUT ?= /dev/null
55

6-
GOLANGCI_LINT_VERSION ?= v1.64.7
6+
GOLANGCI_LINT_VERSION ?= v2.0.2
77
MOCKERY_VERSION ?= v2.53.2
88

99
GO ?= go

go.mod

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ require (
1515
require (
1616
github.com/bool64/shared v0.1.5 // indirect
1717
github.com/davecgh/go-spew v1.1.1 // indirect
18-
github.com/fsnotify/fsnotify v1.8.0 // indirect
18+
github.com/fsnotify/fsnotify v1.9.0 // indirect
1919
github.com/iancoleman/orderedmap v0.3.0 // indirect
2020
github.com/kr/text v0.2.0 // indirect
2121
github.com/mattn/go-isatty v0.0.20 // indirect
@@ -25,8 +25,8 @@ require (
2525
github.com/stretchr/objx v0.5.2 // indirect
2626
github.com/yudai/gojsondiff v1.0.0 // indirect
2727
github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82 // indirect
28-
golang.org/x/net v0.37.0 // indirect
29-
golang.org/x/sys v0.31.0 // indirect
30-
golang.org/x/text v0.23.0 // indirect
28+
golang.org/x/net v0.39.0 // indirect
29+
golang.org/x/sys v0.32.0 // indirect
30+
golang.org/x/text v0.24.0 // indirect
3131
gopkg.in/yaml.v3 v3.0.1 // indirect
3232
)

go.sum

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs
1111
github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw=
1212
github.com/fsnotify/fsnotify v1.8.0 h1:dAwr6QBTBZIkG8roQaJjGof0pp0EeF+tNV7YBP3F/8M=
1313
github.com/fsnotify/fsnotify v1.8.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0=
14+
github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S9k=
15+
github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0=
1416
github.com/iancoleman/orderedmap v0.3.0 h1:5cbR2grmZR/DiVt+VJopEhtVs9YGInGIxAoMJn+Ichc=
1517
github.com/iancoleman/orderedmap v0.3.0/go.mod h1:XuLcCUkdL5owUCQeF2Ue9uuw1EptkJDkXXS7VoV7XGE=
1618
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
@@ -56,14 +58,18 @@ github.com/yudai/pp v2.0.1+incompatible h1:Q4//iY4pNF6yPLZIigmvcl7k/bPgrcTPIFIcm
5658
github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc=
5759
go.nhat.io/aferomock v0.8.0 h1:jESv25NuTpA/Wga+AOKqKI1lPKdYiBYvxpIUDJWyfPM=
5860
go.nhat.io/aferomock v0.8.0/go.mod h1:thJD/9Yeo+CcIW45u6rNU8WYc1yIWdqfOSpKcGtjAXw=
59-
golang.org/x/net v0.37.0 h1:1zLorHbz+LYj7MQlSf1+2tPIIgibq2eL5xkrGk6f+2c=
60-
golang.org/x/net v0.37.0/go.mod h1:ivrbrMbzFq5J41QOQh0siUuly180yBYtLp+CKbEaFx8=
61+
golang.org/x/net v0.38.0 h1:vRMAPTMaeGqVhG5QyLJHqNDwecKTomGeqbnfZyKlBI8=
62+
golang.org/x/net v0.38.0/go.mod h1:ivrbrMbzFq5J41QOQh0siUuly180yBYtLp+CKbEaFx8=
63+
golang.org/x/net v0.39.0 h1:ZCu7HMWDxpXpaiKdhzIfaltL9Lp31x/3fCP11bc6/fY=
64+
golang.org/x/net v0.39.0/go.mod h1:X7NRbYVEA+ewNkCNyJ513WmMdQ3BineSwVtN2zD/d+E=
6165
golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
6266
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
6367
golang.org/x/sys v0.31.0 h1:ioabZlmFYtWhL+TRYpcnNlLwhyxaM9kWTDEmfnprqik=
6468
golang.org/x/sys v0.31.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
65-
golang.org/x/text v0.23.0 h1:D71I7dUrlY+VX0gQShAThNGHFxZ13dGLBHQLVl1mJlY=
66-
golang.org/x/text v0.23.0/go.mod h1:/BLNzu4aZCJ1+kcD0DNRotWKage4q2rGVAg4o22unh4=
69+
golang.org/x/sys v0.32.0 h1:s77OFDvIQeibCmezSnk/q6iAfkdiQaJi4VzroCFrN20=
70+
golang.org/x/sys v0.32.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
71+
golang.org/x/text v0.24.0 h1:dd5Bzh4yt5KYA8f9CJHCP4FB4D51c2c6JvN37xJJkJ0=
72+
golang.org/x/text v0.24.0/go.mod h1:L8rBsPeo2pSS+xqN0d5u2ikmjtmoJbDBT1b7nHvFCdU=
6773
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
6874
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
6975
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=

jar.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -501,9 +501,7 @@ func (j *Jar) domainAndType(host, domain string) (string, bool, error) {
501501
// From here on: If the cookie is valid, it is a domain cookie (with
502502
// the one exception of a public suffix below).
503503
// See RFC 6265 section 5.2.3.
504-
if domain[0] == '.' {
505-
domain = domain[1:]
506-
}
504+
domain = strings.TrimPrefix(domain, ".")
507505

508506
if len(domain) == 0 || domain[0] == '.' {
509507
// Received either "Domain=." or "Domain=..some.thing",

0 commit comments

Comments
 (0)