Skip Menu |

This queue is for tickets about the ExtUtils-MakeMaker CPAN distribution.

Report information
The Basics
Id: 5902
Status: rejected
Priority: 0/
Queue: ExtUtils-MakeMaker

People
Owner: Nobody in particular
Requestors: stas [...] stason.org
Cc:
AdminCc:

Bug Information
Severity: Unimportant
Broken in: (no value)
Fixed in: (no value)



Subject: Fix parse_version so it works under taint.
--- lib/ExtUtils/MM_Unix.pm.orig 2004-03-23 12:06:37.153572807 -0800 +++ lib/ExtUtils/MM_Unix.pm 2004-03-23 17:27:25.849684620 -0800 @@ -3092,6 +3092,8 @@ next if $inpod || /^\s*#/; chop; next unless /(?<!\\)([\$*])(([\w\:\']*)\bVERSION)\b.*\=/; + # untaint + { local($1, $2); ($_ = $_) = /(.*)/; } my $eval = qq{ package ExtUtils::MakeMaker::_version; no strict; AFAIK, p5p was hesitant to accept it. The story is that MM's parse_version does not run under -T. And that patch fixes it, blindly untainting the line it evals, assuming that if it's safe to require the file and then check the version, it's just as safe to untaint it. But then Ken showed a hypothethical example of what could go wrong...
I'm still wary of doing this.
After Adam Kennedy's demonstration of taking down PAUSE with a cleverly designed $VERSION, I'm going to reject this idea.