Fixed authentication problems