Added authentication through main page