bbot 2.1.0.5078rc0__py3-none-any.whl → 2.1.0.5097rc0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of bbot might be problematic. Click here for more details.

bbot/__init__.py CHANGED
@@ -1,4 +1,4 @@
1
1
  # version placeholder (replaced by poetry-dynamic-versioning)
2
- __version__ = "v2.1.0.5078rc"
2
+ __version__ = "v2.1.0.5097rc"
3
3
 
4
4
  from .scanner import Scanner, Preset
@@ -1,5 +1,4 @@
1
1
  import sys
2
- import atexit
3
2
  import logging
4
3
  from copy import copy
5
4
  import multiprocessing
@@ -71,7 +70,6 @@ class BBOTLogger:
71
70
  # Start the QueueListener
72
71
  self.listener = logging.handlers.QueueListener(self.queue, *self.log_handlers.values())
73
72
  self.listener.start()
74
- atexit.register(self.listener.stop)
75
73
 
76
74
  self.log_level = logging.INFO
77
75
 
@@ -342,7 +342,15 @@ class DepsInstaller:
342
342
  # ensure tldextract data is cached
343
343
  self.parent_helper.tldextract("evilcorp.co.uk")
344
344
  # command: package_name
345
- core_deps = {"unzip": "unzip", "curl": "curl"}
345
+ core_deps = {
346
+ "unzip": "unzip",
347
+ "zipinfo": "unzip",
348
+ "curl": "curl",
349
+ "git": "git",
350
+ "make": "make",
351
+ "gcc": "gcc",
352
+ "bash": "bash",
353
+ }
346
354
  for command, package_name in core_deps.items():
347
355
  if not self.parent_helper.which(command):
348
356
  to_install.add(package_name)
@@ -0,0 +1,48 @@
1
+ from bbot.modules.templates.subdomain_enum import subdomain_enum_apikey
2
+
3
+
4
+ class BufferOverrun(subdomain_enum_apikey):
5
+ watched_events = ["DNS_NAME"]
6
+ produced_events = ["DNS_NAME"]
7
+ flags = ["subdomain-enum", "passive", "safe"]
8
+ meta = {
9
+ "description": "Query BufferOverrun's TLS API for subdomains",
10
+ "created_date": "2024-10-23",
11
+ "author": "@TheTechromancer",
12
+ "auth_required": True,
13
+ }
14
+ options = {"api_key": "", "commercial": False}
15
+ options_desc = {"api_key": "BufferOverrun API key", "commercial": "Use commercial API"}
16
+
17
+ base_url = "https://tls.bufferover.run/dns"
18
+ commercial_base_url = "https://bufferover-run-tls.p.rapidapi.com/ipv4/dns"
19
+
20
+ async def setup(self):
21
+ self.commercial = self.config.get("commercial", False)
22
+ return await super().setup()
23
+
24
+ def prepare_api_request(self, url, kwargs):
25
+ if self.commercial:
26
+ kwargs["headers"]["x-rapidapi-host"] = "bufferover-run-tls.p.rapidapi.com"
27
+ kwargs["headers"]["x-rapidapi-key"] = self.api_key
28
+ else:
29
+ kwargs["headers"]["x-api-key"] = self.api_key
30
+ return url, kwargs
31
+
32
+ async def request_url(self, query):
33
+ url = f"{self.commercial_base_url if self.commercial else self.base_url}?q=.{query}"
34
+ return await self.api_request(url)
35
+
36
+ def parse_results(self, r, query):
37
+ j = r.json()
38
+ subdomains_set = set()
39
+ if isinstance(j, dict):
40
+ results = j.get("Results", [])
41
+ for result in results:
42
+ parts = result.split(",")
43
+ if len(parts) > 4:
44
+ subdomain = parts[4].strip()
45
+ if subdomain and subdomain.endswith(f".{query}"):
46
+ subdomains_set.add(subdomain)
47
+ for subdomain in subdomains_set:
48
+ yield subdomain
bbot/modules/gowitness.py CHANGED
@@ -72,7 +72,7 @@ class gowitness(BaseModule):
72
72
 
