FIX: Untaint the $safename var in unpack7zip

Prevent the taint error in open when the file is encrypted.
This commit is contained in:
Andrew Colin Kissa 2018-02-23 09:40:43 +02:00
parent c0dc8d8025
commit 86cde73a97
No known key found for this signature in database
GPG key ID: EA9171E4333F2952

View file

@ -3189,6 +3189,8 @@ sub Unpack7zip {
$nopathname = $name;
$nopathname =~ s/^.*\///;
$safename = $this->MakeNameSafe('r'.$nopathname,$explodeinto);
$safename =~ m|(.*)|;
$safename = $1;
$NameTwo = $safename;
$NameTwo = $1 if $NameTwo =~ /([^\/]+)$/;
#MailScanner::Log::InfoLog("UnPackRar: Member : %s", $member);