[제나플러스] 카테고리에서 특정 글자로 인해 문제 발생시 > 팁앤테크

본문 바로가기

사이트 내 전체검색

뒤로가기 팁앤테크

[제나플러스] 카테고리에서 특정 글자로 인해 문제 발생시

본문

/common.php

if (isset($sca))  {
    $sca = mysql_real_escape_string($sca);
    $sca = stripslashes($sca);
    $qstr .= '&sca=' . urlencode($sca);
}

if (isset($sfl))  {
    $sfl = mysql_real_escape_string($sfl);
    // 크롬에서만 실행되는 XSS 취약점 보완
    // 코드 $sfl 변수값에서 < > ' " % = ( ) 공백 문자를 없앤다.
    $sfl = preg_replace("/[\<\>\'\"\%\=\(\)\s]/", "", $sfl);
    //$sfl = preg_replace("/[^\w\,\|]+/", "", $sfl);
    $qstr .= '&sfl=' . urlencode($sfl); // search field (검색 필드)
}

if (isset($stx))  { // search text (검색어)
    $stx = mysql_real_escape_string($stx);
    $stx = stripslashes($stx);
    $qstr .= '&stx=' . urlencode($stx);
}
추천0

댓글목록 0

등록된 댓글이 없습니다.

전체 285건 1 페이지
게시물 검색
Copyright (c) 株式会社YHPLUS. All rights reserved.

사이트 정보

株式会社YHPLUS / 대표 : ZERO
〒171-0014 東京都豊島区池袋2-41-5 アーバン154 8F
050-5539-7787
오픈카카오톡 (YHPLUS) :
https://open.kakao.com/o/slfDj15d

PC 버전으로 보기