Make request.pg available in auth code.

Make the `request.pg` object available, so it can also be used for authentication.