Fix grammar in comments.

pull/717/head
Mariano Cano 3 years ago
parent 781d5fb6e8
commit 5d0bd7d155

@ -19,7 +19,7 @@ func init() {
}) })
} }
// Scheme is the scheme used for Azure Key Vault uris. // Scheme is the scheme used for the Azure Key Vault uris.
const Scheme = "azurekms" const Scheme = "azurekms"
// keyIDRegexp is the regular expression that Key Vault uses for on the kid. We // keyIDRegexp is the regular expression that Key Vault uses for on the kid. We
@ -96,11 +96,11 @@ var signatureAlgorithmMapping = map[apiv1.SignatureAlgorithm]keyType{
}, },
} }
// vaultResource is that the client will use as audience. // vaultResource is the value the client will use as audience.
const vaultResource = "https://vault.azure.net" const vaultResource = "https://vault.azure.net"
// KeyVaultClient is the interface implemented by keyvault.BaseClient. It it // KeyVaultClient is the interface implemented by keyvault.BaseClient. It will
// will be used for testing purposes. // be used for testing purposes.
type KeyVaultClient interface { type KeyVaultClient interface {
GetKey(ctx context.Context, vaultBaseURL string, keyName string, keyVersion string) (keyvault.KeyBundle, error) GetKey(ctx context.Context, vaultBaseURL string, keyName string, keyVersion string) (keyvault.KeyBundle, error)
CreateKey(ctx context.Context, vaultBaseURL string, keyName string, parameters keyvault.KeyCreateParameters) (keyvault.KeyBundle, error) CreateKey(ctx context.Context, vaultBaseURL string, keyName string, parameters keyvault.KeyCreateParameters) (keyvault.KeyBundle, error)

@ -99,7 +99,7 @@ func (s *Signer) Sign(rand io.Reader, digest []byte, opts crypto.SignerOpts) ([]
return sig, nil return sig, nil
} }
// Convert to ans1 // Convert to asn1
if len(sig) != octetSize*2 { if len(sig) != octetSize*2 {
return nil, errors.Errorf("keyVault Sign failed: unexpected signature length") return nil, errors.Errorf("keyVault Sign failed: unexpected signature length")
} }

@ -263,7 +263,7 @@ func WithDeploymentType(dt DeploymentType) Option {
} }
} }
// WithKMS enabled the kms with the given name. // WithKMS enables the kms with the given name.
func WithKMS(name string) Option { func WithKMS(name string) Option {
return func(p *PKI) { return func(p *PKI) {
typ := linkedca.KMS_Type_value[strings.ToUpper(name)] typ := linkedca.KMS_Type_value[strings.ToUpper(name)]

Loading…
Cancel
Save