PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Noms de domaine > comp.protocols.tcp-ip > IPv6 Payload length calculation
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.protocols.tcp-ip TCP and IP network protocols.

IPv6 Payload length calculation

Réponse
 
LinkBack Outils de la discussion
Vieux 02/10/2007, 20h05   #1
DSv6Guy
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut IPv6 Payload length calculation

Hi,
I understand the IPv6 header is 40 bytes in length - fixed.
One of the fields in the v6 header is Payload length.
This field is fixed at 2-bytes in length and depending on the value of
each bit will determine the total length of the data field. No
problem.

I understand 2 Bytes = 0000 0000 0000 0000 = 64 different combinations
BUT how does this equate to 64KB?

The statement is
"The fact that the payload length field has 2 bytes limits the maximum
packet payload size to 64 KB."
How is it that 64 KB is arrived?
Thanks for any understanding.

  Réponse avec citation
Vieux 02/10/2007, 20h46   #2
Jim Logajan
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: IPv6 Payload length calculation

DSv6Guy <fsebera@yahoo.com> wrote:
> I understand 2 Bytes = 0000 0000 0000 0000 = 64 different combinations
> BUT how does this equate to 64KB?


It's basic binary number representation. There are 2 possible permutations
in 1 bit. 4 permutations in 2 bits, 8 permutations in 3 bits, 16
permutations in 4 bits, and so on - doubling for each additional bit. One
reaches 64 permutations in only 6 bits. By 16 bits there are 65536
permutations (or 64k, where k = 1024). I'm not sure how you are coming up
with only 64.
  Réponse avec citation
Vieux 02/10/2007, 21h41   #3
Albert Manfredi
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: IPv6 Payload length calculation

On Oct 2, 3:05 pm, DSv6Guy <fseb...@yahoo.com> wrote:
> Hi,
> I understand the IPv6 header is 40 bytes in length - fixed.
> One of the fields in the v6 header is Payload length.
> This field is fixed at 2-bytes in length and depending on the value of
> each bit will determine the total length of the data field. No
> problem.


Homework is such a drag.

Still, always go to the source. In this case, RFC 2460 is the source.
It's free, as are all RFCs.

http://www.ietf.org/rfc/rfc2460.txt?number=2460

Actually, the header is variable in IPv6 (and IPv4), in the sense that
you can add extensions to it. But for the purposes of the "length"
field, it is assumed to be a fixed 40 bytes, as you said. This is
different from IPv4, where the length of the header is also specified
as part of the header.

RFC 2460 says:

Version 4-bit Internet Protocol version number = 6.

Traffic Class 8-bit traffic class field. See section 7.

Flow Label 20-bit flow label. See section 6.

Payload Length 16-bit unsigned integer. Length of the IPv6
payload, i.e., the rest of the packet
following
this IPv6 header, in octets. (Note that any
extension headers [section 4] present are
considered part of the payload, i.e., included
in the length count.)

Next Header 8-bit selector. Identifies the type of header
immediately following the IPv6 header. Uses
the
same values as the IPv4 Protocol field
[RFC-1700
et seq.].

Hop Limit 8-bit unsigned integer. Decremented by 1 by
each node that forwards the packet. The packet
is discarded if Hop Limit is decremented to
zero.

And the 16-byte source and 16-byte destination addresses. Total is 40
bytes.

The "next header," if one or more exist, would have the length of that
extension in it, so you can always tell where the payload begins.

> I understand 2 Bytes = 0000 0000 0000 0000 = 64 different combinations
> BUT how does this equate to 64KB?


2 bytes is a series of 16 bits. Each one of these can be set to 0 or
1. So how many combinations can you have?

2^16 = 65536 = 64K

Bert

  Réponse avec citation
Vieux 04/10/2007, 01h24   #4
slebetman@yahoo.com
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: IPv6 Payload length calculation

On Oct 3, 3:05 am, DSv6Guy <fseb...@yahoo.com> wrote:
> Hi,
> I understand the IPv6 header is 40 bytes in length - fixed.
> One of the fields in the v6 header is Payload length.
> This field is fixed at 2-bytes in length and depending on the value of
> each bit will determine the total length of the data field. No
> problem.
>
> I understand 2 Bytes = 0000 0000 0000 0000 = 64 different combinations


Nothing to do whth 64 combinations. Infact you'll find you can
potentially have more than 64 THOUSAND combinations with those bits.
Didn't anyone teach you maths?

> BUT how does this equate to 64KB?
>


I wonder what is the decimal value of the binary number
1111111111111111 ?

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 22h29.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,11074 seconds with 12 queries