Extension talk:GoogleAppsAuthentification

Jump to: navigation, search

About this board

By clicking "Add topic", you agree to our Terms of Use and agree to irrevocably release your text under the CC BY-SA 3.0 License and GFDL
181.29.27.39 (talkcontribs)

Hi, i am getting this error:

Auth request object error. Try again

Is this probably related to the variable in LocalSettings.php, 'GoogleAppsDomain'?? i've set it this way:

$wgDefaultUserOptions['GoogleAppsDomain'] = 'google.com/a/myDomain.com';

Thanks in advance!

This post was posted by 181.29.27.39, but signed as Daniel.SL.

205.251.160.140 (talkcontribs)

The variable 'GoogleAppsDomain' should have the domain you want to allow logins from. e.g. I only want google accounts with domain example.com to login, such as mom@example.com or dad@example.com:

$wgDefaultUserOptions['GoogleAppsDomain'] = 'example.com';

This way, jimmy@gmail.com won't be authenticated.

Reply to "Error with auth request"
220.255.2.28 (talkcontribs)

I would like to know about the permission in the mediawiki, if I use this extension let say: sysops,beaurecrat,....

This post was posted by 220.255.2.28, but signed as 220.255.2.25.

Reply to "Permission"
Jme2390 (talkcontribs)

Great plugin, it solves one of the missing pieces in our Google Apps login project.

With that said, it seems that while users can logout successfully, they can also log back in without being logged in to Google Apps.

Say I login to my MediaWiki install (whether or not I'm logged into Apps already) and I end up back at Main_Page. If I click log out, I'm logged out and everything is peachy keen. Now, if I'm also logged out of Apps at this point, I can log right back in just by clicking the log in link in the header. That is to say, I don't need to be logged into Apps again to actually authenticate to the wiki; it lets me right back in. I'm not sure what's going on here, I suspect it has to do with the temp files, but erasing them isn't solving the issue. On the off chance it was OS or browser specific, several have been tried (Safari, Chrome, Firefox, on Windows and OS X - all latest versions as of this writing). The (Apache on Debian) web server user has full r/w permissions to the tmp directory and subdirectories.

If you have any insight as to how to solve this "endlessly" persistent login problem, that would be greatly appreciated. We've come up empty handed thus far.

Thanks!

122.201.18.43 (talkcontribs)

implement userlogout hook and remove the session variable

This post was posted by 122.201.18.43, but signed as 122.201.18.155.

Willcwf (talkcontribs)
$wgHooks['UserLogout'] = array('fnUnsetLoggedInUser');

function fnUnsetLoggedInUser() {
        session_unset();
        return true;
}

this works if you're logged out of google

Reply to ""Endlessly" persistant logins"
206.108.165.248 (talkcontribs)

After installation when I click to login, I get a blank page. Any idea?

206.108.165.249 (talkcontribs)

Error log post.

[08-Sep-2014 21:23:55 America/Detroit] PHP Fatal error: Call-time pass-by-reference has been removed in /home/leobaeck/public_html/wiki/extensions/GoogleAppsAuthentication/Auth/Yadis/Manager.php on line 416

Reply to "Blank page"
208.97.104.194 (talkcontribs)

I was having an issue where after logging in from the home page, mediawiki would bring you straight back to the login page with a username and password field.

So I modified this code:

       // Return URL
       $config['return_server'] = (isset($_SERVER["HTTPS"]) ? 'https://' : 'http://') .$_SERVER['SERVER_NAME'].":".$_SERVER['SERVER_PORT'];
       $config['return_url'] = $config['return_server'].$_SERVER['REQUEST_URI'];

to

       // Return URL
       $config['return_server'] = (isset($_SERVER["HTTPS"]) ? 'https://' : 'http://') .$_SERVER['SERVER_NAME'].":".$_SERVER['SERVER_PORT'];
       if ($_REQUEST["title"] == $lg->specialPage("Userlogin")) {
               $config['return_url'] = $config['return_server'].$_SERVER['SCRIPT_NAME'];
       }
       else {
               $config['return_url'] = $config['return_server'].$_SERVER['REQUEST_URI'];
       }

This resolved my issue.

5.28.71.149 (talkcontribs)

Thanks! Had the same issue. (MW1.19.1) However you missed one simple line.

Before the code above add: $lg = Language::factory($wgLanguageCode);

Otherwise you get a blank page. (Or PHP-Error of unknown $lg, depending on your debug settings.)

Additionaly, after Login I get a dialog asking if I wanted to purge the cache of the mainpage. (Usually only NOT logged in users should get that.) Fixed it by changing:

$wgOut->redirect($url."?action=purge");

to

$wgOut->redirect($url."?action=view");

Have to wait and see if there are serious isuess with with not-current mainpages.

Dyspatch (talkcontribs)

I am still working through some issues here, but two modifications are already apparent to the above.

  1. You need to also specify the global variable, $wgLanguageCode, at the top of the getGoogleAccount function.
  2. The "?action=view" is not the proper query string syntax. It needs to be an "&" instead of a "?".

That all being said, I am noticing issues with this implementation when it comes to logging in from pages that aren't the main page. I'll update this once I've worked through those issues.

Reply to "Redirecting to login page after login"
Koemski (talkcontribs)

(The solution outlined in 2012 further down this page doesn't work with mw 1.22)

After login I get redirected to the mediawiki login page. How can I get redirected to the page I was before or maybe the main page?

thx, Karsten PS: I use mw1.22.5

Reply to "Redirect to login page after login"
79.218.125.106 (talkcontribs)

Hi,

ok, now I'm logged in ... but how do I make myself an administrator or bureaucrat?

Best, Karsten

Jasper Deng (talkcontribs)

There should be a non-Google-Apps default account that you setup when you initially installed MediaWiki.

93.218.115.162 (talkcontribs)

When using GoogleAppsAuthentification you cannot login with another user. There is no other login screen than the google-oAuth screen.

Jasper Deng (talkcontribs)

In that case, you can assign it through database access. See Manual:User rights.

Koemski (talkcontribs)
  • mysql -u root -pPassword databasename
  • select user_id, user_name from user; -- find user_id of user, let's say: 2
  • insert into user_groups values (2, 'sysop'), (2, 'bureaucrat');
  • \q
Reply to "How do I make myself administrator?"

GoogleAppsAuthentication MediaWiki 1.22.1

1
79.189.12.114 (talkcontribs)

Is the extention still valid for MediaWiki 1.22.1? It looks like it doesn't work anymore.

Reply to "GoogleAppsAuthentication MediaWiki 1.22.1"

Suggestion / Has any : set this up for multipel domains

2
50.137.193.149 (talkcontribs)

Has anyone tried to get multiple domains working for instance gmail.com and somegoogleappaccount.com?

I would think you could just loop through the domains somewhere but I am not sure where. Anyone have an idea?

Reply to "Suggestion / Has any : set this up for multipel domains"

Sometimes can not sign in after Google's response

1
Llin.mitbbs (talkcontribs)

It is very convenient to have people log on a wiki with Google credential. Thanks for Bertrand Gorge and Emanuele Nanetti for the great work.

http://www.mediawiki.org/wiki/Extension:GoogleAppsAuthentification

An issue is that sometimes, even with Google return the right credential, mediawiki (19.2) does not get people log in correctly.

So far, I found the root cause was with SpecialUserlogin.php and patched it. Detail is here.

http://stackoverflow.com/questions/18536237/mediawiki-extension-googleappsauthentification-can-not-sign-in-after-googles-r

Reply to "Sometimes can not sign in after Google's response"