The XXTEA encryption algorithm (a.k.a. Correct Block TEA) is an update to the original Tiny Encryption Algorithm (TEA) introduced in 1988 by Roger Needham and David Wheeler. Designed expressly for simplicity, the algorithm itself can be expressed in a mere 20 lines of C code. In spite of having been shown susceptible to a chosen-plaintext-attack, for basic uses it is actually reasonably secure.
Simplecrypt is a bare-bones implementation of file encryption using XXTEA as a block cipher in conjunction with several techniques to allow it work with reasonable security and efficiency on standard user files. The program is written in ANSI C and depends on a few POSIX library calls.
simplecrypt.c (~7k)