1200 auth fixes

This should solve all the bullet points of #1200, broken into separate commits.