 
    
                            Generic FoF OAuth
                            blt950/oauth-generic
                        
                        Generic OAuth2 provider for Flarum
- Downloads
- 961
- Version control
- github.com/blt950/flarum-ext-oauth-generic
Log in with custom OAuth2 Server
A Flarum extension. Generic oauth provider for Flarum
Features
Adds a Generic provider to FoF OAuth to enable Login with <your custom provider> functionality.
Installation
Install with composer:
composer require blt950/oauth-generic
Configuration
Admin Panel
Example configuration, please consult your provider for the correct values.
- Client ID <id from your provider>
- Client Secret <secret from your provider>
- Scope <scope from your provider>or empty
- Authorization Endpoint https://yourprovider.com/oauth/authorize
- Token Endpoint https://yourprovider.com/oauth/token
- User Information Endpoint https://yourprovider.com/api/user
To correctly find your user fields that might be nested in arrays, the parameters support nesting such as:
- User ID data-id
- Username data-username
- Email data-personal-email
Forcing or suggesting fields gives you the possiblity to force or pre-fill a suggested value when signing up the user.
- Force User ID 1or0.
- Force Display Name 1or0.
- Force Email 1or0.
Provider Name
If you wish to change the name of provider you can do so by editing the locale file. I did not find a way to make this dynamic.
Updating
composer update blt950/oauth-generic
php flarum cache:clear
Requests and Issues
Please file a pull request if you find issues or want to expand the functionality. Thank you for contributing.
Known quirks and bugs
- The nickname input field in signup modal fills in username regardless of display name is provided. This is due to get fixed in this pull request for a future Flarum version
- The icon of provider in admin panel is invisible due to FoF OAuth plugin forces a font-weight that won't display the font, it shows correctly other places though.
- The force settings are a boolean but have a string input, simply because boolean values are not supported for provider settings.
Links
Versions
- 
                            Version v1.0.0. Likely works with Flarum v1.8.11. 
- 
                    Extension created.