Error 400: domain-restricted sharing
Cause. Your org enforces theconstraints/iam.allowedPolicyMemberDomains org policy (“domain
restricted sharing”), which blocks granting IAM to identities outside your own domain — including
the 0Labs broker principal.
Fix (Terraform). Allow 0Labs’ Google Workspace customer id (C0257jo7q) alongside your own in
that policy. Scope it as narrowly as you like — e.g. only on the host project where the scanner SA
lives:
C0257jo7q.
This grants 0Labs nothing by itself — it only permits the single token-creator binding the module
creates.
Impersonation denied
Symptom. The connectivity test’simpersonation check fails, or
gcloud auth print-access-token --impersonate-service-account=… errors.
Causes & fixes.
- IAM propagation. Bindings can take ~2 minutes to take effect. Wait and retry.
- Domain-restricted sharing. If the token-creator binding never landed, see the Error 400 section above.
- Wrong principal. Confirm the trust binding grants
serviceAccount:detections-agent@detections-0labs.iam.gserviceaccount.com(the stable broker) — not an env-suffixed SA.
No findings after 30 minutes
Symptom. The connector saved and the test passed, but Posture is still empty. Causes & fixes.-
Scan hasn’t run yet. The first scan runs on the daily schedule. Trigger it on demand (admin
token):
-
Nothing to find. If your estate is clean, there’s nothing to surface. To prove the loop end to
end, drop a deliberate test misconfig first:
-
Asset Inventory empty. Confirm Cloud Asset Inventory is enabled and the
asset_inventorycheck passed in the connectivity test (see Connect GCP).
Wrong or legacy module source
Symptom. Terraform can’t resolve the module, or you pulled an older path. Fix. Use this exact source string, pinned to a release tag:Older internal references pointed the module at a path inside the platform monorepo. The
published, supported module is the standalone
terraform-google-zerolabs-connector repo above.