org.apache.tools.ant.taskdefs
public abstract class AbstractJarSignerTask extends Task
| Field Summary | |
|---|---|
| protected String | alias
The alias of signer. |
| static String | ERROR_NO_SOURCE
error string for unit test verification: |
| protected Vector | filesets
the filesets of the jars to sign |
| protected File | jar
The name of the jar file. |
| protected static String | JARSIGNER_COMMAND
name of JDK program we are looking for |
| protected String | keypass
password for the key in the store |
| protected String | keystore
The url or path of keystore file. |
| protected String | maxMemory
The maximum amount of memory to use for Jar signer |
| protected String | storepass
password for the store |
| protected String | storetype
type of store,-storetype param |
| protected boolean | verbose
verbose output |
| Method Summary | |
|---|---|
| void | addFileset(FileSet set)
Adds a set of files to sign
|
| void | addSysproperty(Environment.Variable sysp)
Add a system property.
|
| protected void | addValue(ExecTask cmd, String value)
add a value argument to a command |
| protected void | beginExecution()
init processing logic; this is retained through our execution(s) |
| protected void | bindToKeystore(ExecTask cmd)
bind to a keystore if the attributes are there |
| protected ExecTask | createJarSigner()
create the jarsigner executable task |
| Path | createPath()
Adds a path of files to sign.
|
| protected Path | createUnifiedSourcePath()
clone our path and add all explicitly specified FileSets as
well, patch in the jar attribute as a new fileset if it is
defined. |
| protected Vector | createUnifiedSources()
clone our filesets vector, and patch in the jar attribute as a new
fileset, if is defined |
| protected void | declareSysProperty(ExecTask cmd, Environment.Variable property) |
| protected void | endExecution()
any cleanup logic |
| RedirectorElement | getRedirector()
get the redirector. |
| protected boolean | hasResources()
Has either a path or a fileset been specified? |
| void | setAlias(String alias)
the alias to sign under; required
|
| protected void | setCommonOptions(ExecTask cmd)
these are options common to signing and verifying |
| void | setJar(File jar)
the jar file to sign; required
|
| void | setKeypass(String keypass)
password for private key (if different); optional
|
| void | setKeystore(String keystore)
keystore location; required
|
| void | setMaxmemory(String max)
Set the maximum memory to be used by the jarsigner process
|
| void | setStorepass(String storepass)
password for keystore integrity; required
|
| void | setStoretype(String storetype)
keystore type; optional
|
| void | setVerbose(boolean verbose)
Enable verbose output when signing ; optional: default false
|
Parameters: set a set of files to sign
Since: Ant 1.4
Parameters: sysp system property.
Parameters: cmd command to manipulate value value to add
Parameters: cmd command to configure
Returns: a task set up with the executable of jarsigner, failonerror=true and bound to our redirector
Returns: a path of files to sign.
Since: Ant 1.7
Returns: a path that contains all files to sign
Since: Ant 1.7
Returns: a vector of FileSet instances
Parameters: cmd command to configure property property to set
Throws: BuildException if the property is not correctly defined.
Returns: a redirector or null
Returns: true if a path or fileset has been specified.
Since: Ant 1.7
Parameters: alias the alias to sign under
Parameters: cmd command to configure
Parameters: jar the jar file to sign
Parameters: keypass the password for the key (if different)
Parameters: keystore the keystore location
Parameters: max a string indicating the maximum memory according to the JVM conventions (e.g. 128m is 128 Megabytes)
Parameters: storepass the password for the keystore
Parameters: storetype the keystore type
Parameters: verbose if true enable verbose output