Scapy 中是否有一个选项:only_summaries?
Is there an option: only_summaries in Scapy?
我正在用 Scapy 处理一个巨大的 pcap 文件,但是速度很慢。
当我计划用 Pyshark 重构它时,我发现有一个名为 'pyshark.FileCapture()' 的函数提供了一个选项:only_summaries.
这就是我想要的。那么,Scapy中是否也有任何选项或方法?
不,它没有。我在 github 上得到了 gpotter2 的回答,他是 scapy 的负责人之一。
见https://github.com/secdev/scapy/issues/1509
If you want to perform the better, you can use with
PcapReader(filename) as reader:
for pkt in reader:
[... actions on the pkt ...] You can store specific informations on the packet that you want, or directly perform actions
on the packet. But scapy does not have a only_summaries by itself:
scapy would have to dissect the packet anyways, before returning only
some few informations
我正在用 Scapy 处理一个巨大的 pcap 文件,但是速度很慢。
当我计划用 Pyshark 重构它时,我发现有一个名为 'pyshark.FileCapture()' 的函数提供了一个选项:only_summaries.
这就是我想要的。那么,Scapy中是否也有任何选项或方法?
不,它没有。我在 github 上得到了 gpotter2 的回答,他是 scapy 的负责人之一。
见https://github.com/secdev/scapy/issues/1509
If you want to perform the better, you can use with
PcapReader(filename) as reader: for pkt in reader: [... actions on the pkt ...] You can store specific informations on the packet that you want, or directly perform actions
on the packet. But scapy does not have a only_summaries by itself: scapy would have to dissect the packet anyways, before returning only some few informations