Class linkedin.
More...
Class linkedin.
OAuth 2 issuer for linkedin which is mostly OIDC compliant, with a few notable exceptions which require working around:
- LinkedIn don't provide their OIDC discovery doc at {ISSUER}/.well-known/openid-configuration as the spec requires. i.e. https://www.linkedin.com/.well-known/openid-configuration isn't present. Instead, they make the configuration available at https://www.linkedin.com/oauth/.well-known/openid-configuration. See: https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfig
- LinkedIn don't return 'locale' as a string in the userinfo but instead return an object with 'language' and 'country' props. See: https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims This is resolved in {
- See also
- core\oauth2\client\linkedin\get_userinfo()}
- Copyright
- 2021 Peter Dias
- License
- http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
◆ create_discovery_endpoint()
static core\oauth2\discovery\base_definition::create_discovery_endpoint |
( |
issuer | $issuer, |
|
|
string | $url ) |
|
staticprotectedinherited |
Helper method to create discovery endpoint.
- Parameters
-
issuer | $issuer | Issuer the endpoints should be created for. |
string | $url | Discovery endpoint URL. |
- Return values
-
endpoint | The endpoint created. |
- Exceptions
-
◆ create_endpoints()
static core\oauth2\discovery\base_definition::create_endpoints |
( |
issuer | $issuer | ) |
|
|
staticinherited |
◆ create_field_mappings()
static core\oauth2\discovery\openidconnect::create_field_mappings |
( |
issuer | $issuer | ) |
|
|
staticprotectedinherited |
Process how to map user field information.
- Parameters
-
issuer | $issuer | The OAuth issuer the endpoints should be discovered for. |
- Return values
-
Reimplemented from core\oauth2\discovery\base_definition.
◆ discover_endpoints()
static core\oauth2\discovery\base_definition::discover_endpoints |
( |
| $issuer | ) |
|
|
staticinherited |
If the discovery endpoint exists for this issuer, try and determine the list of valid endpoints.
- Parameters
-
- Return values
-
int | The number of discovered services. |
◆ get_discovery_endpoint_url()
static core\oauth2\discovery\openidconnect::get_discovery_endpoint_url |
( |
issuer | $issuer | ) |
|
|
staticinherited |
Get the URL for the discovery manifest.
- Parameters
-
issuer | $issuer | The OAuth issuer the endpoints should be discovered for. |
- Return values
-
string | The URL of the discovery file, containing the endpoints. |
Reimplemented from core\oauth2\discovery\base_definition.
◆ init()
static core\oauth2\service\linkedin::init |
( |
| ) |
|
|
static |
Build an OAuth2 issuer, with all the default values for this service.
- Return values
-
issuer | The issuer initialised with proper default values. |
◆ process_configuration_json()
static core\oauth2\discovery\openidconnect::process_configuration_json |
( |
issuer | $issuer, |
|
|
stdClass | $info ) |
|
staticprotectedinherited |
Process the discovery information and create endpoints defined with the expected format.
- Parameters
-
issuer | $issuer | The OAuth issuer the endpoints should be discovered for. |
stdClass | $info | The discovery information, with the endpoints to process and create. |
- Return values
-
Reimplemented from core\oauth2\discovery\base_definition.
◆ register()
static core\oauth2\discovery\openidconnect::register |
( |
issuer | $issuer | ) |
|
|
staticprotectedinherited |
Self-register the issuer if the 'registration' endpoint exists and client id and secret aren't defined.
- Parameters
-
issuer | $issuer | The OAuth issuer to register. |
- Return values
-
Reimplemented from core\oauth2\discovery\base_definition.
The documentation for this class was generated from the following file: