Skip to content

Multi-cloudArchitecture stage

Centralized inspection on AWS with Transit Gateway: patterns and pitfalls

Three ways to inspect traffic centrally on Transit Gateway: an inspection VPC, the Network Firewall attachment, or Gateway Load Balancer, with failure modes.

On this page10 sections

Short answer

How do you centralize traffic inspection on AWS with Transit Gateway?

Route traffic between VPCs, to the internet, and from on premises through one inspection point attached to the transit gateway, and keep both directions of every flow on the same firewall. AWS documents three designs for it: an inspection VPC with AWS Network Firewall, Network Firewall attached natively to the transit gateway, or Gateway Load Balancer with third-party firewalls.

Who this is for: network and cloud architects who run several VPCs and want one place where traffic is inspected. The article is based on AWS documentation and on design work our engineers have delivered: Gateway Load Balancer with Palo Alto Networks VM-Series transparent inspection, and transit gateway route segmentation for east-west and egress inspection.

What does the pattern consist of?

AWS describes a transit gateway as “a Regional virtual router” that routes at layer 3 between VPCs and on-premises networks. Centralized inspection adds one place that holds the firewalls:

  • Spoke VPCs, whose subnet route tables send traffic for other networks to the transit gateway.
  • Transit gateway route tables. Each attachment is associated with exactly one route table and can propagate its routes to one or more. The spokes’ table sends traffic to the inspection attachment; the inspection table routes back to each spoke.
  • The inspection point: a VPC you build, with a transit gateway subnet and a firewall subnet per Availability Zone, or the Network Firewall attachment, where AWS places the endpoints in a VPC it manages.
  • Appliance mode on the inspection attachment.

Three directions are usually in scope: east-west (spoke to spoke), north-south (on premises, through Site-to-Site VPN or Direct Connect gateway attachments), and egress to the internet.

Why is appliance mode needed?

Without appliance mode, a transit gateway tries to keep traffic between VPC attachments in the Availability Zone where it started. The result is asymmetric routing: request and response use different network interfaces, and traffic can be dropped. In AWS’s example, the reply returns through the appliance in a second zone, which never saw the request, so the packet is dropped.

With appliance mode on the inspection VPC’s attachment, the transit gateway picks one network interface in that VPC with a flow hash and uses it for both directions for the life of the flow. AWS attaches conditions:

  • Attach exactly one transit gateway to the inspection VPC. Transit gateways do not share flow state.
  • Stickiness holds while both directions reach the inspection VPC from the same transit gateway attachment. Traffic can drop if source and destination sit on two different attachments, or if the inspection VPC receives traffic from another gateway, such as an internet gateway, and then sends it to the transit gateway after inspection.
  • Turning appliance mode on for an existing attachment can change that attachment’s current routes. Treat it as a change with a rollback.

With Gateway Load Balancer, the target group must use 5-tuple stickiness: AWS does not support the 2-tuple and 3-tuple options when transit gateway appliance mode is on.

Which design? The inspection pattern decision table

AWS Network Firewall is a managed, stateful firewall and intrusion prevention service built on the open-source Suricata engine. Gateway Load Balancer is not a firewall: it distributes traffic to virtual appliances from the vendor you choose, at layer 3, and exchanges traffic with them over GENEVE on port 6081.

The inspection pattern decision table compares the three designs. Rows marked (author) are our engineering reading; the rest come from the AWS pages in the sources.

