Update main class, and add steps for encryption into the encrytion class.

Signed-off-by: Antti-Ville Jokela <jokela.anttiville@gmail.com>