Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: smallstep/cli
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: eb550ee3c05d06854ef303e8452d4aa7f0da03d2
Choose a base ref
..
head repository: smallstep/cli
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 92a5eabb464feeee0480f5acd679dec84acf77f6
Choose a head ref
Showing with 6 additions and 10 deletions.
  1. +6 −10 integration/crypto_test.go
16 changes: 6 additions & 10 deletions integration/crypto_test.go
Original file line number Diff line number Diff line change
@@ -332,16 +332,12 @@ func checkKeyPair(ts *testscript.TestScript, neg bool, args []string) {

keyType := strings.ToUpper(args[2])
if keyType == "OCT" {
// TODO(hs): implement comparison for "oct" key type; go-jose doesn't seem to
// have functionality built in for those.
// pubJSON, err := pub.Public().MarshalJSON()
// ts.Check(err)
// privJSON, err := priv.Public().MarshalJSON()
// ts.Check(err)

// if !bytes.Equal(pubJSON, privJSON) {
// ts.Fatalf("%s and %s have different public key JSON representation", args[0], args[1])
// }
if _, ok := pub.Key.([]byte); !ok {
ts.Fatalf("expected public key %s to be a byte slice; got %T", args[0], pub.Key)
}
if _, ok := priv.Key.([]byte); !ok {
ts.Fatalf("expected private key %s to be a byte slice; got %T", args[0], pub.Key)
}
} else {
pubHash, err := pub.Thumbprint(crypto.SHA1)
ts.Check(err)