[feature/auth-refactor] Use a base class for all authentication providers

Creates a base class that all authentication providers implements in order to reduce code repetition.

PHPBB3-9734