Article

Google Workspace Security Hardening: The 4-Layer Defense-in-Depth Runbook

A production engineering runbook for hardening Google Workspace from the outside in. Enforce OU-staged 2SV and Super Admin FIDO2 isolation, lock down Google Drive with Trusted Domains, IRM, and DLP, govern third-party OAuth scopes, close email routing bypasses, and stream audit telemetry to BigQuery or a SIEM.

10 min read

Verified on: Google Workspace Enterprise Standard / Plus, Google Admin Console, GAM7 / GAMADV-XTD3, Google Cloud BigQuery

Contents
  1. 1. Layer 1: Securing the Identity Perimeter
  2. 1.1 Staged 2-Step Verification (2SV) Rollout Without Self-Lockouts
  3. 1.2 Tier-0 Super Admin Isolation, FIDO2 Keys & Passkeys
  4. 1.3 Context-Aware Access & BYOD Mobile Isolation
  5. 2. Layer 2: Locking Down the Data Vault (Drive, IRM & DLP)
  6. 2.1 Kill “Anyone with the Link” & Enforce Trusted Domains
  7. 2.2 Shared Drive OU Boundaries, Classification Labels & IRM
  8. 2.3 Automated Workspace Data Loss Prevention (DLP)
  9. 3. Layer 3: Governing Third-Party OAuth Apps & Shadow AI
  10. 3.1 Audit & Lock Down High-Risk Scopes
  11. 4. Layer 4: Email Routing Edge Cases & SIEM Telemetry
  12. 4.1 Closing Email Routing & DMARC Gaps
  13. 4.2 Streaming Workspace Audit Logs to BigQuery & SIEM
  14. 5. Production Hardening Verification Checklist
WatchGoogle Workspace Security Hardening: The 4-Layer Defense-in-Depth Runbook

Out-of-the-box Google Workspace defaults are engineered to minimize collaboration friction, not to enforce Zero Trust security. Left unconfigured, standard tenants permit users to share Drive files publicly via “Anyone with the link”, leave third-party OAuth consent grants open to unverified SaaS or shadow AI apps, and retain persistent OAuth refresh tokens that survive password resets and MFA enrollment.

Industry telemetry shows that MFA remains disabled or inactive across over 60% of end-user SaaS accounts, while attackers increasingly rely on Adversary-in-the-Middle (AitM) cookie theft and illicit OAuth consent phishing to bypass legacy authentication controls entirely. Leaving 2-Step Verification (2SV) optional or relying solely on Google’s native attachment scanning creates silent blind spots across identity, data egress, and administrative telemetry.

flowchart TD
    Attack["External Threats & Insider Misconfiguration"] --> L1["Layer 1: Identity Perimeter<br/>OU-Staged 2SV, Super Admin Isolation, FIDO2/APP, Passkeys, Context-Aware Access"]
    L1 --> L2["Layer 2: Data Vault Lockdown<br/>No Public Links, Trusted Domains, Shared Drive OUs, IRM & Workspace DLP"]
    L2 --> L3["Layer 3: Third-Party App Governance<br/>OAuth App Access Control, Scope Restrictions, Persistent Token Audits"]
    L3 --> L4["Layer 4: Email Routing & SIEM Telemetry<br/>DMARC p=reject, Suspended Account Routing Audits, BigQuery / SIEM Log Streaming"]

[!IMPORTANT] Executive Summary (BLUF):

  1. Shift from Collaboration-First to Secure-by-Design: Enforce 2-Step Verification (2SV) at the Organizational Unit (OU) level with staggered grace periods, isolate Tier-0 Super Admin accounts from daily mail/browsing, and mandate physical FIDO2 hardware keys + Google Advanced Protection Program (APP) for privileged roles.
  2. Eliminate Accidental Data Exfiltration: Flip Drive external sharing defaults from "Anyone with the link" to Off (Restricted) or explicit Trusted Domains, apply Information Rights Management (IRM) to block download/print/copy on confidential files, and deploy automated Workspace DLP detectors.
  3. Close the OAuth & Shadow AI Backdoor: Audit existing third-party OAuth grants (gmail.modify, gmail.send, drive) and lock API Controls so users can only authorize admin-vetted applications.
  4. Verify Routing & Stream Logs: Audit custom MTA envelope routing rules that can bypass suspended user states, enforce DMARC alignment, and stream Workspace audit logs to BigQuery or a SIEM for real-time alerting on risky OAuth grants, impossible-travel ASNs, mass Drive deletions, and break-glass logins.