Inspection VPC with Network Firewall Network Firewall attached to the transit gateway Gateway Load Balancer with third-party firewalls
Who runs what AWS runs the firewall service; you manage policy and rule groups Same, and AWS also places the firewall endpoints in a VPC it manages You run the appliances on EC2; AWS runs the load balancer
Vendor choice Network Firewall only Network Firewall only; third-party firewalls are not supported Any appliance that supports GENEVE and Gateway Load Balancer
Inspection VPC to build Yes No; centralized internet egress still needs a separate egress VPC with NAT and internet gateways Yes
Appliance mode You enable it on the attachment Always enabled You enable it; target group uses 5-tuple stickiness
Routing VPC and transit gateway route tables Transit gateway route tables only, static routes only Route tables, with Gateway Load Balancer endpoints as next hops
TLS inspection Supported Supported Depends on the appliance (author)
AWS Cloud WAN Compatible Not supported, as of September 16, 2026 Not covered here
Costs to plan Endpoint-hours per Availability Zone and per GB, plus transit gateway attachment-hours and per GB Same, plus a second transit gateway processing hop and an extra attachment for centralized internet egress Instances, vendor licenses, Gateway Load Balancer and endpoint charges, plus transit gateway charges
Choose it when (author) You need granular routing control, Cloud WAN, or existing runbooks You use Network Firewall and want the least to operate You need a specific vendor’s features or must reuse existing policy and tooling

AWS’s blog of September 16, 2026, puts it plainly: “For most customers, Transit Gateway Native Attachment provides the simplest operational model.” It keeps the inspection VPC for granular routing control or where a team’s expertise is built around it.

How do you build it?

  1. List the flows that must be inspected, and the ones that must not. Inspection is a policy decision before it is a routing one.
  2. Lay out subnets per Availability Zone. In AWS’s layout, the transit gateway subnet routes to the firewall endpoint in the same zone, and the endpoint’s subnet routes back to the transit gateway. A Network Firewall endpoint cannot filter traffic entering or leaving its own subnet, so the firewall subnets are dedicated.
  3. Design the transit gateway route tables. The spokes’ table sends the default route, or the inspected prefixes, to the inspection attachment; the inspection table routes to each spoke. The most specific prefix wins first; for the same prefix, a static route beats a propagated one.
  4. Turn on appliance mode on the inspection attachment. The native Network Firewall attachment has it on already.
  5. Place firewalls in every enabled zone. AWS recommends multiple Availability Zones for transit gateway VPC attachments. A Gateway Load Balancer target group needs at least one registered target in each enabled zone, and cross-zone load balancing is off by default.
  6. Test outside production. Send a flow whose source and destination sit in different zones through the inspection path. Then remove one appliance and watch existing flows: by default, Gateway Load Balancer keeps them on the failed target, where they drop, and sends new flows to healthy targets.

The inspection failure-mode checklist

# Failure mode Cause in the AWS documentation Check
1 Replies dropped for flows that cross zones Appliance mode off Appliance mode on for the inspection attachment
2 Paths change during a change window Appliance mode enabled on a live attachment Change plan with a rollback
3 Stickiness not guaranteed More than one transit gateway attached to the inspection VPC Exactly one transit gateway
4 Drops after inspection Traffic enters from another gateway, or source and destination use different attachments Trace both directions of each flow
5 Endpoint does not inspect Firewall endpoint in a subnet that carries the traffic it must filter Dedicated firewall subnets
6 Flows break when a target fails Gateway Load Balancer failover defaults to no_rebalance; both failover attributes take the same value Choose the failover behavior on purpose and test it
7 A zone stops inspecting No healthy target in that zone, with cross-zone load balancing off Targets and health checks per zone
8 Stateful rule groups keep default variables on the native attachment Rule groups that reference HOME_NET or EXTERNAL_NET must use values that differ from the firewall policy’s defaults Set both values explicitly
9 New prefixes are not inspected on the native attachment Static routes only Manage the routes in code
10 Higher bill than planned Cross-zone charges when an endpoint filters traffic from another zone; a second processing hop for centralized egress on the native attachment Check the design against current pricing

One more check follows from AWS’s route order rather than from an AWS statement: if spoke VPC routes propagate into the spokes’ table, those more specific routes beat the static default, and east-west traffic skips the firewall. AWS’s example spoke table holds only the static default route.

What about multiple Regions?

Transit gateways are Regional. Two of them connect through a peering attachment, which supports static routes only, and AWS recommends a unique autonomous system number for each peered transit gateway. Our default (author) is one inspection point per Region, with static routes between Regions.

