summaryrefslogtreecommitdiff
path: root/ext/phar/tests/bug72928.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/phar/tests/bug72928.phpt')
-rw-r--r--ext/phar/tests/bug72928.phpt18
1 files changed, 18 insertions, 0 deletions
diff --git a/ext/phar/tests/bug72928.phpt b/ext/phar/tests/bug72928.phpt
new file mode 100644
index 0000000000..8e6a95418c
--- /dev/null
+++ b/ext/phar/tests/bug72928.phpt
@@ -0,0 +1,18 @@
+--TEST--
+Phar: #72928 (Out of bound when verify signature of zip phar in phar_parse_zipfile)
+--SKIPIF--
+<?php if (!extension_loaded("phar")) die("skip"); ?>
+--FILE--
+<?php
+chdir(__DIR__);
+try {
+$phar = new PharData('bug72928.zip');
+var_dump($phar);
+} catch(UnexpectedValueException $e) {
+ print $e->getMessage()."\n";
+}
+?>
+DONE
+--EXPECTF--
+phar error: signature cannot be read in zip-based phar "%sbug72928.zip"
+DONE \ No newline at end of file