elharo opened a new issue, #153:
URL: https://github.com/apache/maven-jarsigner-plugin/issues/153

   **Affected version:** HEAD
   
   **File:** 
`src/main/java/org/apache/maven/plugins/jarsigner/AbstractJarsignerMojo.java:560-567`
   
   The `decrypt()` method logs the error and re-throws, but the root cause 
details from `SecDispatcherException` may be partially lost:
   
   ```java
   protected String decrypt(String encoded) throws MojoExecutionException {
       try {
           return securityDispatcher.decrypt(encoded);
       } catch (SecDispatcherException e) {
           getLog().error("error using security dispatcher: " + e.getMessage(), 
e);
           throw new MojoExecutionException("error using security dispatcher: " 
+ e.getMessage(), e);
       }
   }
   ```
   
   The exception is passed as the cause to `MojoExecutionException`, so details 
are preserved in the chain. However, the error message string uses 
`e.getMessage()` which may omit important context (like the password key that 
failed to decrypt). Consider including more context in the message.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to