Yandex Cloud
Search
Discuss with expertTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
    • Cloud Interconnect
    • Cloud Backup
    • Cloud Registry
    • Yandex AI Studio
    • Compute Cloud
    • Object Storage
    • Managed Service for Kubernetes®
    • Yandex BareMetal
    • Smart Web Security
    • Security Deck
    • Managed Service for PostgreSQL
    • Managed Service for ClickHouse®
    • Monium
    • Cloud CDN
    • Network Load Balancer
    • Virtual Private Cloud
    • Cloud DNS
    • Application Load Balancer
    • Yandex Cloud Video
    • Stackland
    • Yandex Cloud Router
    • Yandex Managed Service for Trino
    • Managed Service for MySQL®
    • Managed Service for Valkey™
    • Managed Service for Apache Spark™
    • Yandex StoreDoc
    • Managed Service for OpenSearch
    • Managed Service for Apache Kafka®
    • Data Transfer
    • Yandex MPP Analytics Engine for PostgreSQL
    • Yandex Managed Service for Apache Airflow®
    • Data Processing
    • Yandex MetaData Hub
    • Managed Service for YDB
    • Managed Service for Sharded PostgreSQL
    • Managed Service for YTsaurus
    • Yandex WebSQL
    • DataLens
    • Yandex Search API
    • SpeechSense
    • SpeechKit
    • DataSphere
    • Vision OCR
    • Translate
    • Yandex Identity Hub
    • Key Management Service
    • Certificate Manager
    • Yandex Lockbox
    • Audit Trails
    • SmartCaptcha
    • Cloud Desktop
    • Yandex SIEM
    • SourceCraft Code Assistant
    • Container Registry
    • Managed Service for GitLab
    • Managed Service for Prometheus®
    • Cloud Functions
    • API Gateway
    • Yandex Cloud Postbox
    • Message Queue
    • Serverless Integrations
    • IoT Core
    • Data Streams
    • Serverless Containers
    • Cloud Notification Service
    • Yandex Query
    • Identity and Access Management
    • Yandex Cloud Console
    • Resource Manager
    • Yandex Cloud Billing
    • Yandex Cloud Quota Manager
    • Cloud Apps
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Tutorials
    • All tutorials
    • Architecture and protection of a basic web service
    • Cost analysis by resource using Object Storage
    • Obtaining the information you need to request the Russian Ministry of Digital Development to whitelist a resource
        • Solution architecture
        • Unassisted implementation with Yandex Cloud
        • Deploying S2S VPN using strongSwan in Yandex Cloud
        • SGW solution by the Yandex Cloud architect team
      • Connecting to a cloud network using OpenVPN
      • Setting up a UserGate proxy server
  1. Basic infrastructure
  2. VPNs
  3. Establishing network connectivity with the help of IPsec gateways
  4. Solution architecture

Setting up network connectivity between cloud and remote resources with IPsec gateways

Written by
Yandex Cloud
Updated at December 29, 2025
View in Markdown

Network connectivity between your corporate data center and cloud resources must be properly protected. For this purpose, you can use secure connections.

One of the technologies used for that is an internet connection through IPsec gateways over the IPsec protocol. IPsec is widely used on a variety of network devices, both physical and virtual.

Cloud site:

  • Network named cloud-net with the following subnets: subnet-a (172.16.1.0/24), subnet-b (172.16.2.0/24), and ipsec-subnet (172.16.0.0/24).
  • Main IPsec gateway named cloud-gw as a VM based on the open-source strongSwan solution. Connect this IPsec gateway to ipsec-subnet. The main goal of the gateway is to set up an IPsec connection to a remote gateway and provide network connectivity between test VMs.
  • cloud-net-sg security group is used for the VM network interface of the main gateway and allows IPsec traffic between the gateways.
  • cloud-net-rt route table with static routes ensures traffic towards subnet-1 of the remote site through the main IPsec gateway.
  • Ubuntu Linux-based test VMs, vm-a and vm-b, get connected to subnet-a and subnet-b, respectively. These VMs are used to check IP connectivity via an IPsec connection.

Remote site:

  • remote-net network with subnet-1 (10.10.0.0/16).
  • Remote IPsec gateway named remote-gw as a VM based on the open-source strongSwan solution. Connect this IPsec gateway to subnet-1. The main goal of the gateway is to set up an IPsec connection to the main gateway and provide network connectivity between test VMs.
  • remote-net-sg security group is used for the VM network interface of the remote gateway and allows IPsec traffic between the gateways.
  • remote-net-rt route table with static routes ensures traffic towards subnet-a and subnet-b of the cloud site through the remote IPsec gateway.
  • Ubuntu Linux-based test VM, vm-1, gets connected to subnet-1. This VM is used to check IP connectivity via an IPsec connection.

The IPsec connection is established between the public IP addresses of the main gateway (x1.x1.x1.x1) and those of the remote one (x2.x2.x2.x2).

To set up network connectivity with IPsec gateways, use one of the following methods:

  • Setting up network connectivity with IPsec gateways on your own using Yandex Cloud
  • Deploying S2S VPN using strongSwan in Yandex Cloud
  • Security GateWay solution by the Yandex Cloud architect team

Was the article helpful?

Previous
Installing a Mikrotik CHR virtual router
Next
Unassisted implementation with Yandex Cloud
© 2026 Direct Cursus Technology L.L.C.