# [CTI] Shodan ## Introduction Shodan est un moteur de recherche permettant de trouver des machines exposées sur Internet avec des filtres. [![image.png](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/scaled-1680-/mDpimage.png)](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/mDpimage.png) ## Manuel Vous pouvez accéder à l'interface de Shodan : - [https://www.shodan.io/dashboard](https://www.shodan.io/dashboard) #### Usage ``` : ``` #### Filtres Voici quelques filtres courants :
**Filtres**
ip
port
org
country
city
product
version
os
Sinon voici la liste complète des filtres : - [https://www.shodan.io/search/filters](https://www.shodan.io/search/filters) #### Exemples - Chercher des informations sur une IP spécifique : ``` ip:8.8.8.8 ``` Chercher toutes les machines françaises de l'hébergeur Scaleway : ``` country:FR org:scaleway ``` Chercher toutes les machines Ubuntu ayant un service SSH : ``` os:ubuntu port:22 ``` Vous pouvez retrouver plus d'exemples : - [https://www.shodan.io/search/examples](https://www.shodan.io/search/examples) - [https://github.com/BushidoUK/OSINT-SearchOperators/blob/main/ShodanQueriesAppliances.csv](https://github.com/BushidoUK/OSINT-SearchOperators/blob/main/ShodanQueriesAppliances.csv) #### Analyse Vous pouvez analyser les résultats rapidement grâce à la section **View Report** : [![shodan-1.png](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/scaled-1680-/shodan-1.png)](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/shodan-1.png) On voir les ports les plus exposés, les services les plus utilisés, les hébergeurs les plus utilisés pour ces machines etc : [![image.png](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/scaled-1680-/YsJimage.png)](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/YsJimage.png) Vous pouvez aussi consulter les statistiques pour cette query dans le temps grâce à l'onglet **Historical Trends** : [![shodan-4.png](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/scaled-1680-/shodan-4.png)](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/shodan-4.png) [![shodan-3.png](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/scaled-1680-/shodan-3.png)](https://wiki.neopipe.fr/uploads/images/gallery/2024-10/shodan-3.png) #### Tracking de serveurs C2 Certains filtres ont été mis en place pour chercher des serveurs de commande et contrôle (C2) : - [https://github.com/BushidoUK/OSINT-SearchOperators/blob/main/ShodanAdversaryInfa.md](https://github.com/BushidoUK/OSINT-SearchOperators/blob/main/ShodanAdversaryInfa.md)
**Serveurs C2** **Filtres**
Metasploit http.favicon.hash:-12788697 ssl:MetasploitSelfSignedCA http.html:"msf4"
Cobalt Strike ssl.jarm:07d14d16d21d21d07c42d41d00041d24a458a375eef0c576d23a7bab9a9fb1 port:443 ssl.cert.serial:146473198 product:"Cobalt Strike Beacon" http.html:"cs4.4"
Brute Ratel http.html\_hash:-1957161625 product:"Brute Ratel C4"
Vous pouvez aussi retrouver des **JARM** de C2 qui sont des empreintes des certificats par défaut : - [https://github.com/BushidoUK/OSINT-SearchOperators/blob/main/ShodanAdversaryInfa.md](https://github.com/BushidoUK/OSINT-SearchOperators/blob/main/ShodanAdversaryInfa.md) #### API Pour utiliser l'API, il vous faut payer (une version premium à 69$ payable en une seule fois vous autorise à 100 queries par mois). Une fois votré clé API récupérée, vous pouvez initialiser shodan : ```bash shodan init ``` Pour faire une recherche : ```bash shodan search "" ``` Pour trouver des informations sur une IP : ```bash shodan host ``` Pour télécharger les résultats d'une recherche au format **JSON** : ```bash shodan download .json "" ``` Pour consulter les résultats : ```bash shodan parse .json ``` Ou alors : ```bash cat .json | jq ```