Twitter desktop website is broken after login
Hi,
I have a problem with Twitter website with Firefox 60. After logining in to my twitter account, I'm always getting a page with redirect URL (see the attached screenshot), in every page I'm trying to go on twitter (maybe only the home page working).
If I'm logging out, the website working as usual, and I don't get this redirect page. Also when using the mobile website while logged in in my desktop firefox (mobile.twitter.com), everything working fine.
I tried clearing cache and cookies, but nothing helped. Also used a different browser on same computer and have no issue with the desktop site on other browser.
I think this problem started after I did a "refresh" (reset) to my FF, after it failed to start (I think it was after upgrading to version 59, not sure).
Any suggestions?
Thanks.
Okulungisiwe
All Replies (18)
That screen shot doesn't tell much of what happened to get that.
This shouldn't be turned on after a Refresh, but just in case, please make sure the redirect block is turned off:
(1) In a new tab, type or paste about:config in the address bar and press Enter/Return. Click the button accepting the risk.
(2) In the search box above the list, type or paste access and pause while the list is filtered
(3) If the accessibility.blockautorefresh preference is bolded and "modified" or "user set" to true, double-click it to restore the default value of false
A few other things:
Double-checking content blockers: Firefox's Tracking Protection feature and extensions that counter ads and tracking may break websites that weren't built to operate normally without the blocked components.
Do you see a shield icon toward the left end of the address bar, near the lock icon? More info on managing the Tracking Protection feature in this article: What happened to Tracking Protection?.
Extensions such as Adblock Plus, Blur, Disconnect, Ghostery, NoScript, Privacy Badger, uBlock Origin or uMatrix should provide toolbar buttons to manage blocked content in a page. There may or may not be a number on the icon indicating the number of blocked items; you may need to click the button to see what's going on and test whether you need to make an exception for this site.
Testing in Firefox's Safe Mode: In its Safe Mode, Firefox temporarily deactivates extensions, hardware acceleration, and some other advanced features to help you assess whether these are causing the problem.
If Firefox is not running: Hold down the Shift key when starting Firefox. (On Mac, hold down the option/alt key instead of the Shift key.)
If Firefox is running: You can restart Firefox in Safe Mode using either:
- "3-bar" menu button > "?" Help > Restart with Add-ons Disabled
- (menu bar) Help menu > Restart with Add-ons Disabled
and OK the restart.
Both scenarios: A small dialog should appear. Click "Start in Safe Mode" (not Refresh).
Any improvement?
Clear the Cache and remove the Cookies from websites that cause problems via the "3-bar" Firefox menu button (Options/Preferences).
"Remove the Cookies" from websites that cause problems:
- Options/Preferences -> Privacy & Security
Cookies and Site Data -> Manage Data
"Clear the Cache":
- Options/Preferences -> Privacy & Security
Cookies and Site Data -> Clear Data -> Cached Web Content: Clear
WestEnd said
That screen shot doesn't tell much of what happened to get that.
If I had more information I would probably solved this problem by myself.
jscher2000 said
This shouldn't be turned on after a Refresh, but just in case, please make sure the redirect block is turned off: (1) In a new tab, type or paste about:config in the address bar and press Enter/Return. Click the button accepting the risk. (2) In the search box above the list, type or paste access and pause while the list is filtered (3) If the accessibility.blockautorefresh preference is bolded and "modified" or "user set" to true, double-click it to restore the default value of false
A few other things:
Double-checking content blockers: Firefox's Tracking Protection feature and extensions that counter ads and tracking may break websites that weren't built to operate normally without the blocked components.
Do you see a shield icon toward the left end of the address bar, near the lock icon? More info on managing the Tracking Protection feature in this article: What happened to Tracking Protection?.
Extensions such as Adblock Plus, Blur, Disconnect, Ghostery, NoScript, Privacy Badger, uBlock Origin or uMatrix should provide toolbar buttons to manage blocked content in a page. There may or may not be a number on the icon indicating the number of blocked items; you may need to click the button to see what's going on and test whether you need to make an exception for this site.
Testing in Firefox's Safe Mode: In its Safe Mode, Firefox temporarily deactivates extensions, hardware acceleration, and some other advanced features to help you assess whether these are causing the problem.
If Firefox is not running: Hold down the Shift key when starting Firefox. (On Mac, hold down the option/alt key instead of the Shift key.)
If Firefox is running: You can restart Firefox in Safe Mode using either:
- "3-bar" menu button > "?" Help > Restart with Add-ons Disabled
- (menu bar) Help menu > Restart with Add-ons Disabled
and OK the restart.
Both scenarios: A small dialog should appear. Click "Start in Safe Mode" (not Refresh).
Any improvement?
Nope. The first parameter was set to the default value.
And this problem happens even in safe mode. And no tracking protection.
cor-el said
Clear the Cache and remove the Cookies from websites that cause problems via the "3-bar" Firefox menu button (Options/Preferences). "Remove the Cookies" from websites that cause problems:"Clear the Cache":
- Options/Preferences -> Privacy & Security
Cookies and Site Data -> Manage Data
- Options/Preferences -> Privacy & Security
Cookies and Site Data -> Clear Data -> Cached Web Content: Clear
As I said, I already tried this before, and it's not solving the problem.
Okulungisiwe
Judging from the screenshot, the redirect is done either with a meta refresh tag or with a script. I think we've already covered the reasons that Firefox might not implement those. Do you use any filtering software that might be stripping redirects? Perhaps something in your security software?
jscher2000 said
Judging from the screenshot, the redirect is done either with a meta refresh tag or with a script. I think we've already covered the reasons that Firefox might not implement those. Do you use any filtering software that might be stripping redirects? Perhaps something in your security software?
I don't think the problem is the client side redirecting. Even if I'm clicking "click this link" manually (href=https://twitter.com/<profile>/status/<id>), twitter still re-rendering this redirect page in their server side.
I'm using pi-hole, but I can't see it's blocking anything releated to this. And anyway other browsers on the same machine and the same network are working just fine with the same twitter account.
Okulungisiwe
sha-2 said
I don't think the problem is the client side redirecting. Even if I'm clicking "click this link" manually (href=https://twitter.com/<profile>/status/<id>), twitter still re-rendering this redirect page in their server side.
Oh. Didn't realize that. Hmm.
Is that link overridden by a tracking page -- similar to Google results where the normal link changes to a tracking link (Google's exit script) when you mouse down on the link?
To watch the address progression, you can try the Network Monitor. To open it in the lower part of the tab, you can use either:
- "3-bar" menu button > Web Developer > Network
- (menu bar) Tools > Web Developer > Network
- (Windows) Ctrl+Shift+e
Check the box for "Persists Logs" so that you can retain entries across multiple page loads. (You may turn this off later for situations where you only care about the current page load, to declutter the list.)
When you try the link again, Firefox should start listing all the files it is requesting, along with information about whether the response (e.g. 301 or 302 redirect, or some failure code). For redirects, the "Location" header in the Headers panel on the right side (it opens when you click an item on the list) will show the new address Firefox was given.
jscher2000 said
sha-2 saidI don't think the problem is the client side redirecting. Even if I'm clicking "click this link" manually (href=https://twitter.com/<profile>/status/<id>), twitter still re-rendering this redirect page in their server side.Oh. Didn't realize that. Hmm.
Is that link overridden by a tracking page -- similar to Google results where the normal link changes to a tracking link (Google's exit script) when you mouse down on the link?
To watch the address progression, you can try the Network Monitor. To open it in the lower part of the tab, you can use either:
- "3-bar" menu button > Web Developer > Network
- (menu bar) Tools > Web Developer > Network
- (Windows) Ctrl+Shift+e
Check the box for "Persists Logs" so that you can retain entries across multiple page loads. (You may turn this off later for situations where you only care about the current page load, to declutter the list.)
When you try the link again, Firefox should start listing all the files it is requesting, along with information about whether the response (e.g. 301 or 302 redirect, or some failure code). For redirects, the "Location" header in the Headers panel on the right side (it opens when you click an item on the list) will show the new address Firefox was given.
OK, so the status code is 200 whatsoever, and the request URL is the current tweet URL.
Okulungisiwe
sha-2 said
OK, so the status code is 200 whatsoever, and the request URL is the current tweet URL.
If you compare the address bar, does it show the URL of the previous page, the URL of the destination page, or something else that isn't accounted for in the Network Monitor?
jscher2000 said
sha-2 saidOK, so the status code is 200 whatsoever, and the request URL is the current tweet URL.If you compare the address bar, does it show the URL of the previous page, the URL of the destination page, or something else that isn't accounted for in the Network Monitor?
I don't have previous page. It's always the same URL, the tweet URL that I'm trying to view.
Well it sounds like that overlay or placeholder content is supposed to be replaced by the real content as a result of a script retrieving it in the background. That's speculation -- everything moves too fast for me to see that happening.
I don't know why you get different results when you're logged in vs. not logged in. Perhaps Firefox is hanging up on a background request that is unique to logged in sessions, or stumbling on a script command unique to logged in sessions.
Perhaps there is some setting we're not thinking of related to those processes. There are so many possible customizations...
Could it be permission issue? When you click the green lock in the address bar's site identity area, any customized permissions should be shown in the drop-down. Anything unusual there?
As one way to test whether it could be a setting:
New Profile Test
This takes about 3 minutes, plus the time to test the site.
Inside Firefox, type or paste about:profiles in the address bar and press Enter/Return to load it.
Click the Create a New Profile button, then click Next. Assign a name like July2018, ignore the option to relocate the profile folder, and click the Finish button.
After creating the profile, scroll down to it and click the Set as default profile button below that profile, then scroll back up and click the Restart normally button. (There are some other buttons, but please ignore them.)
Firefox should exit and then start up using the new profile, which will just look brand new. Please ignore any tabs enticing you to connect to a Sync account or to activate extensions found on your system so we can get a clean test.
Does Twitter work any better in the new profile?
When you are done with the experiment, open the about:profiles page again, click the Set as default profile button for your normal profile, then click the Restart normally button to get back to it.
OK, using a new profile is working fine. Now, how can I find the problematic setting?
Okay, now the hard part. To test whether the problem is in the prefs.js file, you could copy it from your regular profile to the new one and see whether the new one starts having the problem.
Open the profile folder of whatever profile you're running in using either
- "3-bar" menu button > "?" Help > Troubleshooting Information
- (menu bar) Help > Troubleshooting Information
- type or paste about:support in the address bar and press Enter
In the first table on the page, on the Profile Folder row, click the "Open Folder" button. This should launch a new window listing various files and folders in Windows Explorer.
The Windows Explorer address bar should show the profile folder name, which has a random part and then the actual name. You can right-click > Copy the prefs.js file in your regular profile folder, then right-click > Paste it into the test profile folder to replace the non-customized one. Note that if you are running in the test profile, you should exit Firefox first before replacing the file.
Can you confirm the problem is something in prefs.js?
jscher2000 said
Okay, now the hard part. To test whether the problem is in the prefs.js file, you could copy it from your regular profile to the new one and see whether the new one starts having the problem. Open the profile folder of whatever profile you're running in using eitherIn the first table on the page, on the Profile Folder row, click the "Open Folder" button. This should launch a new window listing various files and folders in Windows Explorer. The Windows Explorer address bar should show the profile folder name, which has a random part and then the actual name. You can right-click > Copy the prefs.js file in your regular profile folder, then right-click > Paste it into the test profile folder to replace the non-customized one. Note that if you are running in the test profile, you should exit Firefox first before replacing the file. Can you confirm the problem is something in prefs.js?
- "3-bar" menu button > "?" Help > Troubleshooting Information
- (menu bar) Help > Troubleshooting Information
- type or paste about:support in the address bar and press Enter
Yes, the problem is in perfs.js
If you open the about:config page and click the status column, all the "modified" settings should be sorted together. We don't know what we're looking for, so some experimentation is needed. You could try using right-click > Reset on any customizations that start with network. and see whether that makes any difference.
I found the problematic parameter: network.http.sendRefererHeader.
If it set to 0 (Never send the Referer header or set document.referrer), Twitter's desktop site won't work. So I need to choose between better privacy, or operational Twitter. :(
Thanks.
Edit: I found your suggestion to set network.http.referer.XOriginPolicy parameter instead: https://support.mozilla.org/en-US/questions/1130505#answer-895983
Thanks!
Okulungisiwe
sha-2 said
I found the problematic parameter: network.http.sendRefererHeader. If it set to 0 (Never send the Referer header or set document.referrer), Twitter's desktop site won't work. So I need to choose between better privacy, or operational Twitter. :( Thanks. Edit: I found your suggestion to set network.http.referer.XOriginPolicy parameter instead: https://support.mozilla.org/en-US/questions/1130505#answer-895983 Thanks!
Phew, I can't believe that was so hard to track down!
See also "Prefs allowing granular control of referers"