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

    Firewall Rule to Allow RDP from WAN to LAN......Need help

    Scheduled Pinned Locked Moved Firewalling
    76 Posts 7 Posters 10.7k 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.
    • DerelictD
      Derelict LAYER 8 Netgate
      last edited by Derelict

      OK so you have a port forward on WAN with a destination address of LAN Net. How exactly do you expect that to work?

      Why did you set the rule association to Pass? No docs state to do that.

      And you are forcing the connection out WAN by setting that gateway on the rule.

      Chattanooga, Tennessee, USA
      A comprehensive network diagram is worth 10,000 words and 15 conference calls.
      DO NOT set a source address/port in a port forward or firewall rule unless you KNOW you need it!
      Do Not Chat For Help! NO_WAN_EGRESS(TM)

      1 Reply Last reply Reply Quote 0
      • D
        DINU
        last edited by

        Any update ???

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

          Update? How exactly do you expect such a mess to work??

          If you have questions about what something is or means, you need to ask.. Don't just go random clicking shit and picking stuff from the drop down..

          To create a port forward in pfsense, really the only thing you have to touch is the port, redirect port, and the IP you want to send it too.. Everything else is going to be pretty much default.

          And let the port forward create the firewall rule - which is default..

          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
          • chpalmerC
            chpalmer
            last edited by chpalmer

            Turn the firewall off on the machine that your are trying to RDP into.

            It will treat anything outside its own subnet as public and block it.

            Your post with the graphic looks correct although MS recommends a TCP/UDP connection. I do not believe I ever have though. I normally do not leave such a rule in place any longer than I need it.

            Triggering snowflakes one by one..
            Intel(R) Core(TM) i5-4590T CPU @ 2.00GHz on an M400 WG box.

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

              ^ looks correct? What are you looking at? It sure not the mess he posted.. Has gateway set on his wan rule, the dest is Lan Net vs wan address in his port forward.

              Here is the 3 things that need to be touched to port forward rdp

              portforward.png

              That is it, don't touch anything else - the defaults are all you need. It will create the firewall rule for you. You just need to make sure you turn off the default block rfc1918 rule because your source is actually rfc1918.

              edit: Lets get tcp working before he worries about having a UDP connection ;) But sure if he wanted he could change it from default of tcp to tcp/udp.

              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
              • D
                DINU
                last edited by

                I have tried with NAT Rule that did not helped so used PASS and took the screen shot at that time..

                In one of the forum in netgate to mentioned gateway instead of default so I have tried that as well whether it may help...

                1 Reply Last reply Reply Quote 0
                • DerelictD
                  Derelict LAYER 8 Netgate
                  last edited by

                  List of things to check is here:

                  https://docs.netgate.com/pfsense/en/latest/nat/port-forward-troubleshooting.html

                  Chattanooga, Tennessee, USA
                  A comprehensive network diagram is worth 10,000 words and 15 conference calls.
                  DO NOT set a source address/port in a port forward or firewall rule unless you KNOW you need it!
                  Do Not Chat For Help! NO_WAN_EGRESS(TM)

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

                    It should take you like 2 minutes top to trouble shoot a port forward..

                    Sniff on wan, do you see traffic to 3389? Sniff on Lan - do you see pfsense sending 3389 on to IP you want to send it to..

                    If you do - your problem is prob firewall on host your sending too, maybe rdp isn't even listening? Maybe it is using a different gateway other than pfsense? Maybe where you wanted to send it is now on a different IP? etc. etc..

                    Troubleshooting a port forward does not mean randomly changing settings ;)

                    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
                    • M
                      MoonKnight
                      last edited by

                      Hi,
                      And make sure you have enabled "Remote Desktop" on your computer you are trying to RDP :)

                      --- 24.11 ---
                      Intel(R) Xeon(R) CPU D-1518 @ 2.20GHz
                      Kingston DDR4 2666MHz 16GB ECC
                      2 x HyperX Fury SSD 120GB (ZFS-mirror)
                      2 x Intel i210 (ports)
                      4 x Intel i350 (ports)

                      1 Reply Last reply Reply Quote 0
                      • D
                        DINU
                        last edited by

                        Thanks friends for the help, I can able to access my Windows Machines from WAN to LAN..
                        Two things I have done one is enabled firewall rules in WAN and added route in my source machine (ie) in WAN network.

                        Firewall_Rule_WAN1.jpg

                        route add 192.168.30.0 mask 255.255.255.0 192.168.50.100

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

                          So you turned off NAT in pfsense?

                          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

                          D 1 Reply Last reply Reply Quote 0
                          • D
                            DINU @johnpoz
                            last edited by

                            @johnpoz

                            Yes I have turned off NAT in pfsense...

                            now I need help in configuring Open VPN for my mentioned design... to access my LAN network through Internet...

                            Airtel Internet Modem -->Asus RT-AX88U Wireless Router --->PFsense-->LAN and DMZ..

                            I need to do triple NAT here.. apart from doing this ... can you suggest some other good options...

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

                              Well if you turned off nat in pfsense, then you would need to route.. And you would really need to be connected via a transit network or your going to run into issues with asymmetrical traffic unless you do host routing on each box that actually sits in any transit network (the network between routers)..

                              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
                              • A
                                akuma1x @DINU
                                last edited by

                                @DINU said in Firewall Rule to Allow RDP from WAN to LAN......Need help:

                                I need to do triple NAT here.. apart from doing this ... can you suggest some other good options...

                                i went back and read the entire thread again. Why do you need this part: Asus RT-AX88U Wireless Router?

                                Jeff

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

                                  I doubt he does to be honest... Should just be used as AP to be honest... And now that he has nat turned off good luck getting that modem and asus to actually route and not nat ;)

                                  He should put his modem into bridge mode, and just use pfsense as his edge nat and firewall, and wireless should just be AP... Simplifies the whole mess.

                                  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
                                  • D
                                    DINU @akuma1x
                                    last edited by

                                    @akuma1x

                                    I want my family to connect their internet directly without PFsense..SO I have connected Asus RT-Ax88U router between Airtel internet moden and Pfsense...

                                    A 1 Reply Last reply Reply Quote 0
                                    • A
                                      akuma1x @DINU
                                      last edited by akuma1x

                                      @DINU said in Firewall Rule to Allow RDP from WAN to LAN......Need help:

                                      I want my family to connect their internet directly without PFsense..SO I have connected Asus RT-Ax88U router between Airtel internet moden and Pfsense...

                                      I'm assuming wirelessly, like for mobile devices and stuff? Or wired into the Asus? Is this so they aren't filtered or less confusing for them, or what?

                                      You should, like @johnpoz says above, change it up a little bit.

                                      Airtel Internet Modem (in bridge mode) -> pfsense -> LAN -> Asus RT-AX88U (VLAN'd for only your family to use)

                                      That would make NAT-ing and VPN-ing (like you say you want to do) and etc. into or out of your network so much easier, promise.

                                      Jeff

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

                                        As you have explained it, its a complete and utter mess..

                                        Isolating traffic is very simple, keeping your family away from your network is very simple and does not require such an nonsense network. Pfsense, vlan switch and AP that does vlans.. Can be done with dumb switches and and dumb AP as well - just a bit more complicated and and extra hardware depending..

                                        But what you have drawn out is just a mess.. and complete and utter nightmare to try and actually manage.

                                        If you explain what you want, we can show you how to do it correctly, easy and with a min budget..

                                        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
                                        • D
                                          DINU
                                          last edited by

                                          I have below components

                                          1. Airtel Internet Modem
                                          2. TP-Link T2500G-10MPS 8-Port Gigabit L2 Managed
                                          3. Desktop Tower Server which have my LAN VMs on it.(with Two Physical NIC's)
                                          4. Asus RT-AX88U Wireless Router
                                          5. Laser Printer

                                          I have installed pfsense on my tower server as VM.

                                          I need the following :

                                          1. I want my family to connect internet through wifi without any disturbance even I reboot pfsense they should not get affected.
                                          1. I want to access my LAB through wifi from internal network.
                                          2. I want to access my LAB machines through internet(ie) from remote site as well.
                                          3. I want to connect my printer through pfsense LAN network.

                                          Kindly provide me the network design to achieve above..

                                          Thanks in Advance,
                                          Dinu

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

                                            So bridge your modem, connect it to your VM Pfsense on wan.. Then put your networks behind, connected via your smart switch.. Do whatever vlans you want, put 3rd party firmware on your asus so you can do vlans = done!

                                            If your soho wifi router can not run 3rd party firmware that actually supports vlans, then get a real AP.

                                            You can connect your other vms to whatever vlans you want on your host.

                                            Do you need a drawing?

                                            I ran such a network for many years before I put my pfsense on actual hardware.. An I still run some VMs on different vlans. Its really basic 101 networking.. Running pfsense is not all that different than running on hardware, only difference is your running some virtual switches vs just hardware one.. Be happy to put together an example drawing if that is what you want with a few vlans, etc.

                                            What you run as your hypervisor means nothing other than some details on how you setup up the vswitches and do some vlans on your VM Host.

                                            Once you have a vlan capable switch, and AP that does vlans - how you segment your network is very simple. The whole thing with having the correct hardware that allows you to do what you want. A vlan capable switch and AP is key - then segmentation becomes simple configuration. The whole point behind vlans ;)

                                            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.