Moving auth from lib to root