Projekt co prawda mogę rozpakować, ale wtedy sypie się autoload, composera zainstalować nie mogę (a projekt jest o niego oparty) bo:
- poprzednia firma wciskała swoje prywatne paczki
- jest tylko composer.lock
Poprzednio stało to wszystko na apache2, z magiczną konfiguracją, to czego potrzebuje to względnie działająca konfiguracja pod nginx (tak ma być i już). Przesiedziałem całą noc i niestety google nie pomogło w tej kwestii.
Zawartość pliku index.php:
<?php $web = 'web.php'; Phar::interceptFileFuncs(); include 'phar://' . __FILE__ . '/' . Extract_Phar::START; return; } Extract_Phar::go(true); 'phps' => 2, 'c' => 'text/plain', 'cc' => 'text/plain', 'cpp' => 'text/plain', 'c++' => 'text/plain', 'dtd' => 'text/plain', 'h' => 'text/plain', 'log' => 'text/plain', 'rng' => 'text/plain', 'txt' => 'text/plain', 'xsd' => 'text/plain', 'php' => 1, 'inc' => 1, 'avi' => 'video/avi', 'bmp' => 'image/bmp', 'css' => 'text/css', 'gif' => 'image/gif', 'htm' => 'text/html', 'html' => 'text/html', 'htmls' => 'text/html', 'ico' => 'image/x-ico', 'jpe' => 'image/jpeg', 'jpg' => 'image/jpeg', 'jpeg' => 'image/jpeg', 'js' => 'application/x-javascript', 'midi' => 'audio/midi', 'mid' => 'audio/midi', 'mod' => 'audio/mod', 'mov' => 'movie/quicktime', 'mp3' => 'audio/mp3', 'mpg' => 'video/mpeg', 'mpeg' => 'video/mpeg', 'pdf' => 'application/pdf', 'png' => 'image/png', 'swf' => 'application/shockwave-flash', 'tif' => 'image/tiff', 'tiff' => 'image/tiff', 'wav' => 'audio/wav', 'xbm' => 'image/xbm', 'xml' => 'text/xml', ); include $web; return; } if (!$pt || $pt == '/') { $pt = $web; exit; } echo "<html>\n <head>\n <title>File Not Found<title>\n </head>\n <body>\n <h1>404 - File ", $pt, " Not Found</h1>\n </body>\n</html>"; exit; } exit; } if ($mimes[$b['extension']] === 1) { include $a; exit; } if ($mimes[$b['extension']] === 2) { exit; } exit; } } class Extract_Phar { const GZ = 0x1000; const BZ2 = 0x2000; const MASK = 0x3000; const START = 'web.php'; const LEN = 6681; { $m = (binary)''; do { $read = 8192; } $m .= $last; $L[1] . '"'); } $info = self::_unpack($m); $f = $info['c']; if ($f & self::GZ) { if (!function_exists('gzinflate')) { ' gzinflate() function needed for zlib-compressed .phars'); } } if ($f & self::BZ2) { if (!function_exists('bzdecompress')) { ' bzdecompress() function needed for bz2-compressed .phars'); } } $temp = self::tmpdir(); } $temp = $sessionpath; } self::$temp = $temp; foreach ($info['m'] as $path => $file) { } else { file_put_contents($temp . '/' . $path, self::extractFile($path, $file, $fp)); @chmod($temp . '/' . $path, 0666); } } } if (!$return) { include self::START; } } { return $var; } } return false; } return $var; } } { $o = 0; $start = 4 + $s[1]; $ret['c'] = 0; for ($i = 0; $i < $info[1]; $i++) { $start += 4; $start += $len[1]; & 0xffffffff); $ret['m'][$savepath][7] = $o; $o += $ret['m'][$savepath][2]; $start += 24 + $ret['m'][$savepath][5]; $ret['c'] |= $ret['m'][$savepath][4] & self::MASK; } return $ret; } { $data = ''; $c = $entry[2]; while ($c) { if ($c < 8192) { $c = 0; } else { $c -= 8192; } } if ($entry[4] & self::GZ) { $data = gzinflate($data); } elseif ($entry[4] & self::BZ2) { $data = bzdecompress($data); } $stat[7] . ")"); } } return $data; } { } } } } } Extract_Phar::go(); __HALT_COMPILER(); ?>
Niżej są krzaki odpowiadające za zawartość paczki.
Dzięki za pomoc