Insecure regexes
Robin Houston [Mon, 7 May 2001 21:56:12 +0000 (22:56 +0100)]
Message-ID: <20010507215612.A31114@penderel>

p4raw-id: //depot/perl@10021

regcomp.c

index da54f96..bf77ee6 100644 (file)
--- a/regcomp.c
+++ b/regcomp.c
@@ -2117,7 +2117,7 @@ S_reg(pTHX_ RExC_state_t *pRExC_state, I32 paren, I32 *flagp)
                        /* No compiled RE interpolated, has runtime
                           components ===> unsafe.  */
                        FAIL("Eval-group not allowed at runtime, use re 'eval'");
-                   if (PL_tainted)
+                   if (PL_tainting && PL_tainted)
                        FAIL("Eval-group in insecure regular expression");
                }