Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/grondilu/libdigest-raku
Raku implementation of various digests
https://github.com/grondilu/libdigest-raku
digests raku
Last synced: about 1 month ago
JSON representation
Raku implementation of various digests
- Host: GitHub
- URL: https://github.com/grondilu/libdigest-raku
- Owner: grondilu
- License: artistic-2.0
- Created: 2012-05-15T13:50:22.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2023-12-28T09:32:18.000Z (11 months ago)
- Last Synced: 2024-09-30T17:38:03.750Z (about 1 month ago)
- Topics: digests, raku
- Language: Raku
- Homepage:
- Size: 146 KB
- Stars: 27
- Watchers: 9
- Forks: 42
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![SparrowCI](https://ci.sparrowhub.io/project/gh-grondilu-libdigest-raku/badge)](https://ci.sparrowhub.io)
# Digests in rakuThis is a pure [raku](https://raku.org/) repository implementing some digest
algorithms.As of today (march 2023), raku still is fairly slow so if you need a faster way
to compute digest, consider using a
[nativecall](https://docs.raku.org/language/nativecall) binding to the OpenSSL
library instead.## Synopsis
Nb. Since commit 911c292688ad056a98285f7930297c5e1aea3bfb,
there is no `Digest` module anymore, the submodules, `Digest::MD5`, `Digest::SHA1` and
so on must be used directly.```raku
use Digest::MD5;
say md5 "hello";
use HMAC;
say hmac
key => "key",
msg => "The quick brown fox jumps over the lazy dog",
hash => &md5,
block-size => 64;use Digest::SHA1;
say sha1 "Hola";use Digest::SHA2;
say sha256 "Привет";use Digest::RIPEMD;
say rmd160 "Saluton";use Digest::SHA3;
say sha3_256 "Bonjour";
say shake256 "Merhaba", 16;# This will keep printing blocks
.say for shake256 "नमस्ते", *;
```
## FeaturesCurrently implemented:
* HMAC
- hmac
* Digest
- md5
* Digest::SHA1
- sha1
* Digest::SHA2
- sha224
- sha256
- sha384
- sha512
* Digest::SHA3
- sha3\_224
- sha3\_256
- sha3\_384
- sha3\_512
- shake128
- shake256
* Digest::RIPEMD :
- rmd160## License
This work is published under the terms of the artistic license, as rakudo is.
See LICENSE file.