EMbedded Secure HAshing library. https://docs.shimmering-clarity.net/emsha/
Go to file
Kyle Isom 5edb920881 gitea doesn't support rST READMEs. 2023-10-18 03:42:15 -07:00
.idea Cut a release. 2023-10-18 03:39:27 -07:00
.trunk Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
cmake Cut a release. 2023-10-18 03:39:27 -07:00
debian Miscellaneous packaging fixes. 2016-01-29 16:38:18 -08:00
docs Cut a release. 2023-10-18 03:39:27 -07:00
emsha Cut a release. 2023-10-18 03:39:27 -07:00
scripts Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
.clang-format Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
.clang-tidy Cut a release. 2023-10-18 03:39:27 -07:00
.gitignore Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
.travis.yml pkg-config and add gitignore. 2016-01-28 09:42:03 -08:00
CHANGELOG Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
CMakeLists.txt Cut a release. 2023-10-18 03:39:27 -07:00
LICENSE Initial import. 2015-12-17 01:54:10 -08:00
README.md gitea doesn't support rST READMEs. 2023-10-18 03:42:15 -07:00
TODO.rst Add Debian package, finish TODOs. 2016-01-27 21:41:02 -08:00
emsha.cc Cut a release. 2023-10-18 03:39:27 -07:00
emsha.pc.in Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
hmac.cc Cut a release. 2023-10-18 03:39:27 -07:00
sha256.cc Cut a release. 2023-10-18 03:39:27 -07:00
test_emsha.cc Cut a release. 2023-10-18 03:39:27 -07:00
test_hmac.cc Major refactoring effort underway. 2023-10-17 23:43:18 -07:00
test_mem.cc Cut a release. 2023-10-18 03:39:27 -07:00
test_sha256.cc Cut a release. 2023-10-18 03:39:27 -07:00
test_utils.cc Cut a release. 2023-10-18 03:39:27 -07:00
test_utils.h Cut a release. 2023-10-18 03:39:27 -07:00

README.md

libemsha

image

image

This library is an MIT-licensed HMAC-SHA-256 C++11 library designed for embedded systems. It is built following the JPL Power of Ten rules. It was written in response to a need for a standalone HMAC-SHA-256 package that could run on several platforms.

Getting and Building the Source

The source code is available via Github; each version should be git tagged. :

git clone https://github.com/kisom/libemsha
git clone git@github.com:kisom/libemsha

The current release is 1.0.1.

The project is built using Autotools and make.

When building from a git checkout, the [autobuild]{.title-ref} script will bootstrap the project from the autotools sources (e.g. via autoreconf -i), run configure (by default to use clang), and attempt to build the library and run the unit tests.

Once the autotools infrastructure has been bootstrapped, the following should work: :

./configure && make && make check && make install

There are three flags to configure that might be useful:

  • --disable-hexstring disables the provided hexstring function; while this might be useful in many cases, it also adds extra size to the code.
  • --disable-hexlut disables the larger lookup table used by hexstring, which can save around a kilobyte of program space. If the hexstring function is disabled, this option has no effect.
  • --disable-selftest disables the internal self-tests, which can reclaim some additional program space.

Documentation

Documentation is currently done with Sphinx. See doc/.

See also

Footnotes


  1. This library came about after extracting the relevant C code from RFC 6234, and needing a C++ version. It draws heavy inspiration from that code base. ↩︎