KeySetCommands command group for the AdminTask object
You can use the Jython or Jacl scripting languages to configure security with the wsadmin tool. The commands and parameters in the KeySetCommands group can be used to create, delete, and query for key set settings in your configuration.
createKeySet
The createKeySet command creates the key set settings in the configuration. Use this command to control key instances that have the same type.
Target object
None.Required parameters
- -name
- Specifies the name that uniquely identifies the key set. (String, required)
- -aliasPrefix
- Specifies the prefix for the key alias when a new key generates. (String, required)
- -password
- Specifies the password that protects the key in the keystore. (String, required)
- -maxKeyReferences
- Specifies the maximum number of key references from the returned keys in the key set of interest. (Integer, required)
- -keyStoreName
- Specifies the keystore that contains the keys. (String, required)
Optional parameters
- -scopeName
- Specifies the unique name of the management scope. (String, optional)
- -deleteOldKeys
- Set the value of this parameter to true to delete old keys when new keys are generated. Otherwise, set the value of this parameter to false. (Boolean, optional)
- -keyGenerationClass
- Specifies the class that is used to generate new keys in the key set. (String, optional)
- -keyStoreScopeName
- Specifies the management scope where the keystore is located. (String, optional)
- -isKeyPair
- Set the value of this parameter to true if the keys in the key set are key pairs. Otherwise, set the value of this parameter to false. (Boolean, optional)
Example output
The command returns the configuration object name of the key set object that you created.Examples
Batch mode example usage:
- Using Jacl:
$AdminTask createKeySet {-name testKeySet -aliasPrefix test -password pwd -maxKeyReferences 2 -deleteOldKeys true -keyStoreName testKeyStore -isKeyPair false}
- Using Jython string:
AdminTask.createKeySet('[-name testKeySet -aliasPrefix test -password pwd -maxKeyReferences 2 -deleteOldKeys true -keyStoreName testKeyStore -isKeyPair false]')
- Using Jython list:
AdminTask.createKeySet(['-name', 'testKeySet', '-aliasPrefix', 'test', '-password', 'pwd', '-maxKeyReferences', '2', '-deleteOldKeys', 'true', '-keyStoreName', 'testKeyStore', '-isKeyPair', 'false'])
Interactive mode example usage:
- Using Jacl:
$AdminTask createKeySet {-interactive}
- Using Jython string:
AdminTask.createKeySet ('[-interactive]')
- Using Jython list:
AdminTask.createKeySet (['-interactive'])
deleteKeySet
The deleteKeySet command deletes the settings of a key set from the configuration.
Target object
None.Required parameters
- -name
- The name that uniquely identifies the key set. (String, required)
Optional parameters
- -scopeName
- Specifies the unique name of the management scope. (String, optional)
Example output
The command does not return output.Examples
Batch mode example usage:
- Using Jacl:
$AdminTask deleteKeySet{ -name testKeySet}
- Using Jython string:
AdminTask.deleteKeySet('[-name testKeySet]')
- Using Jython list:
AdminTask.deleteKeySet(['-name', 'testKeySet'])
Interactive mode example usage:
- Using Jacl:
$AdminTask deleteKeySet {-interactive}
- Using Jython string:
AdminTask.deleteKeySet ('[-interactive]')
- Using Jython list:
AdminTask.deleteKeySet (['-interactive'])
generateKeyForKeySet
The generateKeyForKeySet command generates keys for the keys in the key set.
Target object
None.Required parameters
- -keySetName
- Specifies the name of the key set. (String, required)
Optional parameters
- -keySetScope
- Specifies the scope of the key set. (String, optional)
- -keySetSaveConfig
- Set the value of this parameter to true to save the configuration of the key set. Otherwise, set the value of this parameter to false. (Boolean, optional)
Example output
The command does not return output.Examples
Batch mode example usage:
- Using Jacl:
$AdminTask generateKeyForKeySet{ -keySetName testKeySet }
- Using Jython string:
AdminTask.generateKeyForKeySet('[-keySetName testKeySet]')
- Using Jython list:
AdminTask.generateKeyForKeySet(['-keySetName', 'testKeySet'])
Interactive mode example usage:
- Using Jacl:
$AdminTask generateKeyForKeySet {-interactive}
- Using Jython string:
AdminTask.generateKeyForKeySet ('[-interactive]')
- Using Jython list:
AdminTask.generateKeyForKeySet (['-interactive'])
getKeySet
The getKeySet command displays the settings of a particular key set.
Target object
None.Required parameters
- -name
- Specifies the name that uniquely identifies the key set. (String, required)
Optional parameters
- -scopeName
- Specifies the unique name of the management scope. (String, optional)
Example output
The command returns the settings of the specified key set group.Examples
Batch mode example usage:
- Using Jacl:
$AdminTask getKeySet {-name testKeySet}
- Using Jython string:
AdminTask.getKeySet ('[-name testKeySet]')
- Using Jython list:
AdminTask.getKeySet (['-name', 'testKeySet'])
Interactive mode example usage:
- Using Jacl:
$AdminTask getKeySet {-interactive}
- Using Jython string:
AdminTask.getKeySet ('[-interactive]')
- Using Jython list:
AdminTask.getKeySet (['-interactive'])
listKeySets
The listKeySets command lists the key sets in a particular scope.
Target object
None.Required parameters
None.Optional parameters
- -scopeName
- Specifies the unique name of the management scope. (String, optional)
- -displayObjectName
- Set the value of this parameter to true to list the key set configuration objects within the scope. Set the value of this parameter to false if you want to list the strings that contain the key set group name and management scope. (Boolean, optional)
- -all
- Specify the value of this parameter as true to list all key sets. This parameter overrides the scopeName parameter. The default value is false. (Boolean, optional)
Example output
The command returns the key sets for the scope that you specified.Examples
Batch mode example usage:
- Using Jacl:
$AdminTask listKeySets {-displayObjectName true}
- Using Jython string:
AdminTask.listKeySets ('[-displayObjectName true]')
- Using Jython list:
AdminTask.listKeySets (['-displayObjectName', 'true'])
Interactive mode example usage:
- Using Jacl:
$AdminTask listKeySets {-interactive}
- Using Jython string:
AdminTask.listKeySets ('[-interactive]')
- Using Jython list:
AdminTask.listKeySets (['-interactive'])
modifyKeySet
The modifyKeySet command changes the settings of an existing key set.
Target object
None.Required parameters
- -name
- Specifies the name that uniquely identifies the key set. (String, required)
Optional parameters
- -scopeName
- Specifies the unique name of the management scope. (String, optional)
- -aliasPrefix
- Specifies the prefix for the key alias when a new key generates. (String, optional)
- -password
- Specifies the password that protects the key in the keystore. (String, optional)
- -maxKeyReferences
- Specifies the maximum number of key references from the returned keys in the key set of interest. (Integer, optional)
- -deleteOldKeys
- Set the value of this parameter to true to delete old keys when new keys are generated. Otherwise, set the value of this parameter to false. (Boolean, optional)
- -keyGenerationClass
- Specifies the class that is used to generate new keys in the key set. (String, optional)
- -keyStoreName
- Specifies the keystore that contains the keys. (String, optional)
- -keyStoreScopeName
- Specifies the management scope where the keystore is located. (String, optional)
- -isKeyPair
- Set the value of this parameter to true if the keys in the key set are key pairs. Otherwise, set the value of this parameter to false. (Boolean, optional)
Example output
The command does not return output.Examples
Batch mode example usage:
- Using Jacl:
$AdminTask modifyKeySet {-name testKeySet -maxKeyReferences 3 -deleteOldKeys false}
- Using Jython string:
AdminTask.modifyKeySet ('[-name testKeySet -maxKeyReferences 3 -deleteOldKeys false]')
- Using Jython list:
AdminTask.modifyKeySet (['-name', 'testKeySet', '-maxKeyReferences', '3', '-deleteOldKeys', 'false'])
Interactive mode example usage:
- Using Jacl:
$AdminTask modifyKeySet {-interactive}
- Using Jython string:
AdminTask.modifyKeySet ('[-interactive]')
- Using Jython list:
AdminTask.modifyKeySet (['-interactive'])