-
Hello, @ZerBea ! I encountered an incomprehensible behavior of the tool.
The interface is in managed mode:
Switching to monitor mode via:
After switching to monitor mode:
As I see in src, wlan0 is not visible because this system call fails:
And after this run f.e.:
The behavior is logical. BUT! After this run:
Why wlan0 is visible now? After reviewing the src, it became clear that if a socket is created in opensocket() |
Beta Was this translation helpful? Give feedback.
Replies: 13 comments 9 replies
-
hcxdumptool <= 6.2.9 depend on WIRELESS EXTENSIONS. They are called via ioctl() system calls. If this calls are not available, hcxdumptool will not work as expected. This is not an unexpected behavior (because all tests are skipped) and it is mentioned in help first section (usage):
I started to remove WIRELESS EXTENSIONS from hcxdumptool and move to NL80211. You can try latest git head, but I guess it will not work, too, if the driver does not support an AF_PACKET SOCK_RAW and an AF_NETLINK SOCK_RAW, e.g. as commented here: |
Beta Was this translation helpful? Give feedback.
-
Please compile latest git head and comment output if Do not use a third party tool to bring interface up/down or to set monitor mode, because that skip the internal tests. |
Beta Was this translation helpful? Give feedback.
-
This is the (old) way like deprecated hcxdumptool (WIRELESS EXTENSION version )handling monitor mode:
This ioctl(WIRELESS EXTENSIONS) are deprecated and they will not receive new features. This is the way like latest hcxdumtool (NL80211 version )handling monitor mode:
It is mandatory that the driver support all steps (1..6). |
Beta Was this translation helpful? Give feedback.
-
Thanks for the comments. If you take a look at this line: As I mentioned here: |
Beta Was this translation helpful? Give feedback.
-
Most of the functions of hcxdumptool require an up-to-date kernel. What is the version of your installed kernel. My recommendation (from README.md Requirements section) is at least kernel 5.15: |
Beta Was this translation helpful? Give feedback.
-
Maybe this will work:
Now comment this lines:
set monitor mode
Steps 2 -> 6 are now disabled and hcxdumptool accept that third party tool has set monitor mode. Run hcxdumptool on wlan0 and let's see what happens. |
Beta Was this translation helpful? Give feedback.
-
Ok, thanks for testing that. Unfortunately this "failed to open raw packet socket" is definitely the end of the tests. |
Beta Was this translation helpful? Give feedback.
-
It looks like creating raw sockets running Android is not possible.
or this one: or this one: or this one: or this one: |
Beta Was this translation helpful? Give feedback.
-
"As I understand it, in the case of my driver this will not work. And because of the setting the monitor mode through third-party utilities, the behavior of the program and socket operation becomes unpredictable. Am I right?" Looks like it is a combination of Android behavior and the driver (monitor mode by con_mode=4 and not by NL80211). |
Beta Was this translation helpful? Give feedback.
-
Please use latest git head of hcxdumptool of hcxdumptool, because socket handling is completely different to the WIRELESS EXTENSION version. BTW: |
Beta Was this translation helpful? Give feedback.
-
Thanks. or you get an ERROR similar to hcxdumptool (WIRELESS EXTENSION version): Android doesn't alow you to send raw packets. While the aircrack-ng suite is divided into several tools (e.g. airodump-ng = receive, aireplay-ng = transmit), transmit and receive functions are part of hcxdumptool. If this functions (control, receive and transmit) are not working, hcxdumptool will terminated. |
Beta Was this translation helpful? Give feedback.
-
No problem, you're welcome. BTW: Some options may look similar, but they are not. The engine is completely different. |
Beta Was this translation helpful? Give feedback.
-
By latest commit, I added Qualcomm chipsets to the list of not recommended interfaces, because they don't support frame injection:
https://wireless.wiki.kernel.org/en/users/Drivers/ath10k The same applies to Android (cnss). |
Beta Was this translation helpful? Give feedback.
Thanks.
As you can see, aireplay-ng is not able to transmit. Either no packet is transmitted
13:40:49 Trying broadcast probe requests...
13:40:50 No Answer...
13:40:50 Found 0 APs
or you get an ERROR similar to hcxdumptool (WIRELESS EXTENSION version):
ioctl(SIOCSIWMODE) failed: Operation not supported
Android doesn't alow you to send raw packets.
While the aircrack-ng suite is divided into several tools (e.g. airodump-ng = receive, aireplay-ng = transmit), transmit and receive functions are part of hcxdumptool. If this functions (control, receive and transmit) are not working, hcxdumptool will terminated.