SQ(1)

NAME
sq key generate - Generates a new key

SYNOPSIS
sq [GLOBAL OPTIONS] key generate [OPTIONS]

DESCRIPTION
Generates a new key.

Generating a key is the prerequisite to receiving encrypted messages and creating signatures. There are a few parameters to this process, but we provide reasonable defaults for most users.

When generating a key, we also generate a revocation certificate. This can be used in case the key is superseded, lost, or compromised. It is a good idea to keep a copy of this in a safe place.

After generating a key, use "sq key extract-cert" to get the certificate corresponding to the key. The key must be kept secure, while the certificate should be handed out to correspondents, e.g. by uploading it to a keyserver.

OPTIONS

  Global options

-f, --force
    Overwrites existing files

--help
    Print help information

--known-notation=NOTATION
    Adds NOTATION to the list of known notations

--output-format=FORMAT
    Produces output in FORMAT, if possible

--output-version=VERSION
    Produces output variant VERSION.

--version
    Print version information

  Subcommand options

-c, --cipher-suite=CIPHER-SUITE
    Selects the cryptographic algorithms for the key

--can-authenticate
    Adds an authentication-capable subkey (default)

--can-encrypt=PURPOSE
    Adds an encryption-capable subkey [default: universal]

--can-sign
    Adds a signing-capable subkey (default)

--cannot-authenticate
    Adds no authentication-capable subkey

--cannot-encrypt
    Adds no encryption-capable subkey

--cannot-sign
    Adds no signing-capable subkey

--creation-time=CREATION_TIME
    Sets the key's creation time to TIME (as ISO 8601)

-e, --export=OUTFILE
    Writes the key to OUTFILE

--expires=TIME
    Makes the key expire at TIME (as ISO 8601)

--expires-in=DURATION
    Makes the key expire after DURATION (as N[ymwds]) [default: 5y]

--help
    Print help information

--rev-cert=FILE or -
    Writes the revocation certificate to FILE

-u, --userid=EMAIL
    Adds a userid to the key

--version
    Print version information

--with-password
    Protects the key with a password

EXAMPLES

First, this generates a key

    sq key generate --userid "<juliet@example.org>" --export juliet.key.pgp

Then, this extracts the certificate for distribution

    sq key extract-cert --output juliet.cert.pgp juliet.key.pgp

Generates a key protecting it with a password

    sq key generate --userid "<juliet@example.org>" --with-password

Generates a key with multiple userids

    sq key generate --userid "<juliet@example.org>" --userid "Juliet Capulet"

SEE ALSO
sq(1).

For the full documentation see <https://docs.sequoia-pgp.org/sq/>.

VERSION
0.28.0 (sequoia-openpgp 1.13.0, using Nettle)