Skip to content

Commit ab04eab

Browse files
authored
Merge pull request #54 from smallstep/permanent-identifier
Permanent identifier
2 parents 72ddf42 + 022ae3d commit ab04eab

File tree

19 files changed

+512
-163
lines changed

19 files changed

+512
-163
lines changed

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ubuntu-20.04
1313
strategy:
1414
matrix:
15-
go: [ '1.17', '1.18' ]
15+
go: [ '1.18', '1.19' ]
1616
steps:
1717
- name: Install dependencies
1818
run: sudo apt update && sudo apt install -y libpcsclite-dev
@@ -25,7 +25,7 @@ jobs:
2525
- name: golangci-lint
2626
uses: golangci/golangci-lint-action@v2
2727
with:
28-
version: 'v1.46.2'
28+
version: 'v1.48'
2929
args: --timeout=30m
3030
- name: Test
3131
run: V=1 make ci

.github/workflows/test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-20.04
1515
strategy:
1616
matrix:
17-
go: [ '1.17', '1.18' ]
17+
go: [ '1.18', '1.19' ]
1818
steps:
1919
- name: Install dependencies
2020
run: sudo apt update && sudo apt install -y libpcsclite-dev
@@ -27,13 +27,13 @@ jobs:
2727
- name: golangci-lint
2828
uses: golangci/golangci-lint-action@v2
2929
with:
30-
version: 'v1.46.2'
30+
version: 'v1.48'
3131
args: --timeout=30m
3232
- name: Test
3333
run: V=1 make ci
3434
- name: Codecov
3535
uses: codecov/[email protected]
36-
if: matrix.go == '1.18'
36+
if: matrix.go == '1.19'
3737
with:
3838
file: ./coverage.out
3939
name: codecov-umbrella

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module go.step.sm/crypto
22

3-
go 1.17
3+
go 1.18
44

55
require (
66
cloud.google.com/go/kms v1.4.0

go.sum

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,6 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de
306306
github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
307307
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
308308
github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
309-
github.com/yuin/goldmark v1.4.0/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
310309
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
311310
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
312311
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
@@ -399,7 +398,6 @@ golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v
399398
golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc=
400399
golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
401400
golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
402-
golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
403401
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
404402
golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
405403
golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
@@ -488,7 +486,6 @@ golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBc
488486
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
489487
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
490488
golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
491-
golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
492489
golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
493490
golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
494491
golang.org/x/sys v0.0.0-20211031064116-611d5d643895/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
@@ -572,7 +569,6 @@ golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
572569
golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
573570
golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
574571
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
575-
golang.org/x/tools v0.1.7/go.mod h1:LGqMHiF4EqQNHR1JncWGqT5BVaXmza+X+BDGol+dOxo=
576572
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
577573
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
578574
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=

internal/bcrypt_pbkdf/bcrypt_pbkdf.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
// Package bcrypt_pbkdf implements password-based key derivation function based
66
// on bcrypt compatible with bcrypt_pbkdf(3) from OpenBSD.
7+
//
78
//nolint:revive // ignore underscore in package
89
package bcrypt_pbkdf
910

internal/bcrypt_pbkdf/bcrypt_pbkdf_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// Copyright 2014 Dmitry Chestnykh. All rights reserved.
22
// Use of this source code is governed by a BSD-style
33
// license that can be found in the LICENSE file.
4+
//
45
//nolint:revive // ignore underscore in package
56
package bcrypt_pbkdf
67

internal/utils/io_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ package utils
22

33
import (
44
"fmt"
5-
"io/ioutil"
65
"os"
76
"path/filepath"
87
"reflect"
@@ -67,7 +66,7 @@ func TestReadPasswordFromFile(t *testing.T) {
6766
}
6867

6968
func TestWriteFile(t *testing.T) {
70-
tmpDir, err := ioutil.TempDir(os.TempDir(), "go-tests")
69+
tmpDir, err := os.MkdirTemp(os.TempDir(), "go-tests")
7170
if err != nil {
7271
t.Fatal(err)
7372
}

jose/generate_test.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import (
99
"crypto/x509"
1010
"encoding/json"
1111
"encoding/pem"
12-
"io/ioutil"
1312
"math/big"
1413
"os"
1514
"reflect"
@@ -357,8 +356,8 @@ func newCert(t *testing.T, keyUsage x509.KeyUsage) []byte {
357356
return cert
358357
}
359358

360-
func tempFile(t *testing.T) (_ *os.File, cleanup func()) {
361-
f, err := ioutil.TempFile("" /* use default tmp dir */, "jose-generate-test")
359+
func tempFile(t *testing.T) (*os.File, func()) {
360+
f, err := os.CreateTemp("", "jose-generate-test")
362361
assert.NoError(t, err)
363362
return f, func() {
364363
f.Close()

jose/types.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ var ErrInvalidID = jwt.ErrInvalidID
122122
var ErrIssuedInTheFuture = jwt.ErrIssuedInTheFuture
123123

124124
// Key management algorithms
125+
//
125126
//nolint:revive // use standard names in upper-case
126127
const (
127128
RSA1_5 = KeyAlgorithm("RSA1_5") // RSA-PKCS1v1.5
@@ -162,6 +163,7 @@ const (
162163
)
163164

164165
// Content encryption algorithms
166+
//
165167
//nolint:revive // use standard names in upper-case
166168
const (
167169
A128CBC_HS256 = ContentEncryption("A128CBC-HS256") // AES-CBC + HMAC-SHA256 (128)

sshutil/certificate_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ func TestNewCertificate(t *testing.T) {
204204
return
205205
}
206206
if !reflect.DeepEqual(got, tt.want) {
207-
t.Errorf("NewCertificate() = \n%+v, want \n%+v", got, tt.want)
207+
t.Errorf("NewCertificate() = %v, want %v", got, tt.want)
208208
}
209209
})
210210
}

0 commit comments

Comments
 (0)