Feature/3037 separate keymanager into its own package