Troubleshooting Built-In Account authentication¶
This topic covers common problems when configuring Enterprise Issuer to authenticate to Next-Gen Trust Security using a Built-In Account.
For general Enterprise Issuer troubleshooting, including how to inspect resources or adjust the logging level, see Troubleshooting Enterprise Issuer.
Wrong Client ID¶
The Connection resource status message contains invalid_client: Not Found or grant not found. This means the clientID in the VenafiConnection does not match the Built-In Account's Client ID.
- In Next-Gen Trust Security, on the Built-In Account page, copy the Client ID.
-
Compare it with the
clientIDfield inVenafiConnection:kubectl get venaficonnection ngts-connection -n venafi -o jsonpath='{.spec.ngts.jwt[1].privateKeyJWT.clientID}' -
If they do not match, update
VenafiConnection.
Wrong or corrupted private key¶
The Connection resource status message contains a JWT signing error or an OAuth error such as invalid_grant. This means the private key in the Kubernetes Secret does not match the public key registered with the Built-In Account or the PEM data is malformed (for example, there are missing newlines).
-
Verify that the Secret contains a valid PEM-encoded private key:
kubectl get secret ngts-credentials -n venafi -o jsonpath='{.data.privateKey}' | base64 -d | head -1The output should begin with
-----BEGIN EC PRIVATE KEY-----or-----BEGIN RSA PRIVATE KEY-----. -
If the key is corrupted or does not match the Built-In Account, on the Built-in Account page in Next-Gen Trust Security, click the account.
-
In the panel that appears, click Renew to generate a new key pair, saving the private key.
-
Update the Kubernetes Secret with the new private key.
Unreachable endpoint¶
The Connection resource status message contains a connection error such as dial tcp: lookup ... no such host or connection refused. This means the tsgID in VenafiConnection is incorrect or that the cluster cannot reach the Next-Gen Trust Security data plane endpoint.
-
Verify that the
tsgIDinVenafiConnectionmatches your Tenant Service Group ID. ThetsgIDis used to construct the URL for the Next-Gen Trust Security data plane endpoint, for examplehttps://0000000000.ngts.paloaltonetworks.com:kubectl get venaficonnection ngts-connection -n venafi -o jsonpath='{.spec.ngts.tsgID}' -
From a pod in the cluster, verify that the cluster can reach the endpoint:
kubectl run -it --rm curl-test --image=curlimages/curl -- curl -v https://<tsgID>.ngts.paloaltonetworks.com/v1/health
Untrusted TLS certificate in non-production environments¶
The Connection resource status message contains x509: certificate signed by unknown authority. Non-production environments use TLS certificates signed by an untrusted Palo Alto Networks internal CA.
-
Obtain the Palo Alto Networks CA bundle and create a
ConfigMapin the Enterprise Issuer namespace:kubectl create configmap cyberark-ca-bundle \ --from-file=ca-bundle.crt=ca-bundle.pem \ -n venafi -
Configure the Enterprise Issuer Helm chart to trust the CA bundle by setting the
trustedCaBundlesvalue:venafiEnhancedIssuer: manager: trustedCaBundles: - configMapName: cyberark-ca-bundle configMapKey: ca-bundle.crt -
Upgrade the Enterprise Issuer Helm release with the updated values.
Invalid issuing template¶
The Certificate resource remains Pending and CertificateRequest events show a 404 response or a message indicating the issuing template was not found. This means the zone field in VenafiIssuer doesn't match a valid issuing template in Next-Gen Trust Security.
-
Check the
zonevalue inVenafiIssuer:kubectl get venafiissuer ngts-issuer -n venafi -o jsonpath='{.spec.zone}' -
Confirm the
zoneformat, which must followIssuing Template Name. -
In Next-Gen Trust Security, confirm that the issuing template exist and that the Built-In Account has access to them.
Secret access denied¶
The Connection resource status message contains secrets "ngts-credentials" is forbidden or a similar error. This means the venafi-connection service account does not have permission to read the Kubernetes Secret that contains the private key.
-
Verify that the
RoleandRoleBindingexist:kubectl get role get-ngts-credentials -n venafi kubectl get rolebinding ngts-credentials-rolebinding -n venafi -
Verify that the
RoleBindingreferences the correct service account name and namespace. The service account name must match the one used by the Connection resource controller (typicallyvenafi-connectionin thevenafinamespace).
Cross-namespace reference denied¶
The Certificate resource remains Pending and the VenafiIssuer in a different namespace from the Connection resource shows reference not allowed. This means the Connection resource does not allow references from the namespace where the VenafiIssuer or Certificate resource is created.
To resolve this error, add an allowReferencesFrom field to the Connection resource to permit cross-namespace access, as described in About cross-namespace access for Connection resource.