mirror of
https://github.com/getrebuild/rebuild.git
synced 2025-09-27 17:15:57 +08:00
Update CommonsUtils.java
This commit is contained in:
parent
1396c8a0dc
commit
fed4f1b2ad
1 changed files with 1 additions and 2 deletions
|
@ -306,8 +306,7 @@ public class CommonsUtils {
|
|||
*/
|
||||
public static void checkFilePathAttack(String filepath) throws SecurityException {
|
||||
if (filepath == null) return;
|
||||
if (filepath.contains(".rebuild") || filepath.contains("../")
|
||||
|| filepath.contains("<") || filepath.contains(">")) {
|
||||
if (filepath.contains("../") || filepath.contains("<") || filepath.contains(">")) {
|
||||
throw new SecurityException("Attack path detected : " + filepath);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue