Topic on Extension talk:GoogleLogin

Automatically register anyone who logs-in with a Google account

5
Domtron vox (talkcontribs)

Is there a way to make the plugin or AuthManager automatically register wiki accounts for people logging in with google accounts for the first time? I searched for this and couldn't find anything, but a generic remote user extension that has an auto register option, but no clue how hard it would be to get working with google accounts.

I would like for anyone in the company to seamlessly login without needing to stop and create an account.

Thanks!

Info Dump:

I have the wiki login restricted to certain custom gmail domains.

Hosted on reseller cPanel/WHM

PHP 7.0

MediaWiki 1.30 (Installed with cPanel one click install)

GoogleLogin Version file: GoogleLogin: REL1_30 2017-09-21T22:09:00 f594074

Domtron vox (talkcontribs)

Realized this is really important because anyone can still register an account using the registration field. I want to Disable normal mediawiki login process using the $wgAuthManagerAutoConfig['primaryauth'] = []; config but then users can't register their google account via the Special:CreateAccount page since it is effectivly removed when the GoogleLogin login setup takes over. :/

Am I missing something? I've read the wiki page and this discussion page multiple times and just can't figure out what I'm doing wrong.

Florianschmidtwelzow (talkcontribs)

Hi, this is currently not possible (at least not from the UI, see more in the second section of my answer), sorry :( The difference with GoogleLogin and the Auth_remoteuser extension is, that GoogleLoign actually is an authentication provider. It gives MediaWiki an additional way to authenticate a specific user inside of MediaWiki. On the other hand, Auth_remoteuser is a so called SessionProvider. It provides a possibility to get a session based on a specific environment variable, so the user does not need to authenticate with MediaWiki, the user is coming from a different source.

There's actually the task T138678 which goal it is to provide a way to auto-create a new wiki-user if no user already exists when using an authentication provider other than MediaWiki's own one. However, we're currently not really actively working on it :( The AuthManager already provides a way of automatically linking an account when someone if logging in the first time, however, it's not yet exposed in the UI.

Jsmith6 (talkcontribs)

Florianschmidtwelzow, this is great information. Thank you.

The main issue that I am having is that once new users are authorized in our wiki, their wiki account should get linked to their Google account once they login. But instead, they get the error message "The supplied credentials are not associated with any user on this wiki".

We are not trying to create a wiki account upon authentication with Google, but simply to link an existing wiki account with an existing Google account.

Above, you said: "The AuthManager already provides a way of automatically linking an account when someone if logging in the first time, however, it's not yet exposed in the UI."

Could you please advise how to avail ourselves of this?

Chabamkazam (talkcontribs)

Was a solution ever found to this? I am having the exact same problem described by Jsmith6, but have been unable to figure out how to do this

Reply to "Automatically register anyone who logs-in with a Google account"