Skip to content
New issue

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

Update berate_ap #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

realalexandergeorgiev
Copy link

fix for "ERROR: Your adapter can not transmit to channel 1, frequency band 2.4GHz." - see #12

iw list now seems to add ".0" to the frequency, which causes parsing to fail. may be similar for 5ghz, not tested due to lack of hardware.

10:44 root@kali /alex $ iw list | egrep " MHz "                
			* 2412.0 MHz [1] (20.0 dBm)
			* 2417.0 MHz [2] (20.0 dBm)
			* 2422.0 MHz [3] (20.0 dBm)
			* 2427.0 MHz [4] (20.0 dBm)
			* 2432.0 MHz [5] (20.0 dBm)
			* 2437.0 MHz [6] (20.0 dBm)
			* 2442.0 MHz [7] (20.0 dBm)
			* 2447.0 MHz [8] (20.0 dBm)
			* 2452.0 MHz [9] (20.0 dBm)
			* 2457.0 MHz [10] (20.0 dBm)
			* 2462.0 MHz [11] (20.0 dBm)
			* 2467.0 MHz [12] (20.0 dBm)
			* 2472.0 MHz [13] (20.0 dBm)
			* 2484.0 MHz [14] (disabled)

fix for "ERROR: Your adapter can not transmit to channel 1, frequency band 2.4GHz." - see sensepost#12

iw list now seems to add ".0" to the frequency, which causes parsing to fail. may be similar for 5ghz, not tested due to lack of hardware.

```
10:44 root@kali /alex $ iw list | egrep " MHz "                
			* 2412.0 MHz [1] (20.0 dBm)
			* 2417.0 MHz [2] (20.0 dBm)
			* 2422.0 MHz [3] (20.0 dBm)
			* 2427.0 MHz [4] (20.0 dBm)
			* 2432.0 MHz [5] (20.0 dBm)
			* 2437.0 MHz [6] (20.0 dBm)
			* 2442.0 MHz [7] (20.0 dBm)
			* 2447.0 MHz [8] (20.0 dBm)
			* 2452.0 MHz [9] (20.0 dBm)
			* 2457.0 MHz [10] (20.0 dBm)
			* 2462.0 MHz [11] (20.0 dBm)
			* 2467.0 MHz [12] (20.0 dBm)
			* 2472.0 MHz [13] (20.0 dBm)
			* 2484.0 MHz [14] (disabled)
```
@cablethief
Copy link
Member

Im looking at the linux-router project (The successor to create_ap), and seeing how they addressed this. What are your thoughts on https://github.com/garywill/linux-router/blob/master/lnxrouter#L624-L641.

@cablethief
Copy link
Member

As an additional note, your regex does not escape the .. This solution also has the effect of killing previous iw outputs so it will kill backwards compatibility.

@realalexandergeorgiev
Copy link
Author

Yes,true. Feel free to add the [], but I strongly believe whoever uses kali has it up2date anyway ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants