authentication cleanup