Uploaded image for project: 'Dev - Nexus Repo'
  1. Dev - Nexus Repo
  2. NEXUS-23235

Unable to upload file containing '@' in the name

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 2.14.16
    • Fix Version/s: None
    • Component/s: Repository
    • Labels:

      Description

      I am trying to upload a site to Nexus2, but every time the upload gets to a file with a '@' in its name, the upload break. Because this file is generated, I can't change the name.

      Initially I tried the upload with curl, since this is not a Maven Project, but to test other options as well, I tried using Maven (with dav) as well.

      My curl command is this:

      find . -type f -exec curl --user <user>:<pass> --ftp-create-dirs -T {} http://<server>/content/sites/<repo>/<project>/{} \;

      Exception I can see in the log is this:

      2020-03-20 18:30:44 WARN [817133444-35724] - org.sonatype.nexus.web.internal.ErrorPageFilter - Unexpected exception
      javax.servlet.ServletException: java.lang.IllegalStateException: Cannot translate request to Nexus action, request: PUT http://<server>/content/sites/<repo>/<project>/assets/images/icons@2x.png
      {{ at org.apache.shiro.web.servlet.AdviceFilter.cleanup(AdviceFilter.java:196)}}
      {{ at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:148)}}
      {{ at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)}}
      {{ at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)}}
      {{ at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108)}}
      {{ at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137)}}
      {{ at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)}}
      {{ at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)}}
      {{ at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108)}}
      {{ at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137)}}
      {{ at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)}}
      {{ at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66)}}
      {{ at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:449)}}
      {{ at org.sonatype.nexus.web.internal.SecurityFilter.executeChain(SecurityFilter.java:90)}}
      {{ at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:365)}}
      {{ at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)}}
      {{ at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)}}
      {{ at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:387)}}
      {{ at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:362)}}
      {{ at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:125)}}
      {{ at com.google.inject.servlet.AbstractFilterPipeline.dispatch(AbstractFilterPipeline.java:100)}}
      {{ at org.sonatype.nexus.web.internal.NexusGuiceFilter$MultiFilterChain.doFilter(NexusGuiceFilter.java:82)}}
      {{ at com.yammer.metrics.web.WebappMetricsFilter.doFilter(WebappMetricsFilter.java:76)}}
      {{ at org.sonatype.nexus.web.internal.CommonHeadersFilter.doFilter(CommonHeadersFilter.java:69)}}
      {{ at org.sonatype.nexus.web.internal.ErrorPageFilter.doFilter(ErrorPageFilter.java:71)}}
      {{ at org.sonatype.nexus.web.internal.BaseUrlHolderFilter.doFilter(BaseUrlHolderFilter.java:66)}}
      {{ at org.sonatype.nexus.web.internal.HeaderPatternFilter.doFilter(HeaderPatternFilter.java:96)}}
      {{ at com.google.inject.servlet.AbstractFilterPipeline.dispatch(AbstractFilterPipeline.java:100)}}
      {{ at org.sonatype.nexus.web.internal.NexusGuiceFilter$MultiFilterChain.doFilter(NexusGuiceFilter.java:82)}}
      {{ at org.sonatype.nexus.web.internal.NexusGuiceFilter$MultiFilterPipeline.dispatch(NexusGuiceFilter.java:56)}}
      {{ at com.google.inject.servlet.GuiceFilter$1.call(GuiceFilter.java:133)}}
      {{ at com.google.inject.servlet.GuiceFilter$1.call(GuiceFilter.java:130)}}
      {{ at com.google.inject.servlet.GuiceFilter$Context.call(GuiceFilter.java:203)}}
      {{ at com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:130)}}
      {{ at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1476)}}
      {{ at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:501)}}
      {{ at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)}}
      {{ at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557)}}
      {{ at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)}}
      {{ at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)}}
      {{ at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:429)}}
      {{ at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)}}
      {{ at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)}}
      {{ at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)}}
      {{ at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)}}
      {{ at com.yammer.metrics.jetty.InstrumentedHandler.handle(InstrumentedHandler.java:200)}}
      {{ at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:154)}}
      {{ at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)}}
      {{ at org.eclipse.jetty.server.Server.handle(Server.java:370)}}
      {{ at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)}}
      {{ at org.eclipse.jetty.server.AbstractHttpConnection.content(AbstractHttpConnection.java:982)}}
      {{ at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.content(AbstractHttpConnection.java:1043)}}
      {{ at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:865)}}
      {{ at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)}}
      {{ at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)}}
      {{ at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:696)}}
      {{ at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:53)}}
      {{ at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)}}
      {{ at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)}}
      {{ at java.lang.Thread.run(Thread.java:748)}}
      Caused by: java.lang.IllegalStateException: Cannot translate request to Nexus action, request: PUT }}{{http://<server>/content/sites/<repo>/<project>/assets/images/icons@2x.png
      {{ at org.sonatype.nexus.security.filter.authz.NexusTargetMappingAuthorizationFilter.getHttpMethodAction(NexusTargetMappingAuthorizationFilter.java:138)}}
      {{ at org.sonatype.nexus.security.filter.authz.NexusTargetMappingAuthorizationFilter.isAccessAllowed(NexusTargetMappingAuthorizationFilter.java:156)}}
      {{ at org.apache.shiro.web.filter.AccessControlFilter.onPreHandle(AccessControlFilter.java:162)}}
      {{ at org.apache.shiro.web.filter.PathMatchingFilter.isFilterChainContinued(PathMatchingFilter.java:203)}}
      {{ at org.apache.shiro.web.filter.PathMatchingFilter.preHandle(PathMatchingFilter.java:178)}}
      {{ at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:131)}}
      {{ ... 58 common frames omitted}}
      Caused by: java.lang.IndexOutOfBoundsException: No group 2
      {{ at java.util.regex.Matcher.group(Matcher.java:538)}}
      {{ at org.sonatype.nexus.security.filter.authz.NexusTargetMappingAuthorizationFilter.getResourceStorePath(NexusTargetMappingAuthorizationFilter.java:82)}}
      {{ at org.sonatype.nexus.security.filter.authz.NexusTargetMappingAuthorizationFilter.getResourceStoreRequest(NexusTargetMappingAuthorizationFilter.java:101)}}
      {{ at org.sonatype.nexus.security.filter.authz.NexusTargetMappingAuthorizationFilter.getHttpMethodAction(NexusTargetMappingAuthorizationFilter.java:122)}}
      {{ ... 63 common frames omitted}}

       

      Is there a way to get this to work or is this indeed a bug?

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            malice Roland Asmann
            Last Updated By:
            Joe Tom
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:

                tigCommentSecurity.panel-title