Skip to content
This repository has been archived by the owner on Sep 27, 2024. It is now read-only.

svenstucki/sha256

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SHA-256

This is a very basic implementation of a SHA-256 hash according to the FIPS 180-4 standard in C. I did it for educational purposes, the code is not optimized at all, but (almost) corresponds line by line to the standard.

The algorithm to process a small block of data is quite simple and very well described in the standard. I found that correctly implementing the padding is much harder.

It does not have any dependencies (except for the C standard library of course) and can be compiled with make. When sha256sum is installed, a short test can be run with make test.

Usage:

./main <input file>

About

Basic unoptimized SHA256 implementation in C

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages