A collection of cryptographic algorithms implemented from scratch in Zig. Starting with SHA-1, with more to come.
- SHA-1 - Secure Hash Algorithm 1 (FIPS 180-4)
- SHA-256
- SipHash
- HMAC
- Ensure you have Zig 0.11+ installed
- Clone the repository:
git clone https://github.com/rohitanwar/Cryptography.git cd Cryptography - Run the SHA-1 implementation:
zig run src/sha1.zig
⚠️ Warning
Currently the build.zig doesn't work. You need to manually enter the string to hash in thesrc/sha1.zigfile
Contributions are welcome! Please open an issue or PR if you:
-
Find a bug
-
Want to add another algorithm
-
Have optimization suggestions