What does 80::80 mean? - ip

I was trying to connect to a router and the IP address for that device had and IP address with 80::80 at the end of it.I just wanted to know what it was and in what scenarios it would be used?
Thank you in advance

That's an IPv6 address. :: is replaced by an appropriate number of zeroes (it's a shorthand notation).

Related

CIDR /28 calculation confusion

I am trying to learn how to calculate IP addresses from CIDR block.
For example, 10.88.135.144/28 or
10.88.135.10010000/28
From what I understand, that means first 28 bits are associated with network address while the rest 4 bits are host addresses. That would result in following IP range:
10.88.135.10010000 - 10.88.135.10011111
The first IP should be 10.88.135.144 and last IP address should be 10.88.135.159
But according to cidr.xyz. The first IP should be 10.88.135.145 and the last one should be 10.88.135.158.
I really can't figure out why. Can anyone explain the reason for me? Thanks!
Generally, the first IP is the network identifier and cannot be assigned to any device.This is used by router or switch on the network.
The last one is the broadcasting IP and cannot be assigned to any device as this IP is used by router or switch on the network to broadcast information.
https://www.quora.com/In-IP-addresses-what-is-meant-by-network-ID-and-host-ID
https://supportforums.cisco.com/t5/wan-routing-and-switching/what-is-broadcast-address/td-p/2494445#messageBodySimpleDisplay_1

NS2, Node IP Addressing

I want to assign IP address to each node in NS2. How can I do it?
I want something like
node_(1) IP= 192.168.10.2
I have tried some other ways but does not seem to be working.
In implementing IP in NS2 it's quite tricky, we should make a new perspective about IP in NS2 and the other simulator.
As far as I Know, IP Address in NS2 refers no Node ID number.
You can read this conversation below :
1) https://www.researchgate.net/post/In_NS2_when_we_start_a_simple_wireless_simulation_1_Where_is_the_IP_address_of_a_node_stored_2_How_is_the_address_assigned_when_it_is_created2
2)
http://ns2ultimate.tumblr.com/post/1196152906/address-and-ip-routing-in-ns2

How can I determine the nearest IP address from certain IP address

I have 3 IP addresses.
source IP : IP1
target IP : IP2, IP3
How can I determine what target IP is the nearest one from source IP by C-code
I don't need to know exact locations of IP addresses.
Just want to know what target IP is the nearest.
Please give me some advices.
Thank you.
Your ip is in form
aaa.bbb.ccc.ddd - 4 components.
First you should process 1st component:
compare (source.aaaa - target1.aaaa) and (source.aaaa - target2.aaaa)
(by module, so diffs are always positive)
If both are equal, then proceed with next component.
If different - the one with smaller difference is the closest one.
Use traceroute?
$traceroute <IP ADDR>
Should return hop information and speed, assuming you have the IP Addresses themselves

What's the idea behind a network address?

I want to block an entire ip range from my webserver but I'm not sure if it's possible with lighttpd. What exactly is the idea behind a network address for example 10.0.0.0/8 or 176.4.8.0/24? Especially the backslash and the number confuse me?
That is the netmask. (A binary mask that tells the router which part of the IP to use)
/24 stands from 24 ones so 174.4.8.0/24
10110000.00000010.00000100.00000000 Address
11111111.11111111.11111111.00000000 Netmask
This is kind of a pain to get right but its not hard
http://en.wikipedia.org/wiki/Subnetwork

How do ports work with IPv6?

Conventional IPv4 dotted quad notation separates the address from the port with a colon, as in this example of a webserver on the loopback interface:
127.0.0.1:80
but with IPv6 notation the address itself can contain colons. For example, this is the short form of the loopback address:
::1
How are ports (or their functional equivalent) expressed in a textual representation of an IPv6 address/port endpoint?
They work almost the same as today. However, be sure you include [] around your IP.
For example : http://[1fff:0:a88:85a3::ac1f]:8001/index.html
Wikipedia has a pretty good article about IPv6: http://en.wikipedia.org/wiki/IPv6#Addressing
The protocols used in IPv6 are the same as the protocols in IPv4. The only thing that changed between the two versions is the addressing scheme, DHCP [DHCPv6] and ICMP [ICMPv6]. So basically, anything TCP/UDP related, including the port range (0-65535) remains unchanged.
Edit: Port 0 is a reserved port in TCP but it does exist. See RFC793
Wikipedia points out that the syntax of an IPv6 address includes colons and has a short form preventing fixed-length parsing, and therefore you have to delimit the address portion with []. This completely avoids the odd parsing errors.
(Taken from an edit Peter Wone made to the original question.)
They're the same, aren't they? Now I'm losing confidence in myself but I really thought IPv6 was just an addressing change. TCP and UDP are still addressed as they are under IPv4.
I'm pretty certain that ports only have a part in tcp and udp. So it's exactly the same even if you use a new IP protocol
I would say the best reference is Format for Literal IPv6 Addresses in URL's where usage of [] is defined.
Also, if it is for programming and code, specifically Java, I would suggest this readsClass for Inet6Address java/net/URL definition where usage of Inet4 address in Inet6 connotation and other cases are presented in details. For my case, IPv4-mapped address Of the form::ffff:w.x.y.z, for IPv6 address is used to represent an IPv4 address also solved my problem. It allows the native program to use the same address data structure and also the same socket when communicating with both IPv4 and IPv6 nodes. This is the case on Amazon cloud Linux boxes default setup.

Resources