You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Call "sniff" - either interactively or in code - sniff(iface="Valid Wifi Interface Name",monitor=True,count=5)
Actual result
'\WlanHelper.exe' is not recognized as an internal or external command,
operable program or batch file.
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\sendrecv.py", line 1311, in sniff
sniffer.run(*args, **kwargs)
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\sendrecv.py", line 1171, in run
sniff_sockets[RL2(iface)(type=ETH_P_ALL, iface=iface,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\libpcap.py", line 481, in init
fd = open_pcap(
^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 766, in open_pcap
monitored = iface.ismonitor()
^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 413, in ismonitor
res = (self.mode() == "monitor")
^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 404, in mode
return self.npcap_get("mode")
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 396, in _npcap_get
raise OSError(res.decode("utf8", errors="ignore"))
OSError
Expected result
<Sniffed: TCP:0 UDP:0 ICMP:0 Other:5>
Related resources
No response
The text was updated successfully, but these errors were encountered:
Brief description
On a windows machine, with scapy 2.5.0 and npcap 1.79, when calling sniff like this:
a=sniff(iface="Valid Wifi Interface Name",monitor=True,count=5)
Scapy throws an exception due to a path formulation error for WLanHelper.
Scapy version
2.5
Python version
3.12
Operating system
Windows LATEST
Additional environment information
Name: scapy
Version: 2.5.0
Summary: Scapy: interactive packet manipulation tool
Home-page: https://scapy.net
Author: Philippe BIONDI
Author-email: guillaume@valadon.net
License: GPL-2.0-only
Location: C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages
Requires:
Required-by:
How to reproduce
Actual result
'\WlanHelper.exe' is not recognized as an internal or external command,
operable program or batch file.
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\sendrecv.py", line 1311, in sniff
sniffer.run(*args, **kwargs)
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\sendrecv.py", line 1171, in run
sniff_sockets[RL2(iface)(type=ETH_P_ALL, iface=iface,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\libpcap.py", line 481, in init
fd = open_pcap(
^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 766, in open_pcap
monitored = iface.ismonitor()
^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 413, in ismonitor
res = (self.mode() == "monitor")
^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 404, in mode
return self.npcap_get("mode")
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\scapy\arch\windows_init.py", line 396, in _npcap_get
raise OSError(res.decode("utf8", errors="ignore"))
OSError
Expected result
<Sniffed: TCP:0 UDP:0 ICMP:0 Other:5>
Related resources
No response
The text was updated successfully, but these errors were encountered: