Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Z4nzu
GitHub Repository: Z4nzu/hackingtool
Path: blob/master/tools/others/wifi_jamming.py
1781 views
1
# coding=utf-8
2
from core import HackingTool
3
from core import HackingToolsCollection
4
5
from rich.console import Console
6
from rich.theme import Theme
7
from rich.table import Table
8
from rich.panel import Panel
9
from rich.prompt import Prompt
10
from rich import box
11
12
_theme = Theme({"purple": "#7B61FF"})
13
console = Console(theme=_theme)
14
15
16
class WifiJammerNG(HackingTool):
17
TITLE = "WifiJammer-NG"
18
DESCRIPTION = "Continuously jam all wifi clients and access points within range."
19
INSTALL_COMMANDS = [
20
"sudo git clone https://github.com/MisterBianco/wifijammer-ng.git",
21
"cd wifijammer-ng;sudo pip install -r requirements.txt"
22
]
23
RUN_COMMANDS = [
24
'echo "python wifijammer.py [-a AP MAC] [-c CHANNEL] [-d] [-i INTERFACE] [-m MAXIMUM] [-k] [-p PACKETS] [-s SKIP] [-t TIME INTERVAL] [-D]"| boxes | lolcat',
25
"cd wifijammer-ng;sudo python wifijammer.py"
26
]
27
PROJECT_URL = "https://github.com/MisterBianco/wifijammer-ng"
28
29
30
class KawaiiDeauther(HackingTool):
31
TITLE = "KawaiiDeauther"
32
DESCRIPTION = "Kawaii Deauther is a pentest toolkit whose goal is to perform \n " \
33
"jam on WiFi clients/routers and spam many fake AP for testing purposes."
34
INSTALL_COMMANDS = [
35
"sudo git clone https://github.com/aryanrtm/KawaiiDeauther.git",
36
"cd KawaiiDeauther;sudo bash install.sh"
37
]
38
RUN_COMMANDS = ["cd KawaiiDeauther;sudo bash KawaiiDeauther.sh"]
39
PROJECT_URL = "https://github.com/aryanrtm/KawaiiDeauther"
40
41
42
class WifiJammingTools(HackingToolsCollection):
43
TITLE = "Wifi Deauthenticate"
44
TOOLS = [
45
WifiJammerNG(),
46
KawaiiDeauther()
47
]
48
49
def pretty_print(self):
50
table = Table(title="Wifi Jamming Tools", show_lines=True, expand=True)
51
table.add_column("Title", style="purple", no_wrap=True)
52
table.add_column("Description", style="purple")
53
table.add_column("Project URL", style="purple", no_wrap=True)
54
55
for t in self.TOOLS:
56
desc = getattr(t, "DESCRIPTION", "") or ""
57
url = getattr(t, "PROJECT_URL", "") or ""
58
table.add_row(t.TITLE, desc.strip().replace("\n", " "), url)
59
60
panel = Panel(table, title="[purple]Available Tools[/purple]", border_style="purple")
61
console.print(panel)
62
63
def show_options(self, parent=None):
64
console.print("\n")
65
panel = Panel.fit("[bold magenta]Wifi Jamming Tools Collection[/bold magenta]\n"
66
"Select a tool to view details or run it.",
67
border_style="purple")
68
console.print(panel)
69
70
table = Table(title="[bold cyan]Available Tools[/bold cyan]", show_lines=True, expand=True)
71
table.add_column("Index", justify="center", style="bold yellow")
72
table.add_column("Tool Name", justify="left", style="bold green")
73
table.add_column("Description", justify="left", style="white")
74
75
for i, tool in enumerate(self.TOOLS):
76
title = getattr(tool, "TITLE", tool.__class__.__name__)
77
desc = getattr(tool, "DESCRIPTION", "—")
78
table.add_row(str(i + 1), title, desc or "—")
79
80
table.add_row("[red]99[/red]", "[bold red]Exit[/bold red]", "Return to previous menu")
81
console.print(table)
82
83
try:
84
choice = Prompt.ask("[bold cyan]Select a tool to view/run[/bold cyan]", default="99")
85
choice = int(choice)
86
if 1 <= choice <= len(self.TOOLS):
87
selected = self.TOOLS[choice - 1]
88
if hasattr(selected, "show_options"):
89
selected.show_options(parent=self)
90
elif hasattr(selected, "run"):
91
selected.run()
92
elif hasattr(selected, "show_info"):
93
selected.show_info()
94
else:
95
console.print("[bold yellow]Selected tool has no runnable interface.[/bold yellow]")
96
elif choice == 99:
97
return 99
98
except Exception:
99
console.print("[bold red]Invalid choice. Try again.[/bold red]")
100
return self.show_options(parent=parent)
101
102
103
if __name__ == "__main__":
104
tools = WifiJammingTools()
105
tools.pretty_print()
106
tools.show_options()
107