Added 'restrict' middleware for authorization

'restrict' will ensure that the user is authenticated, and redirect them to the login page if not. It accepts a whitelisted set of URLs that all users can access (e.g., home page, login, register), but redirects requests for all other paths to the specified login URL.