Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Route all traffic through VPN (with some exceptions)

    Scheduled Pinned Locked Moved OpenVPN
    1 Posts 1 Posters 866 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H
      Heli0s
      last edited by

      Currently, I have a site-to-site OpenVPN setup that when activated, redirects all traffic through the VPN. I've created an alias for WAN ports and an alias for allowed ports, as well as the associated firewall rules. Currently, when the VPN is active, all outbound traffic that matches the ports in the allowed ports alias is routed through the VPN. When the VPN goes down or is turned off, the ports in the alias are routed through the WAN. The ports in the WAN ports alias are always routed through the WAN no matter what.

      What I'd like to do is setup a rule or a set of rules so that when the VPN is up, everything is routed through the VPN. When the VPN is down, all ports in the allowed ports alias are blocked from the internet (WAN). Is that possible to do with pfSense? I looked at floating rules, but I can't seem to get that to work.

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.