Monday, June 15, 2009

Semeir Status

Currently the project is looking very good, I've been able to work on it for a couple dozen hours. The main functions are all done, working, and currently is being brute tested and stress tested.

On a bright note, here are some little tidbits I see so far.

  1. The compiled+stripped code for the entire cipher, is about 5k, and the actual cipher file is only about 2k. The code size suggests it will be workable in an embedded environment.


  2. The keysize (if we optimize for size) for a good 4-8byte cipher, will likely take anywhere from 300-1500 bytes total, plus needing a 1k stack or less.

  3. thread-safe; after the key is generated, using the encrypt/decrypt functions make small copies of working data to the local space, making it thread safe.

  4. Speed; it is very fast; unlike the previous schema this has fixed limits and can easily optimized a lot more for speed. which also translates for size. Due to the keysize being rather small, other speedups will be noticed when implemented in the kernel.

Once testing has finished and the last few functions written, along with a new 'simple' program for encryption and PRNG, the code will likely be ready for release.

Thursday, June 4, 2009

Semeir from scratch

It is truly amazing how much one can learn over a period of time, as well as how much your style of coding changes.

After hard and careful consideration and trying to keep code from the old project, I have decided to start completely over from scratch. Looking carefully at my goals, I've re-thought and redone the API for the library, and I'm happy to say it's a lot smaller and simpler.

Goals:
  • Simple Cipher: The new public API will only have about 7 functions. The encryption also only has about 4 rules/steps to follow.

  • Documented & Tested: Following the advice of 'clean code' I'm writing documentation before working on the code. Test code will be written to test the code, and failure behavior.

  • Less Memory: Key data for a Standard key can be as small 1k, or as large (estimated max) as a 128k.

  • Cipher & PRNG: Build what we are working for, and not everything.


Depending on how busy I get, I foresee this being done by the end of the year, or earlier. I just hope this newer version is accepted more by the community than my previous one.