Skip to content

Commit

Permalink
최신글 캐시 파일 삭제 취약점 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
thisgun committed Dec 6, 2017
1 parent ea55f38 commit 6bf57bd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/common.lib.php
Expand Up @@ -2137,6 +2137,10 @@ function check_device($device)
// 게시판 최신글 캐시 파일 삭제
function delete_cache_latest($bo_table)
{
if (!preg_match("/^([A-Za-z0-9_]{1,20})$/", $bo_table)) {
return;
}

$files = glob(G5_DATA_PATH.'/cache/latest-'.$bo_table.'-*');
if (is_array($files)) {
foreach ($files as $filename)
Expand Down

0 comments on commit 6bf57bd

Please sign in to comment.