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

PHP 8.3 Session issue? #11601

Closed
RouatbiH opened this issue Jul 5, 2023 · 8 comments
Closed

PHP 8.3 Session issue? #11601

RouatbiH opened this issue Jul 5, 2023 · 8 comments

Comments

@RouatbiH
Copy link

RouatbiH commented Jul 5, 2023

Description

Using PHP 8.2.4 and older with phpMyAdmin 5.2.1 working fine but when i use it with PHP 8.3.0 it gives this php session error
image
and some times this
image

I'm not sure if it's a phpMyAdmin issue or a php issue.

PHP Version

PHP 8.3.0alpha3

Operating System

Windows 10

@nielsdos
Copy link
Member

nielsdos commented Jul 6, 2023

I can reproduce this. I'll run a bisect.

@nielsdos
Copy link
Member

nielsdos commented Jul 6, 2023

First bad commit: b3e33be
cc @iluuu1994

Probably, ext/session was relying on some behaviour that got changed in this commit.

@iluuu1994
Copy link
Member

Weird. I can't immediately think of how this change could cause such an issue. Are you looking into it? If not I will do so.

@nielsdos
Copy link
Member

nielsdos commented Jul 6, 2023

@iluuu1994 I'm not checking it out atm, I'm busy with other stuff :)

@iluuu1994
Copy link
Member

iluuu1994 commented Jul 6, 2023

The problem is that the code doesn't handle the graceful and unwind exit exceptions, I'll check what the best solution is.

@usarise
Copy link
Contributor

usarise commented Jul 6, 2023

@iluuu1994 The code executes, but writes broken data to the session

@usarise
Copy link
Contributor

usarise commented Jul 6, 2023

A key is written to the session without any value data

@iluuu1994
Copy link
Member

iluuu1994 commented Jul 6, 2023

@usarise The issue is in my patch (b3e33be). It's missing the handling of some special exceptions that get thrown when you exit() out of a request. It's catching these when it shouldn't, causing a fatal error and probably not properly closing and writing to the session. I will need to fix that. But thanks for checking. 🙂

iluuu1994 added a commit to iluuu1994/php-src that referenced this issue Jul 6, 2023
These exceptions should not invoke the user error handler.

Fixes phpGH-11601
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants