This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 71043 - Do not resolve symbolic links in path
Summary: Do not resolve symbolic links in path
Status: RESOLVED FIXED
Alias: None
Product: installer
Classification: Unclassified
Component: Code (show other bugs)
Version: 5.x
Hardware: All All
: P2 blocker (vote)
Assignee: Libor Fischmeistr
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-05 14:07 UTC by mslama
Modified: 2013-04-04 14:31 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mslama 2006-01-05 14:07:59 UTC
When user enters path with symbolic link on UNIX anywhere in installer GUI
symbolic links are resolved (File.getAbsolutePath()). Solution is not to use
getAbsolutePath or getCanonicalPath. Instead we could try java.net.URI.normalize
to resolve relative path and remove ../ segments from path.

Eg. /home/user/../user should be resolved to /home/user, ../../user should be
resolved to /home/user.
Comment 1 Jiri Rechtacek 2012-10-07 12:59:08 UTC
Assigned to new owner.
Comment 2 Libor Fischmeistr 2013-02-05 07:45:34 UTC
The useful solution could be done using java.nio.file.Path - normalize()
Comment 3 Libor Fischmeistr 2013-03-28 14:02:48 UTC
First attempt in http://hg.netbeans.org/core-main/rev/232dcb37e51a
Comment 4 Libor Fischmeistr 2013-04-04 14:31:30 UTC
Fixed in changeset: http://hg.netbeans.org/core-main/rev/8354c1b7bfc9