gcloud_alpha_kms_asymmetric-sign (1)
NAME
- gcloud alpha kms asymmetric-sign - sign a user input file using an asymmetric-signing key version
SYNOPSIS
-
gcloud alpha kms asymmetric-sign --digest-algorithm=DIGEST_ALGORITHM --input-file=INPUT_FILE [--key=KEY] [--keyring=KEYRING] [--location=LOCATION] [--signature-file=SIGNATURE_FILE] [--version=VERSION] [GCLOUD_WIDE_FLAG ...]
DESCRIPTION
(ALPHA) Creates a digital signature of the input file using the provided
The required flag signature-file indicates the path to store signature.
REQUIRED FLAGS
-
- --digest-algorithm=DIGEST_ALGORITHM
-
The algorithm to digest the input. DIGEST_ALGORITHM must be one of:
sha256, sha384, sha512.
- --input-file=INPUT_FILE
-
Path to the input file to sign.
OPTIONAL FLAGS
-
- --key=KEY
-
to use for signing.
- --keyring=KEYRING
-
Key ring of the key.
- --location=LOCATION
-
Location of the keyring.
- --signature-file=SIGNATURE_FILE
-
Path to the signature file to output.
- --version=VERSION
-
Version to use for signing.
GCLOUD WIDE FLAGS
These flags are available to all commands: --account, --configuration, --flags-file, --flatten, --format, --help, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity. Run $ gcloud help for details.
EXAMPLES
The following command will read the file '/tmp/my/file.to.sign', digest it with the digest algorithm 'sha256' and sign it using the asymmetric CryptoKey dont-panic Version 3, and save the signature in base64 format to '/tmp/my/signature'.
- $ gcloud alpha kms asymmetric-sign \ --location us-central1 \ --keyring hitchhiker \ --key dont-panic \ --version 1 \ --digest-algorithm sha256 \ --input-file /tmp/my/file.to.sign \ --signature-file /tmp/my/signature
NOTES
This command is currently in ALPHA and may change without notice. If this command fails with API permission errors despite specifying the right project, you will have to apply for early access and have your projects registered on the API whitelist to use it. To do so, contact Support at cloud.google.com/support