Implemented Rest User and authentication logic