public JarSignerRequest createSignRequest ( File jarToSign , File signedJar ) throws MojoExecutionException { JarSignerSignRequest request = new JarSignerSignRequest ( ) ; request . setAlias ( getAlias ( ) ) ; request . setKeystore ( getKeystore ( ) ) ; request . setSigfile ( getSigfile ( ) ) ; request . setStoretype ( getStoretype ( ) ) ; request . setWorkingDirectory ( workDirectory ) ; request . setMaxMemory ( getMaxMemory ( ) ) ; request . setVerbose ( isVerbose ( ) ) ; request . setArchive ( jarToSign ) ; request . setSignedjar ( signedJar ) ; request . setTsaLocation ( getTsaLocation ( ) ) ; request . setProviderArg ( getProviderArg ( ) ) ; request . setProviderClass ( getProviderClass ( ) ) ; // Special handling for passwords through the Maven Security Dispatcher request . setKeypass ( decrypt ( keypass ) ) ; request . setStorepass ( decrypt ( storepass ) ) ; if ( ! arguments . isEmpty ( ) ) { request . setArguments ( arguments . toArray ( new String [ arguments . size ( ) ] ) ) ; } return request ; }
Creates a jarsigner request to do a sign operation .