Skip to content

Commit 1f5a737

Browse files
committed
Use ToED25519SignerVerifier
Signed-off-by: Riccardo Schirone <riccardo.schirone@trailofbits.com>
1 parent 16c0256 commit 1f5a737

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

cmd/cosign/cli/sign/sign.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -552,7 +552,7 @@ func keylessSigner(ctx context.Context, ko options.KeyOpts, sv *SignerVerifier)
552552
err error
553553
)
554554

555-
fulcioSV, err := AdaptSignerVerifierToFulcio(sv)
555+
fulcioSV, err := adaptSignerVerifierToFulcio(sv)
556556
if err != nil {
557557
return nil, fmt.Errorf("adapting signer verifier to Fulcio: %w", err)
558558
}
@@ -629,14 +629,14 @@ func (c *SignerVerifier) Bytes(ctx context.Context) ([]byte, error) {
629629
return pemBytes, nil
630630
}
631631

632-
// AdaptSignerVerifierToFulcio adapts, if necessary, the SignerVerifier to be used to interact with Fulcio.
632+
// adaptSignerVerifierToFulcio adapts, if necessary, the SignerVerifier to be used to interact with Fulcio.
633633
//
634634
// This is needed in particular for ED25519 keys with the pre-hashed version of
635635
// the algorithm, which is not supported by Fulcio. This function creates a
636636
// ED25519 SignerVerifier based on that instead.
637-
func AdaptSignerVerifierToFulcio(sv *SignerVerifier) (*SignerVerifier, error) {
637+
func adaptSignerVerifierToFulcio(sv *SignerVerifier) (*SignerVerifier, error) {
638638
if ed25519phSV, ok := sv.SignerVerifier.(*signature.ED25519phSignerVerifier); ok {
639-
signerVerifier, err := ed25519phSV.ConvertToED25519()
639+
signerVerifier, err := ed25519phSV.ToED25519SignerVerifier()
640640
if err != nil {
641641
return nil, err
642642
}

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ require (
3232
github.com/secure-systems-lab/go-securesystemslib v0.8.0
3333
github.com/sigstore/fulcio v1.4.3
3434
github.com/sigstore/rekor v1.3.4
35-
github.com/sigstore/sigstore v1.8.2-0.20240129195947-e1f9a175c451
35+
github.com/sigstore/sigstore v1.8.2-0.20240206082515-7fa5044eab09
3636
github.com/sigstore/sigstore/pkg/signature/kms/aws v1.8.1
3737
github.com/sigstore/sigstore/pkg/signature/kms/azure v1.8.1
3838
github.com/sigstore/sigstore/pkg/signature/kms/gcp v1.8.1

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -608,8 +608,8 @@ github.com/shibumi/go-pathspec v1.3.0 h1:QUyMZhFo0Md5B8zV8x2tesohbb5kfbpTi9rBnKh
608608
github.com/shibumi/go-pathspec v1.3.0/go.mod h1:Xutfslp817l2I1cZvgcfeMQJG5QnU2lh5tVaaMCl3jE=
609609
github.com/sigstore/fulcio v1.4.3 h1:9JcUCZjjVhRF9fmhVuz6i1RyhCc/EGCD7MOl+iqCJLQ=
610610
github.com/sigstore/fulcio v1.4.3/go.mod h1:BQPWo7cfxmJwgaHlphUHUpFkp5+YxeJes82oo39m5og=
611-
github.com/sigstore/sigstore v1.8.2-0.20240129195947-e1f9a175c451 h1:ypAyd4AiAndzEED10G5JO/cxSJ2xAERD1aNpWtr8a4Q=
612-
github.com/sigstore/sigstore v1.8.2-0.20240129195947-e1f9a175c451/go.mod h1:rbZxJoss0Qf/OQeIuyqkQxo9jLKZlyLqOGX0BUaK7/I=
611+
github.com/sigstore/sigstore v1.8.2-0.20240206082515-7fa5044eab09 h1:BpZhOReWZECJ1okzh5N9G/UjfoAWPm7Gy58vZHGE9zU=
612+
github.com/sigstore/sigstore v1.8.2-0.20240206082515-7fa5044eab09/go.mod h1:rbZxJoss0Qf/OQeIuyqkQxo9jLKZlyLqOGX0BUaK7/I=
613613
github.com/sigstore/sigstore/pkg/signature/kms/aws v1.8.1 h1:rEDdUefulkIQaMJyzLwtgPDLNXBIltBABiFYfb0YmgQ=
614614
github.com/sigstore/sigstore/pkg/signature/kms/aws v1.8.1/go.mod h1:RCdYCc1IxCYWzh2IdzdA6Yf7JIY0cMRqH08fpQYechw=
615615
github.com/sigstore/sigstore/pkg/signature/kms/azure v1.8.1 h1:DvRWG99QGWZC5mp42SEde2Xke/Q384Idnj2da7yB+Mk=

0 commit comments

Comments
 (0)