* Added register functionality to both the server and the client