Cookie expiration date validation and url escaping from session id, and async testing the changes