Add registration and extension support for custom auth backends.

The auth backend code now follows the same registration pattern used
throughout the codebase. Auth backends can be registered, unregistered,
iterated through, and looked up.

A new requirement is that auth backends must have an ID. For
compatibility purposes, we assign an ID if one is not set when scanning
entry points, but all registrations going straight through the new
functions will require an ID set directly on the class.

There's also a new AuthBackendHook for extensions, which will handle the
registration and unregistration for the extension.

Documentation has been added for the new hooks, and the guide on writing
an auth backend has been updated as well.