Article

Google Workspace Gmail, Endpoint & Recovery Hardening: Security Sandbox, MTA-STS, GCPW Windows MDM & the 25-Day Restore Cutoff

A production engineering runbook for hardening Google Workspace mail flow beyond DMARC, managing Windows 10/11 fleets with GCPW and company-owned inventory controls, and architecting data recovery around Google Workspace’s hard 25-day post-trash purge cutoff.

9 min read

Verified on: Google Workspace Enterprise Plus (Hosted S/MIME, Enterprise Data Regions) & Enterprise Standard / Business Plus (Security Sandbox, Windows MDM), Windows 10/11 Pro/Enterprise (GCPW), Android Zero-Touch & Apple Business Manager (ADE)

Contents
  1. 1. Advanced Inbound Gmail Hardening (Beyond DMARC)
  2. 1.1 Pre-Delivery Inspection & Attachment Detonation
  3. 1.2 Lock Down Legacy Mail Protocols & Enforce Transport Security
  4. 1.3 Hosted S/MIME vs. Gmail Confidential Mode
  5. 2. Windows Fleet Management via GCPW & Company-Owned Inventory
  6. 2.1 Google Credential Provider for Windows (GCPW)
  7. 2.2 Company-Owned Inventory, Drive for Desktop Gating & Mobile Enrollment
  8. 3. Data Recovery Lifecycles & The Hard 25-Day Cutoff
  9. The 20-Day User & 25-Day Post-Trash Recovery Cliffs
  10. Designing a Resilient Recovery Architecture
  11. 4. Production Hardening Checklist
WatchGoogle Workspace Gmail, Endpoint & Recovery Hardening: Security Sandbox, MTA-STS, GCPW Windows MDM & the 25-Day Restore Cutoff

Publishing a p=reject DMARC record stops outsiders from spoofing your domain, but it does nothing against a zero-day weaponized attachment from a compromised vendor, a legacy IMAP app password sitting on an unmanaged laptop, or an employee permanently emptying their Trash 26 days before anyone notices a critical folder is gone.

This runbook pairs with Google Workspace Shared Drives, Zero-Data-Loss Offboarding & Vault Resilience Runbook and Email Authentication & Security Protocols to close three high-impact operational blind spots: inbound Gmail defenses beyond DMARC, Windows/mobile endpoint governance via GCPW, and the hard 25-day post-trash recovery ceiling.

[!IMPORTANT] Executive Summary (BLUF):

  1. Harden Gmail Beyond DMARC: Enable Security Sandbox (with a Content Compliance rule for Admin Quarantine), Enhanced Pre-Delivery Message Scanning, and Safe Browsing click-time URL warnings; enforce MTA-STS (with TLS-RPT) & TLS compliance; and lock down POP/IMAP by disabling it for web/Gmail-app OUs or restricting native mail clients strictly to allowlisted OAuth2 client IDs.
  2. Govern Windows 10/11 & Company-Owned Fleets: Deploy Google Credential Provider for Windows (GCPW) to bind Windows sign-in to Workspace credentials + 2SV, enforce OS updates and BitLocker (only after configuring external recovery key escrow), and restrict Drive for Desktop sync strictly to registered company-owned hardware.
  3. Respect the 20-Day User & 25-Day Post-Trash Recovery Cliffs: Deleted user accounts expire after 20 days, and purged Gmail/Drive items expire 25 days after leaving Trash. On Day 26, data is permanently gone—even Google Support cannot recover it. Pair Vault with Data Export (cold exit archive) and an isolated, immutable third-party SaaS backup.
flowchart LR
    Inbound["Inbound Mail<br/>(Post-SPF/DKIM/DMARC)"] --> TLS["MTA-STS + TLS-RPT<br/>& TLS Compliance"]
    TLS --> ML["Enhanced Pre-Delivery Scanning<br/>& Security Sandbox Detonation"]
    ML --> Inbox["Hardened Gmail<br/>(Scoped POP/IMAP + OAuth Client Allowlist,<br/>Hosted S/MIME / Confidential Mode)"]
    Endpoint["Windows 10/11 & Mobile Fleet"] --> GCPW["GCPW + MDM Inventory<br/>Desktop 2SV, Escrowed BitLocker, OMA-URI,<br/>Drive for Desktop Gated to Owned Devices"]
    Data["Deleted Drive / Gmail Data"] --> Trash["User Trash (30d)"]
    Trash --> AdminWin["Admin Restore Window<br/>(25d Items / 20d Deleted Users)"]
    AdminWin --> Gone["Day 26+: Permanently Unrecoverable<br/>(Even by Google Support)"]

