I relatively new to routers and how they work and I've been struggling with this issue for months and cannot seem to solve it.
I want to access my web server via the public IP address on my internal network.
Ubiquiti EdgeOS Public IP to LAN & Hairpin
I know it can be done apparently by reading the discussion at this link:. But I cannot get it working on my router. Just so you know, I have no idea what I'm doing and I have figured things out by searching the internet for examples I cannot even tell you what router I have and the version of the software on it, I just don't have any idea how to figure THAT outbut for this issue I'm going to need help.
I've read and reread on how things work and they may as well be written in Greek for all that I can understand, so trying to get me to understand how it all works is apparently useless. In any event, if someone is willing to work with me in configuring my router I would be forever grateful. My basic configuration is the Cisco router providing access to the internet and all NAT translations are done on it.
I have a wireless Linksys router connected to the Cisco router over which I connect my laptop and other devices that need to access my servers internally over the public IP address from the laptop. I cannot use the host table to solve this problem because the other devices that do not have that capability and they would need to access the server via the public IP address, I currently use the host table on the laptop to access the servers from it but need to change that.
Can anyone walk me through this? Go to Solution. View solution in original post. Can you post the configuration of your router so we can fill in the necessary bits and pieces? Current configuration : bytes! Please be aware that some parts of the configuration are useless. Once it worked, I saved changes without removing what didn't work. Now I cannot remember which is what and so I just left it in there. In this configuration, the internal address of the server is I don't know if that corresponds with your real web server address, since you have several static NAT translations configured, so you might need to change the addresses accordingly:.
I have no idea how to implement your suggested configuration, "loopback" and "PBR" are Greek to me. Is there a performance advantage to using your configuration over Paul's "NVI nat" configuration? I'll update this thread with the results. Many thanks to both of you for your assistance.GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community. Already on GitHub? Sign in to your account. But a device connected to the Guest wifi cannot connect to services on the wired home network. I feel like sometimes the documentation on Ubiquiti's site is old and not updated and never sure if it still applies.
For example, that doc you referenced which I've seen seems like it's for pre Skip to content. Dismiss Join GitHub today GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together. Sign up. New issue. Jump to bottom. Copy link Quote reply.
Excellent guide got here via Security Now as I'm sure a lot of people did. Could you possibly add a section relating to hairpinning?
Bus error: Jake Billo's weblog
This comment has been minimized. Sign in to view.
I'll keep poking at it Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment. Linked pull requests.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window.I spent most of my Labour Day trying to accomplish two tasks with an EdgeRouter 4 and the other miscellaneous networking gear in the house: setting up a simple VLAN and getting my backup DSL connection working.
The system got a lease in the correct range, but hosts on VLAN 1 At this point I had changed out all components in the equation except for the server, so after dinner I poked around with a few more settings in the switch and then tried a different scenario:.
When all components were connected, the desktop on VLAN 1 at At this point, the trouble seemed to lie with the server itself. Skip to content I spent most of my Labour Day trying to accomplish two tasks with an EdgeRouter 4 and the other miscellaneous networking gear in the house: setting up a simple VLAN and getting my backup DSL connection working. Can I ping the router IP address? Yes, clients from VLAN 1 could ping What does tcpdump say? Is the switch not permitting VLAN traffic?
The Cisco SGP purchased as surplus gear has the most awful web interface. I also took the opportunity to upgrade the firmware.
It only takes a minute to sign up. We have a network with clients, a server, and a NAT Router. There is port forwarding on the router to the server so some of it's services are available externally. Local network clients fail to connect, but external work. This question has answeres merged from multiple other questions.
They're all trying to solve the same problem however. What you're looking for is called "hairpin NAT". Requests from the internal interface for an IP address assigned to the external interface should be NAT'ted as though they came in from the external-side interface. Since this has been elevated to be the canonical question on hairpin NATI thought it should probably have an answer that was more generally-valid than the currently-accepted one, which though excellent relates specifically to FreeBSD.
Internal users then try to access those services via the external address. Their packet goes out from the client to the gateway device, which rewrites the destination address and immediately injects it back into the internal network. It is this sharp about-turn the packet makes at the gateway that gives rise to the name hairpin NATby analogy with the hairpin turn.
The problem arises when the gateway device rewrites the destination address, but not the source address. The server then receives a packet with an internal destination address its ownand an internal source address the client's ; it knows it can reply directly to such an address, so it does so. Since that reply is direct, it doesn't go via the gateway, which therefore never gets a chance to balance the effect of inbound destination NAT on the initial packet by rewriting the source address of the return packet.
The client thus sends a packet to an external IP address, but gets a reply from an internal IP address. It has no idea that the two packets are part of the same conversation, so no conversation happens.Quick Configs Ubiquiti - Source NAT & Masquerade
The solution is that for packets which require such destination NAT, and which reach the gateway from the internal networkto also perform source NAT SNAT on the inbound packet, usually by rewriting the source address to be that of the gateway.
The server then thinks the client is the gateway itself, and replies directly to it. That in turn gives the gateway a chance to balance the effects of both DNAT and SNAT on the inbound packet by rewriting both source and destination addresses on the return packet.
The client thinks it's talking to an external server. The server thinks it's talking to the gateway device. All parties are happy. A diagram may be helpful at this point:. Some consumer gateway devices are bright enough to recognise those packets for which the second NAT step is needed, and those will probably work out-of-the-box in a hairpin NAT scenario. Others aren't, and so won't, and it is unlikely that they can be made to work.
A discussion of which consumer-grade devices are which is off-topic for Server Fault. Proper networking devices can generally be told to work, but - because they are not in the business of second-guessing their admins - they do have to be told do so.This allows anyone to wirelessly project from their computer, eliminating cord clutter and confusion.
Sounds great! However, the presenter needs to be on the same network as the Gateway. Seems I could trunk the port the Gateway is on, but would that potentially allow guests to see our internal network? A LAN is a wire. You have two separate wires. If you bridge them, then yes, you open yourself up to the possibility that your work network can be reached from the guest network. But, this isn't a new problem. You may have resources inside your LAN that you want to be accessed from outside your WAN under controlled conditions.
Things like web servers, mail servers, and so on. Yes, they may be in a DMZ, but it's the same principle. You could put a firewall between your lans and set up a rule to NAT your presentation system to an IP that is reachable on the guest network. That's probably the simplest and most straightforward way. You could get as creative as you want with the firewall rules, even limiting them to specific times of the day or source IPs.
The advantage to this approach is that you don't screw around with your production network. You don't have to program your switches or add vlans or mess up STP or anything like that. Just connect the Edge with one port on each vlan and you're done. Later, if your needs change, just unplug the router and you're done. You will need to alter something then. Either better define what is on the other side of the passport on How will any router know about internet addresses vs internal.
The only thing you might be able to do in the X goto the passport and the default route is then the untangle box, but that won't help the people on the other side of the Potentially you might consider setting up a proxy server and have the clients connect to the proxy server to get to the internet, it is not a clean solution but it might work.
I believe it is possible. We have setup like that with two different networks able to print to the same printer without the computers on the other network being able to see the devices on the main network. What we did was assigned a static IP to the printer, created a tunnel from one network to the other on our firewall and then created NAT rules that only allowed specific traffic to reach only that printer.
Ubiquiti EdgeRouter Lite Setup Part 3: VLAN Setup
Let me know what happens. Depends on what equipment you're using but most likely you can. Thats not a problem at all. Your setup should look something like this Next you will need to make a tagging decision on the port within the new vlan.I have 2 internal servers that have Public IPs. I can access those from outside of the network fine. Skills: Network AdministrationTroubleshooting. Hello there, I would like to share my experience and skills with you let me know if anything for me, I have more than 10 years of industrial experience in information technology over various platforms and technolog More.
Hi, I'll be pleased to work on this project for you. Let me introduce myself. Hi Sir, I am very interested in this project since that related to the network and i would like to solve the problem that you have.
Thankyou for your post and time. Hope we can collaborate in this project Regard More. Best Regards Sushil. The email address is already associated with a Freelancer account. Enter your password below to link accounts:. The router is an Ubiquiti Edgerouter Pro. I can give you temp VPN access for the job.
Looking to make some money? Your email address. Apply for similar jobs. Set your budget and timeframe. Outline your proposal. Get paid for your work. It's free to sign up and bid on jobs. Awarded to:. Link Accounts.
I am a new user I am a returning user. Email address. Username Valid username. I am looking to Hire Work. Username or Email.One way to separate the home and office networks would be to put them on different interfaces of the ERL, e. This would work but has a some disadvantages - reconfiguring the network might involve rewiring, and each network needs its own wireless AP.
With VLANs the networking equipment provides a logical separation of networks which can easily be reconfigured in software. A single interconnect can carry traffic for multiple VLANs using A VLAN deployment will also require configuring switches and wireless APs, but exactly how to do this is hardware-specific and thus will not be covered here. A VLAN is created by adding a virtual interfaces or vif to one of the physical interfaces.
Each VLAN will need its own pool of addresses to assign to clients. Firewall rules and zone policy also need to be defined for the management zone. Once the VLAN configuration has been verified to be working with other networking equipment, much of the old configuration for the LAN is likely no longer needed. Any firewall rulesets that are no longer used can also be deleted. Make sure that you delete only the rules for the eth2 interface itself and not for its VLANs.
Also be sure that the firewall rules allow access to the router configuration from at least one of the VLANs, otherwise you may find yourself locked out! Guests could be bringing compromised devices into your network, and IoT devices are infamous for their poor security practices. Unless you have a specific reason that the device needs to be on the same network as your other machines e.
Using the information above it is strightforward to add one or more additional VLANs for these devices. Set up the vlan similarly to the one above, set up DHCP with an unused range of IPv4 addresses, add a new firewal zone for the network, and configure the firewall so that all trafic to and from the zone is dropped except for WAN traffic. Written by Blog Logo. Seth Forshee's Blog Back to Overview.