• I’m currently researching for a plugin I need to write.

    We need to allow members of an organisation to login to their WP-site, by authenticating on an external site. So they should not have to have a WP user account.

    Like this:

    1. User logs in to WP.
    2. Login plugin checks user details in an external system though API calls
    3. The external system recognized the user details
    4. The user is authorized as logged in to the WP site.

    Is this possible and does anyone have any links to article about this or even plugins that does similar things

Viewing 4 replies - 1 through 4 (of 4 total)
  • Did you have something in mind like the Google Authenticator plugin? It requires you to logon with a UserID, Password, and an authentication code which you can access from your cell phone/tablet.

    Did you have something in mind like the Google Authenticator plugin? It requires you to logon with a UserID, Password, and an authentication code which you can access from your cell phone/tablet.

    Thread Starter topheman

    (@topheman)

    No, the login is supposed to be handled through an API to another system.
    So the user just logs in to the WP site with the credentials from the other site.

    The “other” site you mentioned will need to provide an OAuth Server of some sort in order to authorize access to the user’s username and other information needed for proper SSO (Single Sign On).

    Does the other site provide an API you can use? The way SSO works is that if the user is not logged into your WP install, then it redirects the user to the authorize endpoint for authentication. Once authenticated on the other site, the user is redirected back to your WP site with a auth code of some type. Then it is up to you to call the other sites API and get an access token or access their resource API for user information.

    Once you have the user’s information, you then check to see if the user is registered in your WP site. If not, then you create the user account and log them into your WP site automatically. If the user does exist, then you would simply log the user into that account.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Login to WP through external site credentials’ is closed to new replies.