Bug 676547 - Large number of string evals makes interpreter emit syntax error [perl #83364]
Summary: Large number of string evals makes interpreter emit syntax error [perl #83364]
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: perl
Version: 5.8
Hardware: All
OS: All
unspecified
medium
Target Milestone: rc
: ---
Assignee: Marcela Mašláňová
QA Contact: Petr Šplíchal
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-02-10 07:55 UTC by andreas
Modified: 2016-06-01 01:41 UTC (History)
5 users (show)

Fixed In Version: perl-5.8.8-33.el5
Doc Type: Bug Fix
Doc Text:
Cause Large number of string evaluation. Consequence Large number of string evaluation makes interpreter emit syntax error. Fix The variable used within string evaluation had too small value. The upstream patch, which enlarge this value, was backported. Result Large number of string evaluation does not make interpreter emit syntax error.
Clone Of:
Environment:
Last Closed: 2012-02-21 05:40:29 UTC
Target Upstream Version:


Attachments (Terms of Use)
modified patch from maint-5.12 (317 bytes, text/plain)
2011-09-13 08:04 UTC, Marcela Mašláňová
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0199 0 normal SHIPPED_LIVE perl bug fix update 2012-02-20 14:54:01 UTC

Description andreas 2011-02-10 07:55:03 UTC
Description of problem:

Upstream [perl #83364] affects perl 5.8 and perl 5.10 but will only be fixed in 5.12 by perl5-porters.  Reporter requests backport of upstream fix into Redhat perl 5.8 and perl 5.10.

Version-Release number of selected component (if applicable):

Reproduced on perl 5.8.8, 32 and 64 bit (see [1]).

Steps to Reproduce:

Proof of concept code in [1].  Typically takes 2-8 wall clock hours to reproduce.
  
Additional info:

[1] http://rt.perl.org/rt3//Public/Bug/Display.html?id=83364

Comment 1 Marcela Mašláňová 2011-04-13 11:53:18 UTC
Most probably for 5.8.8 will be needed more patches than these. Patches are part of perl-5.13.11.

Comment 2 Marcela Mašláňová 2011-09-13 08:00:10 UTC
It seems to be fixable by patch d1bfb649a8c4cc0b39b0fd6371c009b71c0b497f (maint-5.12). Other patches cleaned the code, but they are not easily applicable on 5.8.x.

As test could be used code:
$ cat eval.pl
use strict;
use warnings;
my $c;

print 'start: ' . scalar localtime();

for ($c = 0; !$@; $c++) {
eval 'my $abc = 1; $abc++; ';
}

print $c . ' ' . $@;
print 'end : ' . scalar localtime();

__END__

Other tests could be found in original report, but sadly it takes few hours to reproduce.

Comment 3 Marcela Mašláňová 2011-09-13 08:04:13 UTC
Created attachment 522868 [details]
modified patch from maint-5.12

Comment 10 Marcela Mašláňová 2011-09-26 07:50:35 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Cause
    Large number of string evaluation.
Consequence
    Large number of string evaluation makes interpreter emit syntax error.
Fix
    The variable used within string evaluation had too small value. The upstream patch, which enlarge this value, was backported.
Result
     Large number of string evaluation does not make interpreter emit syntax error.

Comment 12 errata-xmlrpc 2012-02-21 05:40:29 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2012-0199.html


Note You need to log in before you can comment on or make changes to this bug.