1. Advanced Inbound Gmail Hardening (Beyond DMARC)

SPF, DKIM, and DMARC validate sender domain identity—they do not inspect malicious payloads sent from legitimate, hijacked partner mailboxes. Layer these native Workspace Gmail controls on top of email authentication:

[!NOTE] Licensing Gate: Several controls in this runbook carry strict SKU boundaries: Hosted S/MIME and Enterprise Data Regions (per-OU placement) require Enterprise Plus (or Frontline Plus / Education for S/MIME); Security Sandbox requires Business Standard/Plus, Enterprise Standard/Plus, or Frontline Plus; and Windows Device Management requires Business Plus, Enterprise Standard/Plus, Frontline, Education Standard/Plus, or Cloud Identity Premium. If you are on Business tiers or Enterprise Standard, weigh the Enterprise Plus per-seat uplift against an API-integrated third-party email security layer before upgrading solely for native checkboxes.

1.1 Pre-Delivery Inspection & Attachment Detonation

Configure these across two distinct Admin Console sections:

  • Security Sandbox (Apps → Google Workspace → Gmail → Spam, Phishing and Malware): Detonates suspicious incoming attachments inside an isolated virtual environment before delivery, catching zero-day payloads and polymorphic malware that evade signature scanners. (Requires Business Standard/Plus, Enterprise Standard/Plus, or Frontline Plus.) Because Security Sandbox routes flagged messages to user Spam by default—not Admin Quarantine—create a Content Compliance rule (Gmail → Compliance) matching the Security Sandbox spam metadata attribute to divert hits into an admin-controlled Quarantine where users cannot self-release them.
  • Enhanced Pre-Delivery Message Scanning (Apps → Google Workspace → Gmail → Spam, Phishing and Malware): Enables dedicated deep-learning inspection that selectively delays a tiny fraction (<0.05%) of suspicious inbound messages for deeper reputation and phishing analysis.
  • Safe Browsing Click-Time URL Warnings (Apps → Google Workspace → Gmail → Safety → Links and external images): Dynamically evaluates link reputation at click time and warns users before loading credential-harvesting pages.

1.2 Lock Down Legacy Mail Protocols & Enforce Transport Security

  • Scope POP/IMAP Correctly (Do Not Break XOAUTH2 Clients): XOAUTH2 is an authentication mechanism over IMAP/POP/SMTP, not a separate protocol. Disabling IMAP globally under Gmail → End User Access → POP and IMAP Access immediately breaks OAuth2-authenticated Apple Mail (iOS/macOS), Thunderbird, and Outlook profiles. Instead, split by OU:
    1. Web & Gmail Mobile App-only OUs: Disable POP and IMAP entirely.
    2. Native Mail Client OUs (Apple Mail / Outlook / Thunderbird): Keep IMAP enabled and enforce Allow only specific OAuth client IDs (verify IDs under Security → Access and data control → API controls → Manage Third-Party App Access).
    3. Legacy Relays & App Passwords: Audit Gmail Log Events before cutover and migrate scan-to-email printers, ERP connectors, or scripts off per-user App Passwords onto IP-authenticated Google Workspace SMTP Relay in a dedicated exception OU.
  • Enforce MTA-STS (with TLS-RPT) & TLS Compliance: Publish an MTA-STS policy (_mta-sts TXT record + HTTPS policy file) alongside a TLS-RPT (_smtp._tls) reporting record. Run MTA-STS in mode: testing for 2–4 weeks and verify daily TLS-RPT JSON reports before moving to mode: enforce so an expired mta-sts.<domain> cert or stale MX entry doesn’t bounce inbound mail. Scope hard Gmail → Compliance → Transport Layer Security (TLS) compliance rules strictly to verified partner domains so a partner’s expired cert does not silently bounce critical traffic.
  • Restricted Email Delivery: For high-risk OUs (contractors, kiosks, K-12 students, or sensitive internal workflows), restrict accounts so they can only send and receive email with an explicit allowlist of internal or partner domains.

1.3 Hosted S/MIME vs. Gmail Confidential Mode

Choose the right message-protection mechanism—they solve different problems:

