선택적 세션 시작 + 서드파티 자료 호환성 (Proof of Concept)

This commit is contained in:
Kijin Sung 2015-07-10 16:05:46 +09:00
parent 6745497ad7
commit 23a83a7033
5 changed files with 88 additions and 18 deletions

View file

@ -391,7 +391,10 @@ class documentItem extends Object
if($this->isSecret() && !$this->isGranted() && !$this->isAccessible()) return Context::getLang('msg_is_secret');
$result = $this->_checkAccessibleFromStatus();
if($result) $_SESSION['accessible'][$this->document_srl] = true;
if($result && Context::getInstance()->isSessionStarted)
{
$_SESSION['accessible'][$this->document_srl] = true;
}
$content = $this->get('content');
$content = preg_replace_callback('/<(object|param|embed)[^>]*/is', array($this, '_checkAllowScriptAccess'), $content);
@ -452,7 +455,10 @@ class documentItem extends Object
if($this->isSecret() && !$this->isGranted() && !$this->isAccessible()) return Context::getLang('msg_is_secret');
$result = $this->_checkAccessibleFromStatus();
if($result) $_SESSION['accessible'][$this->document_srl] = true;
if($result && Context::getInstance()->isSessionStarted)
{
$_SESSION['accessible'][$this->document_srl] = true;
}
$content = $this->get('content');
if(!$stripEmbedTagException) stripEmbedTagForAdmin($content, $this->get('member_srl'));