A hash library for vlang.
- vlang >= 0.5.2
Add the dependency to your project:
v install deatil.hashor
v install --git https://github.com/deatil/v-hashThe v-hash structure can be imported in your application with:
import deatil.hashmodule main
import deatil.hash.md2
fn main() {
mut d := md2.new()
d.write("abc".bytes()) or { panic(err) }
out := d.sum([])
// output: da853b0d3f88d99b30283a69e6ded6bb
println("output: ${out.hex()}")
}md2: deatil.hash.md2md4: deatil.hash.md4has160: deatil.hash.has160tiger: deatil.hash.tigersm3: deatil.hash.sm3esch: deatil.hash.esch
- The library LICENSE is
Apache2, using the library need keep the LICENSE.
- Copyright deatil(https://github.com/deatil).