What this article has not tested

  • Nothing here was built or measured for this article. Behavior is as AWS documents it on October 4, 2026; throughput, quotas, and prices are not covered.
  • IPv6, multicast, Cloud WAN designs, multi-Region inspection, and the distributed endpoint pattern are not covered.

FAQ

What is appliance mode on a transit gateway attachment?

It is an attachment option that makes the transit gateway pick one network interface in the appliance VPC, using a flow hash, and keep both directions of the flow on that interface for the life of the flow. It prevents the asymmetric routing across Availability Zones that a stateful firewall would otherwise drop.

Do I need appliance mode with AWS Network Firewall?

If you build the inspection VPC yourself, yes: AWS says to enable it on the attachment of the VPC that hosts the firewall endpoints when the design spans several zones. The Network Firewall attachment to the transit gateway has appliance mode always enabled. In both cases, confirm the setting rather than assuming it.

Why are replies dropped by my inspection firewall?

The usual cause is asymmetric routing. Without appliance mode, the transit gateway tries to keep each direction of a flow in its original Availability Zone, so the reply can reach a firewall that never saw the request. Enable appliance mode on the inspection attachment, and check that only one transit gateway attaches to that VPC.

Can I use a third-party firewall with the Network Firewall attachment?

No. AWS states that the transit gateway’s Network Firewall integration does not support third-party firewalls. For a vendor appliance, build an inspection VPC with a transit gateway attachment, put Gateway Load Balancer in front of the appliances, enable appliance mode, and use 5-tuple stickiness on the target group.

Does the inspection point also cover traffic from on premises?

Yes, by route-table design. Site-to-Site VPN and Direct Connect gateway attachments follow transit gateway route tables like VPC attachments, so their traffic can be sent to the inspection attachment. Test both directions, because AWS warns that flows can drop when traffic arrives through another gateway or on different attachments.

Sources

Checked against vendor documentation on How the articles are checked

  1. How AWS Transit Gateway works (appliance mode, Availability Zones, route evaluation, Network Firewall integration)docs.aws.amazon.comread
  2. What is AWS Transit Gatewaydocs.aws.amazon.comread
  3. Transit gateway network function attachmentsdocs.aws.amazon.comread
  4. Route traffic to a Network Firewall attachmentdocs.aws.amazon.comread
  5. Transit gateway peering attachmentsdocs.aws.amazon.comread
  6. Direct Connect gateway attachmentsdocs.aws.amazon.comread
  7. AWS Transit Gateway traffic flow and asymmetric routing (AWS Prescriptive Guidance)docs.aws.amazon.comread
  8. Solution options for inline inspection (AWS Prescriptive Guidance)docs.aws.amazon.comread
  9. What is a Gateway Load Balancer?docs.aws.amazon.comread
  10. Gateway Load Balancers (attributes, MTU)docs.aws.amazon.comread
  11. Target groups for your Gateway Load Balancersdocs.aws.amazon.comread
  12. Edit target group attributes (failover, flow stickiness)docs.aws.amazon.comread
  13. Gateway Load Balancer endpointsdocs.aws.amazon.comread
  14. What is AWS Network Firewall?docs.aws.amazon.comread
  15. Considerations for transit gateway-attached firewallsdocs.aws.amazon.comread
  16. Network Firewall with a transit gateway across Availability Zonesdocs.aws.amazon.comread
  17. Choosing the right inspection architecture for AWS Network Firewall (AWS blog, 2026-09-16)aws.amazon.comread
  18. AWS Network Firewall native Transit Gateway support in all Regions (What’s New, 2025-07-08)aws.amazon.comread

About the author

Eduard Agopyan

Founder & Principal Architect, Saber Security · Sofia, Bulgaria

Eduard Agopyan is the founder and principal architect of Saber Security, a network, security, and cloud engineering company headquartered in Sofia, Bulgaria. Eduard has more than seven years of experience building and operating secure networks across on-premises and multi-cloud environments, and sets the architecture standards behind Saber Security’s work on networks, cloud connectivity, edge security, Zero Trust, and automation.

Need help with the work itself?

The articles describe the method. If you want our engineers to apply it to your environment, start with a few lines about what you run today.

    No results