> For the complete documentation index, see [llms.txt](https://docs.material.security/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.material.security/getting-started/deployment-guides/your-first-30-days/2-enable-file-security.md).

# 2: Enable Google Drive Security

**Google Drive Security** secures sensitive files synced from Google Drive. It detects files with improper sharing and excessive permissions, external applications with excessive file access, and orphaned file sharing from offboarded accounts, then allows you to take action right from Material.

File detections are enabled immediately and start identifying potential issues right after you connect your tenants, **but you're not yet responding (remediating).** Follow the steps in this guide to configure response and enable remediation.

## Review File Detections

First, familiarize yourself with file-specific detections:

1. From the left navigation, click **Detections**.
2. Click **Filters**, then select **Entity Type**, then **File**.
3. Browse the existing detections, then update your preferred default **Severity** as needed.

<figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/O0VPUA9i883lIQbQrCoZ/image.png" alt="Detection detail view is a slide out that appears after clicking the detection name"><figcaption><p>Detection detail view</p></figcaption></figure>

## Enable Shared Drive Remediation

To send responses to **Shared Drive Admins**, shared drive syncing must be on. If you didn't turn it on in [1: Connect & Sync](https://docs.material.security/getting-started/deployment-guides/your-first-30-days/1-connect-and-sync.md#google-drive-security-settings), do that first.

To check which shared drives Material syncs, from the left navigation expand **Google Drive Security**, then click **Settings**. Under **Syncing and Protection**, click the settings gear next to shared drive syncing.

## Default Responses

Responses for file detections are configured per detection. Response options include:

<details>

<summary>Add Labels</summary>

Automatically add or remove labels from files that match this detection, like "Sensitive" or "Internal."

The labels themselves are managed in your Google Admin console. In Material, choose from your existing labels.

</details>

<details>

<summary>Send email</summary>

When a file detection creates an issue, you can send an email informing the recipient of the issue and asking them to fix it if needed. Using variables, the default message informs the recipient that a specific file name has an issue, and references the detection name so they know what the issue is. It also includes a link to the file so the recipient can fix the issue.

You can customize these emails as needed, and even send multiple emails in response to one issue separated by a period of time.

</details>

<details>

<summary>Time delay</summary>

You can include a time delay before adding another action.

For example, sometimes sending an initial email then giving the recipient time to fix the issue is the best path. Add a time delay between the initial email and another action:

<figure><img src="https://3411262179-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FksjM8NywYRSHu1IlfxdP%2Fuploads%2F2bHOhcFGD68RkWRbqvWo%2Fimage.png?alt=media&amp;token=cde0b3eb-da07-4072-a1e0-b48d2123b3f0" alt="" width="304"><figcaption></figcaption></figure>

</details>

<details>

<summary>Update Permissions</summary>

Automatically update permissions on files that match this detection. Remediation only affects the matched files and doesn't update permissions inherited from a parent folder or drive.

<figure><img src="https://3411262179-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FksjM8NywYRSHu1IlfxdP%2Fuploads%2FXf4gTXtgvPjUwMwMlmCM%2Fimage.png?alt=media&amp;token=6f89eaed-973a-40cc-be66-623a2073ee9b" alt="" width="190"><figcaption><p>Permissions in Google Docs</p></figcaption></figure>

Options include:

* **Revoke Permissions**
  * Update general access permissions to revoke, viewer, commenter, or editor
  * Update permissions for accounts with direct access (customize to internal and external access)
* **Add Permissions**
  * Select specific Google groups or accounts to assign permissions for this file to

</details>

### Configure Default Response

1. From the left navigation, click **Detections**.
2. Click **Filters**, then select **Entity Type**, then **File**.
3. Browse the existing file detections.
4. Open the detection, then set the default response as needed:

<figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/jebEgXvM9DIv8IrsyrDL/image.png" alt="detection default response located in detection detail view" width="311"><figcaption></figcaption></figure>

5. Detections are enabled out of the box, so as soon as you set your default response, it's active. From this detection detail view, you can also disable the detection. **At deployment, we recommend you leave detections enabled and let them run before revising them:**

<figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/LrLanMAAOH7450KkA1vP/image.png" alt="detection enabled toggle on in detection detail view" width="311"><figcaption></figcaption></figure>

{% hint style="warning" %}
At this point, you've configured default responses but you have **not** enabled them completely yet. Follow the steps in [#enable-file-remediation](#enable-file-remediation "mention") below to finish deployment.
{% endhint %}

## Enable File Remediation

Now that you've configured your default responses, enable File Remediation so they take effect. You turn it on separately for My Drives and shared drives, and only for files Material syncs.

### Turn on File Remediation

1. With a Google tenant selected, from the left navigation expand **Google Drive Security**, then click **Settings**.
2. Under **Syncing and Protection**, turn on remediation for My Drives, shared drives, or both.
3. In the window that opens, choose a default:
   * **Default on**: protect every synced account or shared drive. In the next step, you can pick any to leave out.
   * **Default off**: protect only the accounts, groups, or shared drives you pick in the next step.
4. Pick the accounts, groups, or shared drives, then click **Protect**.

### Roll Out Remediation to Specific Accounts or Groups

The default you choose decides who File Remediation covers:

* **Leave out some users:** Choose **Default on**, then pick the accounts or groups to leave out.
* **Roll it out gradually:** Choose **Default off**, then pick only the accounts or groups you want to start with. Only those users receive response emails and have their files remediated.

To change who's covered later, click the settings gear next to the remediation setting, then update your selection. Turning remediation off asks you to confirm.

For My Drives, you can also override File Remediation in account or group settings. Accounts or groups with their own File Remediation override stay on even when you turn remediation off. Learn more in [Group and Account Customization](https://docs.material.security/administration/group-and-account-customization.md).

{% hint style="info" %}
File Remediation applies the detection's full response to every account where it's turned on. If several groups have File Remediation on, they all get the same response. You can't send emails or apply labels to only one of them. To respond differently for one group, disable the default detection and create a [custom detection](https://docs.material.security/detections/detections-overview/custom-detections.md) scoped to that group.
{% endhint %}

{% hint style="success" %}
Google Drive Security is now enabled. Before moving on to configure **Account Security**, take a moment to learn about bulk remediation below.
{% endhint %}

## How to Bulk Remediate

Auto-response is best practice. If you need to revoke access manually for any reason, do this in the Explorer. Try this example to familiarize yourself with this process:

1. From the workspace left navigation, click **Explorer**, then **Files**.
2. The Explorer uses MQL, a querying language unique to Material. Use the query builder to search for files with issues. This example uses the query `shared.externally and location.is_my_drive`, built with the Explorer tools:

   <figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/c0BEyXr2q9WFptR0dt5G/2025-03-20_13-49-05%20(1).gif" alt="search for files in the explorer located in the workspace"><figcaption><p>Search for files in the Explorer. Learn more in <a href="https://docs.material.security/working-with-issues/explorer/file-search.md">File Search</a>.</p></figcaption></figure>
3. Check the boxes for any files you want to revoke access to immediately, then click **Revoke External Access**:

<figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/R4KVJS93Spn8kUtW1SSm/image.png" alt="check boxes for files then click revoke external access at the bottom of the screen to revoke external access to multiple files"><figcaption><p>Revoke external access to multiple files</p></figcaption></figure>

4. Select the domains to revoke access to:

<figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/kda4olRfcO3aGZh9E66Z/image.png" alt="select the domain to revoke access to on this screen by checking the box next to the domain name" width="375"><figcaption><p>Revoke access to a specific domain</p></figcaption></figure>

5. Optionally, toggle on **Set General Access to Restricted**:

<figure><img src="https://content.gitbook.com/content/ksjM8NywYRSHu1IlfxdP/blobs/PuMIbyuy00cBzBLnbnBx/image.png" alt="toggle used to set general access to restricted" width="375"><figcaption><p>Toggle on to Set General Access to Restricted</p></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.material.security/getting-started/deployment-guides/your-first-30-days/2-enable-file-security.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
