Prepare and test your skills

Prepare and test your skills

Free sample question with answers and detailed explanation below. The Professional Cloud Developer practice bank has an additional 608 practice questions.Try 10 free realistic questions: instant score, no credit card, and no account required.
Your organization deploys containerized microservices built with Cloud Build to both Google Kubernetes Engine (GKE) and Cloud Run in a single production project. You need to configure Binary Authorization to meet the following requirements:
How should you configure the policy and manage emergency deployments?
--binauthz-evaluation-mode=POLICY_BINDINGS and set defaultAdmissionRule evaluationMode to REQUIRE_ATTESTATION with globalPolicyEvaluationMode set to ENABLE. During an emergency, temporarily set evaluationMode to ALWAYS_ALLOW to deploy the hotfix to GKE and Cloud Run.POLICY_BINDINGS and ALWAYS_ALLOW doSetting --binauthz-evaluation-mode=POLICY_BINDINGS on a GKE cluster configures the cluster to use Continuous Validation (CV) monitoring only, evaluating running Pods asynchronously and logging violations. Setting evaluationMode to ALWAYS_ALLOW instructs Binary Authorization to permit every image deployment without checking attestations.
POLICY_BINDINGS cluster flag disables an existing project singleton enforcement policy on GKE, meaning unauthorized images are logged rather than blocked. Enforcement on GKE requires PROJECT_SINGLETON_POLICY_ENFORCE (or POLICY_BINDINGS_AND_PROJECT_SINGLETON_POLICY_ENFORCE for both enforcement and CV).evaluationMode to ALWAYS_ALLOW removes all Binary Authorization checks across both GKE and Cloud Run for every team and workload, directly violating the requirement to keep enforcement active for other deployments.ALWAYS_ALLOW bypasses all attestation verification and audit-blocking behavior, while REQUIRE_ATTESTATION enforces signer checks.--binauthz-evaluation-mode.You only wanted Continuous Validation monitoring on GKE without blocking deployments, and did not need to keep strict enforcement active during emergency changes.
defaultAdmissionRule with evaluationMode set to REQUIRE_ATTESTATION, enforcementMode set to ENFORCED_BLOCK_AND_AUDIT_LOG, and add projects/PROJECT_ID/attestors/built-by-cloud-build to requireAttestationsBy. Set globalPolicyEvaluationMode to ENABLE, and use the Binary Authorization breakglass feature for urgent hotfixes.Binary Authorization is a deploy-time security control for GKE, Cloud Run, and Google Distributed Cloud that verifies cryptographic signatures called attestations before allowing container images to run. A policy defines rules governing which images are permitted, while the breakglass mechanism provides an audited emergency bypass for individual deployments that violate policy.
evaluationMode to REQUIRE_ATTESTATION and referencing projects/PROJECT_ID/attestors/built-by-cloud-build under requireAttestationsBy ensures Binary Authorization only permits images signed by Cloud Build at build time. Setting enforcementMode to ENFORCED_BLOCK_AND_AUDIT_LOG blocks non-compliant deployments across both GKE and Cloud Run and records violations.globalPolicyEvaluationMode to ENABLE activates the Google-maintained system image allowlist, ensuring core GKE system containers are evaluated and exempted automatically before custom rules apply.images field.Unlike disabling enforcement or switching to dry-run mode, combining REQUIRE_ATTESTATION and ENFORCED_BLOCK_AND_AUDIT_LOG with breakglass preserves strict software supply chain security while giving incident responders a fast, tightly scoped, and fully auditable exception path.
defaultAdmissionRule with evaluationMode set to REQUIRE_ATTESTATION, enforcementMode set to DRYRUN_AUDIT_LOG_ONLY, and add projects/PROJECT_ID/attestors/built-by-cloud-build to requireAttestationsBy. Set globalPolicyEvaluationMode to ENABLE, and rely on Cloud Audit Logs to monitor urgent hotfixes.Dry-run mode (DRYRUN_AUDIT_LOG_ONLY) is a Binary Authorization enforcement mode that evaluates container images against your policy rules without blocking non-compliant deployments. Instead of rejecting an unattested or unauthorized image, Binary Authorization permits the deployment and writes a policy violation entry to Cloud Logging.
enforcementMode is set to DRYRUN_AUDIT_LOG_ONLY on defaultAdmissionRule, any unattested image—not just an authorized emergency hotfix—is allowed to deploy to GKE and Cloud Run.built-by-cloud-build and globalPolicyEvaluationMode, but the final admission decision is always to allow.You were rolling out a new Binary Authorization policy for the first time in production and wanted to test and audit policy compliance without risking disruption or blocking existing workloads.
defaultAdmissionRule with evaluationMode set to REQUIRE_ATTESTATION and enforcementMode set to ENFORCED_BLOCK_AND_AUDIT_LOG, referencing the built-by-cloud-build attestor. For urgent hotfixes, add the image path with its :hotfix tag to the exempt images list so GKE and Cloud Run bypass the attestation check.Exempt images (configured via admissionWhitelistPatterns) define registry path patterns that Binary Authorization skips during policy evaluation, always permitting matching images to deploy without attestation checks.
:hotfix or :latest in an exempt image path; you must specify an immutable digest (IMAGE_PATH@DIGEST) or use wildcards (* or **).globalPolicyEvaluationMode: ENABLE leaves Google-maintained GKE system images vulnerable to being blocked unless you manually maintain every system image pattern yourself.sha256:...) rather than mutable tags to verify identity and look up attestations.You needed to permanently allow trusted third-party base images or vendor utilities from a specific registry path using valid digest or wildcard patterns across all deployments.
Answer them yourself and get your score the moment you finish. No account needed.
Full access includes
Keep the momentum going with these hand-picked practice scenarios
Last updated Validated