We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Memory is not freed when creating AsyncSniffer repeatedly.
Test code
from scapy.all import * import time def process_packet(packet): pass def start_sniff(): ifaces = ["PortChannel102", "PortChannel103", "PortChannel104", "PortChannel105", "PortChannel106", "PortChannel107", "PortChannel108", "PortChannel109"] sniffstring = "udp and (dst host " + str("10.1.0.32") + " or dst host " + "fc00:1::32" + ") and dst port " + str(65330) sniffer = AsyncSniffer(iface=ifaces, filter=sniffstring, prn=process_packet, store=False) sniffer.start() RETRY = 30 while RETRY >= 0 and not hasattr(sniffer, 'stop_cb'): time.sleep(0.1) RETRY -= 1 print("Sniff started") try: sniffer.stop() except: pass else: print("Sniff stopped") def main(): while True: start_sniff() time.sleep(1) if __name__ == "__main__": main()
2.4.5
3.9.2
Debian GNU/Linux 11 (bullseye)
No response
Run the script and monitor the memory usage
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Brief description
Memory is not freed when creating AsyncSniffer repeatedly.
Test code
Scapy version
2.4.5
Python version
3.9.2
Operating system
Debian GNU/Linux 11 (bullseye)
Additional environment information
No response
How to reproduce
Run the script and monitor the memory usage
Actual result
No response
Expected result
No response
Related resources
No response
The text was updated successfully, but these errors were encountered: