aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorPaul Duncan <pabs@pablotron.org>2019-08-25 07:30:50 -0400
committerPaul Duncan <pabs@pablotron.org>2019-08-25 07:30:50 -0400
commit865e27e4e21784f041517bd0cc8b6d8deb0c3cd1 (patch)
tree8bde5ec0895738fad18530aa1425dc876ec5b416 /README.md
parentf9a7d81ea228c2d87dcd6fee986bb58a3d0813c2 (diff)
downloadsha2-865e27e4e21784f041517bd0cc8b6d8deb0c3cd1.tar.bz2
sha2-865e27e4e21784f041517bd0cc8b6d8deb0c3cd1.zip
add license.txt and update README.md
Diffstat (limited to 'README.md')
-rw-r--r--README.md45
1 files changed, 32 insertions, 13 deletions
diff --git a/README.md b/README.md
index ce217ec..3bbfd8e 100644
--- a/README.md
+++ b/README.md
@@ -1,18 +1,37 @@
-My C11 SHA256 implementation.
+Self-contained C11 SHA-2 implementation.
+
+Includes implementations of the following:
+* SHA-224
+* SHA-256
+* SHA-384
+* SHA-512
+* HMAC-SHA-256
+* HMAC-SHA-512
See `tests.c` for usage.
Benchmarks
==========
- > time -p ./sha256 ~/Videos/8x*avi > /dev/null
- rleal 9.39
- user 9.10
- sys 0.29
- > time -p sha256sum ~/Videos/8x*avi > /dev/null
- real 12.04
- user 11.73
- sys 0.31
- > time -p openssl sha256 ~/Videos/8x*avi > /dev/null
- real 6.36
- user 6.01
- sys 0.32
+Benchmarks. Partially unrolled compression makes this implementation
+faster than [coreutils][], but slower than the [assembly-optimized,
+family-specific OpenSSL SHA-2 implementation][openssl-asm-sha].
+
+```
+> time -p ./sha256 ~/Videos/8x*avi > /dev/null
+rleal 9.39
+user 9.10
+sys 0.29
+> time -p sha256sum ~/Videos/8x*avi > /dev/null
+real 12.04
+user 11.73
+sys 0.31
+> time -p openssl sha256 ~/Videos/8x*avi > /dev/null
+real 6.36
+user 6.01
+sys 0.32
+```
+
+ [sha2]: https://en.wikipedia.org/wiki/SHA-2 "Secure Hash Algorithm 2"
+ [c11]: https://en.wikipedia.org/wiki/C11_(C_standard_revision) "C11 standard of the C programming language"
+ [coreutils]: https://www.gnu.org/software/coreutils/ "GNU core utilities"
+ [openssl-asm-sha]: https://github.com/openssl/openssl/tree/master/crypto/sha/asm "assembly-optimized OpenSSL SHA-2 implementation."