Overview
Change authorization proves which key approved each change to your Formal configuration:- You register the public key of a key pair as a signing key.
- You sign API requests with the private key, using the
FORMAL-SIGauthorization scheme instead of an API key. - Formal verifies the signature and records it with the change.
- Optionally, Connectors verify those recorded signatures before they load configuration.
enforce mode.
Supported Algorithms
All values use standard base64 with padding.
1. Generate a Key Pair
Keep the private key in your signing system. Only the public key goes to Formal.- Ed25519
- ECDSA P-384
- ML-DSA-87
2. Register the Signing Key
1
Open Signing Keys
Go to Signing Keys, the Signing Keys tab of API Keys & Signing Keys. You can also search for Signing Keys in the command menu. You need the Developer permission.
2
Create the key
Click Create Signing Key. Enter a Name, choose the Algorithm, and paste the Public Key (Base64). Click Create.
3
Copy the ID
Copy the key’s ID from the table. You use it as
KeyId when you sign.CreateSigningKey.
Verify: The key appears with status active.
3. Sign a Request
Send the signature in theAuthorization header instead of X-API-KEY:
Build the Canonical Payload
Sign these four parts, joined by newlines (\n), with no trailing newline:
- The HTTP method,
POSTfor every Formal API call - The request path
- The
Timestampvalue, character for character - The canonical body
{} gives an empty canonical body.
For the body {"status":"active","name":"prod-db"}, the canonical body is:
Example: Sign with OpenSSL
This script signs and sends a request with an Ed25519 key:openssl dgst -sha384 -sign signing-key.pem payload.txt instead.
Verify: The API returns 200. A wrong signature, an unknown or revoked key, or a timestamp outside the window returns an authentication error.
The timestamp must be at most 5 minutes old and at most 1 minute in the
future. Keep your signing system’s clock in sync.
4. Verify Signatures on Connectors (Optional)
Connectors can check the signature recorded with each configuration entity before they load it. This covers most configuration a Connector loads, such as Resources, policies, listeners, Native Users, users, and groups. Set these environment variables on the Connector:audit: The Connector loads every entity, and logsChange auth verification failure (audit mode)for each unsigned or invalid one.enforce: The Connector rejects any response that contains an unsigned or invalid entity. It needs at least one key inFORMAL_CHANGE_AUTH_PUBLIC_KEYS.
Rotate a Key
- Generate a new key pair and register it.
- Add the new public key to
FORMAL_CHANGE_AUTH_PUBLIC_KEYSon your Connectors. - Switch your signing system to the new key.
- Revoke the old key with
UpdateSigningKeyby setting its status torevoked, or delete it.
FORMAL_CHANGE_AUTH_PUBLIC_KEYS once no configuration still carries its signature.
API
Manage signing keys withcore.v1.ChangeAuthorizationService: CreateSigningKey, ListSigningKeys, UpdateSigningKey, and DeleteSigningKey. See the Change Authorization section of the API reference.
Next Steps
API Introduction
Authenticate and call the Formal API
Permissions
Control who can manage signing keys