Add naiive implementation of route protection using redirects

Still need to check that token is valid, but because the RESTful resources are protected, it should be fine for now.