Prepare and test your skills

Prepare and test your skills

Designing table architecture for compliance and lifecycle management means separating storage, access, and key controls so confidential data stays isolated and auditable. BigQuery (opens in a new tab) datasets are child resources of projects in the Identity and Access Management (IAM) hierarchy, and a table inherits permissions from the dataset that contains it. Table-level access control breaks that inheritance by granting a user, group, or service account access to specific tables or views without granting access to the complete dataset.
Separation of confidential and non-confidential storage starts with projects and perimeters, not just tables. When data is imported from Google Cloud, BigQuery stores confidential data in the confidential data perimeter protected by VPC Service Controls (opens in a new tab), while non-confidential data remains in a separate non-confidential data project. When data is imported from an external source such as on-premises, BigQuery stores the encrypted data and the wrapped encryption key in separate tables, so compromise of the data table alone does not expose key material. Each warehouse uses its own customer-managed encryption key (CMEK), with one CMEK for the non-confidential project and another for the confidential project, and each CMEK must be in the same location as its resources.
Data flows from the source into the ingestion subsystem through Cloud Storage (opens in a new tab) or Pub/Sub, then through a Dataflow pipeline into the BigQuery warehouse inside the perimeter. An encrypted connection with Cloud VPN or Cloud Interconnect protects movement from external networks, with Dedicated Interconnect recommended for direct, high-throughput streaming. Allowlisted IP addresses in access-level policy rules permit only the expected external environment to reach Google Cloud.
Column-level governance with policy tags restricts confidential columns even when a user can read the rest of the table. Access is defined with policy tags bound to columns, and a data analyst must have the Fine-Grained Reader role plus permission on the tag to read tagged data. Anything that is not tagged remains available to all users who have access to the data warehouse, which enforces data minimization by leaving only truly non-sensitive columns broadly readable.
The reference taxonomy uses three hierarchical tags that build on each other:
| Policy tag | Example data | Access result |
|---|---|---|
| 1_Sensitive | Credit limit that cannot be made public | Grants only 1_Sensitive columns, with no access to 2_Private or 3_Confidential columns |
| 2_Private | First name and other sensitive personally identifiable information (PII) | Grants 2_Private plus 1_Sensitive columns, with no access to 3_Confidential columns |
| 3_Confidential | Credit card numbers and other very sensitive data | Grants 3_Confidential plus 2_Private and 1_Sensitive columns |
These controls persist after re-identification, so re-identified data still cannot be read until access is explicitly granted to the user. For additional protection without blocking column access, column-level dynamic data masking selectively obscures column data for groups of users, while row-level security filters access to specific rows based on qualifying user conditions.
Exam tip: Access flows downward only — 3_Confidential includes 2_Private and 1_Sensitive, but 1_Sensitive does not grant any higher tag.
The de-identification pipeline reduces what is stored in governed tables to the minimum necessary for business goals. Raw data lands in Cloud Storage, then a Dataflow pipeline calls Sensitive Data Protection to find and tokenize confidential fields before loading the result into BigQuery. For structured data the pipeline uses record transformations based on fields, such as checks for credit card numbers and card PINs, while for unstructured data it uses information types (infoTypes) to detect sensitive values.
The ordered lifecycle for internal sources is:
This sequence enforces data minimization because data that is not strictly necessary is never collected, kept, or used in cleartext. Where possible, synthetic or fully anonymized data replaces raw PII, and transformation methods such as pseudonymization, de-identification, and generalization like bucketing preserve utility while reducing exposure.
Encryption and key lifecycle for tables operates at two layers: platform encryption of stored data and column-level protection of sensitive values. BigQuery encrypts all data at rest and in transit by default, and customers who need control over keys use customer-managed encryption keys (CMEKs) in Cloud Key Management Service (Cloud KMS) (opens in a new tab) with Cloud Hardware Security Module (Cloud HSM). By default the CMEK is rotated every 30 days, and organizations that must manage keys outside Google Cloud can use Cloud External Key Manager (Cloud EKM) but then assume responsibility for rotation and other key management activities.
Client-side column encryption adds a separate lifecycle for external ingestion. The Tink encryption library, which is compatible with BigQuery Authenticated Encryption with Associated Data (AEAD) functions, encrypts sensitive columns before they leave the external network. Tink uses a data encryption key (DEK) generated locally or from Cloud HSM to encrypt the column, and a key encryption key (KEK) generated as a symmetric CMEK in Cloud HSM to wrap the DEK. Both the wrapped DEK table and the encrypted-data table are stored in BigQuery, and BigQuery uses AEAD decryption to unwrap the DEK with the KEK and decrypt the protected column only when an authorized analyst queries it.
Centralized governance, lineage, and auditability ties projects, datasets, and tables together for compliance. Knowledge Catalog provides the organization-wide governance layer that discovers, manages, monitors, and governs data and artificial intelligence (AI) artifacts across data platforms and grants access only to trusted users. Its governed-table responsibilities include managing data lineage including column-level lineage from BigQuery, managing data quality checks and data profiles and feature metadata, managing discovery and exploration across different data marts, creating a business glossary with aspects and aspect types, unifying governance across BigLake and open-format tables like Iceberg and Delta Lake, and supporting a data mesh that decentralizes ownership to domain teams while preserving central policy.
Lifecycle governance also depends on audit trails and residency controls. Admin Activity audit logs are enabled by default for all services and record configuration changes, while Data Access audit logs are enabled by default for BigQuery and track reads, creations, and modifications of user-provided data. BigQuery, Cloud Storage, Pub/Sub, and Cloud Logging all help meet data residency requirements by storing or replicating data only within the regions specified, and Cloud Storage lifecycle controls limit prolonged retention or manipulation of sensitive objects.
Establishing data governance through project and resource hierarchy means using the Google Cloud resource hierarchy to isolate data by trust level and then enforcing that isolation with identity, policy, and network controls. Google Cloud Organization (opens in a new tab) sits at the top, folders group environments and business units in the middle, and projects hold datasets and tables at the bottom. This structure lets governance, ingestion, confidential, and non-confidential workloads live in different projects with different controls, so a compromise or misconfiguration in one area does not expose the rest.
The multi-tiered hierarchy with organizations and folders is the skeleton that separates testing from production and governance from data. Google Cloud Resource Manager logically groups every resource under an organization, then into folders, then into projects, and access controls follow the principle of least privilege down that chain. Folders typically represent environments such as bootstrap, common, production, non-production or staging, and development. Most data warehouse projects deploy into the production folder, while the data governance project deploys into the common folder, so key management, catalog management, and logging stay separate from the data itself.
Project segregation by sensitivity and environment places datasets with different sensitivity in different projects so that Identity and Access Management (IAM), encryption, and perimeter rules can differ by project. The confidential data project holds re-identified and restricted BigQuery datasets, while the non-confidential data project holds de-identified or sanitized datasets, and separate ingestion and governance projects hold pipelines and keys. The internal project owns the service account that updates shared data, and the shared data project holds only the sanitized copy that external groups can view. First data lands and is de-identified in the ingestion landing zone, then it flows to the non-confidential or confidential projects, and only after explicit grants can analysts read the restricted copy.
| Project type | Contents | Governance role |
|---|---|---|
| Ingestion or landing project | Incoming batch and streaming data, Dataflow de-identification pipeline | Protects other workloads from untrusted incoming data before it is classified |
| Confidential data project | Re-identified BigQuery warehouse with restricted columns | Limits access to only authorized users and applies column-level controls and separate customer-managed encryption keys (CMEKs) |
| Non-confidential or shared data project | De-identified or sanitized datasets copied from internal sources | Allows broader internal use or external sharing through groups with viewer permission |
| Data governance project in common folder | Encryption keys, data classification taxonomy, catalog metadata, logging | Separates control-plane decisions about what is confidential from the data plane that stores the warehouse |
Enforcing boundaries with IAM policies determines who can act on which project, dataset, and table under least privilege. Identity and Access Management (IAM) (opens in a new tab) policies are attached at the organization, folder, and project levels, so a grant at a higher level flows down to everything below it unless a more restrictive control blocks it. Dedicated, least-privilege service accounts isolate pipelines from human users, so a training or ingestion service account can read from only one Cloud Storage bucket and write to only one registry or dataset.
Enforcing guardrails with organization policies constrains what resources can do rather than granting access. The Organization Policy Service (opens in a new tab) sets centralized guardrails applied globally at the organization or selectively at a folder or project. Because they inherit downward, a guardrail set on the production folder automatically covers every confidential and non-confidential project inside it.
iam.disableServiceAccountCreation set to true to prevent uncontrolled identity sprawl.compute.requireOsLogin set to true and disable serial port logging to Cloud Logging with compute.disableSerialPortLogging set to true.compute.restrictProtocolForwardingCreationForTypes set to INTERNAL and constrain Shared VPC subnetworks with compute.restrictSharedVpcSubnetworks to a specific private subnet.gcp.restrictNonCmekServices set to bigquery.googleapis.com so BigQuery datasets cannot be created without customer-managed keys.cloudfunctions.allowedIngressSettings set to ALLOW_INTERNAL_AND_GCLB so functions accept only internal and load-balancer traffic.Preventing exfiltration with VPC Service Controls (opens in a new tab) perimeters creates a security boundary around Google-managed services that controls data movement across the perimeter, even when the caller has valid IAM credentials. Each perimeter contains specific projects and services, and traffic flows from inside the perimeter to outside only when an explicit ingress or egress rule allows it. A perimeter bridge then allows controlled egress from a more protected perimeter to a less protected one, such as from internal data projects to external share projects, without merging the two perimeters.
Exam tip: IAM determines whether a principal is allowed to access data, while VPC Service Controls determines whether data can leave the perimeter — VPC Service Controls blocks copying to resources outside the perimeter even by users with valid credentials.
Implementing dataset and table-level security and classification in BigQuery is a layered governance model that combines resource hierarchy, Identity and Access Management (IAM), data classification, and fine-grained filters. BigQuery (opens in a new tab) resources are ordered as organization, folder, project, dataset, and then table, column, and view, and access flows down this hierarchy unless a lower-level grant overrides it. Classification with policy tags determines which columns are sensitive, while table access control, dynamic data masking, row-level security, and authorized views determine who can see what.
IAM hierarchy and dataset-level permissions grant access by assigning roles to a user, group, or service account on a specific resource in the hierarchy. Datasets are child resources of projects, and a table inherits permissions from the dataset that contains it unless a more specific grant is applied. Organization and project roles affect the ability to run jobs or manage the project, whereas dataset roles affect the ability to access or modify the data inside the project.
Least privilege is enforced by choosing narrow roles and adding conditions that limit when the grant applies. BigQuery supports three role families that differ in scope and control:
Access can be further constrained with IAM policies with conditions, principal access boundary (PAB) policies that limit what a principal can reach, and Privileged Access Manager for just-in-time temporary elevation that is recorded in audit logs.
BigQuery table-level access control breaks dataset inheritance by granting access to a specific table or view without granting access to the complete dataset. The table policy names the users, groups, and service accounts that can read the table, so a pipeline service account can write to one ingestion table while analysts can read only curated marts. This design supports project, dataset, and table separation where a storage project holds datasets, a separate project runs query jobs, and each sensitive table carries its own grant. Choose table-level grants when datasets mix sensitivity levels and creating a separate dataset per table would fragment management.
BigQuery column-level security restricts sensitive columns using policy tags from a classification taxonomy, or type-based classification of data. A taxonomy defines tags such as sensitivity levels, the tags are attached to columns, and only principals with the Fine-Grained Reader role on the tag plus dataset or table read access can read the tagged values. Discovery with Sensitive Data Protection and governance with Knowledge Catalog feed this process by finding personally identifiable information (PII), storing data profiles in BigQuery, and enriching catalog entries with aspects, lineage, and business glossary terms.
A common three-tier taxonomy shows how tag hierarchy controls inheritance from higher to lower sensitivity. A 3_Confidential tag protects very sensitive data such as credit card numbers and grants access to 2_Private and 1_Sensitive columns. A 2_Private tag protects sensitive PII such as first name and grants access to 1_Sensitive columns but not to 3_Confidential columns. A 1_Sensitive tag protects non-public business data such as credit limit and grants no access to 2_Private or 3_Confidential columns. Columns with no tag remain available to all users who have access to the warehouse, so untagged columns must be an explicit decision rather than a default.
Exam tip: Column-level security denies the column entirely without the tag grant, while dynamic data masking still allows the column but obscures its values; column policies on a base table also apply to all authorized views on that table regardless of the view permissions.
BigQuery column-level dynamic data masking lets authorized users query a column while the service obscures values for groups of users based on masking rules. Data flows from the stored column through the masking policy to the query result, so support teams can join and aggregate without seeing raw PII while data stewards with the masking exception still see plaintext. Masking preserves utility for analytics and troubleshooting where full denial would block the query, while policy tags remain the control when the value must be completely hidden.
BigQuery column-level encryption with Authenticated Encryption with Associated Data (AEAD) functions protects values even from operators who can read the table storage. The sender encrypts sensitive fields with a data encryption key (DEK) from the Tink library, wraps the DEK with a key encryption key (KEK) stored in Cloud Key Management Service (Cloud KMS) with Cloud HSM, and stores the encrypted data and wrapped DEK in separate BigQuery tables. At query time BigQuery unwraps the DEK with the KEK and decrypts the column, so access depends on both IAM on the table and IAM on the KMS key. BigQuery also encrypts all data at rest and in transit by default with no opt-out, with customer-managed encryption keys (CMEK) available when compliance requires control of dataset default keys.
BigQuery row-level security filters rows at query time based on a qualifying condition tied to the requester, such as SESSION_USER() matching a tenant ID or region attribute. The filter sits between the stored table and the query engine, so two users who query the same table receive different row subsets without separate tables. Row filters are ideal for multi-tenant fact tables where tenant segmentation can share partitioning and clustering, and clustering the parent table on tenant ID improves pruning for these filtered scans.
BigQuery authorized views (opens in a new tab) enforce row, column, and business-logic boundaries by separating query permission from storage permission. The view is created in a separate dataset, the view is authorized against the source dataset that holds the base tables, and the consumer is granted read access only to the view dataset with no read access to the base tables. When the user queries the view, BigQuery checks the user against the view and checks the view against the source tables, so the view identity bridges the trust boundary between the consumer project and the protected storage project. The same pattern applies to authorized datasets and authorized routines, including authorized user-defined functions (UDFs), which must be explicitly authorized before they can read protected tables on behalf of the caller.
Tenant isolation can use either tenant-specific authorized views or tenant-specific subset tables, and the choice trades governance overhead against performance and placement control. Authorized resources, which include authorized views, authorized datasets, and authorized functions, have a hard limit of 2500 per dataset, while there is no limit on the number of datasets in a project or tables in a dataset.
| Design dimension | Authorized views | Subset tables |
|---|---|---|
| Partitioning and clustering | View inherits the base table scheme; cluster base table on tenant ID for segmentation | Table can be partitioned and clustered to the tenant needs |
| Regionalization | View must reside in the region of the base table and cannot cross regions | Table can reside in the region most appropriate for the tenant, with copy costs |
| Policy and logging behavior | Column policies on the base table apply to all views; access logs appear in base table logging | Each table must reapply column policies; access to each table is logged separately |
Choose authorized views when tenant logic changes frequently and instant redesign of the exposed object matters, because changing the view SQL immediately changes what tenants access. Choose subset tables when tenants need different regions, independent partitioning, or isolated logging and transformation, accepting the cost of schema changes and policy reapplication for each copy.
Identity and Access Management (IAM) determines whether a principal is allowed to access data, while VPC Service Controls determines whether data can leave the perimeter. VPC Service Controls blocks copying to resources outside the perimeter even by users with valid credentials, with movement allowed only by explicit ingress, egress, or perimeter bridge rules.
Choose authorized views when tenant logic changes frequently and instant redesign of the exposed object matters, because changing the view SQL immediately changes what tenants access. Choose subset tables when tenants need different regions, independent partitioning, or isolated logging and transformation, accepting the cost of schema changes and policy reapplication for each copy.
A 3_Confidential tag grants access to 2_Private and 1_Sensitive columns, a 2_Private tag grants access to 1_Sensitive columns but not to 3_Confidential columns, and a 1_Sensitive tag grants no access to higher tags. Columns with no tag remain available to all users who have access to the warehouse, and reading tagged values requires the Fine-Grained Reader role on the tag plus dataset or table read access.
A financial services organization is architecting its Google Cloud environment to support automated data pipelines and analytics workloads. The company has distinct compliance requirements across its environments and needs to design a resource hierarchy that enforces strict data governance.
The architecture must satisfy the following requirements:
How should the organization structure its resource hierarchy and security boundaries?
Last updated