"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "Kernel/Modules/PictureUpload.pm" between
otrs-5.0.39.tar.bz2 and otrs-5.0.40.tar.bz2

About: OTRS (formerly "Open Ticket Request System" now "Open Technology – Real Service") is a web-based ticketing systems used for Customer Service, Help Desk, IT Service Management. 5.x release ("Community Edition").

PictureUpload.pm  (otrs-5.0.39.tar.bz2):PictureUpload.pm  (otrs-5.0.40.tar.bz2)
skipping to change at line 88 skipping to change at line 88
}, },
); );
return $LayoutObject->Attachment( return $LayoutObject->Attachment(
ContentType => 'text/html; charset=' . $Charset, ContentType => 'text/html; charset=' . $Charset,
Content => $LayoutObject->Output( TemplateFile => 'Pictu reUpload' ), Content => $LayoutObject->Output( TemplateFile => 'Pictu reUpload' ),
Type => 'inline', Type => 'inline',
NoCache => 1, NoCache => 1,
); );
} }
if ( $Attachment->{ContentType} =~ /xml/i ) {
# Strip out file content first, escaping script tag.
my %SafetyCheckResult = $Kernel::OM->Get('Kernel::System::HTMLUt
ils')->Safety(
String => $Attachment->{Content},
NoApplet => 1,
NoObject => 1,
NoEmbed => 1,
NoSVG => 0,
NoIntSrcLoad => 0,
NoExtSrcLoad => 0,
NoJavaScript => 1,
Debug => $Self->{Debug},
);
$Attachment->{Content} = $SafetyCheckResult{String};
}
return $LayoutObject->Attachment( return $LayoutObject->Attachment(
Type => 'inline', Type => 'inline',
%{$Attachment}, %{$Attachment},
); );
} }
} }
# get uploaded file # get uploaded file
my %File = $ParamObject->GetUploadAll( my %File = $ParamObject->GetUploadAll(
Param => 'upload', Param => 'upload',
skipping to change at line 132 skipping to change at line 150
}, },
); );
return $LayoutObject->Attachment( return $LayoutObject->Attachment(
ContentType => 'text/html; charset=' . $Charset, ContentType => 'text/html; charset=' . $Charset,
Content => $LayoutObject->Output( TemplateFile => 'PictureUpload ' ), Content => $LayoutObject->Output( TemplateFile => 'PictureUpload ' ),
Type => 'inline', Type => 'inline',
NoCache => 1, NoCache => 1,
); );
} }
if ( $File{ContentType} =~ /xml/i ) {
# Strip out file content first, escaping script tag.
my %SafetyCheckResult = $Kernel::OM->Get('Kernel::System::HTMLUtils')->S
afety(
String => $File{Content},
NoApplet => 1,
NoObject => 1,
NoEmbed => 1,
NoSVG => 0,
NoIntSrcLoad => 0,
NoExtSrcLoad => 0,
NoJavaScript => 1,
Debug => $Self->{Debug},
);
$File{Content} = $SafetyCheckResult{String};
}
# check if name already exists # check if name already exists
my @AttachmentMeta = $UploadCacheObject->FormIDGetAllFilesMeta( my @AttachmentMeta = $UploadCacheObject->FormIDGetAllFilesMeta(
FormID => $FormID, FormID => $FormID,
); );
my $FilenameTmp = $File{Filename}; my $FilenameTmp = $File{Filename};
my $SuffixTmp = 0; my $SuffixTmp = 0;
my $UniqueFilename = ''; my $UniqueFilename = '';
while ( !$UniqueFilename ) { while ( !$UniqueFilename ) {
$UniqueFilename = $FilenameTmp; $UniqueFilename = $FilenameTmp;
NEWNAME: NEWNAME:
 End of changes. 2 change blocks. 
0 lines changed or deleted 38 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)