maven


Changing digest algorithm for maven-jarsigner-plugin


How can I change the default (in my case SHA256) digest algorithm within the configuration of maven-jarsigner-plugin? I would like it to be SHA1. I tried adding <digestalg>SHA1</digestalg> to the configuration block in the pom but that didn't do it because MANIFEST.MF still came out reporting SHA256.
In a command line, you would just do:
jarsigner ... -digestalg SHA1 myjar.jar myalias
As per this post, using arguments worked for me:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jarsigner-plugin</artifactId>
<version>1.4</version>
<executions>
<execution>
<phase>package</phase>
<id>sign</id>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
<configuration>
<keystore>mykey.jks</keystore>
<alias>myalias</alias>
<storepass>somepass</storepass>
<arguments>
<argument>-digestalg</argument><argument>SHA1</argument>
</arguments>
</configuration>
</plugin>

Related Links

using maven3 plugin for a maven2 build
Failed to execute goal maven release:prepare
Why glassfish behave differently in using maven dependency from a raw Java EE project?
java.lang.NullPointerException at com.sun.faces.application.resource.ResourceHandlerImpl.<init>(ResourceHandlerImpl.java:91)
Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved
Selenium 2 Automation Framework deployed as WAR on tomcat
Maven inherit dependencies of dependency module
Warning: This page calls for XML namespace http://primefaces.org/ui declared with prefix p but no taglibrary exists for that namespace
Ant script for Maven war and deploy
spring security jar files are not being downloded by maven
How to add dependencies to pom.xml in IntelliJ 14
Library development/debug with Maven
What are the group and artifact names for individual ImageJ2 libraries through Maven?
Make jar library from web project (netbeans, maven, web)
Maven remote settings.xml file
How can I build a jar (with all it's dependencies) in maven? [duplicate]

Categories

HOME
java
ibm-bluemix
ionic-framework
asp.net-core
blogger
iot
dot
bookshelf.js
sharepoint-designer
c#-2.0
acquia
datastax-java-driver
adfs
medical
gorm
google-cloud-spanner
apache-cayenne
windows-azure-storage
vb.net-2010
transformation
windows-7-x64
finite-automata
jsdoc
ab-testing
interop
contextmenu
shared-hosting
kryo
url-scheme
uninstall
social-media
publish
jspm
facebook-apps
atlassian-crucible
windows-server-2000
tasklet
bpel
google-cloud-endpoints-v2
catel
google-qpx-express-api
openoffice.org
http-referer
wpf-controls
libraries
hilbert-curve
particles.js
isbn
vao
unixodbc
flashair
s
angular-resource
appcompat
togetherjs
boost-preprocessor
ifs
cubes
jquery-filter
deadbolt-2
libpng
prettytensor
make-install
cloudbees
phpcas
rtbkit
srand
maven-tomcat-plugin
android-listview
deis
cakephp-3.1
splash
sonarqube5.1.2
inmobi
c3
google-style-guide
file-copying
yorick
valuechangelistener
marmalade
rtmfp
ms-project-server-2010
web2py-modules
dbconnection
sqlperformance
limejs
jelly
selected
isnullorempty
rdoc
coderush
dice
pydot
coercion
floating
bespin
uimenucontroller
wsdl.exe
ntvdm.exe

Resources

Database Users
RDBMS discuss
Database Dev&Adm
javascript
java
csharp
php
android
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App