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

Segmentation violation at "wifi.recon.channel clear" command #661

Closed
MartinRJ opened this issue Nov 23, 2019 · 0 comments
Closed

Segmentation violation at "wifi.recon.channel clear" command #661

MartinRJ opened this issue Nov 23, 2019 · 0 comments

Comments

@MartinRJ
Copy link

MartinRJ commented Nov 23, 2019

Crash when issuing wifi.recon.channel clear

Environment

  • Bettercap version v2.26.1
  • Kali GNU/Linux Rolling, Release 2019.4 (AMD 64)
  • Go version go1.13.4 linux/amd64
  • Command line argument: wifi.recon.channel clear
  • Full debug output while reproducing the issue:
192.168.0.0/24 > 192.168.0.56  » wifi.recon.channel clear

Stopping modules and cleaning session state ...
[01:00:47] [session.closing] {session.closing 2019-11-24 01:00:47.612673391 +0100 CET m=+4.180199428 <nil>}
[01:00:47] [sys.log] [dbg] wifi resetting hopping channels
[01:00:47] [mod.stopped] events.stream
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x90 pc=0xf40492]

goroutine 1 [running]:
github.com/bettercap/bettercap/network.(*Endpoint).Name(...)
	/home/git/go/src/github.com/bettercap/bettercap/network/lan_endpoint.go:125
github.com/bettercap/bettercap/modules/wifi.NewWiFiModule.func16(0xc0004b60d0, 0x1, 0x1, 0xc00080ba20, 0xc00080ba88)
	/home/git/go/src/github.com/bettercap/bettercap/modules/wifi/wifi.go:357 +0x372
github.com/bettercap/bettercap/session.(*ModuleHandler).Exec(0xc000198940, 0xc0004b60d0, 0x1, 0x1, 0x0, 0x0)
	/home/git/go/src/github.com/bettercap/bettercap/session/module_handler.go:74 +0xa3
github.com/bettercap/bettercap/session.(*Session).Run(0xc0004de4e0, 0xc000034c80, 0x18, 0x1, 0x1)
	/home/git/go/src/github.com/bettercap/bettercap/session/session.go:416 +0x6ae
main.main()
	/home/git/go/src/github.com/bettercap/bettercap/main.go:94 +0x977

Steps to Reproduce

  1. Start bettercap: sudo bettercap -debug
  2. Issue command: wifi.recon.channel clear

Expected behavior: What you expected to happen
Wifi recon channels are reset to default.

Actual behavior: What actually happened
Application crashes.

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

No branches or pull requests

1 participant