最近对IPv6感兴趣,在看
rfc 2460
里面的一段话不清楚,想请大家解释解释,谢谢
Each extension header is an integer multiple of 8 octets long, in
order to retain 8-octet alignment for subsequent headers. Multi-
octet fields within each extension header are aligned on their
natural boundaries, i.e., fields of width n octets are placed at an
integer multiple of n octets from the start of the header, for n = 1,
2, 4, or 8.
想知道两方面的知识
1、这样字节对齐有什么好处?是方便数据处理么?
2、后面的n=1,2,4,or 8,为什么不是1,2,3,4,5 。。。呢
另外:
IPv6通过下一个扩展头字段指明是否存在扩展头以及是什么样的扩展头,
可是如何确定下一个扩展头的位置(在数据包中的位置或者偏移)的呢?
有几种类型的扩展头的长度是不定的啊 |