Skip to content
New issue

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

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

Already on GitHub? # to your account

[3.0] Remove PHPSESSID #8399

Open
wants to merge 4 commits into
base: release-3.0
Choose a base branch
from

Conversation

sbulen
Copy link
Contributor

@sbulen sbulen commented Jan 7, 2025

Partial for #8383 (addresses 3.0 only)

This PR removes PHPSESSID URL handling altogether from SMF. It also addresses the 8.4 SID & session parameter deprecation issues, that are related. The point of the 8.4 changes was to eventually remove PHP's PHPSESSID URL processing.

It goes a bit further and will not write sessions where cookies are not present/allowed. I believe this last part can significantly decrease MySQL CPU workload for websites that are getting crawled heavily (like mine).

Testing thus far is fine. Things work OK with & without cookies. No impact to logon/logoff. No impact to queryless URLs. And there are DEFINITELY far fewer session records, that I believe were all unused anyway.

I have a modlet with this code that I have installed in various test environments & tested. It's on my prod site as well.

Loss of functionality:
Removing PHPSESSID from the URL did break one piece of functionality: Guest captcha verification, for searches & posts, specifically for people with cookies blocked. The image is not displayed. It works fine if cookies are not blocked.

I'm tempted to just leave it alone; I suspect folks who disable cookies run into lots of such limitations.

If we want something cleaner, another option would be to not display the search & post (& login) buttons when cookies are not found. Or an error popup, saying cookies are required. Open to feedback.

sbulen added 2 commits January 7, 2025 10:04
Signed by Shawn Bulen, bulens@pacbell.net
Signed by Shawn Bulen, bulens@pacbell.net
@sbulen
Copy link
Contributor Author

sbulen commented Jan 7, 2025

See #8394 for 2.1 version.

Signed by Shawn Bulen, bulens@pacbell.net
Signed by Shawn Bulen, bulens@pacbell.net
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants