Hasher256

class Hasher256

Incremental SHA-256 hasher producing a Sha256Hash, the port of libtorrent's hasher256. Used for BitTorrent v2 piece hashing and merkle-tree nodes.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard

Finish and return the digest as a Sha256Hash.

Link copied to clipboard
fun update(data: ByteArray, offset: Int = 0, length: Int = data.size - offset): Hasher256