authenticate user when they try to access activities