CryptoGear encryption algorithm
Designed to be simple and fast, while providing a decent level of security.
It is a symmetric-key block cipher, which can operate in ECB or CBC mode.
Particularities of this block cipher include the fact that it doesn’t produce padding, so the size of plain-text and cipher-text will be always the same, and doesn’t need to be a multiple of the block size.
You can imagine it’s mechanism like a bycicle gear. The gear is the keystream, while the chain that slides though the gear is the data to be crypted. Each gear cog and chain ring rapresents a byte.
In CBC mode, the tooth of the gear gets changed too each time it encrypts a byte.
This way, on each round the gear (keystream) will be very different from the previous one, and will crypt the block in a different way (even if block data is identical to the one of previous round).
You can find also C++ version of the same algorithm.