some work on keystore