Certificate Rotation
AgentCube uses RSA signing keys when a connector runs with AGENTCUBE_AUTH_MODE=internal or oidc (see Auth Modes). There are two keys to look after:
- The connector signing key signs the JWT assertions for Oracle token exchange. It lives on each EPM connector that performs the exchange, and its certificate is imported into OCI.
- The Context Engine internal signing key (
internalmode only) signs the short-lived identity tokens the Context Engine sends tointernal-mode connectors.
Both require periodic rotation.
AgentCube Signing Key
Section titled “AgentCube Signing Key”The signing key is used to create JWT assertions for Oracle token exchange. The certificate has a finite validity period (default 5 years / 1825 days).
When to Rotate
Section titled “When to Rotate”- Before the certificate expires
- If the private key is compromised
- Per your organization’s security policy
Rotation Procedure
Section titled “Rotation Procedure”-
Generate a new key pair (on Windows, install OpenSSL first, as described in Signing Key Generation):
Terminal window openssl genrsa -out agentcube-signing-new.pem 2048openssl req -new -x509 -key agentcube-signing-new.pem -out agentcube-signing-new.cer -days 1825 -subj "/CN=AgentCube MCP/O={organization_name}"Terminal window openssl genrsa -out agentcube-signing-new.pem 2048openssl req -new -x509 \-key agentcube-signing-new.pem \-out agentcube-signing-new.cer \-days 1825 \-subj "/CN=AgentCube MCP/O={organization_name}" -
Import the new certificate to OCI Identity Domain:
- Go to Security → Trusted partner certificates → Import certificate
- Upload the new certificate with a new alias (e.g.,
agentcube-mcp-2)
-
Update environment variables on every connector (Planning, FCCS, Essbase) that does Oracle token exchange with this key:
-
Set
AGENTCUBE_SIGNING_KEY_BASE64to the base64-encoded new private key. Encode it as a single line:Terminal window [Convert]::ToBase64String([IO.File]::ReadAllBytes("agentcube-signing-new.pem")) | Set-Content agentcube-signing-new.b64 -NoNewlineTerminal window base64 < agentcube-signing-new.pem | tr -d '\n' > agentcube-signing-new.b64If you mount the key file instead, point
AGENTCUBE_SIGNING_KEY_PATHat the new PEM. It takes precedence overAGENTCUBE_SIGNING_KEY_BASE64. -
Set
AGENTCUBE_SIGNING_KIDto the new certificate alias. If it is unset, the connector falls back toagentcube-mcp, so a rotation that skips this step keeps presenting the old alias and the token exchange fails.
-
-
Restart the connector containers to pick up the new configuration
-
Verify — test an SSO login and tool call to confirm the new key works
-
Remove the old certificate from OCI trusted partner certificates (after confirming the new key works)
Context Engine Internal Signing Key
Section titled “Context Engine Internal Signing Key”If any connected system is registered with auth mode internal, the Context Engine holds its own RSA private key in AGENTCUBE_CE_INTERNAL_SIGNING_KEY. It signs a short-lived token for every call to an internal-mode connector and publishes the public key at {ce_url}/.well-known/jwks.json, which connectors read through AGENTCUBE_INTERNAL_JWKS_URL. The Context Engine refuses to start while an internal connected system exists and this key is unset. This key is not imported into OCI.
Rotation Procedure
Section titled “Rotation Procedure”-
Generate a new private key (same command on Windows and macOS/Linux):
Terminal window openssl genrsa -out ce-internal-new.pem 2048 -
Set
AGENTCUBE_CE_INTERNAL_SIGNING_KEYon the Context Engine to the full PEM contents ofce-internal-new.pem, in your platform’s secret store. Every Context Engine replica must use the same key. -
Restart the Context Engine.
-
Verify with a tool call through each
internal-mode connector. No connector changes are needed.
Identity Provider Signing Keys
Section titled “Identity Provider Signing Keys”If your identity provider (Entra, Okta, etc.) rotates its signing keys, AgentCube typically handles this automatically through OIDC discovery. No manual action is required unless your IdP requires it.