First pass at account/session controller function.