zoukankan      html  css  js  c++  java
  • 关于“pacaket size limited during capture"的解释


    2011-04-13 15:56307人阅读评论(0)收藏举报
    前言:
    在linux下用tcpdump抓取http数据包,之后用wireshark打开,发现数据包的内容是不全的,如图:
    这时,想分析和获取http包中的内容是不可能是,在图中可以发现,wireshark给出了“Packet size limited during cap”的提示,和:“HTTP truncated”的提示。这是什么呢?

    对于这个问题,一个“外国朋友的MAIL中”给了非常好的解答,MAIL部分原文如下:
    Maynard, Chris wrote:
    "Packet  Size limited during capture" tells me that the packet was bigger than  the snaplen set, so the packet was truncated when captured.  In  Wireshark, the snaplen is set in the capture options dialog using the  "Limit each packet to ___ bytes" option, and with dumpcap, tshark and  tcpdump it is set via the "-s <snaplen>" option.  If not  specified, tcpdump uses a default snaplen of 68 (or 96, depending on the  platform).
    非常感谢这位外国朋友在MAIL中的解释。
     
    这个问题主要有两方面的原因:
    1)在wireshark等包分析软件中,可以设置包的长度,如果不当可能回出现这个问题; wireshark的设置如下图(在[Capture]---[Options]下配置):
     
     
    2)用Tcpdump进行抓包时,没有用-s参数指定抓取数据的长度,采用了默认长度为68或96字节;-s0则表示没有长度的限制。


  • 相关阅读:
    犀牛书学习笔记(2):对象和数组
    犀牛书学习笔记(1):语法结构、数据类型和值、表达式和运算符
    小学了一下css hack
    git学习系列--六分之一
    稍览了一下CommonJS
    意识流_六分之一
    两升的心思系列之-----粒子的预备
    mybatis_延迟加载
    mybatis_动态SQL
    mybatis_mapper动态代理
  • 原文地址:https://www.cnblogs.com/mull/p/4477813.html
Copyright © 2011-2022 走看看