develooper Front page | perl.perl5.porters | Postings from March 2006

[perl #38473] Regexp Bus error

From:
Steve Peters via RT
Date:
March 29, 2006 10:36
Subject:
[perl #38473] Regexp Bus error
Message ID:
rt-3.0.11-38473-131671.19.4127529505107@perl.org
> [kanashimi - Thu Feb 09 01:48:15 2006]:
> 
> This is a bug report for perl from kanashimi@meicho.com.tw,
> generated with the help of perlbug 1.35 running under perl v5.8.7.
> 
> 
> -----------------------------------------------------------------
> [Please enter your report here]
> 
> The following command causes Bus error:
> 
> $a='211.12.23.11 - - [07/Feb/2006:19:09:58 +0800] TLSv1 DHE-RSA-
>    AES256-SHA "GET /'.'X'x(5678).'" 414 250 "-" "-"';
> $a=~/^([\d\.]+|[\:\da-h]+) (-|\w+) (-|\w+) (\[[^\]]+\]) ([\w\d-]+)
>    ([\w\d-]+) "(([^\\"]|\\.)*)" (-|\d+) (-|\d+) "(([^\\"]|\\.)*)"
>    "(([^\\"]|\\.)*)"$/;
> 
> This test was minimized from a program to analysis httpd log file.
> 
> In my machine(at FreeBSD 6.1-PRERELEASE), 5678 can be reduced to 4822.
> 

This problem has been resolved with change #27598.

steve@kirk:~/smoke/perl-current$ perl rt_38473.pl
Segmentation fault (core dumped)
steve@kirk:~/smoke/perl-current$ ./perl rt_38473.pl
steve@kirk:~/smoke/perl-current$ cat rt_38473.pl
#!perl -w

$a='211.12.23.11 - - [07/Feb/2006:19:09:58 +0800] TLSv1
DHE-RSA-AES256-SHA "GET /'.'X'x(5678).'" 414 250 "-" "-"';
$a=~/^([\d\.]+|[\:\da-h]+) (-|\w+) (-|\w+) (\[[^\]]+\]) ([\w\d-]+)
([\w\d-]+) "(([^\\"]|\\.)*)" (- |\d+) (-|\d+) "(([^\\"]|\\.)*)"
"(([^\\"]|\\.)*)"$/;





nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About