Added authentication and location storing