[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

subnet mask

Posted on 2016-10-20
9
Medium Priority
?
76 Views
Last Modified: 2016-11-13
I am learning network +
I saw many tutorials about subnet mask

I am not looking for another tutorial

Please answer 3 questions:
what is subnet mask hiding
whom are they hiding from

how does subnet unmask (un hide)
0
Comment
Question by:rgb192
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
9 Comments
 
LVL 10

Accepted Solution

by:
Muhammad Mulla earned 1000 total points (awarded by participants)
ID: 41852278
- The subnet mask isn't hiding anything.

It is called a mask because it is used to identify the network address of the IP. i.e. it doesn't need to know the bits that represent the host. A bitwise AND operation is used to carry out this function.
0
 
LVL 80

Assisted Solution

by:arnold
arnold earned 500 total points (awarded by participants)
ID: 41852292
Is this a school assignment question?

A mask identifies a subnet, depending on the setup, communication within the subnet, systems with IPs on the same subnet communicate directly, communications with IPs outside the subnet are done through an external processor, router.
0
 
LVL 10

Expert Comment

by:Muhammad Mulla
ID: 41852299
That was my first reaction, arnold.
0
Are You Ready for GDPR?

With the GDPR deadline set for May 25, 2018, many organizations are ill-prepared due to uncertainty about the criteria for compliance. According to a recent WatchGuard survey, a staggering 37% of respondents don't even know if their organization needs to comply with GDPR. Do you?

 
LVL 26

Expert Comment

by:pony10us
ID: 41852315
To word what Arnold has said a little differently:

A subnet mask basically tells an IP what other IP's it can talk to without interference. It "hides" other IP's that are not within the range of the mask from IP's that are in within that range.  This "hiding" can be altered externally with "route" rules on an external device like a router.
0
 
LVL 31

Expert Comment

by:masnrock
ID: 41852316
The subnet mask isn't hiding anything. What it does is that is helps you identify a subnet that an IP address falls in.

For the example I'm going to show, I'm going to use the following:
IP address: 192.168.16.230
Subnet mask: 255.255.255.0

In order to identify a network ID, you have to convert both the IP address and the subnet mask to binary.
IP address: 11000000.10101000.00010000.11100110
Subnet mask: 11111111.11111111.11111111.00000000

Next step is to do a XOR (exclusive OR) operation. To do XOR, you have to go one bit (binary digit at a time). Think of it like an addition problem, except that you never have to carry digits.

When you do XOR, the following applies:
1 XOR 1 = 1
1 XOR 0 = 0
0 XOR 1 = 0
0 XOR 0 = 0

When you have done that. you will get the following result:
11000000.10101000.00010000.00000000

Final step is to convert the binary solution back to decimal numbers:
192.168.16.0

What this tells us is that the IP 192.168.16.230 falls in subnet 192.168.16.0

A subnet mask also tells how many hosts are in a subnet. So remember when I showed the subnet mask in binary earlier:
11111111.11111111.11111111.00000000

Notice that it is has 24 ones. A better way to look at it is the fact it has 8 zeros. You would take 2 to the 8th power (2^8), and your answer would be 256. But remember that in any subnet, 2 IP addresses aren't usable, so subtract those out. You're left with 254, which is the number of hosts in the subnet. You can do host calculations WITHOUT having to pay attention to the IP address at all, only the subnet mask.
0
 
LVL 22

Assisted Solution

by:CompProbSolv
CompProbSolv earned 500 total points (awarded by participants)
ID: 41852882
No general disagreement with what has been posted except for the last one about XOR.  Replace "XOR" with "And" and it will generally be correct.  The truth table for XOR is:
1 XOR 1 = 0
1 XOR 0 = 1
0 XOR 1 = 1
0 XOR 0 = 0
2
 
LVL 27

Expert Comment

by:tliotta
ID: 41857946
It "hides" bits that don't identify the network. It's "hiding" the bits from some networking APIs running in the system.

But "hide" isn't the right word. Why do you think it "hides" anything?

What it does is simply remove bits that aren't needed for some functions. An address value is made up of a couple parts -- the network address and the device address within the network. In order for the system to talk to the network, it needs to know what the address of the network is. But the IP address has bits that are added to it to identify a unique point within the network.

It's like a city name, e.g., 'Seattle, Washington'. You might apply a "state mask" to the city name to extract only the name of the state -- 'Washington'. The mask contains rules that say how to extract just the part that's needed. It's not "hiding"; it's simply separating parts.
0
 
LVL 26

Expert Comment

by:pony10us
ID: 41858790
@tliotta,

That description is good and you are correct that it doesn't "hide" anything.  It is more like limiting the scope.

For instance:

John Doe lives @ 123 whatever lane, Seattle Washington US

So lets break this down to a subnet mask

US would be the first octet
Washington would be the second octet
Seattle would be the third octet
123 whatever lane would be the fourth octet
John Doe is the search string.

So if I use the mask 255.0.0.0 - this will search all of the US for John Doe

mask 255.255.0.0 - this will search all of Washington for John Doe - ignoring or "hide" all other US locations

mask 255.255.255.0 this will search all of Seattle for John Doe - ignoring or "hide" the rest of Washington and anywhere else in the US

mask 255.255.255.255 will find John Doe at 123 Whatever Lane in Seattle Washington US - ignoring or "hide" any other John Doe.
1
 
LVL 10

Expert Comment

by:Muhammad Mulla
ID: 41885203
Question answered
0

Featured Post

When ransomware hits your clients, what do you do?

MSPs: Endpoint security isn’t enough to prevent ransomware.
As the impact and severity of crypto ransomware attacks has grown, Webroot fought back, not just by building a next-gen endpoint solution capable of preventing ransomware attacks but also by being a thought leader.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This month, Experts Exchange’s free Course of the Month is focused on CompTIA IT Fundamentals.
If you're a modern-day technology professional, you may be wondering if certifications are really necessary. They are. Here's why.
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question