Is your computer's IP address 'private'? (10.../192.168..) Everything's a NAT'ed pkt. PAT?
GeneralThis forum is for non-technical general discussion which can include both Linux and non-Linux topics. Have fun!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
View Poll Results: Is your computer's (inside) IP address 'private' (10.../192.168..), or public?
I use 'private' RFC1918 10.../192.168.. on my box.
8
100.00%
I use public IP addressing (so others can reach me)
Is your computer's IP address 'private'? (10.../192.168..) Everything's a NAT'ed pkt. PAT?
Anon, so no posted reply needed (if both, choose 'public')
Inspired by a recent file tutorial, I'd like to explore this.
In addition to my curiosity, it might be of learning value!
By "your IP address", I mean only the 'network card' address, not your WhatIsMyIP.com ?external? NAT'ed ISP address.
(like DOS ipconfig/a or from cli cmd: ip a | grep -w inet)
(&yes, if private, your ISP's router's DHCP gives you this address)
By 'private', I mean RFC1918: 10... or 192.168.. (&172.16../12)
In generalities, this seems to be the difference between:
home/personal vs. where the public *accesses you*.
This can get 'technical', and there's a lot I don't know about NAT boxes, VPN, port_forwarding, firewall (needed? /r:No), ...
(like 5.3 in this advanced book I found at library)
An advantage seems to be (in simplistic terms):
evil outsiders can't (*simply/trivially*) reach you.
This doesn't cover the instance where you "drag in" evil stuff, generally by accessing a malicious site that instructs your (unsecured) web browser to store stuff (like JavaScript &beyond; again, sorry for my simplistic description: lots Idk).
In addition to my curiosity as to how many LQ'ers are 'public vs. private', feel free to post tutorial info/links Thanks!
Last edited by GentleThotSeaMonkey; 09-23-2017 at 11:35 AM.
Your computer has one public IP-address, on the outside-facing side of your router. But, no one can make an unsolicited inbound connection request unless you have enabled "port forwarding." (This creates an open port on your router and delivers the requests and the data to a specified internal IP.)
Connections that you make to the outside world – such as to LQ – occur through randomly-generated port numbers, and replies are accepted only from the intended remote IP-address. This is how NAT = Network Address Translation works.
No one from the outside can see into your internal network. All IP-addresses there are "non-routable." No internal traffic ever enters the outside world bearing internal IP's, and any such traffic is immediately dropped by the next-hop anyway.
If you do want to route from your inside addresses to another "inside" network, you have to use secure routing technologies such as OpenVPN to create a secure "tunnel" between the two subnets. Then, specified traffic from one internal subnet can be routed to another, but the transfer takes place through encrypted packets that are exchanged between the two secure (OpenVPN ...) virtual routers. No one Hello we are listening from to every word you say the P.S. your right shoe is untied outside ... uhh, except maybe those guys ... can interfere.
Last edited by sundialsvcs; 09-21-2017 at 10:18 AM.
For a typical home setup, there is a cable modem or something which has an accessible public IP address. Usually, there is some sort of router connected to that.
If that's some sort of commercially available router appliance then...unfortunately there's a significant chance it is vulnerable to exploits.
My preference is to set up an x86 compatible computer as that router, instead of an off-the-shelf router appliance. This computer receives security updates just like all of my other Debian machines.
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
I don't understand the question. Most home users and small to medium businesses will use NAT and have one internet facing IP address. As things stand with IP version 4 that's not a choice but the wy it is.
Was there a question beyond that?
There is nothing stating that you have to have a router connected to your ISP modem connection. Thus if you are directly connect your device you are using a Public IP Address.
Now if you could get more than 1 Public IP is another story.
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
Quote:
Originally Posted by lazydog
There is nothing stating that you have to have a router connected to your ISP modem connection. Thus if you are directly connect your device you are using a Public IP Address.
Now if you could get more than 1 Public IP is another story.
That depends. In my case, and others, the ISP box needs to be present as it is a brouter. In the case of people still using MODEMs it is often the case now that the ISP will, again, provide a brouter instead.
My point being that in all cases the ISP chooses and in the vast majority of modern internet cobections that choice is a brouter with a switch installed, usually allowing ethernet and wireless.
That depends. In my case, and others, the ISP box needs to be present as it is a brouter. In the case of people still using MODEMs it is often the case now that the ISP will, again, provide a brouter instead.
My point being that in all cases the ISP chooses and in the vast majority of modern internet cobections that choice is a brouter with a switch installed, usually allowing ethernet and wireless.
This all really depends on your ISP handoff. If you have copper or fiber handoff you should be able to connect directly to it. If it is a cox then you might need their device or depending on where you live you could by your own modem and connect it. I know a lot of ISP in the states that allow you to connect your own device.
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
Quote:
Originally Posted by lazydog
This all really depends on your ISP handoff. If you have copper or fiber handoff you should be able to connect directly to it. If it is a cox then you might need their device or depending on where you live you could by your own modem and connect it. I know a lot of ISP in the states that allow you to connect your own device.
Things may well be very different in the US but in the UK at least even those using their own equipment aren't generally connecting a MODEM to their computer in a PCI slot or by USB but, instead, are connecting to a switch and brouter. I actually didn't know internal ADSL MODEMs existed.
The "modem," whatever it is, is the device which converts TCP/IP (and UDP) packets into whatever electrical format the carrier requires. It is, literally, a transmitter and a receiver for some kind of cable (or, for a satellite link).
The "router," which is often built-in to the modem these days, is the digital interface which allows one IP-address to serve many computers ("subnets") on the inside. It also facilitates communication between those "inside" devices.
If your public IP-address is 101.102.103.104, then the packets you're sending to LQ right now might appear to be coming from "port #12345" at this IP. Your router picked this port-number out of its hat, for this particular conversation. When packets come back from LQ's IP, destined for this port-number, your router will strip-off that port number (substituting the one you used), and use that number to forward the packet to "you," on the inside network. When you terminate this conversation, "port #12345" will lose its present meaning. Packets bearing a port-number that are not in-use by the modem (e.g. "stragglers") are dropped.
The router does not reveal the internal IP-address that it is sending it to, nor does it honor an inbound-connection request ...
... unless you've set up "port forwarding." If you, say, wanted to host your own web site, then you'd "port forward" the HTTP and HTTPS port-numbers so that your router would broker connection-request packets, and would forward those packets to your designated web-server machine.
Routers are reasonably well-made, but every manufacturer updates the software from time to time. For instance (just as with a brand-new cell phone ...), you should connect to the manufacturer's web-site and install software updates, unless it does so by itself. (Allow it to do so by itself.)
I also recommend turning off "automatic configuration" options, and that you immediately change the manufacturer-provided network name and password. Don't allow the configuration panels to be accessed wirelessly.
Some routers support OpenVPN, or provide this as an add-on software option, and they happen to do it well.
Last edited by sundialsvcs; 09-22-2017 at 08:05 AM.
You should update to the open source firmware IF your router suppoorts it as this WILL almost certainly be more up-to-date than the manufacturer's and likely VERY much more secure.
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
I have to admit I am confused as to the purpose of this thread?
An above comment reminded me that most corporate machines are NAT'd also, in the IP4 world at least, so I don't understand why this is being asked.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.