Skip to main content

This module sniffs network communications without any requirements

Project description

NetworkSniffer logo

NetworkSniffer

Description

This module sniffs network communications without any requirements (without scapy/npcap/winpcap).

Requirements

This package require:

  • python3
  • python3 Standard Library

Installation

pip install NetworkSniffer

Usages

Command line

python3 -m NetworkSniffer
python3 NetworkSniffer.pyz -x -s -c
NetworkSniffer -x -X -c
NetworkSniffer -x -s -t -c
NetworkSniffer -x -s -u -c
NetworkSniffer -x -s -4 -c
NetworkSniffer -x -s -6 -c
NetworkSniffer -x -s -c -n '192.168.56.0/24'
NetworkSniffer -x -s -c -n '10.0.0.0/8' '192.168.56.0/24'
NetworkSniffer -x -s -c -p 80
NetworkSniffer -x -s -c -p 80 53
NetworkSniffer -x -s -c -m '00:00:00:00:00:00'
NetworkSniffer -x -s -c -m '00:00:00:00:00:00' '08:00:27:b1:9d:67'
NetworkSniffer -x -s -c -i '192.168.56.101'
NetworkSniffer -x -s -c -i '192.168.56.101' '10.0.2.15'
NetworkSniffer -c -l 20
NetworkSniffer -x -s -f 'test.txt'

Python script

from NetworkSniffer import *

sniffer = Sniffer(
    [('192.168.0.47', 0), ('192.168.56.1', 0)],
    [('fe80:0000:0000:0000:6cc8:2732:3de4:496b', 0, 0, 18)],
    (summary, hexadecimal),
)
sniffer.sniff() 

SnifferFilters = new_class(
    "SnifferFilters",
    (TcpFilter, Sniffer),
    {},
)
sniffer = SnifferFilters(
    [('192.168.0.47', 0), ('192.168.56.1', 0)],
    [('fe80:0000:0000:0000:6cc8:2732:3de4:496b', 0, 0, 18)],
    (summary, hexadecimal),
    tcp_filter=True,
)
sniffer.sniff() 

ipv4_addresses, ipv6_addresses = get_addresses()
sniffer = Sniffer(
    ipv4_addresses,
    ipv6_addresses,
    (raw,),
)
sniffer.sniff() 

Links

Licence

Licensed under the GPL, version 3.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

NetworkSniffer-0.0.3.tar.gz (26.5 kB view details)

Uploaded Source

File details

Details for the file NetworkSniffer-0.0.3.tar.gz.

File metadata

  • Download URL: NetworkSniffer-0.0.3.tar.gz
  • Upload date:
  • Size: 26.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.2

File hashes

Hashes for NetworkSniffer-0.0.3.tar.gz
Algorithm Hash digest
SHA256 59950f7e67b97f2850fc7184c0fd8574e9bc1b7ab177e5f19c4ee12b5fc31764
MD5 35ed0d491dec4088740d6942103954b5
BLAKE2b-256 39bd51b3b17657c0a235dd5e522fd3963ecd76d1bb7cdb957f91a9db7a709071

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page