Implements a keystore mechanism.

This commit implements a system whereby a keystore is used to decrypt
incoming authentication tokens. This removes the situation where the
server key could be compromised, thus require all services to change
their encrypting key. With this system in place each service has its
own encrypting key.