title: How can I tell which signed jar is causing maven-shade-plugin to fail?
body: <p>To run maven-shade-plugin, I have to use to method described <a href="https://stackoverflow.com/a/6743609/828638">here</a> due to signed dependencies, as shown here:</p>
  
  <pre><code>&lt;plugin&gt;
      &lt;artifactId&gt;maven-shade-plugin&lt;/artifactId&gt;
      &lt;executions&gt;
          &lt;execution&gt;
              &lt;phase&gt;package&lt;/phase&gt;
              &lt;goals&gt;&lt;goal&gt;shade&lt;/goal&gt;&lt;/goals&gt;
              &lt;configuration&gt;
                  &lt;filters&gt;
                      &lt;filter&gt;
                          &lt;!-- filter out signature files from signed dependencies, else repackaging fails with security ex --&gt;
                          &lt;artifact&gt;*:*&lt;/artifact&gt;
                          &lt;excludes&gt;
                              &lt;exclude&gt;META-INF/*.SF&lt;/exclude&gt;
                              &lt;exclude&gt;META-INF/*.DSA&lt;/exclude&gt;
                              &lt;exclude&gt;META-INF/*.RSA&lt;/exclude&gt;
                          &lt;/excludes&gt;
                      &lt;/filter&gt;
                  &lt;/filters&gt;
              &lt;/configuration&gt;
          &lt;/execution&gt;
      &lt;/executions&gt;
  &lt;/plugin&gt;
  </code></pre>
  
  <p>Question:  How can I tell <em>which</em> JAR caused the plugin to fail?  It doesn't seem to be the most recently mentioned one.</p>
  
  <p>Tail of debug output:</p>
  
  <pre><code>[DEBUG] We have a duplicate org/jdom2/xpath/util/AbstractXPathCompiled.class in C:\Users\me\aaaa-1.11.0-SNAPSHOT.jar
  [DEBUG] We have a duplicate org/jdom2/xpath/util/XPathDiagnosticImpl.class in C:\Users\me\aaaa-1.11.0-SNAPSHOT.jar
  [DEBUG] Processing JAR C:\Users\me\bbbb-1.11.0-SNAPSHOT.jar
  [INFO] ------------------------------------------------------------------------
  [INFO] Reactor Summary:
  [INFO] 
  [INFO] Retrievers JAR ................................ FAILURE [  9.581 s]
  [INFO] Retrievers .................................... SKIPPED
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD FAILURE
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time: 10.208 s
  [INFO] Finished at: 2015-05-12T14:20:54-05:00
  [INFO] Final Memory: 100M/726M
  [INFO] ------------------------------------------------------------------------
  [ERROR] Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.3:shade (default) on project aaa-retrievers-jar: Error creating shaded jar: Invalid signature file digest for Manifest main attributes -&gt; [Help 1]
  org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.3:shade (default) on project aaa-retrievers-jar: Error creating shaded jar: Invalid signature file digest for Manifest main attributes
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:108)
      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:76)
      at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
      at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:116)
      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:361)
      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
      at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
      at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:213)
      at org.apache.maven.cli.MavenCli.main(MavenCli.java:157)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:483)
      at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
      at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
      at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
      at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
  Caused by: org.apache.maven.plugin.MojoExecutionException: Error creating shaded jar: Invalid signature file digest for Manifest main attributes
      at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute(ShadeMojo.java:566)
      at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:133)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
      ... 19 more
  Caused by: java.lang.SecurityException: Invalid signature file digest for Manifest main attributes
      at sun.security.util.SignatureFileVerifier.processImpl(SignatureFileVerifier.java:284)
      at sun.security.util.SignatureFileVerifier.process(SignatureFileVerifier.java:238)
      at java.util.jar.JarVerifier.processEntry(JarVerifier.java:316)
      at java.util.jar.JarVerifier.update(JarVerifier.java:228)
      at java.util.jar.JarFile.initializeVerifier(JarFile.java:383)
      at java.util.jar.JarFile.getInputStream(JarFile.java:450)
      at org.apache.maven.plugins.shade.DefaultShader.shade(DefaultShader.java:147)
      at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute(ShadeMojo.java:471)
      ... 21 more
  [ERROR] 
  [ERROR] 
  [ERROR] For more information about the errors and possible solutions, please read the following articles:
  [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
  </code></pre>