Complete and detailed rewrite of authentication section.