Skip to content

Commit c59699c

Browse files
authored
Merge pull request #50 from xStrom/modules
Add Go modules support.
2 parents cfc72ed + d3dc66f commit c59699c

File tree

4 files changed

+24
-5
lines changed

4 files changed

+24
-5
lines changed

.travis.yml

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,19 @@ sudo: false
33
language: go
44

55
go:
6-
- 1.3.3
7-
- 1.4.2
8-
- 1.5.2
9-
- 1.6beta2
6+
- 1.3.x
7+
- 1.4.x
8+
- 1.5.x
9+
- 1.6.x
10+
- 1.7.x
11+
- 1.8.x
12+
- 1.9.x
13+
- 1.10.x
14+
- 1.11.x
15+
- 1.12.x
16+
17+
env:
18+
- GO111MODULE=on
1019

1120
# Get deps, build, test, and ensure the code is gofmt'ed.
1221
script:

go.mod

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
module github.com/yohcop/openid-go
2+
3+
go 1.3
4+
5+
require golang.org/x/net v0.0.0-20190522155817-f3200d17e092

go.sum

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
2+
golang.org/x/net v0.0.0-20190522155817-f3200d17e092 h1:4QSRKanuywn15aTZvI/mIDEgPQpswuFndXpOj3rKEco=
3+
golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
4+
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
5+
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=

nonce_store.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ func (d *SimpleNonceStore) Accept(endpoint, nonce string) error {
5555
now := time.Now()
5656
diff := now.Sub(ts)
5757
if diff > *maxNonceAge {
58-
return fmt.Errorf("Nonce too old: %ds", diff.Seconds())
58+
return fmt.Errorf("Nonce too old: %.2fs", diff.Seconds())
5959
}
6060

6161
s := nonce[20:]

0 commit comments

Comments
 (0)