add a hack login function for integration for psc-cms
fix client working in cli