IP special purpose address (255) - ip

So i have a one question. In example we have a C class network 192.168.0.0. My question is about special purpose address - translation address. So i have 2 options: one is 192.168.0.255 and another one is 192.168.255.255.
Which one is correct? and why?

Related

How do i calculate the broadcast address for a given subnet without any calculators?

Let's say you had to answer this question and can NOT write anything down or use any calculator as 99% of the solutions I see include one of these which are not possible in this scenario:
Find the broadcast address for 192.156.68.71/21

CIDR vs Classful subnetting

I was studying about Classful addressing with subnetting and Classless addressing but I am not able to clearly understand the difference/advantages between the two of them.
Suppose I have a company wants only 32 public IP addresses I can give them a Class C address with a subnet of 27 bits. Similarly I could give them a CIDR subnet to achieve the same result.
|What is my advantage in using CIDR?
| Why was CIDR required even after subnetting can achieve the same result?
| Shortcomings of subnetting with classful addresses.
Thanks in advance.
You are confusing a couple of concepts. Inter-Domain routing under network classes required that entire address class blocks be assigned to a single entity. There was no way to route inter-domain traffic except by class. You could subnet within a single entity, but you could not divide a classful block between entities.
All CIDR is doing is saying that the classes no longer exist, and you can break up what used to be a classful address block among different entities.
Network classes no longer exist, and they really are studied only for historical purposes. Learn how to subnet using CIDR first (become expert at it), then you can learn about network classes as a history lesson.
Class A starts with first bit 0
Class B starts with first two bits 10
Class C starts with first three bits 110
Class D starts with first four bits 1110
Class E starts with first four bits 1111
My friend, classful addressing is basically dividing the total ipV4 range into five classes :
Class A
Class B
Class C
Class D
Class E
whereas CIDR is based on concept of subnetting.
In your example , your company wants 32 public ip addresses. When we give them a class C address for example : 192.168.2.0 , their company will be reserved for whole ip addresses in range 192.168.2.1 - 192.168.2.254.But they only want 32 ip addresses which means 223 ip addresses will be wasted. This is the constraint of classful addressing . Now if we look at just subnetting , class c ip address has default subnet of 255.255.255.0 so if we divide the range of 192.168.2.0 in 6 subnets each containing 32 available ip addresses your problem is solved. But, if we take this example to higher level we will require CIDR. According to traditional subnetting, we can not combine the addresses from the networks 192.168.2.0 and 192.168.3.0 because the netmask for class C addresses is 255.255.255.0.However, using CIDR notation, we can combine these blocks by referencing this chunk as 192.168.2.0/23. This specifies that there are 23 bits used for the network portion that we are referring to. With this ,the 24th bit can be either 0 or 1 and it will still match, because the network block only cares about the first 23 digits.
CIDR allows us more control over addressing continuous blocks of IP addresses. This is much more useful than the subnetting we talked about originally . Your example only requires subnetting but if we require huge amount of addresses so that we may require to link class C address with class B portion , we will require CIDR.
IP Addresses have stayed the same. What has changed is "How devices can determine Network and Node part from an IP Address. With classful IP Address based processing, the number of bits assigned to network and host parts were fixed. For example when processing ip addresses using classes concept, the system will first determine the class of the IP Address and then use predetermined subnet mask to determine the network portion and host portion.
For class A first octet is network bit which allows 126 networks to be represented.
Due to restrictions on number of hosts and networks imposed by classes, you can define your own subtask mask which represent the network and host part of an IP address regardless which IP Address class you are using. The way that subnet mask is represented in text is called the "CIDR Notation".

Calculate Subnetmask from IP range

