Tshark Grab Bag Analysis

Source: Internet
Author: User
Tags mysql query

One, install
#yum install-y Wireshark

Two. Specific Use cases

1. Crawl 500 packages, extract the visited URLs to print out
Tshark-s 0-i eth0-n-F ' TCP DST Port + '-R ' http.host and Http.request.uri '-t fields-e http.host-e Http.request.uri -L-C 50

2. Crawl 500 packets, extract the visitor's access address and submission method and visitor IP
Tshark-s 0-i eth0-n-F ' TCP DST Port + '-R ' http.host and Http.request.uri '-t fields-e frame.time-e ip.src-e http. Request.method-e http.host-e http.request.uri-e ip.src-e ip.dst-l-C 500


3. Crawl MySQL Query
Tshark-i eth1-d tcp.port==3306,mysql-t fields-e mysql.query ' Port 3306 '
Tshark-i lo-d tcp.port==3306,mysql-t fields-e mysql.query ' Port 3306 '

Specify type
Tshark-i lo-d tcp.port==3306,mysql-t fields-e mysql.query ' Port 3306 '-R ' MySQL matches ' select| Insert| delete| UPDATE "'


4. Statistics HTTP Status
Tshark-n-q-z Http,stat,-Z http,tree

Tshark Grab Bag Analysis

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.