• Модуль: rest
  • Путь к файлу: ~/bitrix/modules/rest/lib/apauth/auth.php
  • Класс: BitrixRestAPAuthAuth
  • Вызов: Auth::getPasswordScope
static function getPasswordScope($passwordId)
{
	if(!array_key_exists($passwordId, static::$scopeCache))
	{
		static::$scopeCache[$passwordId] = array();

		$dbRes = PermissionTable::getList(array(
			'filter' => array(
				'=PASSWORD_ID' => $passwordId,
			),
			'select' => array('PERM')
		));
		while($perm = $dbRes->fetch())
		{
			static::$scopeCache[$passwordId][] = $perm['PERM'];
		}
	}

	return static::$scopeCache[$passwordId];
}