php / php/php-src

phpsessionclean not using settings in {conf_dir}/conf.d/ directory

未关闭
#22,758 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

Bug Status: Needs Triage
主要语言
C
星标
40.4k
派生
8.2k
平均合并
2 天 13 小时
30 天内合并 PR
96

描述

Description

Hi
(debian)
When doing php.ini overrides on my server (this is usally done by putting a 99-settings.ini file inside each /conf.d/ ) the phpsessionclean will not respect those values.

phpsessionclean will keep running on files older than 1440 (which is set in the php.ini file)

gemini says this line should have a ":" after the conf.d/ but i dont have enough expertise to say whether that is right or wrong.
session_config=$(PHP_INI_SCAN_DIR=/etc/php/${version}/${conf_dir}/conf.d/ "/usr/bin/php${version}" -c "/etc/php/${version}/${conf_dir}/php.ini" -d "error_reporting='~E_ALL'" -r 'foreach(ini_get_all("session") as $k => $v) echo "$k=".$v["local_value"]."\n";')

Anyway. this forces me to do my own script override until its fixed.
im not even sure this is a php issue or it is a php-debian package hook issue?

thanks!

PHP Version
tested with

PHP8.5,
PHP8.4,
PHP8.3,
PHP8.2,
PHP8.1,
PHP8.0
Operating System

No response

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从 phpsessionclean 入口点开始,使用所示的 PHP 命令、PHP_INI_SCAN_DIR 以及 Debian 的 /etc/php/{version}/{conf_dir}/ 路径重现该问题。跟踪会话设置的读取方式,并确认 conf.d/ 中的值会被采用;完成的标准是,在列出的所有 PHP 版本中,清理都使用配置的会话生命周期。

由索引模型根据 Issue 内容生成。

评估

技术栈
php
领域
backend
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
冷清
描述清晰度
需要澄清
新手友好度
42/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。