[php-src] PR #23329: session: fix create_sid()/validateId() check depending on interface order
| From: | lazerg | Date: | Mon, 17 Aug 2026 09:50:45 +0000 |
| Subject: | [php-src] PR #23329: session: fix create_sid()/validateId() check depending on interface order | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-37941@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/23329
Author: lazerg
session_handler_interface_gets_implemented() runs while
SessionHandlerInterface is being attached to the class, so
class->function_table only holds what the class itself declares. Interfaces listed
after it have not contributed their abstract methods yet, which is why the warning fires or not
depending on the order of the implements list.
The check now also looks at the interface list, which zend_do_implement_interfaces()
fills in before it starts calling the handlers. That covers sibling interfaces extending
SessionIdInterface or SessionUpdateTimestampHandlerInterface too.
Closes #23328