1. Layer 1: Securing the Identity Perimeter

1.1 Staged 2-Step Verification (2SV) Rollout Without Self-Lockouts

Leaving 2SV optional is accepting a known breach path. At the same time, flipping mandatory 2SV tenant-wide in a single click locks out remote workers, breaks legacy service accounts, and floods the service desk.

Roll out enforcement by Organizational Unit (OU) using Google Workspace’s built-in enrollment grace period:

  1. Navigate to Google Admin Console > Security > Authentication > 2-Step Verification.
  2. Create a staged rollout OU structure (for example: /Engineering & IT first, /Finance & Execs second, /General Staff third).
  3. Set Allow users to turn on 2-Step Verification to On, select Enforcement: On from [Date] with a New user enrollment period (7 to 14 days), and restrict Allowed methods to Any except verification codes via text, phone call once enrollment crosses 95%.
  4. Audit un-enrolled accounts daily via gam before the enforcement cutoff hits.
# Query users in a target OU who are not yet enrolled in 2SV (GAM7 / GAMADV-XTD3)
gam print users query "orgUnitPath='/General Staff' isEnrolledIn2Sv=false" fields primaryEmail,orgUnitPath,isEnrolledIn2Sv,isEnforcedIn2Sv
Identity Breakdown How to Safely Enforce Google Workspace 2SV

1.2 Tier-0 Super Admin Isolation, FIDO2 Keys & Passkeys

Daily-driver email accounts should never hold Super Admin privileges. A single compromised browser extension or phishing payload in a daily inbox should not expose tenant-wide IAM, billing, and routing controls.

  • Separate Admin Identities: Provision dedicated adm-firstname@ Super Admin identities that have Gmail and Calendar turned off (or strictly scoped out of everyday communication) and are excluded from routine browser sessions.
  • Hardware FIDO2 Keys + Advanced Protection Program (APP): Issue two physical FIDO2 security keys per Super Admin and Finance lead (one primary, one stored offline as a backup), set 2SV enforcement to Security keys only on the Tier-0 OU, and enroll those identities in Google’s Advanced Protection Program (Security > Authentication > Advanced Protection Program). APP blocks untrusted third-party OAuth access by default and enforces stricter account-recovery verification.
  • Platform Passkeys for General Staff: Enable passkeys (Security > Authentication > Passwordless) so standard users authenticate via origin-bound WebAuthn credentials instead of phishable SMS or TOTP codes. For deeper cryptographic details on WebAuthn origin binding and AitM defense, see Passkeys & FIDO2 WebAuthn Architecture: The Enterprise Guide to Phishing-Resistant Authentication.
Privilege Isolation How Super Admin Isolation Works

1.3 Context-Aware Access & BYOD Mobile Isolation

Passwords and even stolen session tokens should fail if presented outside trusted device and network boundaries.

  • Context-Aware Access (Security > Access and data control > Context-Aware Access): On Enterprise Plus / Cloud Identity Premium tiers, bind access to Gmail, Drive, and the Admin Console to device posture (OS patch level, disk encryption enabled, screen lock active, endpoint verification agent present) and corporate egress IP ranges. Even if an attacker extracts an active session cookie via an AitM proxy, requests from an unmanaged host or foreign ASN are blocked before reaching Workspace APIs.
  • BYOD Mobile Isolation (Work Profiles & MAM): Adding a Workspace account directly to an unmanaged personal phone’s native mail client often forces full-device MDM policies (including remote factory wipe capability). Enforce Android Work Profiles (cryptographic container separation where IT can wipe only the work container) and iOS User Enrollment / App-Level MAM (Devices > Mobile and endpoints > Settings > Universal) so corporate data remains isolated without exposing personal photos or messages.

2. Layer 2: Locking Down the Data Vault (Drive, IRM & DLP)

