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

[TwitterBridge] increase guest token expiry time #2374

Merged
merged 2 commits into from
Dec 18, 2021
Merged

[TwitterBridge] increase guest token expiry time #2374

merged 2 commits into from
Dec 18, 2021

Conversation

triatic
Copy link
Contributor

@triatic triatic commented Dec 15, 2021

An attempt to mitigate #2366 . In my own tests the guest token does not expire for two hours.

An attempt to mitigate #2366 . In my own tests the guest token does not expire for two hours.
@em92
Copy link
Contributor

em92 commented Dec 16, 2021

Applied patch on my public instance. If everything is ok, I will merge this

@triatic
Copy link
Contributor Author

triatic commented Dec 16, 2021

I am still receiving the error periodically, but at least this edit will reduce the frequency of fetching the guest token.

@triatic
Copy link
Contributor Author

triatic commented Dec 17, 2021

Further testing reveals 3 hours is a safe expiry time.

@triatic
Copy link
Contributor Author

triatic commented Dec 17, 2021

I should add that it would be useful to get some testing on busier or quieter Twitter bridges as I am only hitting Twitter about 100 times every three hours. Therefore I can't really know whether I'm hitting the 3hr time limit or the 100 "uses per token" limit.

It might be that one or the other of those limits could be further increased.

@em92 em92 merged commit 35930ee into RSS-Bridge:master Dec 18, 2021
@em92
Copy link
Contributor

em92 commented Dec 18, 2021

Checked this:

$ curl https://twitter.com | grep "gt="
})();</script><script nonce="OGU3OWQ4YmQtZDk2NS00ODJmLWI0MDMtMzRkMjk5ODEzYzA4">document.cookie = decodeURIComponent("gt=1472142906081349637; Max-Age=10800; Domain=.twitter.com; Path=/; Secure");</script>

That guest token for real expires in 3 hours.

The "100 token uses" is the other issue to deal with.

Good job!

@triatic
Copy link
Contributor Author

triatic commented Dec 18, 2021

Ah, checking the cookie expiry would have been a lot easier than the trial and error I was doing!

@triatic triatic deleted the patch-6 branch June 16, 2022 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants