Notes on VPC
depth
2
Classless Inter-Domain Routing (CIDR) block for e.g, 10.0.0.0/16. CIDR allows fine-grained subnet specification where the number of bits could be anywhere between 1 to 32. e.g. 8, 10, 16, 20, 24, 28, 29, etc. With classful (A, B, C class networks), it must be 8, 16 or 24 resulting in too small or too big sub-network.
Note: In AWS, Smallest block is /28 with 16 addresses, largest block is /16 with 64K addresses ?? Technically largest could be /8 network for 10.*.*.* network.
As per RFC1918, AWS uses private IP ranges :
10.0.0.0/8 (255.0.0.0) Largest Block. 16 Million addresses. 2^24
172.16.0.0/12 (255.240.0.0) 1 Million Addresses. 2^20
192.168.0.0/16 (255.255.0.0) 64K addresses. 2^16
Link-Local Address Purpose
-------------------------------------------------------------
169.254.169.254 EC2 Instance Metadata Service (IMDS)
169.254.169.123 Amazon Time Sync Service (NTP)
169.254.x.x (general) Non-routable local communication
-------------------------------------------------------------
AWS reserves 5 IPs address (first 4 and last 1 IP address) in each Subnet which are not available for use for EC2 instance. For e.g. for a Subnet with a CIDR block 10.0.0.0/24 the five IPs are reserved:
10.0.0.0: Network address
10.0.0.1: Reserved by AWS for the VPC router
10.0.0.2: Reserved by AWS for mapping to Amazon-provided DNS
10.0.0.3: Reserved by AWS for future use
10.0.0.255: The address is reserved for future support for Broadcast.
.
. 1:N
. ENI ---------- Private IPs (Primary Private IP required + Optional )
.
. 1:1
. ENI ---------- Public IP (eth0 only) | (primary eth0) Elastic IP
.
. 1:N
. ENI ---------- (Elastic IP + Private IP) (Every Elastic IP requires one Private IP)
.
. 1:N 1:1
. ENI ---------- Security Groups ENI -------- MAC Address
.
. Note: ENI belongs to AZ.
.
The subnet type is determined by how you configure routing for your subnets.
The main difference is the route for 0.0.0.0/0 in the associated route table.
These are EC2 instances that be configured with multiple network interfaces.
|
| VPC1 VPC2
|
| Public Private [Subnets must be in Same AZ]
| Subnet EC2 Subnet
| ENI1 ENI2
|
|
|
| +---VPC----IGW-----------VGW----------+
| | |
| | VPC-Main-Route-Table |
| | |
| | Route-Table1 Route-Table2 |
| | Subnet1 Subnet2 |
| | |
| +-------------------------------------+
Example Subnet Route Table Entries:
----------------------------------------------------------------------------------
Destination Target Notes
----------------------------------------------------------------------------------
10.0.0.0/16 local Default route for intra-VPC traffic.
0.0.0.0/0 igw-xxxxxxxx Public internet access (for public subnets).
0.0.0.0/0 nat-xxxxxxxx Internet access via NAT Gateway (for private subnets).
192.168.0.0/16 pcx-xxxxxxxx VPC Peering connection route.
172.16.0.0/12 vgw-xxxxxxxx VPN Gateway route for hybrid connections.
10.1.0.0/16 tgw-xxxxxxxx AWS Transit Gateway route for connected VPCs.
| VPC
+---------------------------------+
| IGW |
| |
| Firewall |
| |
| |
| NACL NACL |
| PubSubnet PrivSubnet |
| NAT-GW |
| |
| EC2 EC2 |
| SG SG |
| |
+---------------------------------+
. Implicit Deny. Stateful
.
. Inbound:
.
. TCP 80 0.0.0.0/0
. TCP 443 0.0.0.0/0
. TCP 22 sg-xxxx Allow connections from EC2 for which sg-xxx is attached.
.
. Outbound:
.
. TCP ALL 0.0.0.0/0 Allow all outbound traffic.
.
Represents firewall rules. Associated at (EC2) instance level.
Security groups are stateful, which means that if inbound traffic is allowed, the corresponding outbound traffic is automatically allowed as well. This is because stateful security groups automatically apply changes to outgoing rules based on incoming rules.
Security group rules are whitelist only, and contain an implicit DENY ANY rule.
Overall, security groups are like a Layer 4 distributed firewall.
Security groups can reference other security groups for source. The referenced security group is used like an alias for the private IP addresses of the instances that SG is attached to:
sg-one TCP 22 allow : Means accept ssh connection from all private IPs
for which the sg-one is attached to.
. Implicit Allow Stateless.
.
. Inbound Rules:
. Rule
. 100 TCP 80 0.0.0.0/0 ALLOW Allow HTTP traffic from anywhere.
. 110 TCP 443 0.0.0.0/0 ALLOW Allow HTTPS traffic from anywhere.
. 120 All All 0.0.0.0/0 DENY Deny all other inbound traffic.
.
. Outbound Rules:
.
. 100 All All 0.0.0.0/0 ALLOW Allow all outbound traffic.
.
|
| VPC Firewall VPC or Firewall Subnet (One Per AZ)
| Redirect
| Subnet1 -----------> Gateway Load Balancer (Firewall internally Uses GWLB)
| <---------- Firewall Appliances
|
| Subnet2
|
|
| Redirect
| VPC1 -----------> VPC with Firewall (Inspection VPC)
| <-----------
| VPC2 (Firewall Interface Endpoint)
|
.
. +-----------------------------
. | 0.0.0.0/0 |
. V |
. Ingress Firewall Local |
. IGW ---------> VPC Endpoint ------------> Protected Subnets
. (Subnet)
. |
. <----------------+
. 0.0.0.0/0
.
.
|
| Region1 Region2
| Account1 Account2
| (Peering Connection pcxxxx)
| VPC-A <-------------------------------> VPC-B
|
| (Request & Accept Peering)
|
| Note: Just update route tables in each VPC's subnets.
| Update SG inbound/outbound rules.
|
|
| Destination Target
| 10.0.0.0/16 Local
| 172.31.0.0/16 pcx-1122334
|
| Optional: EnableDNS at Requestor Side and Acceptor Side
|
|
- If you enable DNS on Peering Connection at Requestor side, the Requestor VPC will automatically get fallback DNS resolution from Acceptor VPC. And vice versa.
.
. Shared Subnets === Get Implicit Routing
.
.
. VPC1 VPC2 VPC3
.
. Private-Subnet1
. Private-Subnet2 ------------------------------ (Only Subnet2 shared)
. Share
.
The owner vpc can share it's subnet with one or more VPCs in other accounts.
Owner Accounts must be managed by organizations (same or different organizations OK).
VPC Console, you can view all subnets (with owner VPC information). You can communicate with EC2 on shared subnet without having to update any route tables!
Share from VPC console or use cli:
aws ram create-resource-share ....
aws ram associate-resource-share ....
Use Cases:
Note: RAM share also enables you to share specific resources like PHZ, Resolver Rules, Prefix List, Transit Gateway, etc.
. +-------------+
. Peering Mesh | TGW |
. +----------------| Inter/Intra |
+---------------------------+ | | Region | +---- on-premise
| | +--------------+ +-------------+ |
| Shared VPC - Account-1 | | | +--> VGW-VPN-in-Another-Account
| [ To Share NAT-GW] | | TGW | [Attachments] |
| |======| [Account1] |-------------------+--> VPC-in-Dev-Account
| [Central Network Ac] | | [RAM Shared] | [GRE Tunnel] |
| | +--------------+ [BGP ] +--> VPC-in-Prod-Account
+---------------------------+
.
. ==== indicates initial attachment to shared VPC on TGW creation.
. There is one route-table associated with one attachment.
. You must share TGW before attaching VPC if it belongs to another account.
.
Transit Gateway is a global Resource in an account but not useful without atleast one VPC attachment.
The following are the key concepts for transit gateways.
Attachments — You can attach the following:
Transit gateway Maximum Transmission Unit (MTU) — The maximum transmission unit (MTU) is 8500 bytes. Traffic over VPN connections can have an MTU of 1500 bytes.
Transit gateway route table — A transit gateway has a default route table and can optionally have additional route tables. It can have static and dynamic (propogated by the attachments) entries. The target of these routes could be any transit gateway attachment.
Associations — Each attachment is associated with exactly one route table. Each route table can be associated with zero to many attachments.
Route propagation — A VPC, VPN connection, or Direct Connect gateway can dynamically propagate routes to a transit gateway route table. With a Connect attachment, TGW routes are propagated by default. With a VPC, you must create static routes to send traffic to the transit gateway. With a VPN connection, routes are propagated from the transit gateway to your on-premises router using Border Gateway Protocol (BGP). With a Direct Connect gateway, allowed prefixes are originated to your on-premises router using BGP. With a peering attachment, you must create a static route in the transit gateway route table to point to the peering attachment.
Create Transit Gateway in One account, share it using RAM in other accounts. Create "Transit Gateway Attachment" from TGW to VPC.
TGW is highly available and scalable service to consolidate the AWS VPC routing configuration for a region with a hub-and-spoke architecture.
Acts as a Regional virtual router to interconnect VPCs and on-premises networks.
Traffic always stays on the global AWS backbone. Immune to DDoS attacks.
TGWs across different regions can peer with each other to enable VPC communications across regions.
VPC Peering and Transit Gateway are used to connect multiple VPCs.
VPC Peering is not transitive. You need full mesh connectivity.
Transit Gateway provides hub-and-spoke architecture. Best if you have too many VPCs.
AWS Transit Gateway is a fully managed service that connects VPCs.
Connects On-Premises networks through a central hub without relying on numerous point-to-point connections or Transit VPC.
You can attach all your hybrid connectivity (VPN and Direct Connect connections) to a single Transit Gateway instance, consolidating and controlling your organization’s entire AWS routing configuration in one place! Very powerful.
TGW: Up to 5,000 Attachments per Region.
TGW: Up to 50 Gbps (burst)/attachment. For VPC peering, there is no limit since it is only limited by the instance bandwidth limit.
Slightly lower bandwidth than VPC peering since it involves a hardware (router) hop.
Slightly higher cost due to Data transfer, Data processing, and Hourly per attachment. However operational (administration) cost is lower with simplified architecture.
Security Group (cross-referencing) (per EC2 instance) is supported in Peering but not in TGW.
Extra cost of hourly charge per attachment in addition to data fees.
Use VPC Peering if number of VPC connected is small (<10) or heavy data transfer involved or specific need for low latency or more than 50 Gpbs throughput required.
You can not share NAT Gateway using RAM directly with other VPCs. To share NAT GW among VPCs, you should share Transit GW as described above:
See https://aws.amazon.com/blogs/networking-and-content-delivery/
using-nat-gateways-with-multiple-amazon-vpcs-at-scale/
You can also connect 2 Transit Gateways from 2 accounts with TGW Peering. It is less common but powerful. See https://docs.aws.amazon.com/vpc/latest/tgw/tgw-peering.html
TGW connect attachment is used with GRE (point to point tunneling) protocol and is used to attach VPC. TGW connect peer is used with primarily GRE + BGP (Border Gateway Protocol) and is used to attach SD-WAN or network appliances. :
| VPC Attachment VPC3
| VPC1 --------+
| | Connect
| TGW Attachment Appliance
| Gateway-IP (e.g. 192.0.2.1) ---------------- Peer IP (e.g. 172.31.1.11)
| BGP-IPs (169.254.6.2) ............... BGP IP (e.g. 169.254.6.1)
| | BGP Peering
| VPC2 --------+
|
On the AWS side of the VPN connection, a Virtual Private Gateway (VGW) provides two VPN endpoints for automatic failover. (Managed hardware solution)
On the customer side, a customer gateway (CGW) needs to be configured, which is the physical device or software application on the remote side of the VPN connection:
VGW - Virtual Private Gateway (Max only on1 VGW per VPC allowed. Default is None)
TGW - Transit Gateway
.
VPC Site-to-Site-VPN On-Premises-Network
+-----------+-------------------------+------------------+
| | VPN Connection | |
| VGW | 1:10+ | |
| or | <===================> | Customer-Gateway |
| TGW | BGP | |
| | (2 VPN Tunnels) | |
+-----------+-------------------------+------------------+
.
.
. --------------- On-Premise-1
. VGW --------------- On-Premise-2
. --------------- On-Premise-3
.
. (VPN CloudHub)
.
You can also use Transit Gateway to On-promises configuration using Site-to-Site VPN if you want to connect multiple VPCs.
Recommended that customer Gateway VPN device to support BGP (Border Gateway Protocol) since it auto advertises the connection routing from/to virtual gateway.
One VGW can support upto 10 Customer Gateway creating VPN CloudHub! (Limit can be increased)
Site-to-site VPN Concepts:
VPN connection: A secure IPSec connection between your on-premises equipment and your VPCs.
VPN tunnel: An encrypted link where data can pass from the customer network to or from AWS. Each VPN connection includes two VPN tunnels which you can simultaneously use for high availability.
Customer gateway: An AWS resource which provides information to AWS about your customer gateway device.
Customer gateway device: A physical device or software application on your side of the Site-to-Site VPN connection.
Target gateway: A generic term for the VPN endpoint on the Amazon side of the Site-to-Site VPN connection.
Virtual private gateway: A virtual private gateway is the VPN endpoint on the Amazon side of your Site-to-Site VPN connection that can be attached to a single VPC.
Transit gateway: A transit hub that can be used to interconnect multiple VPCs and on-premises networks, and as a VPN endpoint for the Amazon side of the Site-to-Site VPN connection.
Note:
Note that Dx (DirectConnect GW) can connect multiple VPCs too but traffic will have
to go through DirectConnect-DataCenterRouter if you are not using TGW.
VPN cloud Hub: To connect multiple remote networks (e.g. multiple branch offices) we may have multiple VPN Hardware devices (with each one per branch). Use Transit Gateway for this.
Always make sure every VGW and customer Gateway has unique ASN especially in HUB kind of configuration so that BGP kind of protocols will work fine.
.
. ECMP
. TGW ------------------ Customer Gateway
. Faster VPN
|
| VPC
| Internet
| clientVPN ---------> clientVPN-Endpoint -------> One subnet per AZ in VPC.
| {OpenVPN client} {public DNS Name}
| {created by AWS }
|
|
|
DX = Direct Connect VIF = Virtual Interface VGW = Virtual Private Gateway TGW = Transit Gateway DX-GW = Direct Connect Gateway - Use it to connect to multiple regions. DX-GW? = Optional Direct Connect Gateway
Note: VGW - Virtual Private Gateway is used as both purposes as:
VPN terminator (with public IP) Or
DirectConnect Terminator (to connect to VPC).
VGW is attached to VPC, not subnet.
Dx-GW is also a Direct Connect Terminator.
TGW is not DirectConnect Terminator. You need Dx-GW in front of TGW.
VIF, DX-GW, VGW all are logical constructs and not physical devices.
AWS Backbone is present at the DirectConnect Location itself.
VIF is logically present in DirectConnect Location.
VGW is logically present in VPC.
DX-GW is a global resource and outside region.
Need seperate VIF per VPC or TGW
+-----------------+
| AWS Region | Max 50 VIFs +--------------+
| | | |
| S3-Service <--|---------------- Pub-VIF | |
| | | | LAG
| VPC1 -- VGW <-|-DX-GW?--------- Priv-VIF | Dx-Router in | <---------> Customer-Router
| | | Dx-Location | <---------> On-premise
| VPC2 -- TGW <-|-DX-GW---------- Transit | | BGP
| | VIF +--------------+
+-----------------+
.
. +---------+ VIF1 +-------------+
. Region1 VPC1 VGW -----| DX-GW |--------------| Dx-Location | One VIF per connection.
. Region2 VPC2 VGW -----| |--------------| |
. +---------+ VIF2 +-------------+
.
| Note: Pub-VIF allows you to connect to any Amazon public IP (e.g. s3.amazonaws.com).
| The traffic does not go through public internet.
|
| LAG - Link Aggregation Group uses multiple connection as single logical connection.
| This is to increase the speed.
|
AWS Direct Connect is available at locations around the world such as Mumbai.
Customer network router device must support Border Gateway Protocol (BGP) and BGP MD5 authentication.
802.1Q VLAN encapsulation must be supported across the entire connection, including intermediate devices.
Private VIF, by default, used to connect to single VPC using VGW.
For connecting to multiple VPCs in multiple regions, use DirectConnect Gateway.
If you want to connect to multiple VPCs, you need VGW+DX-GW or TGW+Dx-GW.
DX-GW before connecting to TGW is required.
However Dx-GW before VGW is required only if you want to connect to many VPCs.
The transit Gateway multi-region peering is also supported now.
If you enable SiteLink feature while creating VIF, it allows traffic with-in multiple DX locations without going through AWS regions. If you have multiple On-premise Datacenters, then data will flow through Dx Locations faster:
+---------------+-------+
| AWS | |---- VIF DX-Location-1 ----- On-Premise-DC1
| Region-1 | Dx-GW |
| Region-2 | |---- VIF DX-Location-2 ----- On-Premise-DC2
+---------------+-------+
Note: For connection between DC1 and DC2, SiteLink enables quick flow bypassing Regional routers.
There are many other options also possible:
Virtual Private Gateway is either:
- VPN terminator at AWS side OR
- Direct Connect Terminator
Configure the VGW as VPN terminator.
This acts like Site-To-Site VPN with Direct Connect:
|
| Direct Connect + Site-to-Site VPN
| Dx Location
| IPSec ---------------------+ On-Premise
| VPC - VGW <------------Public-|DxRouter--Customer |-----Customer GW
| VIF | Router | (Router+BGP+IPSec)
| +--------------------+
|
Recollect A simple DirectConnect:
| Simple Direct Connect
| Dx Location
| ---------------------+ On-Premise
| VPC-VGW--[Dx]---------------Private|DxRouter--Customer |-----Router (Router+BGP)
| VIF | Router | (IPSec Not Required)
| +--------------------+
|
Recollect A simple VPN Terminater for Site-to-Site VPN:
| Simple Site-to-Site (Hardware) VPN Terminator
|
| On-Premise
| VPC-VGW-------------------Customer (Router + IPSec) + Optional BGP
| GW
|
Note:
The peer GRE address is the private IP address of the SD-WAN instance that you want to create
the GRE tunnel to. The Transit Gateway GRE address is one of the available IP addresses from
the Transit Gateway CIDR. (e.g. 192.0.2.0/24, etc)
The BGP inside IPs are part of a /29 CIDR block. (e.g. from the 169.254.0.0/16 range for IPv4).
Virtual Private Gateway is similar to Transit Gateway and is associated with IP address in
range 169.254.0.0/16 CIDR block with highest 8 addresses. i.e. Last byte being 248-254
Generic Routing Encapsulation is a tunneling protocol developed by Cisco Systems that can encapsulate a wide variety of network layer protocols inside virtual point-to-point links or point-to-multipoint links over an Internet Protocol network.
Central VPC with VPN connections with other VPCs is a transit VPC.
|
| VPN VPN
| VPC1 <------> Transit-VPC <-------> VPC2
| VGW CustomerGW VGW
| Appliances
|
aws ec2 describe-network-interfaces
VPC Endpoint is a virtual device (like a router) which enables EC2 instances to access AWS services without going over internet.
There are two types of VPC Endpoints:
Note: VPC endpoint is associated with a resource policy. This usually restricts the principals and roles who can access this endpoint.
If this endpoint is pointing to the service, say S3, then the S3 bucket policies further restricts access to the principals -- it can even have conditions like aws:SourceVpc and aws:SourceVpce to protect the access.
The request context of AWS sdk calls may include aws:SourceVPC details as much as possible.
If you have your own Service that you want to make it available to other AWS customers, you can use AWS PrivateLink technology. i.e. You create VPC-Endpoint-Service and let your customers know about it. Your customers will create VPC (interface) Endpoint and connect to your Service :
+------------------------------+ +--------------------------------+
| VPC (Service Provider) | | Another AWS customer VPC |
| | | |
| [Your Own Service] | PrivateLink | |
| +--------+ | <------------------- | {VPC-Interface-Endpoint} |
| +------------+ |EndPoint| | | (Security Group) |
| |NLB or GWLB |<-|Service | | | |
| +------------+ +--------+ | | |
+------------------------------+ +--------------------------------+
Endpoint Service dns name looks like below:
vpce-svc-01234567890abcdef.us-east-1.vpce.amazonaws.com # Resolves to NLB internal IP Address.
my-service.my-domain.com # To associate private dns name, must verify domain ownership
At the other end, the VPC Endpoint is associated with an ENI with unicast routing enabled to this destination service IP.
Interface Endpoint is a set of ENIs (think network card one per AZ) within your VPC.
It uses DNS record to direct your traffic to the private IP address of the nearest interface.
It requires application changes to change the service URL, For example:
https://my-bucket-name.vpce-sd98fs0d9f8g.s3.us-west-2.vpce.amazonaws.com
Gateway Endpoint also uses DNS and route prefix in your route table to direct traffic meant for S3 or DynamoDB to the Gateway Endpoint (something like 0.0. 0.0/0 -> igw).
Both endpoints are associated with permission policies.
Interface endpoint requires Security Group, but Gateway Endpoint do not.
The gateway endpoints are created at VPC level and available from all subnets provided their route tables are pointing to them.
|
| Routing Destination
| pl-68154001 vpce-12345678
|
| RouteTable (PrefixList)
| Subnet1 --------------------------->
| VPC-Gateway-Endpoint (No IP Address. Similar to IGW)
| Subnet2 --------------------------->
| RouteTable
|
| E.g. prefix list id: pl-68a54001 (com.amazonaws.us-west-2.s3) and endpointID vpce-12345678
|
Uses an implicit Private IP (we need not configure). No public IP needed.
Endpoint must be associated with one or more route tables.
Endpoint Policy controls access to resources within the service. (e.g. For S3 gateway endpoint, you can control what s3 buckets can be accessed).
One Gateway Endpoint per Service. i.e. One S3 Gateway Endpoint and Another DynamoDB endpoint.
Can access service in same region only.
Note: No additional charges for using VPC gateway endpoint. Only bandwidth data transfer cost.
When you create a gateway endpoint (for example for S3), you select the VPC route tables for the subnets that you enable. The following route is automatically added to each route table that you select:
Destination Target
prefix_list_id Gateway-endpoint-id
E.g. prefix list id: pl-68a54001 (com.amazonaws.us-west-2.s3) and endpointID vpce-12345678
One subnet can be associated with multiple vpc endpoints (one per service).
One VPC gateway (for a service) can be associated with multiple subnets.
Gateway Endpoint is free, interface endpoint costs money.
Using Gateway Endpoint the client applications don't need to modify the S3 access code and no private DNS required. The https://s3.us-west-2.amazonaws.com/ endpoint is correctly resolved to internal VPC address using that special routing table entry involving prefix list.
Usually VPC endpoint means VPC interface Endpoint at the client side to access some service (provided by AWS or by another VPC).
+------------------------------------------------+
| |
| VPC {VPC-Interface-Endpoint} |
| (client) (policy) |
| |
| vpc-endpoint-service-URL For App | PrivateLink AWS-Service
| | ------------------> (VPC Endpoint Service)
| subnet1-AZ1 | Technology Partner Service
| subnet2-AZ1 [ENI-For-Endpoint-One-per-AZ] | (NLB IP, Partner VPC)
| (SG) | Service-dns-name
| subnet3-AZ2 | (private hosted zone)
| subnet4-AZ2 [ENI-For-Endpoint-One-per-AZ] |
| [Additional per AZ optional] |
+------------------------------------------------+
PrivateLink + (VPC Peering | Transit Gateway Peering) ===> Access Service Across Regions.
PrivateLink Only ===> Same Region Access Only. Overlapping IP not a problem.
Service domain names look like:
ec2.us-east-1.amazonaws.com
s3-east-1.amazonaws.com
VPC Interface Endpoints, by default, have a DNS name like below. This needs application changes to point to this service (e.g. S3 service):
vpce-xxx.s3.us-east-1.vpce.amazonaws.com (S3 interface Regional Endpoint)
vpce-xxx.s3.us-east-1d.vpce.amazonaws.com (AZ2) (S3 interface Zonal Endpoint)
To enable interface endpoint DNS names to resolve to private IP for a VPC endpoint, you can:
Note: Following is the default vs interface regional endpoints.
Default S3 Bucket Endpoint | S3 Interface Bucket Endpoint
-----------------------------------------------------------------------------------------------
Bucket s3.us-east-1.amazonaws.com | bucket.vpce-xxx.s3.us-east-1.vpce.amazonaws.com
AccessPoint s3-accesspoint.us-east-1.am* | accesspoint.vpce-xxx.*
Control s3-control.us-east-1.am* | control.vpce-xxx.*
-----------------------------------------------------------------------------------------------
From outside VPC the interface bucket endpoint will resolve to public regional endpoint.
From inside VPC, it will resolve to the nearest interface endpoint IP address.
Note: Control endpoint is used for S3 operations such as upload file.
aws s3 ls s3://my-bucket/ --region us-east-1 --endpoint-url https://bucket.vpce-xxx.s3.*
If you enable private dns name, you don't need to verify ownership, because it is totally
internal to consumer VPC. (Remember for endpoint service name, you need to verify ownership)
By default, when you say Shared VPC it means the central VPC with it's subnet shared with many other VPCs. You can have NLB, NATGW, EC2, RDS etc in this subnet that can be easily shared with other VPCs.
.
.
. VPC1 Central VPC VPC2
. subnet1+ central-Subnet subnet2+
. NLB
. NAT-GW, VGW
. RDS, EC2
.
.
Format:
version interface-id dstport protocol bytes
accountId srcaddr dstaddr srcport packets start end action
2 12345789010 eni-xxxx a.b.c.d w.x.y.z 2020 22 6 20 4249 xxxxx xxxxx ACCEPT OK
2 12345789010 eni-xxxx a.b.c.d w.x.y.z 2020 22 6 20 4249 xxxxx xxxxx REJECT OK