Examples (8)
Monitor everything on localhost
Only show packets matching a specific output filter
tshark -Y 'http.request.method == "GET"'Decode a TCP port using a specific protocol (e.g. HTTP)
tshark -d tcp.port==8888,httpSpecify the format of captured output
tshark -T json|text|ps|...Select specific fields to output
tshark -T fields|ek|json|pdml -e http.request.method -e ip.srcWrite captured packet to a file
tshark -w path/to/fileAnalyze packets from a file
tshark -r path/to/file.pcapmade by @shridhargupta | data from tldr-pages