created registration and login router and middleware