Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Something went wrong. Please try again" after IPS update #58

Closed
MStruntze opened this issue Aug 18, 2016 · 37 comments

Comments

Projects
None yet
@MStruntze
Copy link

commented Aug 18, 2016

After updating to v4.1.14 users are unable to use this sign in method and are met with the "Something went wrong. Please try again" error.
No errors in system and error logs on ACP.

@johngalt

This comment has been minimized.

Copy link

commented Aug 19, 2016

Can confirm this problem since the v4.1.14 update. Was working fine prior to update. Not seeing any errors aside from what the OP mentioned. Trying to connect the steam account on the Account Settings page just redirects back to the forums as if nothing happened.

@johngalt

This comment has been minimized.

Copy link

commented Aug 19, 2016

I think it has something to do with the recent change in the API with \IPS\Http\Url (https://invisionpower.com/release-notes/4114-r49/). It only shows what was changed to contributors, however.

Doing some debugging, I believe the error is within the validate function, probably with the above mentioned API change:

$response = (string)\IPS\Http\Url::external('https://steamcommunity.com/openid/login')->request()->post($params);

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Aug 19, 2016

@johngalt good guess, but in the post referenced in that release note (in the contributor chat), the functions utilized in this plugin, are unaffected.

Rather than a single \IPS\Http\Url class, there are now 3 classes, each of which extends the previous:
\IPS\Http\Url, objects of which are external URLs
\IPS\Http\Url\Internal, objects of which are internal URLs
\IPS\Http\Url\Friendly, objects of which are front-end friendly URLs
You still create objects in the same way (so backwards compatibility is maintained) using ::internal(), ::external(), etc. or there is a new ::createFromString() method to just take a string.

so it's something else, but looking into it.

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Aug 19, 2016

so far determined its authentication issue. Soon™ (lol shouldn't take as long as valve though)

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Aug 20, 2016

Appears that IPS released an update (4.1.14.1) and it was supposed to fix most 3rd party addons.

Version 4.1.14.1: This is a small maintenance update to address issues some clients had with certain URLs. We have also seen clients having issues with many third-party plugins and this update will attempt to better capture those errors.

But on my site, I got no change with the plugin. everything in the plugin /should/ work as nothing is depreciated/removed.

@MStruntze

This comment has been minimized.

Copy link
Author

commented Aug 20, 2016

Updating to the latest version of IPS didn't change anything. Still no error or system logs.

@NightlyDev

This comment has been minimized.

Copy link

commented Aug 21, 2016

It's an \IPS\Http\Url problem (with encoding I think).

Just uploaded the old Url class, renamed the classname to UrlOld and the calls to \IPS\Http\Url into the class to \IPS\Http\UrlOld

Then replaced all the occurences of \IPS\Http\Url to \IPS\Http\UrlOld in the auth.php and Steam.php files.

It's now working.

Dirty hack but "fixed" the issue.

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Aug 21, 2016

@NightlyDev

Just uploaded the old Url class

oh you're talking about reverting the URL Class back to pre 4.1.14.x ;;; hmm. i guess that's a hacky workaround, but still is a IPS issue that needs to be addressed.

@johngalt

This comment has been minimized.

Copy link

commented Aug 24, 2016

@NightlyDev

Mind sending me the old Url class so I can do the same thing?

@MStruntze

This comment has been minimized.

Copy link
Author

commented Aug 26, 2016

They released another update, but the issue seems to persist.

@Pydrex

This comment has been minimized.

Copy link

commented Aug 26, 2016

We can confirm the issue is still happening on the latest update of 4.1.14.2

@ctark

This comment has been minimized.

Copy link

commented Aug 27, 2016

For anyone who wants to use NightlyDev's workaround until the dev is able to resolve this issue, here is an older version of Url.php. Follow his instructions and you should be fine. Make sure you don't overwrite the Url.php that is there, make a new file called Urlold.php

scrubbed

Repository owner locked and limited conversation to collaborators Aug 28, 2016

Repository owner unlocked this conversation Aug 29, 2016

@madman32395 madman32395 removed their assignment Aug 29, 2016

@Lavoaster Lavoaster self-assigned this Aug 29, 2016

@Lavoaster

This comment has been minimized.

Copy link
Owner

commented Aug 29, 2016

Hi All,

In the update IPS pushed out, it contained an updated query parser which broke some of the values in being sent by Steam. This change meant that the plugin was sending wrong values back over to steam's service and steam was unable to verify a valid request was made to login to the system, so it returned false.

A quick fix for this will be to update system\Http\Url.php find line 1064 and replace

$keyAndValue = explode( '=', $part );

with

$keyAndValue = explode( '=', $part, 2 );

---- Diff

-$keyAndValue = explode( '=', $part );
+$keyAndValue = explode( '=', $part, 2 );
@Lavoaster

This comment has been minimized.

@jimjim135

This comment has been minimized.

Copy link

commented Aug 30, 2016

Thanks for the update, Lavoaster.

I've made the changes you've suggested on line 1064 and I'm still experiencing the same result with admin logins. Logging into the forum itself seems to be working, so thank you!

Do you have any further suggestions? Thank you.

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Aug 30, 2016

Can confirm what @jimjim135 said.

@aStonedPenguin

This comment has been minimized.

Copy link
Contributor

commented Aug 31, 2016

@Lavoaster Doesn't seem to fix the issue on PHP7

@NightlyDev or @ctark Could you re-post post the old Url class?

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Aug 31, 2016

@aStonedPenguin

This comment has been minimized.

Copy link
Contributor

commented Sep 1, 2016

Anyone who needs it can find the old url class here: scrubbed

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Sep 1, 2016

Upon doing lavo's fix, and reverting any changes made by previous "workarounds". it should work to login to the suite on the frontend.

also just a heads up distributing the oldclass (or any part of the suite) is against IPS's SOS anyway.

@Master96Pro

This comment has been minimized.

Copy link

commented Sep 1, 2016

@jimjim135 same problem here. I can't sign in on the cp through steam :(

@MrEichi

This comment has been minimized.

Copy link

commented Sep 5, 2016

Can confirm that lavos fix in the URL class solves it. GG IPS Team :(

@Nesyth

This comment has been minimized.

Copy link

commented Sep 16, 2016

Updating to the newest beta version of 4.1.15 fixes the issue.

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Sep 16, 2016

This was found to be an issue with IPS, caused by IPS. It will be released in 4.1.15, but you can do the fix lavo mentioned which is in 'system\Http\Url.php' Line 1064 replace,

$keyAndValue = explode( '=', $part );
with
$keyAndValue = explode( '=', $part, 2 );

@Celant

This comment has been minimized.

Copy link

commented Sep 17, 2016

Hey @madman32395 we're still seeing issues. We've applied the hotfix that lavo mentioned which worked perfect for the website front-end.

Our issue now is the admincp. Still getting "Something went wrong. Please try again." when attempting to login with Steam via the AdminCP. Any ideas?

Happy to provide a phpinfo(); dump if needed.

@deathward4

This comment has been minimized.

Copy link

commented Sep 25, 2016

Can also confirm I'm getting the same "Please try again" Error when trying to login to AdminCP after the hotfix.

@zpv

This comment has been minimized.

Copy link

commented Sep 30, 2016

I am still receiving this same error. I have reinstalled the plugin multiple times.
I am running IPB v4.1.15 on nginx PHP 7.0.

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Oct 2, 2016

Since NGnix seems to be a popular server configuration, has anyone made sure their rewrites are done correctly? I primarily work with Apache, so I am not sure how your rewrites work. I use apache on windows, and another client uses a linux apache. Both works, and I know our rewrites are different, but both use what IPS recommends for rewrite policy.

But as of 4.1.15, this issue is fixed.

@zpv

This comment has been minimized.

Copy link

commented Oct 2, 2016

Even with Friendly URLs and rewrites disabled, the issue is still occurring. I am running the latest versions of both IPB w/ unmodified Url.php and the plugin.

@jackwickham

This comment has been minimized.

Copy link

commented Oct 2, 2016

It works correctly on 4.1.15 on PHP7 and nginx for me, tunneling the request directly to PHP without rewriting the (friendly) url.

@Aszune

This comment has been minimized.

Copy link

commented Oct 3, 2016

I have Nginx and PHP 5.6, with IPS 4.1.15, I have the same issue @Flumadiddle
The same error, when steam redirect to my forum, I see error message, and the account not linked.

"Something went wrong. Please try again"

What configuration have you @stormdr1ve ?

@madman32395

This comment has been minimized.

Copy link
Collaborator

commented Oct 3, 2016

are you guys using the version available here or the one from the IPS Marketplace? Try uploading the one from the marketplace and see if that helps.

@Aszune

This comment has been minimized.

Copy link

commented Oct 3, 2016

I download and using the plugin from Marketplace @madman32395

@Lavoaster

This comment has been minimized.

Copy link
Owner

commented Oct 3, 2016

Anyone trying to use ACP authentication, can you download this and replace the file at system\Login\Steam.php

@zpv

This comment has been minimized.

Copy link

commented Oct 4, 2016

@madman32395
Looks like you were right! The nginx rewrites I had configured were not taking care of query strings correctly. I fixed them and the plugin is now working properly.

Old rewrite rules:

        location / {
            try_files  $uri $uri/ /index.php;
        }
        location ~^(/page/).*(.php)$ {
            try_files  $uri $uri/ /index.php;
        }

New rewrite rules:

        location / {
            try_files $uri $uri/ /index.php?$args;
        }
@deathward4

This comment has been minimized.

Copy link

commented Oct 4, 2016

The updated Steam.php file worked. AdminCP is accessible now.

You're wonderful.

@Aszune

This comment has been minimized.

Copy link

commented Oct 6, 2016

Thank you @Flumadiddle, I apply new rewrite rules, u posted here, and now works for me!

@Lavoaster Lavoaster closed this Oct 8, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.