Fixed authentication bug in scripts.