XEVE-19-001, XEVE-19-003, XEVE-19-006

xpressengine/xe-core@18ec8078eb
This commit is contained in:
Kijin Sung 2019-05-04 17:36:41 +09:00
parent 880ae97e31
commit 70108f858d
9 changed files with 86 additions and 25 deletions

View file

@ -287,12 +287,12 @@ class commentItem extends BaseObject
return;
}
if(strncasecmp('http://', $url, 7) !== 0)
if(!preg_match('@^[a-z]+://@i', $url))
{
$url = "http://" . $url;
$url = 'http://' . $url;
}
return htmlspecialchars($url, ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
return escape($url, false);
}
function getMemberSrl()
@ -302,17 +302,17 @@ class commentItem extends BaseObject
function getUserID()
{
return htmlspecialchars($this->get('user_id'), ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
return escape($this->get('user_id'), false);
}
function getUserName()
{
return htmlspecialchars($this->get('user_name'), ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
return escape($this->get('user_name'), false);
}
function getNickName()
{
return htmlspecialchars($this->get('nick_name'), ENT_COMPAT | ENT_HTML401, 'UTF-8', false);
return escape($this->get('nick_name'), false);
}
function getVote()