nmap / npcap

Nmap Project's Windows packet capture and transmission library
https://npcap.com
Other
2.99k stars 516 forks source link

how to set WI-FI 5GHz channel with wlanhelper.exe? #98

Open w1nww opened 7 years ago

w1nww commented 7 years ago

hi,all how to set WI-FI 5GHz channel with wlanhelper.exe? image

w1nww commented 7 years ago

I am sure that my adapter supports 5GHz

Varunram commented 7 years ago

@w1nst0nwU Correct me if I'm wrong but WlanHelper supports only those interface channels between 1 and 14 right? Did you try manually setting the frequency using the "freq" command?

hsluoyz commented 7 years ago

WlanHelper doesn't check your input about the channel, it just submits your input (like 153) to the operating system. From the error code STATUS_UNSUCCESSFUL, I can't see any specific reasons about this error.

hsluoyz commented 7 years ago

I think that your adapter supports 5GHz doesn't mean that your driver for the adapter supports to set the 5GHz channel on Windows. There are two different things. I don't know if there are any other ways to set it? (like using Microsoft Network Monitor? I don't know). If it can do this and Npcap can't, then it's a Npcap bug. Otherwise, maybe it's just because your driver for the adapter (usually also developed by the adapter manufacturer) just doesn't develop this part of the function.

alagoutte commented 7 years ago

It is not possible to the list of supported channel ?

hsluoyz commented 7 years ago

I found DOT11_SUPPORTED_ANTENNA here: https://msdn.microsoft.com/en-us/library/windows/hardware/ff548785(v=vs.85).aspx

Is this the same thing with as the channel?

alagoutte commented 7 years ago

i think not

There is often multiple Antenna (and the antenna support 2,4Ghz and 5Ghz)

hsluoyz commented 7 years ago

WlanHelper just read/write some OIDs to do its work. I found OID_DOT11_SUPPORTED_DSSS_CHANNEL_LIST and OID_DOT11_SUPPORTED_OFDM_FREQUENCY_LIST here: https://msdn.microsoft.com/en-us/windows/ff557454(v=vs.80).aspx.

It seems that these two OIDs only support DSSS and OFDM. I remember that there are many PHYs? 802.11 a, b, g, n, ac, etc. Is this the right places to get the channels?

alagoutte commented 7 years ago

DSSS is for 802.11b

and all other PHY (802.11a, g, n, ac...) use OFDM

There is no OID about frequency ? or band ?

hsluoyz commented 7 years ago

I think channel and frequency are regarded as the same thing on Windows at least? I test WlanHelper's channel and freq subcommands and usually get the same result.

alagoutte commented 7 years ago

@hsluoyz it is no possible to get the list of supported channel/freq ?