[izpack-devel] bad file names

Klaus Bartz bartzkau at gmx.net
Sat Oct 28 16:56:19 CEST 2006


The behavior was detected at shortcuts, but it exist also at
file level. There the pain is greater as at shortcuts because the
shortcuts can be removed, the file not.
I have tested it as a <singlefile> in a pack where I
use a colon in the target name.
Interesting what's happen if the compile (packaging) will be
performed on unix with such files in the tree. Are then also
<file> and <fileset> affected?
In fact I think it is a problem in the Windows API which accept the
call, but makes really ugly things. I assume that it is a feature,
not a bug :-)
At the next level class java.io.File will be affected. But until jet
I have never send a bug report to java self.

Nice weekend

Klaus

Am 27.10.2006, 18:07 Uhr, schrieb Elmar Grom <elmar at grom.net>:

> This is indeed an ugly thing.
>
> You mention specifically the shortcut as a problem. Is this only an  
> example
> or is it the only place where this behavior actually leads to a problem?  
> If
> it is the only place, then we might be able to come up with a local
> solution. If it is not, then I suspect a modification of File itself  
> might
> not be sufficient, because this problem could also happen with the  
> content
> of the shortcut, not just with the shortcut file...
>
> Perhaps some more analysis is required to find all possible ways in which
> this problem could affect the performance of IzPack.
>
> 	Elmar
>
> -----Original Message-----
> From: izpack-devel-bounces at lists.berlios.de
> [mailto:izpack-devel-bounces at lists.berlios.de]On Behalf Of Bartz, Klaus
> Sent: Friday, October 27, 2006 3:41 AM
> To: izpack-devel at lists.berlios.de
> Subject: [izpack-devel] bad file names
>
>
> Dear colleagues,
> on the user list there was someone which
> uses a name of a shortcut which contained a colon.
> We all know, that this is not allowed on Windows.
> But the API of Windows accept such nonsens
> without any warning or error. I have tested it for
> installed files via <singelfile>. Also no warning
> or error. The result is a file with a name upto the
> colon. The file cannot be opened and not removed.
> Uninstall fails at this point. In the moment I do not
> know how cleanup.
> May be this can cast a damning light on IzPack.
>
> Therefore I am thinking about how we can avoid
> such ugly usage of our product. One way can be to
> inherit File to a class which verifies a valid filename
> OS dependant (it seems so that on Linux such nonsens
> is allowed). There are many constructor calls of
> File, therefore a little bit more work.
> Additional there is the problem if this is not
> used in custom code.
> Any comment?
> Any better solution?
>
> Cheers
>
> Klaus
> _______________________________________________
> izpack-devel mailing list
> izpack-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-devel
>
> _______________________________________________
> izpack-devel mailing list
> izpack-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-devel
>
>
> __________ NOD32 1.1392 (20060202) Information __________
>
> Diese E-Mail wurde vom NOD32 Antivirus System geprüft
> http://www.nod32.com
>
>



-- 
Erstellt mit Operas revolutionärem E-Mail-Modul: http://www.opera.com/mail/



More information about the izpack-devel mailing list