Added an in memory implementation of the keystore and nonce store