Default Drive sharing permits users to generate public "Anyone with the link" URLs. A single forwarded link on a financial model or HR export exposes sensitive data to the open internet without authentication.

  1. Go to Apps > Google Workspace > Drive and Docs > Sharing settings.
  2. Set Sharing outside of your organization to Allowlisted domains (or Off for sensitive OUs).
  3. Disable Anyone with the link (Link sharing > Off for external public access) at the root OU, creating a narrowly scoped exception OU only for marketing/public-relations assets if genuinely required.
  4. Configure Trusted Domains (Account > Domains > Allowlisted domains, or directly via Apps > Google Workspace > Drive and Docs > Sharing settings > Allowlisted domains) so employees can collaborate externally only with verified partner domains rather than arbitrary consumer Gmail/Yahoo addresses.
Egress Control How Trusted Domains Secure Google Drive

2.2 Shared Drive OU Boundaries, Classification Labels & IRM

Organizing all company files into one flat Shared Drive invites over-permissioning. Align Shared Drives with your OU hierarchy (Finance, Legal, Engineering, Operations) and pair Drive Classification Labels with Information Rights Management (IRM). (For the complete 5-tier Shared Drive RBAC matrix, 3-stage zero-data-loss offboarding workflow, and Google Vault vs. off-cloud backup architecture, see our companion Google Workspace Shared Drives, Offboarding & Vault Resilience Runbook.)

  • Disable Download, Print, and Copy (IRM): For files labeled Confidential or Restricted, configure automatic IRM rules so external or view-only collaborators can read the document in-browser without being able to export a local PDF/CSV copy.
  • Expiration Dates on Temporary Access: Enforce automatic access expiration (e.g., 30 days) on external partner shares so audit permissions do not stay open indefinitely after a project ends.
Document Controls How Google Drive Locks Down Confidential Files

2.3 Automated Workspace Data Loss Prevention (DLP)

Manual sharing rules fail when users accidentally attach sensitive records to outbound Gmail messages or paste secrets into shared docs. Deploy Workspace DLP (Rules > Create rule > Data protection) using a three-stage pipeline:

  1. Identify Sensitive Data Types: Inventory PII (SSN, tax IDs), payment data (PCI), API secrets, and proprietary internal project codes.
  2. Build Detectors: Combine Google’s predefined content detectors with custom regular expressions (e.g., internal customer ID prefixes or private key headers -----BEGIN (RSA|EC|OPENSSH) PRIVATE KEY-----).
  3. Start in Audit, Then Enforce Block: Run new rules in Audit only for 7–14 days to measure false positives, then switch the action to Block external sharing (Drive) and Quarantine / Reject (Gmail) with automatic user notifications.
Automated Guardrails How Workspace DLP Stops Leaks

3. Layer 3: Governing Third-Party OAuth Apps & Shadow AI

Even with hardware FIDO2 keys and strict Drive sharing, third-party OAuth tokens create a persistent backdoor. When an employee clicks “Sign in with Google” on a flashy AI meeting notetaker or calendar plugin, they grant an OAuth 2.0 refresh token that survives password changes and 2SV enforcement.

sequenceDiagram
    autonumber
    actor User as Employee
    participant App as Unverified SaaS / Shadow AI App
    participant Google as Google OAuth Consent Server
    participant Admin as Workspace API Controls

    User->>App: Clicks "Sign in with Google"
    App->>Google: Requests high-risk scopes (gmail.modify, drive, contacts)
    Google->>Admin: Check API Access Policy for Client ID
    alt Unconfigured (Default Permissive)
        Google-->>User: Displays consent prompt
        User->>Google: Clicks "Allow"
        Google-->>App: Issues persistent OAuth refresh token (bypasses future MFA)
    else Hardened (Block Unconfigured + Allowlist)
        Admin-->>Google: App not on Trusted list & requests restricted scopes
        Google-->>User: Error 400 admin_policy_enforced (Blocked)
    end

3.1 Audit & Lock Down High-Risk Scopes

  1. Navigate to Security > Access and data control > API controls > Manage Third-Party App Access.
  2. Audit every existing connected app requesting high-risk scopes—especially gmail.modify, gmail.send, https://mail.google.com/ (full mailbox), and drive (full Drive read/write).
  3. Switch Unconfigured third-party apps from Allow users to access to Don’t allow users to access any third-party apps (or restrict internal/unverified apps while explicitly marking vetted enterprise tools as Trusted).
  4. Audit and revoke stale user-level OAuth grants via gam during every offboarding or security sweep:
# List all third-party OAuth tokens granted across the Workspace tenant
gam all users print tokens

# Revoke a suspicious OAuth Client ID for an impacted user
gam user [email protected] delete token clientid <CLIENT_ID_HERE>
OAuth Governance How OAuth Controls Stop Consent Phishing

