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

    Nat policy through username

    Scheduled Pinned Locked Moved NAT
    5 Posts 3 Posters 2.9k 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.
    • O
      okrug
      last edited by

      Hi!
      I need something like NAT policy by username.
      So, we have several WAN connections and I wish to NAT user through specific interface (wan connections) depending on username.
      Can this be achieved by pfsense?
      Thanks in advance.

      1 Reply Last reply Reply Quote 0
      • johnpozJ
        johnpoz LAYER 8 Global Moderator
        last edited by

        Policy routing can be based upon source IP, dest IP, dest port, etc.

        Why can you not just assign the user a specific IP and then policy route it that way?  Are different users coming from same IP, like a kiosk machine or something

        An intelligent man is sometimes forced to be drunk to spend time with his fools
        If you get confused: Listen to the Music Play
        Please don't Chat/PM me for help, unless mod related
        SG-4860 24.11 | Lab VMs 2.8, 24.11

        1 Reply Last reply Reply Quote 0
        • O
          okrug
          last edited by

          Hi!
          Yes, users are using one IP on terminal server. I also tried to use virtual IP but there is no way to make static mapping user - IP.
          So, the only way of identification is username…
          Maybe someone faced with such task and there is another product to solve it?
          thanks.

          1 Reply Last reply Reply Quote 0
          • K
            kpa
            last edited by

            No you can't do that on traffic that doesn't originate on pfSense itself. The username or any other identification information doesn't make it outside the sending host in such a way it could be used in packet filtering or NAT on pfSense.

            1 Reply Last reply Reply Quote 0
            • johnpozJ
              johnpoz LAYER 8 Global Moderator
              last edited by

              You would normally do such a thing with a proxy that users auth too.

              An intelligent man is sometimes forced to be drunk to spend time with his fools
              If you get confused: Listen to the Music Play
              Please don't Chat/PM me for help, unless mod related
              SG-4860 24.11 | Lab VMs 2.8, 24.11

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