
Le scanner internet récursif pour les hackers. 🧡
[](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** est un scanner polyvalent inspiré par [Spiderfoot](https://github.com/smicallef/spiderfoot), conçu pour automatiser vos missions de **Recon**, de **Bug Bounty** et votre **ASM** !
https://github.com/blacklanternsecurity/bbot/assets/20261699/e539e89b-92ea-46fa-b893-9cde94eebf81
_Un scan BBOT en temps réel - visualisation avec [VivaGraphJS](https://github.com/blacklanternsecurity/bbot-vivagraphjs)_
## Installation
```bash
# stable version
pipx install bbot
# bleeding edge (dev branch)
pipx install --pip-args '\--pre' bbot
```
_Pour plus de méthodes d'installation, notamment [Docker](https://hub.docker.com/r/blacklanternsecurity/bbot), consultez [Getting Started](https://www.blacklanternsecurity.com/bbot/Stable/)_
> **Vous migrez depuis la 2.x ?** BBOT 3.0 contient des changements majeurs dans la CLI, les presets, les modules, les événements et l'API Python. Consultez le [guide de migration 2.x → 3.0](https://www.blacklanternsecurity.com/bbot/Stable/migration/3.0_breaking_changes/) ([source](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/migration/3.0_breaking_changes.md)) avant de mettre à niveau.
> **Conseil de rapidité :** le résolveur DNS de BBOT ([blastdns](https://github.com/blacklanternsecurity/blastdns)) lance plusieurs threads par résolveur dans `/etc/resolv.conf`. Ajouter davantage de résolveurs non filtrés accélère considérablement les scans. Voir l'[exemple de resolv.conf](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/data/resolv-sample.conf) et [Tips and Tricks](https://www.blacklanternsecurity.com/bbot/Stable/scanning/tips_and_tricks/#speed-up-scans-with-more-dns-resolvers) pour plus de détails.
## Exemples de commandes
### 1) Découverte de sous-domaines
Sources API passives ainsi qu'un brute-force DNS récursif avec des mutations de sous-domaines spécifiques à la cible.
```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 trouve systématiquement 20 à 50 % de sous-domaines en plus que les autres outils. Plus le domaine est gros, plus l'écart est grand. Pour comprendre comment c'est possible, voir [How It Works](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works/).

### 2) Spider 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) Collecteur d'e-mails
```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) Scanner 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) Tout, partout, à la fois
```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 -->
## Comment ça marche
Cliquez sur le graphique ci-dessous pour explorer les [rouages internes](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works/) de BBOT.
[](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works/)
## Modules de sortie
- [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)
...et [plus encore](https://github.com/blacklanternsecurity/bbot/blob/stable/docs/scanning/output.md) !
## BBOT comme bibliothèque Python
#### Synchrone
```python
from bbot.scanner import Scanner
if __name__ == "__main__":
scan = Scanner("evilcorp.com", presets=["subdomain-enum"])
for event in scan.start():
print(event)
```
#### Asynchrone
```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>VOIR : Ce bot Discord peu recommandable</b></summary>
Un [bot Discord BBOT](https://www.blacklanternsecurity.com/bbot/Stable/dev/#discord-bot-example) qui répond à la commande `/scan`. Scannez Internet depuis le confort de votre serveur Discord !

</details>
## Aperçu des fonctionnalités
- Prise en charge de cibles multiples
- Captures d'écran web
- Suite de modules web offensifs
- Mutations de sous-domaines propulsées par NLP
- Sortie native vers Neo4j (et plus)
- Installation automatique des dépendances avec Ansible
- Recherche sur toute la surface d'attaque avec des règles YARA personnalisées
- API Python + documentation développeur
## Cibles
BBOT accepte un nombre illimité de cibles via `-t`. Vous pouvez spécifier les cibles directement en ligne de commande ou dans des fichiers (ou les deux !) :
```bash
bbot -t evilcorp.com evilcorp.org 1.2.3.0/24 -p subdomain-enum
```
Les cibles peuvent être n'importe lesquelles des suivantes :
- Nom DNS (`evilcorp.com`)
- Adresse IP (`1.2.3.4`)
- Plage IP (`1.2.3.0/24`)
- Port TCP ouvert (`192.168.0.1:80`)
- URL (`https://www.evilcorp.com`)
- Adresse e-mail (`[email protected]`)
- Organisation (`ORG:evilcorp`)
- Nom d'utilisateur (`USER:bobsmith`)
- Système de fichiers (`FILESYSTEM:/tmp/asdf`)
- Application mobile (`MOBILE_APP:https://play.google.com/store/apps/details?id=com.evilcorp.app`)
Pour plus d'informations, voir [Targets](https://www.blacklanternsecurity.com/bbot/Stable/scanning/#targets-t). Pour apprendre comment BBOT gère le périmètre, voir [Scope](https://www.blacklanternsecurity.com/bbot/Stable/scanning/#scope).
## Clés API
À l'instar d'Amass ou de Subfinder, BBOT prend en charge les clés API pour divers services tiers tels que SecurityTrails, etc.
La méthode standard consiste à saisir vos clés API dans **`~/.config/bbot/secrets.yml`**. Notez que plusieurs clés API sont autorisées :
```yaml
modules:
shodan_dns:
api_key: 4f41243847da693a4f356c0486114bc6
c99:
# multiple API keys
api_key:
- 21a270d5f59c9b05813a72bb41707266
- ea8f243d9885cf8ce9876a580224fd3c
- 5bc6ed268ab6488270e496d3183a1a27
virustotal:
api_key: dd5f0eee2e4a99b71a939bded450b246
securitytrails:
api_key: d9a05c3fd9a514497713c54b4455d0b0
```
Si vous le souhaitez, vous pouvez également les spécifier en ligne de commande :
```bash
bbot -c modules.virustotal.api_key=dd5f0eee2e4a99b71a939bded450b246
```
Pour plus de détails, voir [Configuration](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration/).
## Listes complètes des modules, flags, etc.
- Liste complète des [Modules](https://www.blacklanternsecurity.com/bbot/Stable/modules/list_of_modules/).
- Liste complète des [Flags](https://www.blacklanternsecurity.com/bbot/Stable/scanning/#list-of-flags).
- Liste complète des [Presets](https://www.blacklanternsecurity.com/bbot/Stable/scanning/presets_list/).
- Liste complète des [Options de configuration globales](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration/#global-config-options).
- Liste complète des [Options de configuration des modules](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration/#module-config-options).
## Documentation
<!-- BBOT DOCS TOC -->
- **Manuel de l'utilisateur**
- **Bases**
- [Getting Started](https://www.blacklanternsecurity.com/bbot/Stable/)
- [How it Works](https://www.blacklanternsecurity.com/bbot/Stable/how_it_works)
- [Comparison to Other Tools](https://www.blacklanternsecurity.com/bbot/Stable/comparison)
- **Scan**
- [Scanning Overview](https://www.blacklanternsecurity.com/bbot/Stable/scanning/)
- **Presets**
- [Overview](https://www.blacklanternsecurity.com/bbot/Stable/scanning/presets)
- [List of Presets](https://www.blacklanternsecurity.com/bbot/Stable/scanning/presets_list)
- [Events](https://www.blacklanternsecurity.com/bbot/Stable/scanning/events)
- [Output](https://www.blacklanternsecurity.com/bbot/Stable/scanning/output)
- [Tips and Tricks](https://www.blacklanternsecurity.com/bbot/Stable/scanning/tips_and_tricks)
- [Advanced Usage](https://www.blacklanternsecurity.com/bbot/Stable/scanning/advanced)
- [Configuration](https://www.blacklanternsecurity.com/bbot/Stable/scanning/configuration)
- [Scan Sanity](https://www.blacklanternsecurity.com/bbot/Stable/scanning/scan_sanity)
- **Modules**
- [List of Modules](https://www.blacklanternsecurity.com/bbot/Stable/modules/list_of_modules)
- [Internal 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)
- [Custom YARA Rules](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)
- **Migration**
- [2.x → 3.0 Breaking Changes](https://www.blacklanternsecurity.com/bbot/Stable/migration/3.0_breaking_changes)
- **Divers**
- [Contribution](https://www.blacklanternsecurity.com/bbot/Stable/contribution)
- [Release History](https://www.blacklanternsecurity.com/bbot/Stable/release_history)
- [Troubleshooting](https://www.blacklanternsecurity.com/bbot/Stable/troubleshooting)
- **Manuel du développeur**
- [Development Overview](https://www.blacklanternsecurity.com/bbot/Stable/dev/)
- [Setting Up a Dev Environment](https://www.blacklanternsecurity.com/bbot/Stable/dev/dev_environment)
- [Core Dependencies](https://www.blacklanternsecurity.com/bbot/Stable/dev/core_dependencies)
- [BBOT Internal Architecture](https://www.blacklanternsecurity.com/bbot/Stable/dev/architecture)
- [How to Write a BBOT Module](https://www.blacklanternsecurity.com/bbot/Stable/dev/module_howto)
- [Validating & Inspecting Presets](https://www.blacklanternsecurity.com/bbot/Stable/dev/preset_validation)
- [Unit Tests](https://www.blacklanternsecurity.com/bbot/Stable/dev/tests)
- [Discord Bot Example](https://www.blacklanternsecurity.com/bbot/Stable/dev/discord_bot)
- **Référence du code**
- [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)
- **Helpers**
- [Overview](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)
- [Miscellaneous](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/misc)
- [Web](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/web)
- [Word Cloud](https://www.blacklanternsecurity.com/bbot/Stable/dev/helpers/wordcloud)
<!-- END BBOT DOCS TOC -->
## Contribution
Certains des meilleurs modules BBOT ont été écrits par la communauté. BBOT est constamment amélioré ; chaque jour, il devient plus puissant !
Nous accueillons volontiers les contributions. Pas seulement le code, mais aussi les idées ! Si vous avez une idée de nouvelle fonctionnalité, faites-nous-en part dans [Discussions](https://github.com/blacklanternsecurity/bbot/discussions). Si vous voulez vous retrousser les manches, voir [Contribution](https://www.blacklanternsecurity.com/bbot/Stable/contribution/). Vous y trouverez les instructions d'installation et un tutoriel simple sur la façon d'écrire un module BBOT. Nous disposons également d'une vaste [Documentation développeur](https://www.blacklanternsecurity.com/bbot/Stable/dev/).
Merci à ces personnes formidables pour leur contribution à 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>
Remerciements particuliers à :
- @TheTechromancer pour avoir créé BBOT
- @liquidsec pour son travail considérable sur les fonctionnalités de hacking web de BBOT, notamment [badsecrets](https://github.com/blacklanternsecurity/badsecrets) et [baddns](https://github.com/blacklanternsecurity/baddns)
- Steve Micallef (@smicallef) pour avoir créé Spiderfoot
- @kerrymilan pour son expertise Neo4j et Ansible
- @domwhewell-sage pour sa famille de modules de pillage de code redoutables
- @aconite33 et @amiremami pour leurs tests impitoyables
- Aleksei Kornev (@alekseiko) pour nous avoir accordé la propriété du dépôt PyPI bbot <3