安全加固: 用可疑代码模式检测替换有缺陷的反篡改检查#59
Closed
nilm61 wants to merge 1 commit into
Closed
Conversation
- 移除仅检查 Kernel.php 中是否包含字符串 Kernel 的有缺陷检查
- 新增 checkCoreFileIntegrity() 方法,检测以下可疑代码模式:
- eval(base64_decode(...)) 典型 webshell
- file_put_contents(... .php) 文件写入后门
- <meta http-equiv=refresh> 页面跳转劫持
- 混淆变量函数调用 (="eval"; (...))
- 远程文件包含 (include('http://...'))
- 危险的远程文件下载+执行组合
- 发现可疑代码时记录安全日志并返回 HTTP 503 终止执行
修复 CWE-354(完整性校验值验证不当)漏洞
基于 PbootCMS 3.2.15 安全性评估报告
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
问题描述
原代码通过检查
Kernel.php中是否包含字符串"Kernel"来判断文件是否被篡改: