SSO - "There is a problem with your account. Please contact the site's administrator."


(Programster) #1

I just setup SSO on my discourse forum that I deployed through docker using the latest “stable” version (1.5). To clarify, I have my own SSO service that I am using to log into discourse. I am not using Discourse as an SSO provider. I used the cviebrock/discourse-php PHP package in order to develop the SSO service to work with discourse.

Whenever I hit login, everything redirects okay, but I land on the discourse forum with the message:

There is a problem with your account. Please contact the site’s administrator.

The address I land on is:

http://discourse.mydomain.org/session/sso_login?sso=bm9uY2U9NzFiNGIzM2UxMGQxYWJiYzc1MGI3MDFjMzE4ZTQwZTMmZXh0ZXJuYWxfaWQ9NTcw&sig=a3250a90855912afdbeb13be004449df52f404934b0414de02444c0d9be812ad

I tested messing with the signature or the sso and if I do that I get a blank page. I also tested plugging in an incorrect secret and got a different error message.

Has anyone else received this error message and know what I should do? Are there logs anywhere I can get more detailed information from?


(Programster) #2

Nevermind, it was a stupid implementation error on my part. I had the code:

$extraParameters = array(
    'name' => $userEmail = $_SESSION['name']
);

which should have been:

$extraParameters = array(
    'name' => $_SESSION['name']
);

I don’t khow how to delete or close this post, but would be grateful if someone else would.


(Régis Hanol) #3

(Régis Hanol) #4

You can’t on your own. Here, we recommend that you ask a moderator :wink:


(Jeff Atwood) #5

Hmm, how can we make the error message more useful in this case? Any ideas?


(Jeff Atwood) #6

(Arve Knudsen) #7

No suggestions, but I agree it should be more descriptive!


(Jeff Atwood) #8

@techapj can you add to your list, to look into this error message and any detail we can add to it at the time it occurs?


(Emanuelet) #9

At the moment I have a user on my Discourse instance experiencing this issue. For the SSO I’m using the official Wordpress Plugin GitHub - discourse/wp-discourse: WordPress plugin that lets you use Discourse as the community engine for a WordPress blog version 0.7


(Emanuelet) #10

and now I have a new one. I’m hosting Discourse version 1.5.2