Issue 50533 - verify system pathes, so "not allowed values" cant make trouble
Summary: verify system pathes, so "not allowed values" cant make trouble
Alias: None
Product: General
Classification: Code
Component: code (show other issues)
Version: current
Hardware: All All
: P3 Trivial (vote)
Target Milestone: AOO Later
Assignee: AOO issues mailing list
QA Contact:
Depends on:
Reported: 2005-06-09 13:24 UTC by andreas.schluens
Modified: 2013-02-07 21:54 UTC (History)
1 user (show)

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


Note You need to log in before you can comment on or make changes to this issue.
Description andreas.schluens 2005-06-09 13:24:25 UTC
See the corresponding sub tasks. They show some problems which can occure if 
you are able to use "anything you like" inside e.g. a SaveAs dialog as file name.

We should restrict these in a platform dependend way. Because the list of allowed 
values within a file name is different e.g. between windows and linux.

AS->JSK: Please provide a list of all keywords, letters etcpp, which can make 
trouble by using it inside file names. Then send this task to MMP.

AS->MMP: Please specify the handling in case the user typed in such "non 
acceptable" keywords and letters. Then send this task to HRO.

AS->HRO: Please provide the new functionality inside OSL so it can be used by 
the file content provider. If needed please send this task to ABI, so he can make 
the needed changes inside its file UCP. Or send this task to me, so I can 
implement the error handling inside the file save dialog.
Comment 1 joerg.skottke 2005-07-26 14:00:00 UTC
setting started.
Comment 2 joerg.skottke 2005-07-26 14:27:44 UTC
Most restrictive platform is windows due to its DOS heritage. So let's start there:

Reserved names are:
COM1 ... COM9 (with or without suffix)
LPT1 ... LPT9 (with or without suffix)

Forbidden ASCII characters are
0 ... 31 (\,/,:,*,?,",<,>,| ...)

- no . as first letter
- not more than one . 
- no . as last letter

Sparc and linux:
Are not restrictive at all. Almost any character and filename can be used, if
necessary by "escaping" them. /dev/nul is a bad place to store files. However,
there may be constraints set by the filesystem used. Using ASCII 0 ... 31 is
always a bad idea, we might want to prohibit that.

All OSes:
- maximum filename length is 255 chars

There is a document on the net that might give additional insight:
http://www.portfoliofaq/pfaq/FAQ00352.htm. The document takes into account that
there might be problems with network shares as well regarding the characters

Issues to consider:
- not all characters can be entered into our filesave-dialog (escaping is not
- BASIC has no means to protect the user against doing strange things. It allows
any character BASIC knows about by building filenames using CHR$(ASCII DEC
CHAR). Same for any other programming language. 
- we must pay attention to situations where a filename gets converted to
something else (in the past we converted names like "a%20b" to "a b" which
turned the entries in the picklist invalid). I don't know if this still applies.
- probably not all characters can be displayed in our file-open dialog (tab,
vertical tab etc.) but we should leave that aside for now. Please add it to the
spec anyway.

JSK->MMP: Is this good enough for you to work with or do you need more info?
Comment 3 matthias.mueller-prove 2009-09-06 10:04:16 UTC
I am no longer officially active on OOo. Please take over.