4. Layer 4: Email Routing Edge Cases & SIEM Telemetry

4.1 Closing Email Routing & DMARC Gaps

Two email-layer misconfigurations silently undermine Workspace security even in hardened tenants:

  • DMARC Header Alignment: SPF alone only validates the hidden MAIL FROM envelope. Without an active DMARC policy (p=quarantine progressing to p=reject), attackers can still spoof your visible From: header. Follow our Email Authentication & Security Protocols Field Guide to deploy 2048-bit DKIM and strict DMARC alignment.
  • Suspended Account Routing Bypass: When an employee leaves and you suspend their Workspace account, custom Google Workspace Routing rules (Apps > Google Workspace > Gmail > Routing) evaluated at the MTA envelope layer can still redirect or deliver mail to forwarding targets before user suspension checks apply. Always audit catch-all and envelope routing rules during offboarding and remove obsolete forwarding entries.
Header Alignment How DMARC Blocks Forged Emails
MTA Routing Trap How Email Routing Bypasses Suspended Accounts

4.2 Streaming Workspace Audit Logs to BigQuery & SIEM

Google scans over 300 billion email attachments weekly at the platform layer, but relying solely on invisible upstream defenses leaves you blind to tenant-specific compromises. Default alert emails sent to one admin inbox are fragile and get buried.

  1. Enable Data Export to BigQuery (Reporting > Data integrations > BigQuery Export) or connect your SIEM (Chronicle / Microsoft Sentinel / Elastic) via the Google Workspace Reports API.
  2. Configure automated high-fidelity alerts (Rules > Activity rules) for four critical signals:
    • New OAuth Grants to High-Risk Scopes: Any non-allowlisted client_id requesting Gmail, Drive, or Admin SDK scopes.
    • Anomalous Logins & New ASNs: Successful logins from unexpected autonomous systems or foreign geographies bypassing normal corporate egress.
    • Mass Drive Deletions or Exports: Sudden spikes in delete, trash, or download events exceeding baseline thresholds (early ransomware/exfiltration signal).
    • Break-Glass Emergency Account Sign-In: Immediate P1 pager/webhook notification whenever a Tier-0 recovery account authenticates.
-- Example BigQuery audit query (Workspace Activity export): detect high-risk third-party OAuth grants
SELECT
  TIMESTAMP_MICROS(time_usec) AS event_time,
  email AS user_email,
  token.client_id,
  token.app_name,
  scope AS granted_scope
FROM
  `your_project.workspace_logs.activity`,
  UNNEST(token.scope) AS scope
WHERE
  record_type = 'token'
  AND event_name = 'authorize'
  AND (
    scope LIKE '%mail.google.com%'
    OR scope LIKE '%gmail.modify%'
    OR scope LIKE '%drive%'
  )
  AND TIMESTAMP_MICROS(time_usec) >= TIMESTAMP_SUB(CURRENT_TIMESTAMP(), INTERVAL 7 DAY)
ORDER BY
  event_time DESC;
Telemetry & Detection How Workspace Log Streaming Stops Attacks

5. Production Hardening Verification Checklist

Before signing off on a Google Workspace tenant audit, verify every control across all four layers:

  • OU-Enforced 2SV: 100% of active users enrolled in phishing-resistant 2SV; SMS/Voice fallback disabled for all hardened OUs.
  • Super Admin Isolation: Daily email accounts hold zero admin roles; Tier-0 accounts protected by dual FIDO2 keys + Advanced Protection Program (APP).
  • Context-Aware Access: Device posture and trusted IP policies enforced on Admin Console, Drive, and Gmail.
  • Drive Default Off: "Anyone with the link" public sharing disabled; external collaboration restricted to Trusted Domains.
  • IRM & DLP Active: Confidential Drive files enforce download/print/copy restrictions; DLP rules actively block PII/PCI/secret egress.
  • OAuth Allowlist Enforced: Unconfigured third-party apps blocked via API Controls; legacy high-risk tokens audited and purged.
  • Email & Routing Verified: DMARC enforced at p=quarantine or p=reject, and MTA routing rules audited for suspended-account bypasses.
  • SIEM / BigQuery Streaming Live: Audit logs exported automatically with P1 alerting on break-glass logins, mass deletions, and risky OAuth grants.