
ハッカーのための再帰的インターネットスキャナー。🧡
[](https://github.com/blacklanternsecurity/bbot)
[](https://www.python.org) [](https://github.com/blacklanternsecurity/bbot/blob/dev/LICENSE) [](https://pepy.tech/project/bbot) [](https://github.com/astral-sh/ruff) [](https://github.com/blacklanternsecurity/bbot/actions?query=workflow%3A"tests") [](https://codecov.io/gh/blacklanternsecurity/bbot) [](https://discord.com/invite/PZqkgxu5SA)
### **BEE·bot** は [Spiderfoot](https://github.com/smicallef/spiderfoot) に触発された多目的スキャナーで、あなたの **Recon**、**バグバウンティ**、**ASM** を自動化するために作られました!
https://github.com/blacklanternsecurity/bbot/assets/20261699/e539e89b-92ea-46fa-b893-9cde94eebf81
_リアルタイムのBBOTスキャン - [VivaGraphJS](https://github.com/blacklanternsecurity/bbot-vivagraphjs)による可視化_
## インストール
```bash
# stable version
pipx install bbot
# bleeding edge (dev branch)
pipx install --pip-args '\--pre' bbot
```
_[Docker](https://hub.docker.com/r/blacklanternsecurity/bbot)を含むその他のインストール方法については、[Getting Started](https://www.blacklanternsecurity.com/bbot/Stable/)を参照してください_
> **2.xからアップグレードしますか?** BBOT 3.0には、CLI、プリセット、モジュール、イベント、およびPython APIに対する破壊的な変更が含まれています。アップグレードする前に、[2.x → 3.0 移行ガイド](https://www.blacklanternsecurity.com/bbot/Stable/migration/3.0_breaking_changes/)([ソース](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/migration/3.0_breaking_changes.md))を参照してください。
> **速度向上のヒント:** BBOTのDNSリゾルバー([blastdns](https://github.com/blacklanternsecurity/blastdns))は、`/etc/resolv.conf`内のリゾルバーごとに複数のスレッドを起動します。フィルタリングされていないリゾルバーを追加すると、スキャンが劇的に高速化されます。詳細は、[サンプル resolv.conf](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/data/resolv-sample.conf)と[ヒントとコツ](https://www.blacklanternsecurity.com/bbot/Stable/scanning/tips_and_tricks/#speed-up-scans-with-more-dns-resolvers)を参照してください。
## コマンド例
### 1) サブドメイン検出
パッシブAPIソースと、ターゲット固有のサブドメインミューテーションを用いた再帰的DNSブルートフォース。
```bash
# find subdomains of evilcorp.com
bbot -t evilcorp.com -p subdomain-enum
# passive sources only
bbot -t evilcorp.com -p subdomain-enum -rf passive
```
<!-- BBOT SUBDOMAIN-ENUM PRESET EXPANDABLE -->
<details>
<summary><b><code>subdomain-enum.yml</code></b></summary>
```yaml
description: Enumerate subdomains via APIs, brute-force
flags:
# enable every module with the subdomain-enum flag
- subdomain-enum
output_modules:
# output unique subdomains to TXT file
- subdomains
config:
dns:
threads: 25
brute_threads: 1000
# put your API keys here
# modules:
# github:
# api_key: ""
# chaos:
# api_key: ""
# securitytrails:
# api_key: ""
```
</details>
<!-- END BBOT SUBDOMAIN-ENUM PRESET EXPANDABLE -->
BBOTは他のツールよりも常に20〜50%多くのサブドメインを発見します。ドメインが大きいほど、その差は顕著になります。なぜそれが可能なのかについては、[仕組み](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works/)を参照してください。

### 2) Webスパイダー
```bash
# crawl evilcorp.com, extracting emails and other goodies
bbot -t evilcorp.com -p spider
```
<!-- BBOT SPIDER PRESET EXPANDABLE -->
<details>
<summary><b><code>spider.yml</code></b></summary>
```yaml
description: Recursive web spider
modules:
- http
blacklist:
# Prevent spider from invalidating sessions by logging out
- "RE:/.*(sign|log)[_-]?out"
config:
web:
# how many links to follow in a row
spider_distance: 2
# don't follow links whose directory depth is higher than 4
spider_depth: 4
# maximum number of links to follow per page
spider_links_per_page: 25
```
</details>
<!-- END BBOT SPIDER PRESET EXPANDABLE -->
### 3) メール収集
```bash
# quick email enum with free APIs + scraping
bbot -t evilcorp.com -p email-enum
# pair with subdomain enum + web spider for maximum yield
bbot -t evilcorp.com -p email-enum subdomain-enum spider
```
<!-- BBOT EMAIL-ENUM PRESET EXPANDABLE -->
<details>
<summary><b><code>email-enum.yml</code></b></summary>
```yaml
description: Enumerate email addresses from APIs, web crawling, etc.
flags:
- email-enum
output_modules:
- emails
```
</details>
<!-- END BBOT EMAIL-ENUM PRESET EXPANDABLE -->
### 4) Webスキャナー
```bash
# run a light web scan against www.evilcorp.com
bbot -t www.evilcorp.com -p web
# run a heavy web scan against www.evilcorp.com
bbot -t www.evilcorp.com -p web-heavy
```
<!-- BBOT WEB PRESET EXPANDABLE -->
<details>
<summary><b><code>web.yml</code></b></summary>
```yaml
description: Quick web scan
include:
- iis-shortnames
flags:
- web
```
</details>
<!-- END BBOT WEB PRESET EXPANDABLE -->
<!-- BBOT WEB-HEAVY PRESET EXPANDABLE -->
<details>
<summary><b><code>web-heavy.yml</code></b></summary>
```yaml
description: Aggressive web scan
include:
# include the web preset
- web
flags:
- web-heavy
```
</details>
<!-- END BBOT WEB-HEAVY PRESET EXPANDABLE -->
### 5) エブリシング・エブリウェア・オール・アット・ワンス
```bash
# everything everywhere all at once
bbot -t evilcorp.com -p kitchen-sink
# roughly equivalent to:
bbot -t evilcorp.com -p subdomain-enum cloud-enum code-enum email-enum spider web paramminer webbrute web-screenshots
```
<!-- BBOT KITCHEN-SINK PRESET EXPANDABLE -->
<details>
<summary><b><code>kitchen-sink.yml</code></b></summary>
```yaml
description: Everything everywhere all at once
include:
- subdomain-enum
- cloud-enum
- code-enum
- email-enum
- spider
- web
- paramminer
- webbrute
- web-screenshots
- baddns-heavy
config:
modules:
dnsbrute:
recursive_mutations: true
dnscommonsrv:
recursive_mutations: true
webbrute:
avoid_wafs: False
wayback:
urls: True
parameters: True
archive: True
```
</details>
<!-- END BBOT KITCHEN-SINK PRESET EXPANDABLE -->
## 仕組み
下のグラフをクリックして、BBOTの[内部構造](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works/)を探索してください。
[](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works/)
## 出力モジュール
- [Neo4j](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#neo4j)
- [Teams](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#teams)
- [Discord](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#discord)
- [Slack](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#slack)
- [Postgres](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#postgres)
- [MySQL](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#mysql)
- [SQLite](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#sqlite)
- [Splunk](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#splunk)
- [Elasticsearch](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#elasticsearch)
- [CSV](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#csv)
- [JSON](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#json)
- [HTTP](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#http)
- [Websocket](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md#websocket)
...および[その他](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md)!
## PythonライブラリとしてのBBOT
#### 同期
```python
from bbot.scanner import Scanner
if __name__ == "__main__":
scan = Scanner("evilcorp.com", presets=["subdomain-enum"])
for event in scan.start():
print(event)
```
#### 非同期
```python
from bbot.scanner import Scanner
async def main():
scan = Scanner("evilcorp.com", presets=["subdomain-enum"])
async for event in scan.async_start():
print(event.json())
if __name__ == "__main__":
import asyncio
asyncio.run(main())
```
<details>
<summary><b>参照: この極悪非道なDiscordボット</b></summary>
`/scan` コマンドに応答する[BBOT Discordボット](https://www.blacklanternsecurity.com/bbot/Stable/dev/#discord-bot-example)。Discordサーバーにいながら、手軽にインターネットをスキャンできます!

</details>
## 機能概要
- 複数ターゲットのサポート
- Webスクリーンショット
- 攻撃的なWebモジュール群
- NLPを活用したサブドメインミューテーション
- Neo4jへのネイティブ出力(およびその他)
- Ansibleによる依存関係の自動インストール
- カスタムYARAルールによる攻撃対象領域全体の検索
- Python API + 開発者向けドキュメント
## ターゲット
BBOTは`-t`で無制限にターゲットを受け付けます。ターゲットはコマンドラインで直接指定することも、ファイルで指定することもできます(またはその両方!):
```bash
bbot -t evilcorp.com evilcorp.org 1.2.3.0/24 -p subdomain-enum
```
ターゲットには以下のいずれかを指定できます:
- DNS名 (`evilcorp.com`)
- IPアドレス (`1.2.3.4`)
- IPレンジ (`1.2.3.0/24`)
- オープンTCPポート (`192.168.0.1:80`)
- URL (`https://www.evilcorp.com`)
- メールアドレス (`[email protected]`)
- 組織 (`ORG:evilcorp`)
- ユーザー名 (`USER:bobsmith`)
- ファイルシステム (`FILESYSTEM:/tmp/asdf`)
- モバイルアプリ (`MOBILE_APP:https://play.google.com/store/apps/details?id=com.evilcorp.app`)
詳細については、[ターゲット](https://www.blacklanternsecurity.com/bbot/Stable/scanning/#targets-t)を参照してください。BBOTがスコープをどのように処理するかについては、[スコープ](https://www.blacklanternsecurity.com/bbot/Stable/scanning/#scope)を参照してください。
## APIキー
AmassやSubfinderと同様に、BBOTはSecurityTrailsなどの様々なサードパーティサービス向けのAPIキーをサポートしています。
標準的な方法は、APIキーを**`~/.config/bbot/secrets.yml`**に入力することです。複数のAPIキーを指定できることに注意してください:
```yaml
modules:
shodan_dns:
api_key: 4f41243847da693a4f356c0486114bc6
c99:
# multiple API keys
api_key:
- 21a270d5f59c9b05813a72bb41707266
- ea8f243d9885cf8ce9876a580224fd3c
- 5bc6ed268ab6488270e496d3183a1a27
virustotal:
api_key: dd5f0eee2e4a99b71a939bded450b246
securitytrails:
api_key: d9a05c3fd9a514497713c54b4455d0b0
```
必要であれば、コマンドラインで指定することもできます:
```bash
bbot -c modules.virustotal.api_key=dd5f0eee2e4a99b71a939bded450b246
```
詳細は[設定](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration/)を参照してください。
## モジュール、フラグなどの完全なリスト
- [モジュール](https://www.blacklanternsecurity.com/bbot/Stable/modules/list_of_modules/)の完全なリスト。
- [フラグ](https://www.blacklanternsecurity.com/bbot/Stable/scanning/#list-of-flags)の完全なリスト。
- [プリセット](https://www.blacklanternsecurity.com/bbot/Stable/scanning/presets_list/)の完全なリスト。
- [グローバル設定オプション](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration/#global-config-options)の完全なリスト。
- [モジュール設定オプション](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration/#module-config-options)の完全なリスト。
## ドキュメント
<!-- BBOT DOCS TOC -->
- **ユーザーマニュアル**
- **基本**
- [はじめに](https://www.blacklanternsecurity.com/bbot/Stable/)
- [仕組み](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works)
- [他のツールとの比較](https://www.blacklanternsecurity.com/bbot/Stable/comparison)
- **スキャン**
- [スキャン概要](https://www.blacklanternsecurity.com/bbot/Stable/scanning/)
- **プリセット**
- [概要](https://www.blacklanternsecurity.com/bbot/Stable/scanning/presets)
- [プリセット一覧](https://www.blacklanternsecurity.com/bbot/Stable/scanning/presets_list)
- [イベント](https://www.blacklanternsecurity.com/bbot/Stable/scanning/events)
- [出力](https://www.blacklanternsecurity.com/bbot/Stable/scanning/output)
- [ヒントとコツ](https://www.blacklanternsecurity.com/bbot/Stable/scanning/tips_and_tricks)
- [高度な使用方法](https://www.blacklanternsecurity.com/bbot/Stable/scanning/advanced)
- [設定](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration)
- [スキャンの健全性](https://www.blacklanternsecurity.com/bbot/Stable/scanning/scan_sanity)
- **モジュール**
- [モジュール一覧](https://www.blacklanternsecurity.com/bbot/Stable/modules/list_of_modules)
- [内部モジュール](https://www.blacklanternsecurity.com/bbot/Stable/modules/internal_modules)
- [Nuclei](https://www.blacklanternsecurity.com/bbot/Stable/modules/nuclei)
- [Wayback](https://www.blacklanternsecurity.com/bbot/Stable/modules/wayback)
- [カスタムYARAルール](https://www.blacklanternsecurity.com/bbot/Stable/modules/custom_yara_rules)
- [Lightfuzz](https://www.blacklanternsecurity.com/bbot/Stable/modules/lightfuzz)
- [Webbrute](https://www.blacklanternsecurity.com/bbot/Stable/modules/webbrute)
- **移行**
- [2.x → 3.0 破壊的変更](https://www.blacklanternsecurity.com/bbot/Stable/migration/3.0_breaking_changes)
- **その他**
- [貢献](https://www.blacklanternsecurity.com/bbot/Stable/contribution)
- [リリース履歴](https://www.blacklanternsecurity.com/bbot/Stable/release_history)
- [トラブルシューティング](https://www.blacklanternsecurity.com/bbot/Stable/troubleshooting)
- **開発者マニュアル**
- [開発概要](https://www.blacklanternsecurity.com/bbot/Stable/dev/)
- [開発環境のセットアップ](https://www.blacklanternsecurity.com/bbot/Stable/dev/dev_environment)
- [コア依存関係](https://www.blacklanternsecurity.com/bbot/Stable/dev/core_dependencies)
- [BBOT内部アーキテクチャ](https://www.blacklanternsecurity.com/bbot/Stable/dev/architecture)
- [BBOTモジュールの書き方](https://www.blacklanternsecurity.com/bbot/Stable/dev/module_howto)
- [プリセットの検証と検査](https://www.blacklanternsecurity.com/bbot/Stable/dev/preset_validation)
- [ユニットテスト](https://www.blacklanternsecurity.com/bbot/Stable/dev/tests)
- [Discordボットの例](https://www.blacklanternsecurity.com/bbot/Stable/dev/discord_bot)
- **コードリファレンス**
- [Scanner](https://www.blacklanternsecurity.com/bbot/Stable/dev/scanner)
- [Presets](https://www.blacklanternsecurity.com/bbot/Stable/dev/presets)
- [Event](https://www.blacklanternsecurity.com/bbot/Stable/dev/event)
- [Target](https://www.blacklanternsecurity.com/bbot/Stable/dev/target)
- [BaseModule](https://www.blacklanternsecurity.com/bbot/Stable/dev/basemodule)
- [BBOTCore](https://www.blacklanternsecurity.com/bbot/Stable/dev/core)
- **ヘルパー**
- [概要](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/)
- [Command](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/command)
- [DNS](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/dns)
- [Interactsh](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/interactsh)
- [その他](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/misc)
- [Web](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/web)
- [ワードクラウド](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/wordcloud)
<!-- END BBOT DOCS TOC -->
## 貢献
最高のBBOTモジュールのいくつかはコミュニティによって書かれました。BBOTは絶えず改良されており、日々より強力になっています!
私たちは貢献を歓迎します。コードだけでなく、アイデアも歓迎します! 新機能のアイデアがあれば、[ディスカッション](https://github.com/blacklanternsecurity/bbot/discussions)でお知らせください。実際に手を動かしたい方は、[貢献](https://www.blacklanternsecurity.com/bbot/Stable/contribution/)を参照してください。そこには、セットアップ手順とBBOTモジュールの書き方に関する簡単なチュートリアルがあります。また、充実した[開発者向けドキュメント](https://www.blacklanternsecurity.com/bbot/Stable/dev/)もあります。
BBOTに貢献してくれた素晴らしい人々に感謝します! :heart:
<p align="center">
<a href="https://github.com/blacklanternsecurity/bbot/graphs/contributors">
<img src="https://contrib.rocks/image?repo=blacklanternsecurity/bbot&max=500">
</a>
</p>
特に感謝します:
- BBOTを生み出した @TheTechromancer
- [badsecrets](https://github.com/blacklanternsecurity/badsecrets)や[baddns](https://github.com/blacklanternsecurity/baddns)を含む、BBOTのWebハッキング機能に多大な貢献をした @liquidsec
- Spiderfootを生み出した Steve Micallef (@smicallef)
- Neo4jとAnsibleの専門知識を提供してくれた @kerrymilan
- 素晴らしいコード収集モジュール群を生み出した @domwhewell-sage
- 容赦ないテストをしてくれた @aconite33 と @amiremami
- bbot Pypiリポジトリの所有権を譲渡してくれた Aleksei Kornev (@alekseiko) <3