xref: /PHP-7.4/ext/pcre/tests/bug70345.phpt (revision 661bce47)
1--TEST--
2Bug #70345 (Multiple vulnerabilities related to PCRE functions)
3--FILE--
4<?php
5$regex = '/(?=xyz\K)/';
6$subject = "aaaaxyzaaaa";
7
8var_dump(preg_split($regex, $subject));
9
10$regex = '/(a(?=xyz\K))/';
11$subject = "aaaaxyzaaaa";
12preg_match($regex, $subject, $matches);
13
14var_dump($matches);
15--EXPECTF--
16bool(false)
17
18Warning: preg_match(): Get subpatterns list failed in %s on line %d
19array(0) {
20}
21