What Is a Service Perimeter? Understand Access and Egress Controls in Google Cloud VPC Service Controls
A service perimeter is a security boundary around supported Google Cloud managed services and resources. This article uses the term for Google Cloud VPC Service Controls (VPC SC): communication inside a perimeter is allowed by default, while communication across it to Google Cloud services is blocked unless a policy permits it. VPC SC adds context based controls alongside IAM and network firewalls; it does not replace them.
What Is a Service Perimeter? Understand Access and Egress Controls in Google Cloud VPC Service Controls
A service perimeter is a security boundary around supported Google Cloud managed services and resources. This article uses the term for Google Cloud VPC Service Controls (VPC SC): communication inside a perimeter is allowed by default, while communication across it to Google Cloud services is blocked unless a policy permits it. VPC SC adds context based controls alongside IAM and network firewalls; it does not replace them.
What does the boundary protect?
If a privileged account is misused or credentials are stolen, an actor may try to copy data to another project or storage location. IAM decides which identities may perform which actions. VPC SC adds a boundary check for supported service API requests, including whether a request crosses the perimeter and which identity, service, resource, or network context is involved. For example, a copy between two buckets inside one perimeter can be allowed while a copy to an outside bucket is denied unless an exception permits it.
VPC SC covers communication involving supported Google Cloud managed services. It is not a general firewall for all internet traffic and does not block third party APIs or services on the internet. Some use cases can work without a VPC network, although network based access may require additional configuration such as access levels.
How is it different from IAM and a VPC firewall?
IAM answers “who can do what to which resource?” VPC SC checks whether a supported Google Cloud service API request crosses a perimeter and satisfies its contextual policy. A request can pass the perimeter check and still fail for lack of IAM permission; it can also have IAM permission and still be denied by the perimeter. Use both.
A VPC firewall filters IP connections through network interfaces. VPC SC evaluates supported service API requests at the service boundary. Neither should be treated as a substitute for the other: firewall rules do not express every service API boundary condition, and VPC SC does not cover unsupported services or third party APIs.
Ingress and egress describe request context
Ingress is an API client outside the perimeter accessing a resource inside it. For example, an external analytics client reading a protected Cloud Storage bucket may need an ingress rule. Egress involves a client or resource inside the perimeter and a Google Cloud resource outside it, such as copying an object from an inside bucket to an outside bucket.
These terms describe the request and resource positions, not necessarily the direction in which bytes move. Do not decide a rule from an operation name such as “download” or “copy.” Map the client, job project, source and destination resources to their perimeters. When multiple perimeters are involved, every relevant policy may need to allow the request.
Rules can narrow allowed identities, services, projects or resources, network context and, where supported, API methods. Any one matching rule may allow a request, so broad rules can weaken precise restrictions. A few Google managed resources can be accessible regardless of ingress or egress policy, and method level restrictions are not supported by every service.
Hypothetical example: sharing an analytics result
Example (hypothetical): An organization places a sensitive source bucket and a BigQuery analytics project inside one perimeter. It wants to deliver result files to one partner project without allowing copies to arbitrary projects. First map the user or service account, the project running the job, and the perimeter containing each resource. Then consider a narrowly scoped egress rule for the necessary destination and service; review ingress separately if an outside client must call an inside resource. Keep IAM permissions least privileged. This design does not guarantee safe sharing by itself: verify the rule scope, service support and audit logs.
Adopt the perimeter safely
**Check coverage.** List the projects and services to protect. Review the current supported products list and service specific limitations. The `gcloud access-context-manager supported-services list` and `describe` commands can help inspect support; do not assume every service or method is covered.
**Map real request paths.** Record identities, client networks, job projects, target resources and calls between services. One workflow can invoke several service methods.
**Start in dry run.** Violations of the dry run policy are logged rather than denied. This helps estimate impact but does not protect against the requests it observes. Understand how dry run compares with the enforced policy and what is actually logged.
**Use logs to narrow rules.** Inspect service, method, identity, project and resource context. Permit only necessary paths. Broad identities and wildcards can create data egress paths. Access levels do not have an equivalent dry run mode, so test them separately.
**Verify and enforce gradually.** In a nonproduction environment, test both expected workflows and traffic that should fail. Check known service limitations and recovery procedures. Once logs and business flows are understood, enforce in small changes. Roll back or return to dry run to diagnose unexpected failures. Dry run does not evaluate the impact of Restricted VIP or API access paths.
Limits and common misunderstandings
**Not every Google Cloud service is supported.** Check support and limitations at deployment time; unsupported combinations can fail or behave unexpectedly.
**Not a general internet firewall.** Design internet egress, DNS, routing and firewall controls separately.
**Not comprehensive metadata control.** VPC SC primarily controls data movement across boundaries for supported services. Use IAM and other controls for metadata access.
**Dry run does not block.** It is an observation step, not an enforcement state.
**Perimeter bridges can be broad.** A bridge permits communication between projects across perimeters in both directions. More specific ingress and egress rules may offer tighter control.
When is it useful?
VPC SC can add a useful layer when sensitive data sits in supported Google Cloud services and cross project API access or credential misuse is a concern. It does not by itself control third party APIs, guarantee all metadata locations, create a legal residency commitment, or protect unsupported services. Start with a data flow and support inventory, then design VPC SC together with IAM, network controls, organization policies and contractual commitments.
Sources
[VPC Service Controls overview](https://docs.cloud.google.com/vpc-service-controls/docs/overview)
[Ingress and egress rules](https://docs.cloud.google.com/vpc-service-controls/docs/ingress-egress-rules)
[Service perimeter configuration](https://docs.cloud.google.com/vpc-service-controls/docs/service-perimeters)
[Supported products and limitations](https://docs.cloud.google.com/vpc-service-controls/docs/supported-products)
[Dry run mode](https://docs.cloud.google.com/vpc-service-controls/docs/dry-run-mode)
[Enable VPC Service Controls](https://docs.cloud.google.com/vpc-service-controls/docs/enable)