zoukankan      html  css  js  c++  java
  • tcpdump抓取http的数据

    1. To monitor HTTP traffic including request and response headers and message body:

    tcpdump -A -s 0 'tcp port 80 and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)'

    2. To monitor HTTP traffic including request and response headers and message body from a particular source:

    tcpdump -A -s 0 'src example.com and tcp port 80 and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)'

    3. To monitor HTTP traffic including request and response headers and message body from local host to local host:

    tcpdump -A -s 0 'tcp port 80 and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)' -i lo

    4. To only include HTTP requests, modify “tcp port 80” to “tcp dst port 80” in above commands

    5. Capture TCP packets from local host to local host

    tcpdump -i lo

  • 相关阅读:
    【leetcode】对称二叉树
    【leetcode】判断回文数
    053686
    053685
    053684
    053683
    053682
    053681
    053680
    053477
  • 原文地址:https://www.cnblogs.com/sanshuiqing/p/14292277.html
Copyright © 2011-2022 走看看