This app demonstrates typical username/password authentication, and a pinch of Friend's authorization capabilities.
Each of these links require particular roles (or, any authentication) to access. If you're not authenticated, you will be redirected to a dedicated login page. If you're already authenticated, but do not meet the authorization requirements (e.g. you don't have the proper role), then you'll get an Unauthorized HTTP response.