73
73
  # make sure we have a working chrome install
74
74
  chrome_test_pass = False
75
- for binary in ("chrome", "chromium", custom_chrome_path):
75
+ for binary in ("chrome", "chromium", "chromium-browser", custom_chrome_path):
76
76
  binary_path = self.helpers.which(binary)
77
77
  if binary_path and Path(binary_path).is_file():
78
78
  chrome_test_proc = await self.run_process([binary_path, "--version"])
bbot/modules/wpscan.py CHANGED
@@ -33,7 +33,7 @@ class wpscan(BaseModule):
33
33
  deps_apt = ["curl", "make", "gcc"]
34
34
  deps_ansible = [
35
35
  {
36
- "name": "Install Ruby Deps (Debian/Ubuntu)",
36
+ "name": "Install Ruby Deps (Debian)",
37
37
  "package": {"name": ["ruby-rubygems", "ruby-dev"], "state": "present"},
38
38
  "become": True,
39
39
  "when": "ansible_facts['os_family'] == 'Debian'",
@@ -48,7 +48,13 @@ class wpscan(BaseModule):
48
48
  "name": "Install Ruby Deps (Fedora)",
49
49
  "package": {"name": ["rubygems", "ruby-devel"], "state": "present"},
50
50
  "become": True,
51
- "when": "ansible_facts['os_family'] == 'Fedora'",
51
+ "when": "ansible_facts['os_family'] == 'RedHat'",
52
+ },
53
+ {
54
+ "name": "Install Ruby Deps (Alpine)",
55
+ "package": {"name": ["ruby-dev", "ruby-bundler"], "state": "present"},
56
+ "become": True,
57
+ "when": "ansible_facts['os_family'] == 'Alpine'",
52
58
  },
53
59
  {
54
60
  "name": "Install wpscan gem",
bbot/test/conftest.py CHANGED
@@ -13,17 +13,31 @@ from bbot.core import CORE
13
13
  from bbot.core.helpers.misc import execute_sync_or_async
14
14
  from bbot.core.helpers.interactsh import server_list as interactsh_servers
15
15
 
16
+ # silence stdout + trace
17
+ root_logger = logging.getLogger()
18
+ pytest_debug_file = Path(__file__).parent.parent.parent / "pytest_debug.log"
19
+ print(f"pytest_debug_file: {pytest_debug_file}")
20
+ debug_handler = logging.FileHandler(pytest_debug_file)
21
+ debug_handler.setLevel(logging.DEBUG)
22
+ debug_format = logging.Formatter("%(asctime)s [%(levelname)s] %(name)s %(filename)s:%(lineno)s %(message)s")
23
+ debug_handler.setFormatter(debug_format)
24
+ root_logger.addHandler(debug_handler)
16
25
 
17
26
  test_config = OmegaConf.load(Path(__file__).parent / "test.conf")
18
- if test_config.get("debug", False):
19
- os.environ["BBOT_DEBUG"] = "True"
20
- logging.getLogger("bbot").setLevel(logging.DEBUG)
21
- CORE.logger.log_level = logging.DEBUG
22
- else:
23
- # silence stdout + trace
24
- root_logger = logging.getLogger()
25
- for h in root_logger.handlers:
26
- h.addFilter(lambda x: x.levelname not in ("STDOUT", "TRACE"))
27
+
28
+ os.environ["BBOT_DEBUG"] = "True"
29
+ CORE.logger.log_level = logging.DEBUG
30
+
31
+ # silence all stderr output:
32
+ stderr_handler = CORE.logger.log_handlers["stderr"]
33
+ stderr_handler.setLevel(logging.CRITICAL)
34
+ handlers = list(CORE.logger.listener.handlers)
35
+ handlers.remove(stderr_handler)
36
+ CORE.logger.listener.handlers = tuple(handlers)
37
+
38
+ for h in root_logger.handlers:
39
+ h.addFilter(lambda x: x.levelname not in ("STDOUT", "TRACE"))
40
+
27
41
 
28
42
  CORE.merge_default(test_config)
29
43
 
@@ -0,0 +1,35 @@
1
+ from .base import ModuleTestBase
2
+
3
+
4
+ class TestBufferOverrun(ModuleTestBase):
5
+ config_overrides = {"modules": {"bufferoverrun": {"api_key": "asdf", "commercial": False}}}
6
+
7
+ async def setup_before_prep(self, module_test):
8
+ # Mock response for non-commercial API
9
+ module_test.httpx_mock.add_response(
10
+ url="https://tls.bufferover.run/dns?q=.blacklanternsecurity.com",
11
+ match_headers={"x-api-key": "asdf"},
12
+ json={"Results": ["1.2.3.4,example.com,*,*,sub.blacklanternsecurity.com"]},
13
+ )
14
+
15
+ def check(self, module_test, events):
16
+ assert any(e.data == "sub.blacklanternsecurity.com" for e in events), "Failed to detect subdomain for free API"
17
+
18
+
19
+ class TestBufferOverrunCommercial(ModuleTestBase):
20
+ modules_overrides = ["bufferoverrun"]
21
+ module_name = "bufferoverrun"
22
+ config_overrides = {"modules": {"bufferoverrun": {"api_key": "asdf", "commercial": True}}}
23
+
24
+ async def setup_before_prep(self, module_test):
25
+ # Mock response for commercial API
26
+ module_test.httpx_mock.add_response(
27
+ url="https://bufferover-run-tls.p.rapidapi.com/ipv4/dns?q=.blacklanternsecurity.com",
28
+ match_headers={"x-rapidapi-host": "bufferover-run-tls.p.rapidapi.com", "x-rapidapi-key": "asdf"},
29
+ json={"Results": ["5.6.7.8,blacklanternsecurity.com,*,*,sub.blacklanternsecurity.com"]},
30
+ )
31
+
32
+ def check(self, module_test, events):
33
+ assert any(
34
+ e.data == "sub.blacklanternsecurity.com" for e in events
35
+ ), "Failed to detect subdomain for commercial API"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: bbot
3
- Version: 2.1.0.5078rc0
3
+ Version: 2.1.0.5097rc0
4
4
  Summary: OSINT automation for hackers.
5
5
  Home-page: https://github.com/blacklanternsecurity/bbot
6
6
  License: GPL-3.0
@@ -1,9 +1,9 @@
1
- bbot/__init__.py,sha256=1-RiAOCjZqp4ENXZw4Qq45EKockfj_YlfllL7DjRFX8,130
1
+ bbot/__init__.py,sha256=zEW0INqnPnNqZuqw-WY5CEEWB4EtFYFIRycMv8wpQZ4,130
2
2
  bbot/cli.py,sha256=7S3a4eB-Dl8yodc5WC-927Z30CNlLl9EXimGvIVypJo,10434
3
3
  bbot/core/__init__.py,sha256=l255GJE_DvUnWvrRb0J5lG-iMztJ8zVvoweDOfegGtI,46
4
4
  bbot/core/config/__init__.py,sha256=zYNw2Me6tsEr8hOOkLb4BQ97GB7Kis2k--G81S8vofU,342
5
5
  bbot/core/config/files.py,sha256=pNrcw61UKKZeMt0rp9Ac5mUK7LdIRmcpojMxI-LwjeA,1413
6
- bbot/core/config/logger.py,sha256=C9txmKQtqSFnWU1AapwFS9cZgDBtNZQh4io_13d3AxA,9503
6
+ bbot/core/config/logger.py,sha256=PEiEzZ6CbxtAzWe5MRWKAg2O3YtgM3Y5z7Oum8YPvlA,9441
7
7
  bbot/core/core.py,sha256=twd7-fiaaxzgcWTPwT1zbSWfAa_gHHfl7gAFvLYvFYg,6358
8
8
  bbot/core/engine.py,sha256=wGopKa2GNs61r16Pr_xtp6Si9AT6I-lE83iWhEgtxwA,29290
9
9
  bbot/core/event/__init__.py,sha256=8ut88ZUg0kbtWkOx2j3XzNr_3kTfgoM-3UdiWHFA_ag,56
@@ -16,7 +16,7 @@ bbot/core/helpers/bloom.py,sha256=z7gttz-ugvwj7s2L14feJhEx2rzECdqcB255A0hjvNI,25
16
16
  bbot/core/helpers/cache.py,sha256=1aMr3HVD45cDtHEG5xlznDUCywRgO9oRFidscrs_5sA,1537
17
17
  bbot/core/helpers/command.py,sha256=kORIRaDdbJF7yGOd5BNJH-UDLKi6rHfUoVUaJMF662M,12774
18
18
  bbot/core/helpers/depsinstaller/__init__.py,sha256=2mx1nYylSyvwl0GCM9YDHqrFEt2_5dSWAjP1RmhmbQg,37
19
- bbot/core/helpers/depsinstaller/installer.py,sha256=iL_wUUUU2mEfRSE9Zb2zVwBZvfsLVhuk82lIPLZL6Ls,16450
19
+ bbot/core/helpers/depsinstaller/installer.py,sha256=esbN35gcm_OBr3QEDCpmoJIJ-Z7Enw9GcNbdzz9uY9E,16625
20
20
  bbot/core/helpers/depsinstaller/sudo_askpass.py,sha256=yGa2OQv30RO75QkMuG1iruKqb7amQxRVRRcHmvIeGhk,1276
21
21
  bbot/core/helpers/diff.py,sha256=7waBeHFGnAKn-R-sBd-wc3yjwxT_umwy4YxfE7JFd6w,10599
22
22
  bbot/core/helpers/dns/__init__.py,sha256=2JK8P0BUfPlh4CTuuOWQCOacwL7NEtGFYPJsxbA0Zwo,27
@@ -67,6 +67,7 @@ bbot/modules/bucket_digitalocean.py,sha256=QtTRWAsKgWHaVHSiTfLmesIiVlVNExxPv-NlK
67
67
  bbot/modules/bucket_file_enum.py,sha256=MsjXKNQoHon_M0-IvlsyYY9esKrqBi_a0fSUTJJpM20,2388
68
68
  bbot/modules/bucket_firebase.py,sha256=fburk4quEWbGeixD-PUJh5X06pigHtvbV_mETUX-e4s,1380
69
69
  bbot/modules/bucket_google.py,sha256=IHTfWZEy8wsf8QJ8HXUiVlfo9wxBobrPBVzuERDPcvk,2545
70
+ bbot/modules/bufferoverrun.py,sha256=FcHzj04iSyBqyfUY6lBPLlkD-hT-hBgICKJqlgIGkHY,1865
70
71
  bbot/modules/builtwith.py,sha256=A2Q70GtHtMHQgLYgX-UhUNzBwIZ7n0p5IOEI5lPSBk4,5369
71
72
  bbot/modules/bypass403.py,sha256=Qrszg-vVfjKA0IosM88CekpW6BcazJThpl5moXIdeiQ,6843
72
73
  bbot/modules/c99.py,sha256=cvyLZ7oHk6kxq6UWu0oISbXLKwnZW9yNBmsvT1RTGwI,1388
@@ -104,7 +105,7 @@ bbot/modules/github_org.py,sha256=O1VBn65sYJaPWBDjssyQSnlEh6XQgLEF7gKDzWj64qc,91
104
105
  bbot/modules/github_workflows.py,sha256=GvEVEa2vp5FnpKIthyMIkMmV84Sgh9whxpCcdFY1PB0,9555
105
106
  bbot/modules/gitlab.py,sha256=9oWWpBijeHCjuFBfWW4HvNqt7bvJvrBgBjaaz_UPPnE,5964
106
107
  bbot/modules/google_playstore.py,sha256=N4QjzQag_bgDXfX17rytBiiWA-SQtYI2N0J_ZNEOdv0,3701
107
- bbot/modules/gowitness.py,sha256=akYxtFBQqzyldvUmcvxc4Og7--diZcGqmsdRUoRC7T8,11051
108
+ bbot/modules/gowitness.py,sha256=VYifohEuiIWTejzxM6kxpB8vcWTaiYgwdEeoiLWjZ9g,11071
108
109
  bbot/modules/hackertarget.py,sha256=brp0khcRaSyzwjs6z89WbgULZEE8RmjLM_SxBrj3fDo,969
109
110
  bbot/modules/host_header.py,sha256=JQGqdsuvaCwFaA5_9790T1P2DKJoDUQSPjyHgh6u2tU,7694
110
111
  bbot/modules/httpx.py,sha256=wmgyRyCNg9vw_qO0pVo7I7QzGybDgt9pEdfU3QPgBMA,7588
@@ -187,7 +188,7 @@ bbot/modules/virustotal.py,sha256=GsGaVF05IMgSNOQtUx1B8UXL5JA1Bt8M6ZDWJiiEQ1k,12
187
188
  bbot/modules/wafw00f.py,sha256=I-jEnHWxO4Ga72ukdeBlTGJB9xeucCT3lpDhhFaVyAk,2536
188
189
  bbot/modules/wappalyzer.py,sha256=LL5QeY5DeG7LdaFzZZU-LXaVlJ-sHzOwQLgFtxW3TNg,2176
189
190
  bbot/modules/wayback.py,sha256=9cxd_HfHgLp4AChzA8C0Zjd6DIJ7c3NsJ02W2oLIXuU,3257
190
- bbot/modules/wpscan.py,sha256=jbv1o8FHTIAEhctgIGW6-s3VEocXQhzgSU57Wdtm2Nc,11345
191
+ bbot/modules/wpscan.py,sha256=_mE1OAU7sZUW5HbJ5GepFsljzJ89Z0zmam4jZb69a40,11582
191
192
  bbot/modules/zoomeye.py,sha256=3zZjafgLUFMzkqRSAi6CYVEsjGTN-BWzvbw8gvAxlCQ,2658
192
193
  bbot/presets/baddns-thorough.yml,sha256=FXiNnsf3IIms3UJtS2CwLk82Yp0IXm1OvRM61-CHrno,195
193
194
  bbot/presets/cloud-enum.yml,sha256=U1IuN_Vx4zFSvobQenXwSeEqFxRX28beS1Aek3hNUBg,121
@@ -219,7 +220,7 @@ bbot/scanner/target.py,sha256=X25gpgRv5HmqQjGADiSe6b8744yOkRhAGAvKKYbXnSI,19886
219
220
  bbot/scripts/docs.py,sha256=kg2CzovmUVGJx9hBZjAjUdE1hXeIwC7Ry3CyrnE8GL8,10782
220
221
  bbot/test/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
221
222
  bbot/test/bbot_fixtures.py,sha256=J1_MfpCMXftfGHZc-dgn42ODpTmSJidoBibOltfthac,9862
222
- bbot/test/conftest.py,sha256=QBLUuJSsjYpy8mX1iQTZh9xYMJju3EORUwOEwA-nlH0,10350
223
+ bbot/test/conftest.py,sha256=xmR5vLNwXvzmARP1ew8sF4XBDjAEs2M0EgmN5X6GMoA,10891
223
224
  bbot/test/coverage.cfg,sha256=ko9RacAYsJxWJCL8aEuNtkAOtP9lexYiDbeFWe8Tp8Y,31
224
225
  bbot/test/owasp_mastg.apk,sha256=Hai_V9JmEJ-aB8Ab9xEaGXXOAfGQudkUvNOuPb75byE,66651
225
226
  bbot/test/run_tests.sh,sha256=0oprBl970NAqXS4YQa8nRUtKljPeS_WNSvd-QmO5FNY,945
@@ -272,6 +273,7 @@ bbot/test/test_step_2/module_tests/test_module_bucket_digitalocean.py,sha256=EFz
272
273
  bbot/test/test_step_2/module_tests/test_module_bucket_file_enum.py,sha256=aOgtrsb32nnTZBvX1tf6Fvfjc-GvuxA8Tu7LGq2oDJo,2301
273
274
  bbot/test/test_step_2/module_tests/test_module_bucket_firebase.py,sha256=gM3h1staY3tEHF2l9cYgRhaVwEg7ykfo4E0mvhqTA0g,506
274
275
  bbot/test/test_step_2/module_tests/test_module_bucket_google.py,sha256=wXROpF9TSQVOa8cGTOo8k9uDEj7H5pNAcppj4WR3qnY,1312
276
+ bbot/test/test_step_2/module_tests/test_module_bufferoverrun.py,sha256=os7A6vdwlAAXvprwBdNBD05kylva7ZVxyhchkhQiSs4,1580
275
277
  bbot/test/test_step_2/module_tests/test_module_builtwith.py,sha256=c_Ta6OXWYdUdcwuE-AbaT-tzj8SUuglMecQX6mDavuE,5051
276
278
  bbot/test/test_step_2/module_tests/test_module_bypass403.py,sha256=-MV06l6Q7d_sM0L2OIw1ReXJc2dj30xC3suOl2HhZTY,3551
277
279
  bbot/test/test_step_2/module_tests/test_module_c99.py,sha256=-xyL1y3eX_rGuBR-U0N1HDZuAw_A_UysN5PupWe0iDI,7427
@@ -393,8 +395,8 @@ bbot/wordlists/raft-small-extensions-lowercase_CLEANED.txt,sha256=ruUQwVfia1_m2u
393
395
  bbot/wordlists/top_open_ports_nmap.txt,sha256=LmdFYkfapSxn1pVuQC2LkOIY2hMLgG-Xts7DVtYzweM,42727
394
396
  bbot/wordlists/valid_url_schemes.txt,sha256=VciB-ww0y-O8Ii1wpTR6rJzGDiC2r-dhVsIJApS1ZYU,3309
395
397
  bbot/wordlists/wordninja_dns.txt.gz,sha256=DYHvvfW0TvzrVwyprqODAk4tGOxv5ezNmCPSdPuDUnQ,570241
396
- bbot-2.1.0.5078rc0.dist-info/LICENSE,sha256=GzeCzK17hhQQDNow0_r0L8OfLpeTKQjFQwBQU7ZUymg,32473
397
- bbot-2.1.0.5078rc0.dist-info/METADATA,sha256=nLVxULcttN36BlCTnbEKG0uMP58lHPhzHifkypvotSw,16930
398
- bbot-2.1.0.5078rc0.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
399
- bbot-2.1.0.5078rc0.dist-info/entry_points.txt,sha256=cWjvcU_lLrzzJgjcjF7yeGuRA_eDS8pQ-kmPUAyOBfo,38
400
- bbot-2.1.0.5078rc0.dist-info/RECORD,,
398
+ bbot-2.1.0.5097rc0.dist-info/LICENSE,sha256=GzeCzK17hhQQDNow0_r0L8OfLpeTKQjFQwBQU7ZUymg,32473
399
+ bbot-2.1.0.5097rc0.dist-info/METADATA,sha256=gEn0ACl3ZiIASOavUl8eYJRslp3rL7aVAbvzw-18tbg,16930
400
+ bbot-2.1.0.5097rc0.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
401
+ bbot-2.1.0.5097rc0.dist-info/entry_points.txt,sha256=cWjvcU_lLrzzJgjcjF7yeGuRA_eDS8pQ-kmPUAyOBfo,38
402
+ bbot-2.1.0.5097rc0.dist-info/RECORD,,