This was one task I had as homework I just can't seem to understand. And my teacher is having a hard time explaining it to class. So here I am:
The problem:
What is the subnet mask of following host-address range? 99.224.0.1 - 99.239.255.254
My solution (or as far as I got)
First i wrote down the IPs in binary:
99.224.0.1
01100011.11100000.00000000.00000001
99.239.255.254
01100011.11101111.11111111.11111110
What I know is this is a A class network. And I thought it must have something to do with the difference in the bits, so I started to compare. (highest first)
01100011.11101111.11111111.11111110
01100011.11100000.00000000.00000001 (diff)
-----------------------------------
00000000.00001111.11111111.11111111
I ignored the last bit, because of the network / broadcast address.
Now I can turn it around and have my subnet mask?:
11111111.11110000.00000000.00000000
255.240.0.0
My question is: Is my approach correct? Is there an easier way to do it (by hand, or calc)?
If I'm very far from the correct way to do it, could someone help me understand?
Thanks for any help.
Your answer is correct, except that classful addresses don't exist anymore. The internet moved to Classless Inter-Domain Routing (CIDR) in 1993 so your terminology is a bit outdated ;)
IP networking these days works with routing prefixes. A prefix is a range of IP addresses defined by the first address in that range and the number of fixed bits at the start of the address. Your example shows this nicely.
Your example range is 99.224.0.1 - 99.239.255.254. Actually it is 99.224.0.0 - 99.239.255.255 because when used on a subnet the first and last addresses are reserved (but still part of the subnet and prefix).
The first address in the prefix we already have: 99.224.0.0. You can see the prefix length from your binary calculation (slightly modified):
01100011.11101111.11111111.11111111
01100011.11100000.00000000.00000000
----------------------------------- (xor)
00000000.00001111.11111111.11111111
----------------------------------- (not)
11111111.11110000.00000000.00000000
Just count the number of 1s at the beginning: 12. So your prefix is 99.224.0.0/12. This prefix covers all addresses that match 01100011.1110****.********.********.
When writing the prefix length down as a subnet mask you indeed get 255.240.0.0.
A little off-topic here because it is about networking and not about the algorithm to calculate the subnet mask, but maybe helpful: an example of how you can plan network addressing:
Lets say that for my office building I get IP addresses 192.0.2.0/24 (that is 192.0.2.0 - 192.0.2.255, subnet mask 255.255.255.0, 256 addresses). I need 50 addresses for servers, 100 addresses for employee devices and 40 addresses for guests.
Because addressing works with prefixes everything you get is a power of 2. If you use a /24 you have a prefix with 256 addresses. The full address is 32 bits, the first 24 are fixed so you have 8 bits left to use. 28 = 256. If you use a /25 you have a prefix 128 addresses, a /26 has 64 addresses etc.
That way you can also split up a prefix. 192.0.2.0/24 can be split up into 192.0.2.0/25 and 192.0.2.128/25. And those can be split again and again until you have a prefix that covers only a single address: a /32.
back to the example. To get (at least) 50 addresses for the servers I need to round up to the next power of 2. That is 26 = 64. To have that many addresses I need a /26 prefix. For the client devices I need to round up to 128 (27) so we need a /25. For the guests the next power of 2 is 64 (26) so a /26.
So we need to split up out /24 into a /25 and two /26s. One possible solution is:
Client devices: 192.0.2.0/25
Servers: 192.0.2.128/26
Guests: 192.0.2.192/26
Once we configure these subnets on our devices the first and last address of each subnet become special (the network and broadcast address) so we can use these ranges for our devices:
Client devices: 192.0.2.1 - 192.0.2.126
Servers: 192.0.2.129 - 192.0.2.190
Guests: 192.0.2.193 - 192.0.2.254

What are the names of each section of IPv4 address?

I am writing a UI class for handling IP address and I was wondering if a specific name exists for each of the four sections of IP address V4, to distinguish each part!
It is a mistake to think of an IP address as four octets. Ever since Classless Interdomain Routing came in over 20 years ago they are called 'bits'. There are now only two parts: the 'network address', which is the part that is masked in by the netmask, and the 'host identifier', which is the part that is masked out. The two parts are of variable length depending on the netmask.
No, there is not.
You could just name them first, second, etc...

Reserved MAC-addresses (some are assigned anyway?)

