You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Paul Gier (JIRA)" <ji...@codehaus.org> on 2009/05/04 05:15:45 UTC

[jira] Issue Comment Edited: (MANTTASKS-142) Default remote repository id not safe

    [ http://jira.codehaus.org/browse/MANTTASKS-142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=174930#action_174930 ] 

Paul Gier edited comment on MANTTASKS-142 at 5/3/09 10:15 PM:
--------------------------------------------------------------

I'm not sure using the hostname would be a good idea, since not all repository urls have a host name.  For example deploying to the local file system "file:///home/user/stuff".  Also it seems fairly common that two repositories could be on the same hostname.

Maybe the MD5 digest could work though.

When would the repository id be used in a file path that the special characters would blow up? 

      was (Author: pgier):
    I'm not sure using the hostname would be a good idea, since not all repository urls have a host name.  For example deploying to the local file system "file:///home/user/stuff".  Also it seems fairly common that two repositories could be on the hostname.

Maybe the MD5 digest could work though.

When would the repository id be used in a file path that the special characters would blow up? 
  
> Default remote repository id not safe
> -------------------------------------
>
>                 Key: MANTTASKS-142
>                 URL: http://jira.codehaus.org/browse/MANTTASKS-142
>             Project: Maven 2.x Ant Tasks
>          Issue Type: Bug
>          Components: dependencies task
>    Affects Versions: 2.0.9
>            Reporter: Benjamin Bentmann
>            Priority: Minor
>             Fix For: 2.0.10, 2.1.0
>
>
> The default id for a remote repository is just the repo URL. However, a URL typically contains all kind of characters that are not safe for usage in local file paths. E.g. the colon ':' from the URL scheme will just blow up on Windows. The slashes from the URL also cause troubles for a path that is meant to be a simple file name instead of a directory spec.
> Better choices for the default repo id could be the host name only or just some hex-encoded MD5-digest of the URL.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira