Routing Azure VPN P2S connection through Azure Firewall for S2S connection

Bas Pruijn 951 Reputation points
2024-08-26T14:15:50.89+00:00

Hi all,

I am setting up an IoT configuration where the devices connect via SIMs to a mobile provider. The mobile provider forwards all traffic through a S2S VPN connection. Using a route table I am able to forward all traffic to an Azure Firewall. The Azure Firewall policy is configured to always use SNAT. This is needed because the mobile provider only allows traffic from 1 IP subnet only. This all works as expected.

However, when I connect using a P2S connection on the same VPN Gateway the traffic with a S2S destination seems not to be routed to the firewall. Requests to Azure resources do get routed through the firewall and work without issues. It seems the VPN Gateway directly routes the data to the S2S connection. There the data is dropped, since it does not originate from the predefined subnet.

Any clues on how to fix this?

Furthermore, we need to prevent different S2S connections to directly communicate with each other. All traffic needs to be routed through the firewall where rules will block unwanted traffic. Would this be default behaviour, or does the VPN gateway (also) route this traffic directly?

There is no need for forced tunneling.

Details:

P2S: OpenVPN (SSL) with AAD authentication

S2S: IPSec tunnel with preshared key.

Azure VPN Gateway
Azure VPN Gateway
An Azure service that enables the connection of on-premises networks to Azure through site-to-site virtual private networks.
1,543 questions
Azure Firewall
Azure Firewall
An Azure network security service that is used to protect Azure Virtual Network resources.
669 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.