I'm trying to make a list of all MAC addresses that are reserved, do not exist, should not be used, should only be used locally etc. (Just like the list of reserved IP-addresses on Wikipedia, but for MAC.) Basically I want to loop over all MAC-addresses from a switch and filter out the "real" ones.
This page suggests all addresses starting with 00-00-5E or 01-00-5E are reserved, but when I look them up it seems like 00-00-5E is also assigned to the Information Sciences Institute (part of a university in California).
So 2 questions:
1) Is there any place I can find a list of reserved MAC-adresses?
2) What's up with 00-00-5E? Is only part of that range reserved, or is there some reason they assigned it to ISI?
I was just looking into this myself recently. I believe that the IANA (which you refer to in one of your links) will give the most authoritative answer: IANA Ethernet Number Assignments
I don't think that this means that these addresses can never be used though. According to RFC5342, Section 2.1
"The 2**8 unicast identifiers from 00-00-5E-00-00-00 through 00-00-5E-00-00-FF are reserved and require IESG Ratification for allocation (see Section 5.1)."
So basically, it appears you need special permission from IESG (Internet Engineering Steering Group) to get an address in that range, which I suppose the ISI has obtained somehow.
Section 2.1 of RFC5342 deals with 48-Bit MAC Identifiers and OUIs, and it doesn't make any mention of any address ranges that are strictly forbidden or permanently reserved from what I've understood.
The following OUI are reserved as per RFC 5342:
OUI 01:00:5E:(00:00:00-7f:ff:ff) - Used for IPV4 Multicast and MLPS Multicast.
OUI 00:00:5E:(00:01:00 – 00:01:FF) - Used for Virtual Router Redundancy Protocol (VRRP) IPV4
OUI 00:00:5E:(00:02:00 – 00:02:FF) - Used for Virtual Router Redundancy Protocol (VRRP) IPV6
OUI 33:33:00 – 33:33:FF - Reserved for IPV6 Multicast
OUI CF:00:00 – CF:FF:FF - Reserved by IANA for PPP(Point to Point Protocol)
OUI 00:00:5E (00:00:00 - 00:00:FF) - Requires IESG Ratification for allocation.
Was looking into this myself.. I know it's been a while since the post was active.. but I found these to be ok to use locally:
x2-xx-xx-xx-xx-xx
x6-xx-xx-xx-xx-xx
xA-xx-xx-xx-xx-xx
xE-xx-xx-xx-xx-xx
Source: https://honeywellaidc.force.com/supportppr/s/article/Locally-Administered-MAC-addresses
The registration authority for MAC addresses is the IEEE. It hands out OUIs (Organizationally Unique Identifiers), which give you a three byte prefix, and 2^24 addresses within it, for a fee (currently 2 995USD). You also get the rights to the corresponding multicasts, which have the prefix with the lowest bit of the first byte set. For instance, 00:80:C2 is allocated to the IEEE 802.1 committee, which uses 01:08:C2:00:00:00 for Spanning tree.
So, there isn't really a list of reserved addresses. There is a list of OUIs that have been allocated, unless the buyer has paid (a lot) extra for privacy. You can use any address that has the local bit set freely. A tiny fraction of multicast addresses have a significant meaning because heavyweights like IEEE, Cisco, IANA assign meanings to them. From the IEEE registration point of view, there is no particular significance to these blocks (except possibly to those it has allocated to itself).
Now, how did the 01-00-5E range end up allocated to the Information Sciences Institute? The simple
answer is that they paid for it. So, really the question should be 'how did the Internet get to use part of the range allocated to ISI?'. The answer is that the IANA used to be run from an office in ISI: specifically IANA was the legendary Jon Postel
Bottom line: you are on a bit of a fool's errand. You can distinguish local addresses and multicast addresses, and make some attempt to tie up allocated unicast addresses to vendor blocks. And you can probably do a bit more with well-known multicast addresses but only by tracking down individudal vendor's documentation (IANA is obviously an important one but only definitive for 1 of the 2^22 available blocks). One of the best places to start is probably the Wireshark codebase.

Resources