added user authentication from cookie