tshark 中的过滤器 -Y、-2 和 -R 在 Wireshark 版本 2.XX 中容易混淆。
在 1.8 版本中,我们可以应用多个过滤器并使用以下命令将过滤后的数据包保存在 csv 文件中:
tshark.exe -r src.pcap -T fields -e frame.number -e frame.time -e frame.len -e ip.src -e ip.dst -e udp.srcport -e udp.dstport -E header=y -E separator=, -E quote=d -E occurrence=f -R (ip.src==x.x.x.x)&&(ip.dst==y.y.y.y) > filtered.csv
但是这个命令在 2.x 版本中不起作用。如果有人在新的 Wireshark 版本中应用了多重过滤器,请提供帮助。
最佳答案
您应该能够通过将 -R (ip.src==x.x.x.x)&&(ip.dst==y.y.y.y)
替换为 -Y "(ip. src==x.x.x.x)&&(ip.dst==y.y.y.y)”
。
关于wireshark - tshark 中的多个过滤器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42235352/