Troubleshooting IBM Cloud account not ingesting audit events with CDR
Resolve issues with your IBM Cloud account not ingesting audit events after enabling cloud detection and response (CDR), including verifying the trusted profile and IAM access policies.
After enabling CDR for your IBM Cloud account, the account does not appear as Connected under Integrations > Environments > IBM Cloud in your Workload Protection instance.
The CDR connection might not be active for one of the following reasons:
- The Trusted Profile was not created correctly, or the Workload Protection instance CRN is not set as a trusted entity in the profile.
- The Trusted Profile does not have the required IAM access policies to read from the Object Storage bucket or view the Service ID.
- The Activity Tracker Event Routing target is not writing to the Object Storage bucket correctly.
- The Code Engine application is not running, either because the registry secret is missing or the API key is incorrect.
- The IAM service-to-service authorization policy between Code Engine and IBM Cloud Object Storage is missing, preventing Object Storage event notifications from being delivered.
- The Object Storage event subscription destination does not match the Code Engine application name.
- The parameters in step 7 (
cdr_bucket_region,cdr_bucket_name,cdr_ingestion_url) do not match the resources created in previous steps.
To resolve this issue, complete the following steps:
-
Verify that the Activity Tracker Event Routing target is writing successfully to the Object Storage bucket:
ibmcloud atracker target get --target <target_name>Check that
Write Statusshowssuccess. If it shows an error, verify that the service-to-service authorization between Activity Tracker Event Routing and IBM Cloud Object Storage is enabled and that the bucket exists in the expected region. -
Confirm that the Trusted Profile includes the Workload Protection instance CRN as a trusted entity and has the required access policies:
ibmcloud iam trusted-profile-get ibmcdr-wp-cosEnsure the trust relationship points to the correct Workload Protection CRN and that policies for
cloud-object-storage(Viewer, Reader on the bucket) andiam-identity(Viewer on the Service ID) are present. -
Check that the Code Engine application is running:
ibmcloud ce application get --name sccwp-cdr-appIf the application is not ready, verify that the
icr-secretregistry secret is correctly configured and that thecdr-secretssecret contains a valid API key. If the image cannot be pulled, confirm that the Service ID has Reader access to the IBM Cloud Container Registry. -
Verify that the IAM authorization policy between Code Engine and IBM Cloud Object Storage exists:
ibmcloud iam authorization-policiesLook for a policy granting Code Engine the
Notifications Managerrole on the IBM Cloud Object Storage instance. If missing, rerun the authorization policy command from step 6 of the setup. -
Check that the Object Storage event subscription is ready and pointing to the correct application:
ibmcloud ce subscription cos get --name cdr-cos-subConfirm that
Destinationmatchessccwp-cdr-app,Bucketmatches your Object Storage bucket name, andReadyshowstrue. -
Verify that the Workload Protection instance was updated with the correct parameters by re-running step 7 of the setup with the correct values. Ensure that
cdr_bucket_region,cdr_bucket_name,cdr_trusted_profile_id,cdr_service_id, andcdr_ingestion_urlall match the resources created in previous steps. -
After making any corrections, allow up to 5 minutes for the connection status to update in the Workload Protection UI.
For more information, see Enabling Detection and Response for IBM Cloud.