glFusion Wiki

Site Tools


glfusion:remoteauth:linkedin

LinkedIn Authentication

LinkedIn is the world's largest professional network, where users can build their professional identity online and stay in touch with colleagues and classmates. LinkedIn supports OAuth2 authentication which allows glFusion to request LinkedIn to authenticate a user without exposing the user's password to glFusion.

Configuring LinkedIn Authentication

Navigate to https://www.linkedin.com/secure/developer?newapp=

If you have not already done so, create an application. If you have an existing application, select it to modify its settings.

To prevent fraudulent transactions during the authentication process, we will only communicate with URLs that you have identified as trusted endpoints. Ensure the “OAuth 2.0 Redirect URLs” field for your application contains a valid callback URL to your server that is listening to complete your portion of the authentication workflow.

Select Create an Application

Company Name
Select from the list, or select Create a New Company
Name
A descriptive name for the application - generally your site name.
Description
A brief description about your site.
Application Logo
Upload a logo that will appear on the LinkedIn authorization page.
Application Use
Select an appropriate use from the drop down list
Website URL
The full URL to your site
Business Email
The contact email for your site
Business Phone
A valid contact phone number for your or your site's admin
Read and agree to the LinkedIn API Terms of Use - once you have read the terms, select the checkbox.

Click Submit to create your application.

LinkedIn will now display your Client ID and Client Secret with a few additional input fields:

Default Application Permissions
Ensure you check r_basicprofile
OAuth 2.0 - Authorized Redirect URLs
You will need to add 2 URLs here:
  • http://www.yoursitehere.com/users.php?oauth_login=linkedin
  • http://www.yoursitehere.com
Oauth 1.0a - Default “Accept” Redirect URL
http://www.yoursitehere.com/users.php?oauth_login=linkedin
Oauth 1.0a - Default “Cancel” Redirect URL
http://www.yoursitehere.com

Be sure to record your Client ID and Client Secret so you enter them into the glFusion Configuration.

Select Update and you should be setup.

Save this information for use in the next step.

Finalizing Setup

Once you have created the LinkedIn Oauth keys and access tokens, you will need to enter these into the glFusion Configuration.

  1. Navigate to Command & ControlUsers & Submissions
  2. Ensure User Login Method[oauth] is set to True
  3. Set Enable LinkedIn OAuth Login Method to True
  4. Enter the Client ID from LinkedIn in the LinkedIn OAuth Consumer Key field
  5. Enter the Client Secret from LinkedIn in the LinkedIn OAuth Consumer Secret field
  6. Select Save Changes

Now you should have LinkedIn authentication enabled for your site!

User Experience

Once you have everything setup, when a user selects Login with LinkedIn they will be presented with a LinkedIn login / authorization screen that has your website name and logo (optional).

Once the user had logged into LinkedIn, they will be redirected back to your site automatically and be logged in.

LinkedIn Specific Usage Notes

glFusion Username
glFusion will request the user's LinkedIn user name and use this to create the local glFusion user account profile. If there is already a username that matches, glFusion will automatically add a random number to the end of the LinkedIn username to make it unique on your site. If you have Allow User name change enabled in glFusion's configuration, the user can change their username to something they prefer.
glfusion/remoteauth/linkedin.txt · Last modified: 2017/04/12 21:11 (external edit)

Page Tools