Browsing slashdot I found a lightweight opensource cryptography toolkit called LibTomCrypt. It's really worth taking a look at!

It's like a beginners cryptography toolkit, that don't have a lot of advanced functionality, but it's great to learn from. It's written in C and quite easy to understand. Good for anyone wanting to write their own crypto toolkit. If you wan't to learn how cryptography works, you can take a look inside the files of this toolkit. And it's quite well documented, too.

For advanced features, another toolkit is better - but for learning, this one is great!

This list of features is taken from the website:

* Block Ciphers
o Blowfish
o XTEA
o RC5
o RC6
o SAFER+
o Serpent
o Rijndael (aka AES)
o Twofish
o SAFER (K64, SK64, K128, SK128)
o RC2
o DES, 3DES
o CAST5
o Noekeon
* Chaining Modes
o ECB
o CBC
o OFB
o CFB
o CTR
* One-Way Hash Functions
o MD2
o MD4
o MD5
o SHA-1
o SHA-256/384/512
o TIGER-192
* Pseudo-Random Number Generators
o Yarrow (based algorithm)
o RC4
o Support for /dev/random, /dev/urandom and the Win32 CSP RNG
* Public Key Algorithms
o RSA (using PKCS #1 v1.5 style padding)
o DH (using ElGamal signatures and simple DH encryption)
o ECC (over Z/pZ, ElGamal Signatures, simple DH style encryption)