Socket
Socket
Sign inDemoInstall

bencode-python

Package Overview
Dependencies
0
Maintainers
1
Alerts
File Explorer

Install Socket

Detect and block malicious and high-risk dependencies

Install

    bencode-python

Bencode encoder and decoder written in python.


Maintainers
1

Readme

Bencode

Bencode encoder and decoder written in python.

Installation

pip install bencode-python

Usage

Decoder

Decoding bencode data.

from bencode.decoder import Decoder

decoder = Decoder()
decoded = decoder.decode(b"i42e")
print(decoded) # 42

Encoder

Encoding Python data types into bencode format.

from bencode.encoder import Encoder

encoder = Encoder()
encoded = encoder.encode(42)
print(encoded) # b'i42e'

License

Licensed under the MIT License.

Keywords

FAQs


Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc