Adding authentication and authorization to endpoints.

Will test as soon as I install bcrypt on my compy. Also updated .gitignore to ignore npm-debug.log.