| Current Path : /var/www/homesaver/www/bitrix/modules/main/lib/security/w/rules/ |
| Current File : /var/www/homesaver/www/bitrix/modules/main/lib/security/w/rules/rule.php |
<? namespace Bitrix\Main\Security\W\Rules;$GLOBALS['____581984189']= array(base64_decode('aXN'.'fc3Ry'.'a'.'W5n'),base64_decode('c3RydG9sb3dlcg='.'='),base64_decode('aXNfY'.'X'.'JyYX'.'k='),base64_decode('aXNfc3Rya'.'W5n'),base64_decode(''.'Z3'.'pkZ'.'WNvZGU='),base64_decode('YmF'.'zZ'.'TY0X'.'2RlY'.'29kZQ=='),base64_decode(''.'dX'.'JsZGVjb'.'2Rl'),base64_decode('YXJyY'.'Xl'.'fcm'.'V'.'2ZXJzZQ=='),base64_decode('Z3plbm'.'NvZGU='),base64_decode('Y'.'mFzZTY'.'0X2'.'VuY29kZQ=='),base64_decode('dXJsZW5jb'.'2'.'Rl'),base64_decode('YmluMmhleA=='),base64_decode('a'.'XNfYXJyY'.'X'.'k'.'='),base64_decode('c3Ry'.'dG'.'9sb'.'3dlc'.'g'.'=='),base64_decode('aXNfYXJyYXk'.'='),base64_decode('am9pbg'.'=='),base64_decode(''.'Zm5'.'tYXRjaA=='),base64_decode('cmF'.'3dXJsZGVjb2'.'Rl'),base64_decode('c'.'3Vic'.'3Ry'),base64_decode('c'.'3Vi'.'c3Ry'),base64_decode('c'.'3R'.'yX3JlcG'.'xh'.'Y'.'2U='),base64_decode('cHJlZ19xdW9'.'0Z'.'Q='.'='),base64_decode('cHJlZ1'.'9t'.'YX'.'Rj'.'aA=='));if(!function_exists(__NAMESPACE__.'\\___847817544')){function ___847817544($_1887670779){static $_646491683= false; if($_646491683 == false) $_646491683=array('YWN0a'.'W9u','aW50'.'dmF'.'s','cGF0aA==','Y29u'.'dG'.'V4dA==','a2V5c'.'w='.'=','cHJvY'.'2Vzcw'.'==',''.'Z'.'W'.'5jb2Rpbm'.'c=',''.'cHJlZ'.'19'.'y'.'ZX'.'BsYWN'.'l','cGF0a'.'A==','Y29udG'.'V4d'.'A='.'=','a2V5cw='.'=','cHJ'.'vY2Vz'.'cw==','Z'.'W'.'5jb2Rpbm'.'c=','cG'.'F0dGVybg==','c'.'HJ'.'lZ19tYXRjaA='.'=',''.'c'.'G'.'F'.'0a'.'A==','Y29udGV4dA='.'=','a2V5cw='.'=','cHJ'.'vY2'.'V'.'zcw==',''.'ZW5jb2'.'Rp'.'bmc=','cGF0d'.'GVybg==','cG9z'.'d'.'F9h'.'Y'.'3Rp'.'b'.'24'.'=',''.'Y'.'2hlY2tfY3NyZg==',''.'cGF0aA==',''.'Y29udGV4dA='.'=','a2V5cw==','cHJ'.'vY'.'2Vzc'.'w==','Z'.'W'.'5jb2'.'Rp'.'bmc=','cGF0dGVy'.'b'.'g'.'==','YWN0aW9u','YWN0'.'aW9u','Y'.'WN0a'.'W9u',''.'YWN0'.'aW9'.'u','YWN'.'0aW'.'9u',''.'Y'.'W'.'N0'.'aW9u','cG9z'.'dF9'.'hY3Rpb'.'2'.'4'.'=','ZW5jb2Rpbmc=',''.'ZW5jb2'.'R'.'pbmc=','ZW'.'5'.'j'.'b2R'.'pb'.'m'.'c=',''.'ZW5'.'j'.'b2'.'Rpb'.'m'.'c'.'=',''.'Z'.'W5j'.'b'.'2Rpbmc=','Z'.'W5jb2Rpbmc=','Z3o=',''.'YmFzZTY0',''.'d'.'X'.'Js','aGV'.'4','Lg==','Lw==','aW5kZXg'.'uc'.'G'.'hw','L2luZGV4LnB'.'o'.'cA==',''.'U0N'.'SS'.'VB'.'UX05BTU'.'U=','L2luZ'.'GV'.'4'.'Ln'.'BocA==',''.'U'.'0NSSVB'.'UX'.'05B'.'T'.'U'.'U=','U0NSSVBU'.'X05BTUU'.'=',''.'U0N'.'SSVB'.'UX05BTU'.'U'.'=','fg==',''.'fl4=','fg==',''.'X'.'H4=','J'.'H'.'4=');return base64_decode($_646491683[$_1887670779]);}}; use Bitrix\Main\IO\Path; use Bitrix\Main\Web\Uri; use Bitrix\Main\Security\W\Rules\Results\ModifyResult; abstract class Rule{ protected $_647126711; protected $_609819111; protected $_1018466803; protected $_932540737; protected $_30025486; public static function make(array $_663137182):?static{ $_663137182= static::prepareRuleParameters($_663137182); return match($_663137182[___847817544(0)]){ ___847817544(1) => new IntvalRule( $_663137182[___847817544(2)], $_663137182[___847817544(3)], $_663137182[___847817544(4)], $_663137182[___847817544(5)], $_663137182[___847817544(6)]), ___847817544(7) => new PregReplaceRule( $_663137182[___847817544(8)], $_663137182[___847817544(9)], $_663137182[___847817544(10)], $_663137182[___847817544(11)], $_663137182[___847817544(12)], $_663137182[___847817544(13)]), ___847817544(14) => new PregMatchRule( $_663137182[___847817544(15)], $_663137182[___847817544(16)], $_663137182[___847817544(17)], $_663137182[___847817544(18)], $_663137182[___847817544(19)], $_663137182[___847817544(20)], $_663137182[___847817544(21)]), ___847817544(22) => new CsrfRule( $_663137182[___847817544(23)], $_663137182[___847817544(24)], $_663137182[___847817544(25)], $_663137182[___847817544(26)], $_663137182[___847817544(27)], $_663137182[___847817544(28)],), default => null,};} protected static function prepareRuleParameters(array $_895057098): array{ if($GLOBALS['____581984189'][0]($_895057098[___847817544(29)])){ $_895057098[___847817544(30)]= $GLOBALS['____581984189'][1]($_895057098[___847817544(31)]);} elseif($GLOBALS['____581984189'][2]($_895057098[___847817544(32)])){ $_112497616= $_895057098[___847817544(33)]; $_895057098[___847817544(34)]= $_112497616[(998-2*499)]; $_895057098[___847817544(35)]= $_112497616[round(0+0.2+0.2+0.2+0.2+0.2)];} $_895057098[___847817544(36)]=!empty($_895057098[___847817544(37)])? $_895057098[___847817544(38)]:[]; if($GLOBALS['____581984189'][3]($_895057098[___847817544(39)])){ $_895057098[___847817544(40)]=[$_895057098[___847817544(41)]];} return $_895057098;} public function __construct($_647126711, $_609819111, $_1018466803, $_932540737, $_30025486){ $this->_647126711= $_647126711; $this->_609819111= $this->castContext($_609819111); $this->_1018466803= $this->castKeys($_1018466803); $this->_932540737= $_932540737; $this->_30025486= $_30025486;} public function evaluateValue($_1768736939){ if(!empty($this->_30025486)){ foreach($this->_30025486 as $_905756919){ $_1768736939= match($_905756919){ 'gz' => $GLOBALS['____581984189'][4]($_1768736939), 'base64' => $GLOBALS['____581984189'][5]($_1768736939), 'url' => $GLOBALS['____581984189'][6]($_1768736939), 'hex' => hex2bin($_1768736939)};}} $_1150766460= $this->evaluate($_1768736939); if(!empty($this->_30025486) && $_1150766460 instanceof ModifyResult){ $_141314867= $_1150766460->getCleanValue(); foreach($GLOBALS['____581984189'][7]($this->_30025486) as $_905756919){ $_141314867= match($_905756919){ ___847817544(42) => $GLOBALS['____581984189'][8]($_141314867), ___847817544(43) => $GLOBALS['____581984189'][9]($_141314867), ___847817544(44) => $GLOBALS['____581984189'][10]($_141314867), ___847817544(45) => $GLOBALS['____581984189'][11]($_141314867)};} $_1150766460= new ModifyResult($_141314867);} return $_1150766460;} abstract public function evaluate($_1768736939); protected function castContext($_609819111){ if(!$GLOBALS['____581984189'][12]($_609819111)){ $_609819111=[$_609819111];} foreach($_609819111 as $_1513682098 => $_148601621){ $_609819111[$_1513682098]= $GLOBALS['____581984189'][13]($_148601621);} return $_609819111;} protected function castKeys($_1018466803){ if(!$GLOBALS['____581984189'][14]($_1018466803)){ $_1018466803=[$_1018466803];} return $_1018466803;} public function matchKey(array $_189970465): bool{ $_189970465= $GLOBALS['____581984189'][15](___847817544(46), $_189970465); foreach($this->_1018466803 as $_158228140){ if($GLOBALS['____581984189'][16]($_158228140, $_189970465)){ return true;}} return false;} public function matchPath($_1801740880){ if($this->_647126711 === '*'){ return true;} $_916366884= new Uri($_1801740880); $_1380787035= $_916366884->getPath(); $_1380787035= $GLOBALS['____581984189'][17]($_1380787035); if(str_ends_with($_1380787035, ___847817544(47))){ $_1380787035 .= ___847817544(48);} $_1380787035= Path::normalize($_1380787035); $_1142334710[]= $_1380787035; if(str_ends_with($_1380787035, ___847817544(49))){ $_1142334710[]= $GLOBALS['____581984189'][18]($_1380787035, min(224,0,74.666666666667),-round(0+9));} elseif(str_ends_with($_SERVER[___847817544(50)], ___847817544(51))){ $_1142334710[]= $GLOBALS['____581984189'][19]($_SERVER[___847817544(52)],(138*2-276),-round(0+4.5+4.5));} if($_1380787035 !== $_SERVER[___847817544(53)]){ $_1142334710[]= $_SERVER[___847817544(54)];} if(str_starts_with($this->_647126711, ___847817544(55))){ $_1671790124= $this->_647126711;} else{ $_1671790124= ___847817544(56). $GLOBALS['____581984189'][20](___847817544(57), ___847817544(58), $GLOBALS['____581984189'][21]($this->_647126711)). ___847817544(59);} foreach($_1142334710 as $_2075565392){ if($this->_647126711 === $_2075565392 || $GLOBALS['____581984189'][22]($_1671790124, $_2075565392)){ return true;}} return false;} public function getPath(){ return $this->_647126711;} public function getContext(){ return $this->_609819111;} public function getKeys(){ return $this->_1018466803;} public function getProcess(){ return $this->_932540737;}}?>