refactored clientRegistration because of decoupled registration process