Control How It Works Operational Trade-Off
Hosted S/MIME (Enterprise Plus / Frontline Plus / Education only) Encrypts and digitally signs messages in transit using X.509 certificates managed in Workspace. Preserves Google’s native spam filtering, Workspace DLP, Google Vault retention, and search indexing. Unavailable on Business SKUs and Enterprise Standard.
Gmail Confidential Mode Sets message expiration, optional SMS passcode verification, and strips recipient forward/copy/print/download UI controls. Strong deterrence against casual forwarding, but does not prevent screenshots or out-of-band photo capture—treat as an IRM guardrail, not cryptographic DRM.
Gmail Defense Harden Gmail Beyond DMARC: MTA-STS, Sandbox & OAuth IMAP

2. Windows Fleet Management via GCPW & Company-Owned Inventory

Many Workspace-native organizations assume they need a separate Microsoft Intune license just to enforce baseline Windows 10/11 security. If your fleet is browser-centric and standardized on Google Workspace, Google Credential Provider for Windows (GCPW) + Windows Device Management (requires Business Plus, Enterprise Standard/Plus, Frontline, Education Standard/Plus, or Cloud Identity Premium) closes baseline identity and OS-hardening gaps directly from the Admin Console.

[!NOTE] Know the Architectural Ceiling: GCPW + Google Windows MDM is a strong fit for lean, browser-centric fleets that only need identity-bound desktop 2SV, OS update rings, and basic CSP hardening. It is not a full lifecycle replacement for Intune or a dedicated RMM: if your Windows fleet (30–50+ endpoints) requires Win32/MSI app deployment, third-party patching, Windows Autopilot zero-touch imaging, or integrated EDR, keep a dedicated UEM/RMM alongside Workspace rather than fighting raw OMA-URI strings at scale.

2.1 Google Credential Provider for Windows (GCPW)

  • Unified Desktop Identity & 2SV: Users sign into Windows 10/11 endpoints using their Google Workspace credentials, triggering Workspace 2SV challenges right at the Windows login screen and passing automatic SSO into Chrome and Workspace web apps.
  • Admin Console Windows MDM: Once enrolled in Windows device management (Devices → Mobile & endpoints → Settings → Windows), admins can push:
    • BitLocker full-disk encryption enforcement (only after external recovery key escrow is verified—see caution below)
    • Automated Windows OS update rings
    • Local Windows administrator privilege restrictions (removing standing local admin rights)
    • Custom OMA-URI CSP policies for granular Windows hardening

[!CAUTION] BitLocker Key Escrow & Brownfield Rollout Guardrails:

  1. No Native BitLocker Key Escrow: Google Workspace Windows MDM does not store, escrow, or display 48-digit BitLocker recovery keys in the Admin Console. Never enforce BitLocker from Workspace until you verify an external escrow destination (on-prem Active Directory DS, Entra ID, or an RMM/scripted vault backup) on pilot hardware—otherwise a BIOS/UEFI update or TPM reset permanently locks the laptop.
  2. Never Dual-Enroll Intune Machines: Windows 10/11 supports only one active MDM authority. If endpoints are already managed by Microsoft Intune, leave Google Windows Device Management OFF and feed Intune compliance signals into Workspace via Devices → Mobile & endpoints → Settings → Third-party integrations.
  3. Prevent Profile Orphaning: First-time GCPW sign-in creates a brand-new Windows user profile unless you pre-configure GCPW Account Association (custom Directory user attribute or HKLM\Software\Google\GCPW SID mapping) before migrating existing local/AD desktops.

2.2 Company-Owned Inventory, Drive for Desktop Gating & Mobile Enrollment

  • Register Corporate Hardware Serials: Upload company-owned device serial numbers into Devices → Mobile & endpoints → Company-owned inventory.
  • Gate Drive for Desktop to Owned Devices: Under Apps → Google Workspace → Drive and Docs → Features and Applications (or Drive for desktop), enable “Only allow Google Drive for desktop on authorized devices”—preventing users from syncing entire Shared Drives onto unmanaged personal laptops. Audit 100% serial-number coverage and active Endpoint Verification reporting first, and roll out per-OU so you do not lock out legitimate corporate laptops. Note that gating Drive for Desktop stops bulk local filesystem sync, not browser-based zip downloads—pair it with Context-Aware Access or Drive DLP/download restrictions on unmanaged devices.
  • Zero-Touch Mobile Provisioning: Pair corporate mobile fleets with Android Zero-Touch Enrollment and Apple Business Manager — Automated Device Enrollment (ADE, formerly DEP) / APNs / Apps and Books (formerly VPP) so devices enroll automatically out of the box without manual user setup.
  • Automated Compliance Rules (Wipe account vs. Wipe device): Configure automated endpoint rules to immediately block Workspace sync or wipe corporate data if a device drops encryption, disables screen lock, or becomes rooted/jailbroken. On BYOD / personal device OUs, strictly use Wipe account (selective wipe of the Android Work Profile or iOS corporate account)—reserve Wipe device (full factory reset) exclusively for registered company-owned hardware.
