Added session and cookie tracking in the login and signup files, and added
the needed mongo functions.