/bencode.nu

en- and de-code bencode in nushell

Primary LanguageNushellMIT LicenseMIT

Bencode.nu

A nushell library for de- and en-coding bencode.

Security

Bencode is often used in areas, which also contain malware.

Im not aware of security issues within the library itself, but im not a expert.

Something you should keep in mind while using this is: Decoded strings can contain ANSI-Escapes, which depending on your terminal can execute commands.
Therefore you should clean them before causing a error or outputting them.

Usage

This is nupm and numng compatible.

use bencode *

open -r foo.torrent | from_bencode

{"a": [123 0x[00] "hi"]} | to_bencode | save -r foo.bencode