How to access Nas4free behind pfsense openvpn



  • I want to deploy pfsense on my network with the following

    1. Nas4free ip: 192.168.0.250
    2. NVR ip: 192.168.0.137
    3. Network 1: 192.168.0.0/24  allow internet access
    4. openvpn: 10.7.0.0/24   
    5. remote ip : 192.168.10.0/24     
    6. remote 2 ip: 192.168.1.0/24

    I have 4 ports on my pfsense with 5 public ip.

    I need to allow remote access to Nas4free owncloud

    openVPN works fine and can access dvr/nvr. but can not access nas4free on port 12000 and owncloud on port 10000

    any suggestions and guide highly appreciated.


  • LAYER 8 Global Moderator

    The whole point of setting up a vpn is access to your networks.. So yes can deploy openvpn to get access to this…

    Do you have some ? about how to setup the vpn?  Did you run through the wizard?

    https://doc.pfsense.org/index.php/OpenVPN_Remote_Access_Server



  • thanks for your reply.

    Yes i do but the only thing i don't understand is the "Tunnel Network"

    is this is the address of my local nas4free or it is third party address



  • The tunel network is the VPN network between server and client. You may enter here any private network you want, the only attention you have to pay here is that it doesn't overlap with networks on server and client side.

    The server side network you want to be able to access have to be entered at "IPv4 Local network/s" in CIDR notation (for a single IP use /32).


  • LAYER 8 Global Moderator

    This seems pretty clear to me..

    Tunnel Network – Should be a new, unique network that does not exist anywhere in the current network or routing table.



  • if i am picking it right i can use 10.25.30.1/24 ? as it could be the new network?



  • now since i am able to run vpn on pfsense and can access many things except nas4free and owncloud this is strange still i can not able to access my storage server ?

    my pfsense 192.168.0.1 openVPN
    local LAN 192.168.0.0/24
    tunnel 10.0.7.0/24
    remote ip 192.168.10.0/24

    nas4free
    host 192.168.10.0/24 10.0.70.0/24 192.168.1.0/24

    gateway 192.168.0.1

    what wrong I am doing?????
    please help



  • @irs:

    if i am picking it right i can use 10.25.30.1/24 ? as it could be the new network?

    Best not to use anything in the 192.168.0.0/16 or 10.0.0.0/8 ranges for your tunnel network, as these are often used in private networks that you might be trying to use the VPN from.

    Try something less likely to conflict with those ranges.  Maybe 172.23.46.0/24



  • but I am not using 192.168.0.0/16 for my tunnel
    my tunnel is 10.0.7.0/24



  • Maybe the access is blocked by the nas4free itself. Check if it's accessible from another network connected to pfSense.



  • nas4free is working on LAN no problem. but as soon as i tried to ping from openvpn it fails



  • irs,

    Let's see if we can get to the bottom of this.

    Is it the NAS4Free web GUI that you cannot access, shares on NAS4Free or both?

    What is the IP address of your OpenVPN client before you your start OpenVPN?  Is it always in the range 192.168.10.0/24?

    Your pfSense subnets are as follows:
      LAN - 192.168.0.0/24  (NAS4Free is in that subnet.  Correct?)
      Tunnel - 10.0.7.0/24
    Correct?

    Can you please post screenshots of the following:

    Each of these sections from pfSense GUI:
        VPN / OpenVPN / Servers / Edit
        Firewall / Rules / WAN
        Firewall / Rules / OpenVPN
        Firewall / NAT / Port Forward

    From NAS4Free:
        System > General Setup
        Network > LAN Management
        Network > Firewall
        WebGUI section of System > General Setup


  • LAYER 8 Global Moderator

    can your nas4free get to the internet?  Your first post stated

    1. Nas4free ip: 10.0.10.15

    I think I am going to fireup a copy of nas4fee on my esxi host.. This really should be just clickity clickity!!

    edit:  Like I thought clickity clickity..  Fired up nas4free as vm on my home network esxi host.  Set it to dhcp, got IP address 192.168.9.218, I then accessed the gui and setup the host allow in general to allow my vpn tunnel network and my local 192.168.9.0/24 network.

    Bing bang zoom - into the gui from my vpn connection, before this got the 403 forbidden error.




  • @johnpoz:

    can your nas4free get to the internet?  Your first post stated

    1. Nas4free ip: 10.0.10.15

    That was in this thread.  Here it's on the LAN.

    Maybe a mod could lock the other topics in NAT and General Questions


  • LAYER 8 Global Moderator

    No in this thread go to the top of the page he states 10.0.10.15  Which is why you don't freaking cross post ;)

    I have no idea what he is doing - this literally took a minute to setup…. There is nothing special to do other than allow your vpn tunnel network access via the screenshot I posted.



  • @biggsy:

    irs,

    Let's see if we can get to the bottom of this.

    Is it the NAS4Free web GUI that you cannot access, shares on NAS4Free or both?

    What is the IP address of your OpenVPN client before you your start OpenVPN?  Is it always in the range 192.168.10.0/24?

    Your pfSense subnets are as follows:
      LAN - 192.168.0.0/24  (NAS4Free is in that subnet.  Correct?)
      Tunnel - 10.0.7.0/24
    Correct?

    Can you please post screenshots of the following:

    Each of these sections from pfSense GUI:
        VPN / OpenVPN / Servers / Edit
        Firewall / Rules / WAN
        Firewall / Rules / OpenVPN
        Firewall / NAT / Port Forward

    From NAS4Free:
        System > General Setup
        Network > LAN Management
        Network > Firewall
        WebGUI section of System > General Setup

    ![n4f network hosts.png](/public/imported_attachments/1/n4f network hosts.png)
    ![n4f network hosts.png_thumb](/public/imported_attachments/1/n4f network hosts.png_thumb)



  • @biggsy:

    irs,

    Let's see if we can get to the bottom of this.

    Is it the NAS4Free web GUI that you cannot access, shares on NAS4Free or both?

    What is the IP address of your OpenVPN client before you your start OpenVPN?  Is it always in the range 192.168.10.0/24?

    Your pfSense subnets are as follows:
      LAN - 192.168.0.0/24  (NAS4Free is in that subnet.  Correct?)
      Tunnel - 10.0.7.0/24
    Correct?

    Can you please post screenshots of the following:

    Each of these sections from pfSense GUI:
        VPN / OpenVPN / Servers / Edit
        Firewall / Rules / WAN
        Firewall / Rules / OpenVPN
        Firewall / NAT / Port Forward

    From NAS4Free:
        System > General Setup
        Network > LAN Management
        Network > Firewall
        WebGUI section of System > General Setup

    ![nas4free general.png](/public/imported_attachments/1/nas4free general.png)
    ![nas4free general.png_thumb](/public/imported_attachments/1/nas4free general.png_thumb)
    ![nas4free general.png](/public/imported_attachments/1/nas4free general.png)
    ![nas4free general.png_thumb](/public/imported_attachments/1/nas4free general.png_thumb)
    ![nas4free general.png](/public/imported_attachments/1/nas4free general.png)
    ![nas4free general.png_thumb](/public/imported_attachments/1/nas4free general.png_thumb)



  • @johnpoz:

    can your nas4free get to the internet?  Your first post stated

    1. Nas4free ip: 10.0.10.15

    I think I am going to fireup a copy of nas4fee on my esxi host.. This really should be just clickity clickity!!

    edit:  Like I thought clickity clickity..  Fired up nas4free as vm on my home network esxi host.  Set it to dhcp, got IP address 192.168.9.218, I then accessed the gui and setup the host allow in general to allow my vpn tunnel network and my local 192.168.9.0/24 network.

    Bing bang zoom - into the gui from my vpn connection, before this got the 403 forbidden error.

    Thx dear, Yes I changed as I was trying different options at different times. but still no luck my nas4free can not access internet. I have installed it in new machine without firewall but still nas4free can not access internet.

    The host you suggested I tried that as well but no luck. i tried with several ip but no way.

    ![nas4free general.png](/public/imported_attachments/1/nas4free general.png)
    ![nas4free general.png_thumb](/public/imported_attachments/1/nas4free general.png_thumb)



  • I thought the problem was that you couldn't access teh NAS4Free from OpenVPN.

    You are now saying that it can't access the internet.

    @biggsy:

    irs,

    Can you please post screenshots of the following:

    Each of these sections from pfSense GUI:
        VPN / OpenVPN / Servers / Edit
        Firewall / Rules / WAN
        Firewall / Rules / OpenVPN
        Firewall / NAT / Port Forward

    From NAS4Free:
        System > General Setup
        Network > LAN Management
        Network > Firewall
        WebGUI section of System > General Setup

    And the rest of it?  BTW, you could cut down the repetition in the screenshots  ;)

    Why do you have 0.0.0.1/1, 1.0.0.0/2, 2.0.0.0/3 and 192.168.10.0/24 in the Hosts Allow?

    I think you might need to learn something about networking before you go any further.



  • some other guy suggested to have allow host and try though i tried 192.168.10.0/24 10.0.7.0/24 but no luck


  • LAYER 8 Global Moderator

    dude can your nas4free access the internet or not?

    I already posted how freaking clickity clickity simple it is to allow access from other networks.  Your screenshots are not even the correct place to do that for access to the webgui..



  • even new system can not ping internet

    ![ping diagnostic.png](/public/imported_attachments/1/ping diagnostic.png)
    ![ping diagnostic.png_thumb](/public/imported_attachments/1/ping diagnostic.png_thumb)



  • @johnpoz:

    dude can your nas4free access the internet or not?

    I already posted how freaking clickity clickity simple it is to allow access from other networks.  Your screenshots are not even the correct place to do that for access to the webgui..

    No my n4f can not access internet


  • LAYER 8 Global Moderator

    well if it can not get to internet - how and the F do you think you could get to it from vpn through the internet

    Is pfsense its gateway?  Can it ping pfsense gateway?  What are the rules on your pfsense interface this nas is connected to?  Are you using captive portal?



  • @biggsy:

    I thought the problem was that you couldn't access teh NAS4Free from OpenVPN.

    You are now saying that it can't access the internet.

    @biggsy:

    irs,

    Can you please post screenshots of the following:

    Each of these sections from pfSense GUI:
        VPN / OpenVPN / Servers / Edit
        Firewall / Rules / WAN
        Firewall / Rules / OpenVPN
        Firewall / NAT / Port Forward

    From NAS4Free:
        System > General Setup
        Network > LAN Management
        Network > Firewall
        WebGUI section of System > General Setup

    And the rest of it?  BTW, you could cut down the repetition in the screenshots  ;)

    Why do you have 0.0.0.1/1, 1.0.0.0/2, 2.0.0.0/3 and 192.168.10.0/24 in the Hosts Allow?

    I think you might need to learn something about networking before you go any further.



    ![VPNOpenVPNServersEdit 2.png](/public/imported_attachments/1/VPNOpenVPNServersEdit 2.png)
    ![VPNOpenVPNServersEdit 2.png_thumb](/public/imported_attachments/1/VPNOpenVPNServersEdit 2.png_thumb)
    ![VPNOpenVPNServersEdit 3.png](/public/imported_attachments/1/VPNOpenVPNServersEdit 3.png)
    ![VPNOpenVPNServersEdit 3.png_thumb](/public/imported_attachments/1/VPNOpenVPNServersEdit 3.png_thumb)
    ![VPNOpenVPNServersEdit 4.png](/public/imported_attachments/1/VPNOpenVPNServersEdit 4.png)
    ![VPNOpenVPNServersEdit 4.png_thumb](/public/imported_attachments/1/VPNOpenVPNServersEdit 4.png_thumb)
    ![VPNOpenVPNServersEdit 5.png](/public/imported_attachments/1/VPNOpenVPNServersEdit 5.png)
    ![VPNOpenVPNServersEdit 5.png_thumb](/public/imported_attachments/1/VPNOpenVPNServersEdit 5.png_thumb)




    ![FirewallNATPort Forward.png](/public/imported_attachments/1/FirewallNATPort Forward.png)
    ![FirewallNATPort Forward.png_thumb](/public/imported_attachments/1/FirewallNATPort Forward.png_thumb)
    ![n4f general setup.png](/public/imported_attachments/1/n4f general setup.png)
    ![n4f general setup.png_thumb](/public/imported_attachments/1/n4f general setup.png_thumb)
    ![n4f Network Firewall.png](/public/imported_attachments/1/n4f Network Firewall.png)
    ![n4f Network Firewall.png_thumb](/public/imported_attachments/1/n4f Network Firewall.png_thumb)



  • @johnpoz:

    well if it can not get to internet - how and the F do you think you could get to it from vpn through the internet

    Is pfsense its gateway?  Can it ping pfsense gateway?  What are the rules on your pfsense interface this nas is connected to?  Are you using captive portal?

    yes my gateway is pfsense and I can ping nas4free witin pfsense. No I am not using captive portal.




  • :o  Got WannaCrypt yet?

    Why do you have all those ports open on WAN!!!  All you need open on the WAN is OpenVPN.

    Do a fresh install of pfSense to clear out all those rules.

    Redo your OpenVPN configuration and client export. Use the standard UDP port 1194. Set your tunnel network to 172.23.45.0/24 or something else in that range.  (With your tunnel set to 10.0.7.0/24, if you try to use OpenVPN from a network that uses the 10.0.0.0/8 range, you will have problems.)

    NAS4Free GUI can just run on TCP port 443.  Change the NAS4Free Hosts Allow setting to match your tunnel network and the LAN.  (VPN access to any SMB shares can be dealt with later.)



  • ok I will do that as per your Guide.

    Will let you know after fresh install.

    Thx for your help and guide. i hope it will work this time. But I tried to install nas4free fresh but it can not ping internet.


  • LAYER 8 Global Moderator

    WTF… Yeah start clean!  How do you think forwarding the same port to different IPs would ever work?

    And why in the world would you forward netbios from internet into your network?

    Why/How could you have a source of your lan net hitting your wan, trying to go to 10.10.25.158??



  • @johnpoz:

    WTF… Yeah start clean!  How do you think forwarding the same port to different IPs would ever work?

    And why in the world would you forward netbios from internet into your network?

    Why/How could you have a source of your lan net hitting your wan, trying to go to 10.10.25.158??

    Yes I understand my mistake I should be careful next time not to forward same port to different ips.

    the netbios I don't remember why?

    that address 10.10.25.158 is another mistake.

    Thanks for pointing and helping to understand my mistakes.


  • LAYER 8 Global Moderator

    BTW, unless you have a VIP setup on your wan.. The destination on a port forward is always going to be your WAN address.  * is not how you want to set it..



  • :)



  • I have a quick question. why Nas4free can not access internet even without pfsense?


  • LAYER 8 Global Moderator

    Huh??  Have no idea what that question is suppose to be asking.. Why can some host you setup not access the internet?  Guess would be you set it up wrong ;)  Since it seems you clearly have internet access since your posting this ;)


Log in to reply