add homepage, login, success, and init function for authentication, new functions in service.js