PacketSpy es una poderosa herramienta de rastreo de paquetes de red diseñada para capturar y analizar el tráfico de red. Proporciona un conjunto completo de funciones para inspeccionar solicitudes y respuestas HTTP, ver datos de carga útil sin procesar y recopilar información sobre dispositivos de red. Con PacketSpy, puedes obtener información valiosa sobre los patrones de comunicación de tu red y resolver problemas de red de manera efectiva.
Tabla de Contenido
Características
- Captura de paquetes: captura y analiza paquetes de red en tiempo real.
- Inspección HTTP: inspecciona solicitudes y respuestas HTTP para un análisis detallado.
- Visualización de carga útil sin procesar: ve datos de carga útil sin procesar para una investigación más profunda.
- Información del dispositivo: recopila información sobre dispositivos de red, incluidas direcciones IP y direcciones MAC.
Instalación
git clone https://github.com/HalilDeniz/PacketSpy.git
Requisitos:
PacketSpy requiere que se instalen las siguientes dependencias:
pip install -r requirements.txt
Primeros pasos:
Para comenzar a usar PacketSpy, usa las siguientes opciones de línea de comandos:
root@denizhalil:/PacketSpy# python3 packetspy.py --help
usage: packetspy.py [-h] [-t TARGET_IP] [-g GATEWAY_IP] [-i INTERFACE] [-tf TARGET_FIND] [--ip-forward] [-m METHOD]
options:
-h, --help show this help message and exit
-t TARGET_IP, --target TARGET_IP
Target IP address
-g GATEWAY_IP, --gateway GATEWAY_IP
Gateway IP address
-i INTERFACE, --interface INTERFACE
Interface name
-tf TARGET_FIND, --targetfind TARGET_FIND
Target IP range to find
--ip-forward, -if Enable packet forwarding
-m METHOD, --method METHOD
Limit sniffing to a specific HTTP method
Ejemplos
- Detección de dispositivos
root@denizhalil:/PacketSpy# python3 packetspy.py -tf 10.0.2.0/24 -i eth0
Device discovery
**************************************
Ip Address Mac Address
**************************************
10.0.2.1 52:54:00:12:35:00
10.0.2.2 52:54:00:12:35:00
10.0.2.3 08:00:27:78:66:95
10.0.2.11 08:00:27:65:96:cd
10.0.2.12 08:00:27:2f:64:fe
- Interceptación de paquetes (Man-in-the-Middle Sniffing)
root@denizhalil:/PacketSpy# python3 packetspy.py -t 10.0.2.11 -g 10.0.2.1 -i eth0
******************* started sniff *******************
HTTP Request:
Method: b'POST'
Host: b'testphp.vulnweb.com'
Path: b'/userinfo.php'
Source IP: 10.0.2.20
Source MAC: 08:00:27:04:e8:82
Protocol: HTTP
User-Agent: b'Mozilla/5.0 (X11; Linux x86_64; rv:105.0) Gecko/20100101 Firefox/105.0'
Raw Payload:
b'uname=admin&pass=mysecretpassword'
HTTP Response:
Status Code: b'302'
Content Type: b'text/html; charset=UTF-8'
--------------------------------------------------
Código fuente:
https://github.com/HalilDeniz/PacketSpy