Issue 68848 - Function "SaveDataToFile" in Basic library "Tools" is unsafe
Summary: Function "SaveDataToFile" in Basic library "Tools" is unsafe
Status: CONFIRMED
Alias: None
Product: App Dev
Classification: Unclassified
Component: scripting (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: All All
: P3 Trivial
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-22 10:02 UTC by berend.cornelius
Modified: 2017-05-20 11:27 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description berend.cornelius 2006-08-22 10:02:29 UTC
The following code within the function "SaveDataToFile" is potentially dangerous:

[......]
	oUcb = createUnoService("com.sun.star.ucb.SimpleFileAccess")
	oOutputStream = createUnoService("com.sun.star.io.TextOutputStream")
	If oUcb.Exists(FilePath) Then
		oUcb.Kill(FilePath)
	End If
[......]
It is not checked whether  the passed Url represents a directory as to be done with
oUcb.IsFolder(FilePath).
Comment 1 nospam 2008-03-28 16:25:01 UTC
.
Comment 2 Marcus 2017-05-20 11:27:30 UTC
Reset assigne to the default "issues@openoffice.apache.org".