AI Security

Zero‑Trust Document Protection for AI Summarization with Google Vertex AI and Cloud Storage

TL;DR: Store raw documents in a locked Cloud Storage bucket, encrypt them with Customer‑Managed Encryption Keys (CMEK), grant Vertex AI read‑only access via a short‑lived service account, process summaries in a private VPC, and log every read/write with Cloud Audit Logs. Rotate keys weekly and delete temporary files automatically.

What are the main attack surfaces in an AI‑driven summarization pipeline?

When you feed customer files to a large language model, three vectors can expose sensitive data:

Zero‑trust means you assume every component could be compromised and enforce the least privilege, encryption, and continuous monitoring.

How to set up a zero‑trust storage layer with Google Cloud Storage

1. Create a dedicated bucket for raw documents, e.g., gs://my‑biz‑raw‑docs. Set the bucket policy to private and disable Uniform bucket-level access only if you need fine‑grained object ACLs.

2. Enable Customer‑Managed Encryption Keys (CMEK) using Cloud KMS. Generate a key ring and a symmetric key, then bind the bucket to the key:

gsutil kms encryption -k projects/PROJECT_ID/locations/global/keyRings/my‑ring/cryptoKeys/my‑key gs://my‑biz‑raw‑docs

3. Restrict access with IAM. Grant a short‑lived service account (created in step 4) the role roles/storage.objectViewer on the bucket. Do NOT grant roles/storage.objectAdmin to the Vertex AI service account.

How to provision a least‑privilege Vertex AI service account

Vertex AI runs under a Google-managed service account by default. For zero‑trust you should create a custom service account that only has the permissions you explicitly need:

  1. Run gcloud iam service-accounts create vertex‑summarizer --display-name "Vertex Summarizer".
  2. Assign the role roles/aiplatform.user (allows model invocation) and roles/iam.serviceAccountTokenCreator (enables short‑lived token generation).
  3. Bind the bucket viewer role from the previous section to this service account.

When you start a summarization job, generate an OAuth 2.0 access token that expires in 15 minutes and pass it to the Vertex AI endpoint. This limits the window an attacker could misuse the token.

How to keep processing isolated in a private VPC

Vertex AI can be configured to run in a private endpoint that lives inside a VPC. This prevents the model from reaching the public internet and stops data exfiltration.

Combine this with VPC Service Controls to define a security perimeter that includes the bucket and the Vertex AI project.

How to audit every document access and enforce retention

Google Cloud Audit Logs automatically record READ and WRITE events for Cloud Storage and Vertex AI. Configure a sink to export logs to BigQuery for analysis:

gcloud logging sinks create vertex‑audit-sink bigquery.googleapis.com/projects/PROJECT_ID/datasets/audit_logs --log-filter="resource.type=("gcs_bucket" OR "aiplatform_endpoint")"

Set up a scheduled query that flags any read event without a matching short‑lived token, and alert the security team via Cloud Monitoring.

After a summarization job finishes, delete the temporary copy of the source file (if you made one) and the generated summary after a configurable retention period (e.g., 30 days). Use Object Lifecycle Management rules to automate deletion.

What operational practices keep the pipeline secure over time?

Rotate CMEK keys weekly and re‑encrypt existing objects using gcloud kms keys rotate.

Rotate service‑account keys every 30 days; store them in Secret Manager with versioning.

Run a quarterly penetration test focused on the VPC perimeter and token‑reuse scenarios.

Document the data‑flow diagram and store it in a version‑controlled repository. AISecAll can help you formalize this documentation and run regular compliance checks.

FAQ

Need a practical AI security review?

AISecAll reviews prompts, tool permissions, document flows, and agent behavior so small teams can use AI without guessing where the risk sits.

Book a call Discuss a project