1
0
mirror of https://github.com/php/php-src.git synced 2026-04-29 19:23:22 +02:00
Files
archived-php-src/ext/phar/tests/zip/zlib.phpt
T
Christoph M. Becker 9f96b2bdc8 Fix #76929: zip-based phar does not respect phar.require_hash
Based on the patch provided by david at bamsoftware.

Closes GH-6517.
2021-01-04 17:48:45 +01:00

19 lines
588 B
PHP

--TEST--
Phar: process zlib-compressed zip alias
--INI--
phar.require_hash=0
--SKIPIF--
<?php if (!extension_loaded("phar")) die("skip"); ?>
<?php if (!extension_loaded("zlib")) die("skip zlib not available"); ?>
--FILE--
<?php
try {
$a = new Phar(__DIR__ . '/files/zlib_alias.phar.zip');
var_dump($a->getAlias());
} catch (Exception $e) {
echo $e->getMessage() . "\n";
}
?>
--EXPECT--
string(175) "hitheresuperlongzipistoostupidtodowhatIsaysoIhavetousethisridiculouslylongaliasbecauseitisstupiddidImentionthatalreadythemadnessdoesnotstopIhateinfozipIhateinfozipIhateinfozip"