registration view and auth functions