simplesamlphp / simplesamlphp/simplesamlphp-module-consentadmin
It breaks when regex type in `consent.disable` exists
未关闭
还没有人认领这个 Issue。
- 主要语言
- PHP
- 星标
- 4
- 派生
- 1
- PR 合并指标
- 30 天内没有已合并 PR
描述
When you have ['type' => 'regex', 'pattern' => '/.*\.mycompany\.com.*/i'], in consent.disable variable in config breaks the module.
The relevant line: https://github.com/simplesamlphp/simplesamlphp-module-consentadmin/blob/799cc2096c379a29fc90d1cd711e29718955a224/src/Controller/ConsentAdmin.php#L206
There is no type check for $disable variable.
// Remove services, whitch have consent disabled
if (isset($idp_metadata['consent.disable'])) {
foreach ($idp_metadata['consent.disable'] as $disable) {
if (array_key_exists($disable, $all_sp_metadata)) {
unset($all_sp_metadata[$disable]);
}
}
}
贡献指南
这个仓库没有索引到贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从 src/Controller/ConsentAdmin.php 中链接的行开始,检查每个 consent.disable 条目包含所示 regex 配置时是如何处理的。使用该配置复现故障,然后验证模块不再出错,并且预期的服务过滤仍然有效。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- php
- 领域
- backend
- Issue 类型
- 缺陷
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100