Scapy Socket Logger
Log all traffic going through an Scapy socket to a PCAP file.
Installation
Just use pip :)
pip install scapy-socketlogger
Usage
Practical examples can be found in the Examples folder.
For a plain quick usage reference, you may look into the following snippet:
from scapy.all import SuperSocket, PcapWriter
from scapy_socketlogger import SocketLogger
# Create your socket
sock = SuperSocket(...)
# Create a PCAP writer
pcap_writer = PcapWriter("traffic.pcap")
# Wrap the socket with the logger
logger = SocketLogger(sock, pcap_writer)
# Use the socket normally - all traffic will be logged
# ...
# Close the logger when done
logger.close()
Or use as a context manager:
with SocketLogger(sock, pcap_writer) as logger:
# Use sock here
pass
# Automatically closes and restores socket methods
Metadata
Release files for scapy-socketlogger 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| scapy_socketlogger-0.0.2.tar.gz | 17.0 kB | With provenance | Details for scapy_socketlogger-0.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| scapy_socketlogger-0.0.2-py3-none-any.whl | Python 3 | none | any | Details for scapy_socketlogger-0.0.2-py3-none-any.whl |
Total release size: 32.2 kB
Release files / scapy_socketlogger-0.0.2.tar.gz
| Download URL | scapy_socketlogger-0.0.2.tar.gz |
|---|---|
| Size | 17.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
94fae97326f0c9490ed514583c4610a9eb74570e29738c7e954cb6b3c611569e
|
|
BLAKE2b-256 checksum How to use checksums |
ceec8fcd0116573fe2812bd7027298a055cd3667b32582f4c1df6dacba16194d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 3, 2025.
Transparency logRelease files / scapy_socketlogger-0.0.2-py3-none-any.whl
| Download URL | scapy_socketlogger-0.0.2-py3-none-any.whl |
|---|---|
| Size | 15.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8752d4551adb2ff5526a13e7fe0f32987357254b4ee4d8dcfd9f683f750b6ebc
|
|
BLAKE2b-256 checksum How to use checksums |
8ebd4b7e1264b20dfc46de1eca88d5ba584c7c021f1531fb736fab100f8d1006
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 3, 2025.
Transparency logSecurity for scapy-socketlogger 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for scapy_socketlogger-0.0.2.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 3, 2025.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.