How to Integrate Entra ID and GCP Safely

Published
Length
3 min read

Luis Felipe Dias

All posts

Teams link entra id and gcp to let engineers log in with one work account. This setup syncs user groups from Microsoft to Google Cloud and removes local cloud passwords. Platform teams use this link to manage cloud roles from a central directory. When a worker leaves the company, disabling their directory account stops their cloud work right away. This single flow covers web consoles, command tools, and database sessions across projects. How identity flows between entra id and gcp The link b

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

Teams link entra id and gcp to let engineers log in with one work account. This setup syncs user groups from Microsoft to Google Cloud and removes local cloud passwords.

Platform teams use this link to manage cloud roles from a central directory. When a worker leaves the company, disabling their directory account stops their cloud work right away. This single flow covers web consoles, command tools, and database sessions across projects.

How identity flows between entra id and gcp

The link between entra id and gcp works in two distinct steps. First, an automated background sync sends user profiles and group names to Google Cloud. This job creates matching user records in the Google workspace directory. It also updates group rosters when engineers change teams or leave the firm.

Second, federated sign-in handles the live log in check. When an engineer opens the Google Cloud console, Google sends them back to Microsoft. Microsoft checks their password and MFA device, then sends a signed token back to Google. Google reads that token and starts the cloud session.

For apps and automated jobs, workload federation replaces static service account keys. A job running in Azure can present its Microsoft token to Google Cloud. Google checks that token and trades it for a short-lived cloud token. This removes the need to copy secret key files between clouds.

Common failure modes and how to scope roles

Syncing accounts is only half the battle for platform security. Many teams map broad directory groups to owner or editor roles at the root folder. This gives every engineer in that group write power over production servers and databases. A single stolen token can then expose an entire cloud project.

Shared service accounts create another major blind spot during daily work. Engineers often impersonate one high-privilege service account to run terminal tools or database queries. Cloud audit logs show that the shared account ran a command, but hide the specific SQL query. If someone drops a table, you cannot see the exact text they ran.

Microsoft Entra ID (Azure AD) + GCP IAM Bindings: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Static service account keys also remain a top cause of cloud breaches. Developers download JSON key files to their laptops so local scripts can read cloud resources. Those files sit on disks with no end date and often leak into source control. You should disable key creation across your cloud projects to close this gap.

To fix these risks, split directory groups by job function and project tier. Map read-only groups to production projects and save write roles for tested deploy pipelines. Require MFA on the Microsoft side before issuing any token for Google Cloud.

Securing database and server sessions in Google Cloud

Cloud IAM controls who can change project settings or boot new virtual machines. Still, cloud IAM does not inspect what happens inside a database or server session. Once an engineer connects to a Cloud SQL instance, they often use a shared database user. Native cloud logs miss the row-level queries and results inside that session.

Teams need a way to tie every database query back to the person in the directory. They also need to protect sensitive fields like emails, phone numbers, card numbers, and national IDs. Masking rewrites matched fields in results before they reach the client screen. This keeps production data safe while developers fix bugs or run checks.

Add runtime guardrails and masking beside your databases and APIs

Login rules, role grants, and CI checks govern who connects to your stack. Yet any allowed script, engineer, or AI agent still runs commands with the full scope of its role. For workloads on Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes, SSH, or internal HTTP services, hoop.dev sits beside the service as an open-source proxy, a sidecar for your database or API.

Before a query runs, hoop.dev guardrails check the statement against your rules. An AI Analyzer you configure can score intent or hold risky calls for human review. Next, hoop.dev data masking rewrites sensitive fields in responses, and each verdict is logged per listener. Explore the MIT-licensed project on GitHub.

Frequently asked questions

How does group sync work between Entra ID and Google Cloud?

Microsoft uses a provisioning connector to push users and groups to Google Cloud Identity. This background task runs on a set schedule and keeps group memberships updated without manual work.

Can workloads in Azure talk to Google Cloud without static keys?

Yes, you can set up workload identity federation in Google Cloud to trust your Microsoft tenant. Azure workloads trade their local identity tokens for temporary Google tokens at runtime.

Why do cloud audit logs miss inside-session database queries?

Cloud IAM only checks if a user can reach the database network port or API. Once the database session starts, you need a protocol-aware tool to log specific queries or mask card numbers.

The query runs. The emails stay hidden.