Endpoint Governance Google Workspace GCPW for Windows 10/11: 2 Critical Guardrails

3. Data Recovery Lifecycles & The Hard 25-Day Cutoff

Google Workspace’s underlying infrastructure provides high availability—synchronously replicating sharded, encrypted file chunks with randomized filenames across multiple data centers—but high availability is not a backup.

The 20-Day User & 25-Day Post-Trash Recovery Cliffs

  1. When a user deletes a Gmail message or Drive file, it moves to Trash (retained for up to 30 days unless the user empties Trash manually).
  2. Once purged from Trash, Workspace administrators have an absolute maximum of 25 days to restore individual Drive or Gmail items from the Admin Console (Directory → Users → [User] → Restore data).
  3. Deleted User Accounts Have Only 20 Days: If an entire user account is deleted (Directory → Users → Recently deleted), the restore window is 20 days—five days shorter than the post-trash item window.
  4. Past the Cutoff, Data Is Permanently Purged: On Day 26 (or Day 21 for deleted accounts), data is permanently purged across Google’s storage layer. Not even Google Cloud Technical Support can recover it.

Designing a Resilient Recovery Architecture

  • Separate Vault from Backup: As detailed in Google Workspace Shared Drives, Zero-Data-Loss Offboarding & Vault Resilience Runbook, Google Vault is an eDiscovery and compliance archive—it does not perform point-in-time folder restores back into a live user’s Drive or Gmail with intact sharing ACLs.
  • Treat Data Export as Cold Exit Storage, Not RTO Recovery: Use Data Regions (Enterprise Standard includes org-wide Fundamental Data Regions; per-OU multi-region placement requires Enterprise Plus) to pin covered Workspace data at rest to US or EU geographies. Treat the Data Export tool (Admin Console → Data → Data import & export → Data export) strictly as a periodic cold-archive/compliance dump: it enforces a 30-day cooldown between full exports, requires an initiating Super Admin account >30 days old with 2SV enabled, expires the exported GCS archive after 30 days, and does not reconstruct Drive sharing ACLs.
  • Harden the Third-Party SaaS Backup Blast Radius: Any third-party SaaS backup platform requires broad domain-wide OAuth scopes across Gmail and Drive. Isolate the backup management console behind separate IdP/MFA credentials (never SSO through the same Workspace tenant it backs up) and require immutable snapshots so a compromised Workspace Super Admin cannot wipe both production and backups.
Data Recovery The 25-Day Google Workspace Trash Recovery Cutoff

4. Production Hardening Checklist

  • Enable Security Sandbox + Enhanced Pre-Delivery Message Scanning (Gmail → Spam, Phishing and Malware), add a Content Compliance rule to route Sandbox hits to Admin Quarantine, and enable Safe Browsing click-time warnings (Gmail → Safety → Links and external images).
  • Audit legacy mail relays/printers first; disable POP/IMAP for web/Gmail-app OUs, and restrict native mail client OUs (Apple Mail/Outlook/Thunderbird) via Allow only specific OAuth client IDs.
  • Publish an MTA-STS policy (testing + TLS-RPT _smtp._tls monitoring → enforce) and scope strict TLS Compliance rules only to verified partner domains.
  • Pilot GCPW + Windows Device Management on an IT test OU (never dual-enrolling Intune machines); configure Account Association for existing profiles and verify external BitLocker recovery key escrow before enforcing encryption.
  • Populate Company-owned inventory, verify Endpoint Verification coverage, gate Drive for Desktop per-OU, and confirm BYOD mobile rules use Wipe account (not Wipe device).
  • Verify that your backup RPO/RTO does not rely on Google Workspace’s 20-day deleted-user or 25-day post-trash restore windows, and isolate third-party backup console credentials from Workspace SSO.