Skip to main content
Keypair secrets store asymmetric key pairs (public and private keys) with optional passphrase protection. Use them for SSH authentication, JWT signing, encryption, or any cryptographic operation requiring public-key infrastructure.

Use Cases

  • SSH Authentication: Store SSH keys for accessing remote servers or Git repositories
  • JWT Signing: Sign and verify JSON Web Tokens for API authentication
  • Encryption/Decryption: Encrypt data with the public key, decrypt with the private key
  • Code Signing: Sign artifacts to verify authenticity and integrity
  • Secure Communication: Establish encrypted channels between services

Configuration Options

Both keys must be PEM-encoded. The private key can be encrypted with a passphrase—if so, provide the passphrase so your workload can use the key.

Create a Keypair Secret

1

Navigate to Secrets

In the Console, navigate to Secrets and click New, or use the Create dropdown in the top-right corner and select Secret.
2

Enter basic information

Enter a Name and optional Description.
3

Select secret type

Select Keypair as the secret type.
4

Configure key data

Click Data in the left pane. For Secret Key, drag and drop your private key file or click to import. For Public Key, drag and drop your public key file or click to import. Enter the Passphrase if the private key is encrypted (optional).
5

Create the secret

Click Create.

Generating Key Pairs

RSA Keys

Ed25519 Keys (for SSH)

ECDSA Keys

For JWT signing, RSA with 2048 or 4096 bits and ECDSA P-256 are common choices. Ed25519 offers excellent security with smaller key sizes.

Best Practices

For RSA, use at least 2048 bits (4096 recommended). For ECDSA, use P-256 or higher curves.
Always encrypt private keys with a strong passphrase when storing them, adding an extra layer of protection.
Establish a key rotation schedule. When rotating, update the secret and ensure workloads can handle the transition.
Use Control Plane policies to restrict which workloads can access the keypair. Only services that need to sign or decrypt should have access.

Next Steps

TLS Secrets

Store SSL/TLS certificates and keys

Using Secrets in Workloads

Learn how to grant access and inject secrets