first of all sorry for the bad English.
Well, I want to read the pieces hashes information from a torrent file. Currently, I\'m using https://github.com/hyPiRion/java-be
I'm storing binary data as strings, because the BEncode format in .torrent files, store that binary data as string
Bencode "strings" are sequences of bytes, not sequences of unicode codepoints. Therefore a language's representation of bytes - byte[]
or ByteBuffer
in java - is appropriate and should only be interpreted as utf8 string in certain cases when they actually contain things that are supposed to be human-readable.
So you should use a bencoding library that supports extraction of the raw bytes.