com.waveset.adapter
Class ShellScriptResourceAdapter

java.lang.Object
  extended bycom.waveset.adapter.ResourceAdapterBase
      extended bycom.waveset.adapter.GenericScriptResourceAdapter
          extended bycom.waveset.adapter.UnixResourceAdapter
              extended bycom.waveset.adapter.ShellScriptResourceAdapter
All Implemented Interfaces:
ResourceAdapter, ResourcePolicyTimeouts

public class ShellScriptResourceAdapter
extends UnixResourceAdapter


Nested Class Summary
 
Nested classes inherited from class com.waveset.adapter.GenericScriptResourceAdapter
GenericScriptResourceAdapter.AcctIter
 
Nested classes inherited from class com.waveset.adapter.ResourceAdapterBase
ResourceAdapterBase.SimpleAccountIterator
 
Nested classes inherited from class com.waveset.adapter.ResourceAdapter
ResourceAdapter.ActionResult, ResourceAdapter.Features, ResourceAdapter.ObjectType
 
Field Summary
static java.lang.String CLASS
           
static java.lang.String DISABLED_ATTRIBUTE
          The special attribute name we use to represent the disable status.
static java.lang.String LOGIN_PASSWORD
           
static java.lang.String LOGIN_USER
           
static java.lang.String RA_ACCT_ITER_ACTION
           
static java.lang.String RA_ACCT_ITER_HANDLER
           
static java.lang.String RA_ATTR0
           
static java.lang.String RA_ATTR1
           
static java.lang.String RA_AUTHENTICATE_ACTION
           
static java.lang.String RA_AUTHENTICATE_HANDLER
           
static java.lang.String RA_BLCK_ACCT_HANDLER
           
static java.lang.String RA_BLCK_ACCT_ITER_ACTION
           
static java.lang.String RA_CHECK_CREATE_USER_ACTION
           
static java.lang.String RA_CHECK_CREATE_USER_HANDLER
           
static java.lang.String RA_CHECK_DELETE_USER_ACTION
           
static java.lang.String RA_CHECK_DELETE_USER_HANDLER
           
static java.lang.String RA_CHECK_UPDATE_USER_ACTION
           
static java.lang.String RA_CHECK_UPDATE_USER_HANDLER
           
static java.lang.String RA_CREATE_GROUP_ACTION
           
static java.lang.String RA_CREATE_GROUP_HANDLER
           
static java.lang.String RA_CREATE_USER_ACTION
           
static java.lang.String RA_CREATE_USER_HANDLER
           
static java.lang.String RA_DELETE_GROUP_ACTION
           
static java.lang.String RA_DELETE_GROUP_HANDLER
           
static java.lang.String RA_DELETE_USER_ACTION
           
static java.lang.String RA_DELETE_USER_HANDLER
           
static java.lang.String RA_DISABLE_USER_ACTION
           
static java.lang.String RA_DISABLE_USER_HANDLER
           
static java.lang.String RA_ENABLE_USER_ACTION
           
static java.lang.String RA_ENABLE_USER_HANDLER
           
static java.lang.String RA_GET_ALL_ACTION
           
static java.lang.String RA_GET_ALL_HANDLER
           
static java.lang.String RA_GET_FILE_ACTION
           
static java.lang.String RA_GET_FILE_HANDLER
           
static java.lang.String RA_GET_GROUP_ACTION
           
static java.lang.String RA_GET_GROUP_HANDLER
           
static java.lang.String RA_GET_INFO_ACTION
           
static java.lang.String RA_GET_INFO_HANDLER
           
static java.lang.String RA_GET_USER_ACTION
           
static java.lang.String RA_GET_USER_HANDLER
           
static java.lang.String RA_LISTALL_ACTION
           
static java.lang.String RA_LISTALL_HANDLER
           
static java.lang.String RA_MAKE_DIR
           
static java.lang.String RA_NISSHADOW
           
static java.lang.String RA_RENAME_GROUP_ACTION
           
static java.lang.String RA_RENAME_GROUP_HANDLER
           
static java.lang.String RA_RENAME_USER_ACTION
           
static java.lang.String RA_RENAME_USER_HANDLER
           
static java.lang.String RA_RESULT_HANDLER
           
static java.lang.String RA_SCAN_ACTION
           
static java.lang.String RA_SCAN_HANDLER
           
static java.lang.String RA_SCRIPT_SOURCE
           
static java.lang.String RA_SET_INFO_ACTION
           
static java.lang.String RA_SET_INFO_HANDLER
           
static java.lang.String RA_SKEL_DIR
           
static java.lang.String RA_TEST_CONFIG_ACTION
           
static java.lang.String RA_TEST_CONFIG_HANDLER
           
static java.lang.String RA_UPDATE_GROUP_ACTION
           
static java.lang.String RA_UPDATE_GROUP_HANDLER
           
static java.lang.String RA_UPDATE_USER_ACTION
           
static java.lang.String RA_UPDATE_USER_HANDLER
           
static java.lang.String RA_USERADD_CREATE_GROUP
          Resource attribute name of the variable used to set whether the Red Hat useradd command is to create a group with the same name as the user being added to the system.
static java.lang.String RESOURCE_USER_FORM
           
static java.lang.String RESTYPE_DISPLAY_NAME
           
 
Fields inherited from class com.waveset.adapter.UnixResourceAdapter
CMD_AWK, CMD_CAT, CMD_CHMOD, CMD_CHOWN, CMD_CP, CMD_CUT, CMD_DIFF, CMD_ECHO, CMD_GREP, CMD_GROUPADD, CMD_GROUPDEL, CMD_GROUPMOD, CMD_LAST, CMD_LISTUSERS, CMD_LOGINS, CMD_LS, CMD_MAKE, CMD_MV, CMD_PASSWD, CMD_RM, CMD_SED, CMD_SLEEP, CMD_SORT, CMD_SUDO, CMD_TAIL, CMD_TOUCH, CMD_USERADD, CMD_USERDEL, CMD_USERMOD, CMD_WHICH, CMD_YPCAT, CMD_YPMATCH, CMD_YPPASSWD, code_id, loginPass, loginShellPrompt, loginUser, ONE_TAIL, RA_ALT_ROOT_SHELL_PROMPT, RA_DEL_HOME_DIR, RA_HOME_BASEDIR, RA_LOGIN_SHELL_PROMPT, RA_NISDIR, RA_NISPWDDIR, RA_NISSRCDIR, RA_ROOT_PASSWORD, RA_ROOT_SHELL_PROMPT, RA_ROOT_USER, RA_SUDO_AUTH, RA_SYS_DB_TYPE, removeAction, rootPass, rootPromptCaptureToken, rootPromptCaptureTokenOrig, rootPromptWaitToken, rootPromptWaitTokenOrig, rootShellPrompt, rootShellPromptOrig, rootUser, sudoResetCmd, sudoResetToken, sudoStartCmd, sudoStartToken, wavesetRootPrompt, wavesetRootPromptCaptureToken, wavesetRootPromptWaitToken
 
Fields inherited from class com.waveset.adapter.GenericScriptResourceAdapter
conn, RA_BLOCK_FETCH_TIMEOUT, RA_CONN_MAX, RA_CONN_TIMEOUT, RA_CONN_TYPE, RA_HOST, RA_LOGIN_PASSWORD, RA_LOGIN_USER, RA_PORT, RA_TERM
 
Fields inherited from class com.waveset.adapter.ResourceAdapterBase
_cache, _context, _excludedAccountsRule, _excludedAccountsRuleInited, _listAllObjectsAttrParse, _listAllObjectsAttrParseName, _listUserAttrParse, _listUserAttrParseName, _listUserGroupsAttrParse, _listUserGroupsAttrParseName, _resource, _thread, _trace, displayInfoCode, RA_BLOCKCOUNT, RA_LOGIN_ACTION, RA_LOGOFF_ACTION, RA_MULTI_VALUED_ATTRS, RA_TEST_MODE
 
Fields inherited from interface com.waveset.adapter.ResourceAdapter
CHANGE_PASSWORD_LOCATION, DISABLE, ENABLE, EXPIRE_PASSWORD, GUID, IGNORE_ATTR, NEW_ACCOUNT_ID, OP_DAYS_INACTIVE, OP_DISABLED, OP_DORMANT, OP_EXPIRED, OP_EXPIREDPWD, OP_INACTIVE, OP_LOCKED, OP_NO_PASSWORD_SET, OP_NOOWNERSHIP, OP_NOPASSWORDREQ, OP_NUMINACTIVEDAYS, OP_NUMPWDAYS, OP_PWNUMDAYS, RA_BASE_CTX, RA_DISPLAY_NAME_ATTR, RA_NEW_OBJECT_ID, RA_NEW_OBJECT_NAME, RA_OBJECT_ATTRIBUTES, RA_OBJECT_CLASS, RA_OBJECT_ID, RA_OBJECT_TYPE, RA_OP_TYPE, RA_RENAME_OP, RA_REQUESTOR, RA_SAVEAS_OP, RA_SEARCH_ATTRIBUTE_NAMES, RA_SEARCH_ATTRS_TO_GET, RA_SEARCH_CONTEXT, RA_SEARCH_FILTER, RA_SEARCH_RUN_AS_PASSWORD, RA_SEARCH_RUN_AS_USER, RA_SEARCH_SCOPE, RA_SEARCH_SCOPE_OBJECT, RA_SEARCH_SCOPE_ONE_LEVEL, RA_SEARCH_SCOPE_SUBTREE, RA_SEARCH_TIME_LIMIT, RESET_PASSWORD, SYSTEM_ATTRIBUTES, UNLOCK, WS_USER_PASSWORD
 
Constructor Summary
ShellScriptResourceAdapter()
           
 
Method Summary
protected  java.lang.String constructUserAttributeParameter(java.lang.String key, java.lang.String value)
          Not usefull yet for generic shell scripts.
 Resource createPrototypeResource()
          Non-static version of staticCreatePrototypeResource()
 AccountIterator getAccountIterator()
          Override the GenericScriptResourceAdapter method Returns an account iterator containing all of the users on the resource.
 AccountIterator getAccountIterator(long timeout)
          Note: Overrides the method in GenericScriptAdapter.
protected  AccountIterator getAccountIteratorResult(CaptureList captureList)
          Generates an account iterator from the capture list that was built from running the getAccountIteratorScript generated script through the ScriptedConnection.
protected  Script getAccountIteratorScript()
          Returns a script that can be run on an opened and logged in ScriptedConnection to pull a list of users out of the system.
protected  Script getAccountIteratorScript(long timeout)
           
 Script getAccountIteratorScript(long timeout, boolean hasTimeout)
           
protected  WavesetResult getAuthenticateResult(java.util.HashMap loginInfo, CaptureList captureList)
          Takes the capture list from running the authenticate script through the resource and validates it.
protected  Script getAuthenticateScript(java.util.HashMap loginInfo)
          Generates a script for authenticating a user on the resource using the username and password in the loginInfo HashMap.
 Script getBlockAccountIteratorScript(long timeout, boolean hasTimeout)
           
protected  WavesetResult getCheckCreateAccountResult(CaptureList captureList)
          Validates the capture list returned from the check create account script execution.
 Script getCheckCreateAccountScript()
          Returns a shell script to check the resource and determine if a create account request is likely to succeed.
protected  WavesetResult getCheckDeleteAccountResult(CaptureList captureList)
          Validates the capture list returned from the check delete account script execution.
 Script getCheckDeleteAccountScript()
          Returns a shell script to check the resource and determine if a delete account request is likely to succeed.
protected  WavesetResult getCheckUpdateAccountResult(CaptureList captureList)
          Validates the capture list returned from the check update account script execution.
 Script getCheckUpdateAccountScript()
          Returns a shell script to check the resource and determine if an update account request is likely to succeed.
protected  WavesetResult getConnectionTestResult(CaptureList captureList)
          Evaluates capture list from execution of generic test connection script.
protected  Script getConnectionTestScript()
          Creates a script to test the connection, does NOT login or logout.
 WavesetResult getCreateGroupResult(CaptureList captureList)
           
 Script getCreateGroupScript(java.lang.String groupName, GenericObject attrs, java.util.Map options, boolean isSaveAs)
          Returns a script which will create a group.
protected  void getCreateUserResult(CaptureList captureList, WavesetResult result)
          Analyzes the capture list generated by executing the create user script on the scripted connection.
protected  Script getCreateUserScript(WSUser user)
          Generates a script that will create an account for the passed user on the resource.
 Script getDeleteGroupScript(GenericObject object, java.util.Map options)
          Generates a script that will delete a group on the resource.
protected  void getDeleteUserResult(CaptureList captureList)
          Analyzes the capture list generated by executing the delete user script on the scripted connection.
protected  Script getDeleteUserScript(WSUser user)
          Generates a script that will delete the account of the passed user on the resource.
protected  boolean getDisableUserResult(CaptureList captureList)
          Analyzes the capture list generated by executing the disable user script on the scripted connection.
protected  Script getDisableUserScript(WSUser user, java.lang.String password)
          Generates a script that will disable an account for the passed user on the resource.
protected  boolean getEnableUserResult(CaptureList captureList)
          Analyzes the capture list generated by executing the enable user script on the scripted connection.
protected  Script getEnableUserScript(WSUser user, java.lang.String password)
          Generates a script that will enable an account for the passed user on the resource.
 GenericObject getFeatures()
          Expose features supported by the Resource Adapter.
 GenericObject getGetGroupResult(java.lang.String groupName, java.util.List attrsToGet, CaptureList captureList)
           
protected  Script getGetGroupScript(java.lang.String objectId, java.util.List attrsToGet, java.util.Map options)
          Returns a script which will retrieve a group's attributes.
protected  Script getGetObjectScript(java.lang.String objectType, java.lang.String objectId, java.util.List attrsToGet, java.util.Map options)
          Returns a script which will retrieve the attributes of an object of the specified type from the scriptedConnection.
 GenericObject getGetUserResult(java.lang.String objectName, java.util.List attrsToGet, CaptureList captureList)
           
 java.util.ArrayList getListAllObjectsResult(java.lang.String objectType, CaptureList captureList)
          Analyzes the captrure list generated by executing the listAllObjects script on the scripted connection.
protected  Script getListAllObjectsScript(java.lang.String resObjType, java.util.Map options, java.lang.String runAsUser, EncryptedData runAsPassword)
          Returns a script which will return a list of objects of a specified type from the scriptedConnection.
protected  Script getLoginScript()
          Returns a script that will log the administrative user into the system and set up the shell if necessary.
protected  Script getLogoutScript()
          Returns a script that will log the administrative user out of the resource.
 WavesetResult getRenameGroupResult(GenericObject object, CaptureList captureList)
           
protected  Script getRenameGroupScript(GenericObject object)
          Returns a script which will rename a group.
 WavesetResult getRenameUserResult(GenericObject object, CaptureList captureList)
           
protected  Script getRenameUserScript(GenericObject object)
          Returns a script which will rename a user account.
protected  com.waveset.adapter.ShellScriptResultHandler getResultHandler()
           
 WavesetResult getScanningResult(CaptureList captureList, java.util.Map args)
          Based on the result of the scan routine's capturelist and the arguments passed into the routine, generate some output.
protected  Script getScanningScript(java.util.Map scanArgs)
          Generates a script that will return a list of all the users and interesting attributes for scanning.
protected  com.waveset.adapter.ShellScriptSource getScriptSource()
           
 WavesetResult getUpdateGroupResult(GenericObject object, CaptureList captureList)
           
protected  Script getUpdateGroupScript(GenericObject object)
          Returns a script which will update a group.
 WavesetResult getUpdateUserResult(GenericObject object, CaptureList captureList)
           
protected  void getUpdateUserResult(WSUser user, CaptureList captureList, WavesetResult result)
          Analyzes the capture list generated by executing the update user script on the scripted connection.
protected  Script getUpdateUserScript(java.lang.String accountId, java.lang.String password)
          Generates a script that will update an account for the passed user on the resource.
protected  Script getUpdateUserScript(WSUser user, java.lang.String password)
          Generates a script that will create an account for the passed user on the resource.
protected  WSUser getUserResult(CaptureList captureList, WSUser targetUser)
          Analyzes the capture list generated by executing the get user script on the scripted connection.
protected  Script getUserScript(WSUser user)
          Returns a script that sends commands to check for existence of the passed user on the resource.
protected  boolean isAllowableUserAttribute(java.lang.String name)
          Reports whether a given attribute name is legal on the resource.
protected  void setResultHandler(com.waveset.adapter.ShellScriptResultHandler resultHandler)
           
protected  void setScriptSource(ShellScriptSourceBase scriptSource)
           
protected  void startConnection()
          Starts a scripted connection up and logs into it.
static Resource staticCreatePrototypeResource()
           
static Resource staticCreatePrototypeResource(java.lang.String resName, java.lang.String resTypeDisplayName, java.lang.String className, java.lang.String userFormName, java.lang.String loginModuleName, java.lang.String loginUserAttrName, java.lang.String loginPasswordAttrName)
          Converts the generic svidPrototypeXml to a specific instance (eg Solaris, HP-UX) by creating a Resource object and modifying it appropriately.
 boolean supportsAccountDisable()
          Indicates whether or not this resource supports account disable.
 boolean supportsExcludedAccounts()
           
 boolean supportsResourceAccount()
          Returns true if the resource adapter supports modifications to the resource account.
 
Methods inherited from class com.waveset.adapter.UnixResourceAdapter
addActionScript, addResultItem, addScriptArguments, addSudoReset, addSudoStart, authenticate, createResourceAttr, divideString, escape, getAccountActionResult, getAccountActionScript, getActionResult, getActionScript, getCaptureItem, getConnectionType, getCreateNativeGroupScript, getCreateNativeUserScript, getCreateNISGroupScript, getCreateNISUserScript, getCreateObjectResult, getCreateObjectScript, getCreateUserResult, getCreateUserScript, getDefaultShellsList, getDeleteNativeGroupScript, getDeleteNativeUserScript, getDeleteNISGroupScript, getDeleteNISUserScript, getDeleteObjectScript, getDeleteUserScript, getGetObjectResult, getGetUserScript, getListObjectsResult, getListObjectsScript, getReadOnlyNISTestCmds, getReadOnlyTestCmds, getRenameObjectResult, getRenameObjectScript, getRequiredCmds, getRequiredFileCmds, getRequiredGroupCmds, getRequiredNISCmds, getRequiredUserCmds, getResourceAccounts, getScriptedConnection, getShellsScript, getTestConfigurationResult, getTestConfigurationScript, getUpdateNativeGroupScript, getUpdateNativeUserScript, getUpdateNISGroupScript, getUpdateNISUserScript, getUpdateObjectResult, getUpdateObjectScript, getUpdateUserScript, getWhichScript, init, isNIS, quoteString, replaceSpaces, setWavesetPrompt, stopConnection, stopConnection, sudoAuthorization, supportsActions, supportsCaseInsensitiveAccountIds, testConnection
 
Methods inherited from class com.waveset.adapter.GenericScriptResourceAdapter
checkCreateAccount, checkDeleteAccount, checkUpdateAccount, constructUserAttributeParameters, constructUserAttributeParameters, createObject, deleteObject, getAccountAttributeFromMapName, getAccountAttributes, getCapture, getDeleteObjectResult, getObject, getUpdateUserResult, getUser, getWaitFor, getWaitForIgnoreCase, listAllObjects, listObjects, lookupAndRunAction, realCreate, realDelete, realDisable, realEnable, realUpdate, renameObject, reverseMapAttr, reverseMapAttr, reverseMapMultiAttr, run, runAction, runAction, runAfterAction, runBeforeAction, scan, testConfiguration, updateObject, updateResourceAccount, wellFormedUserAttributeName
 
Methods inherited from class com.waveset.adapter.ResourceAdapterBase
checkForNoPasswordInSchema, checkSyntax, createAccount, createAccounts, createIdentity, deleteAccount, deleteAccount, deleteAccounts, disableAccount, disableAccounts, dnsEqual, dnsEqual, enableAccount, enableAccounts, executeResourceAttributeJavascriptAction, fillInResourceInfo, fillInResourceInfo, getAccountIterator, getAction, getActionNotFoundErrorMessage, getActionNotFoundMessage, getActionRunAsPassword, getActionRunAsUser, getActionTimeout, getActionType, getAdapter, getAdapter, getAdapter, getAdapterProxy, getAdapterProxy, getAllAccounts, getAttrNameFromMapName, getAttrNameFromMapName, getAttrParse, getAttrTypeFromMapName, getAttrTypeFromMapName, getAUserName, getBaseContextAttrName, getBaseContextObject, getBaseContexts, getBlockSize, getContext, getExcludedAccountsRule, getIdentity, getListAllObjectsAttrParse, getListUserAttrParse, getListUserGroupsAttrParse, getOptionalBooleanResAttrVal, getOptionalBooleanResAttrVal, getOptionalEncryptedResAttrVal, getOptionalResAttrVal, getOptionalStringResAttrVal, getRequiredResAttr, getRequiredResAttr, getRequiredResAttrVal, getRequiredResAttrVal, getRequiredResAttrVals, getRequiredUserAttributeNames, getResAttrValActionOnUser, getResAttrVals, getResource, getResourceInfo, getResourceObjectAttrValNameAttr, getResourceObjectClassAttr, getResourceObjectTypePrefix, getSchemaMap, getUser, getWSAttrByMapName, getWSAttrByMapName, getWSAttrFromMap, handleActionResult, handleJavascriptActionResult, isAccountAttributeSecret, isExcludedAccount, isExcludedAccount, isFeatureEnabled, isSupported, isTestMode, listAllObjects, listObjects, listObjectsOfType, lookupAction, lookupAction, lookupActions, namesEqual, objectClassesMatchType, println, restoreResourceObjectClassAttr, run, runResourceAttributeJavascriptAction, setCache, setContext, setDisabled, setFromResource, setResource, setResourceObjectClassAttr, setResourceOptionAttrs, startConnectionWrapper, supportsAccountActions, supportsContainerObjectTypes, supportsScanning, updateAccount, updateAccounts, updateResourceIdentity, vmStoreBoot, vmStoreGet, vmStoreInit, vmStoreLatch, vmStorePut
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.waveset.adapter.ResourceAdapter
checkCreateAccount, checkDeleteAccount, checkUpdateAccount, createAccount, createAccounts, createIdentity, createObject, deleteAccount, deleteAccount, deleteAccounts, deleteObject, disableAccount, disableAccounts, enableAccount, enableAccounts, getAccountAttributes, getAccountIterator, getAllAccounts, getBaseContextAttrName, getBaseContextObject, getBaseContexts, getObject, getResource, getUser, getUser, isSupported, listAllObjects, listAllObjects, listObjects, listObjects, listObjectsOfType, namesEqual, run, run, scan, setCache, setContext, setResource, setResourceObjectClassAttr, supportsContainerObjectTypes, supportsScanning, testConfiguration, updateAccount, updateAccounts, updateObject, updateResourceAccount
 

Field Detail

CLASS

public static final java.lang.String CLASS
See Also:
Constant Field Values

LOGIN_USER

public static final java.lang.String LOGIN_USER
See Also:
Constant Field Values

LOGIN_PASSWORD

public static final java.lang.String LOGIN_PASSWORD
See Also:
Constant Field Values

RA_GET_USER_ACTION

public static final java.lang.String RA_GET_USER_ACTION
See Also:
Constant Field Values

RA_GET_USER_HANDLER

public static final java.lang.String RA_GET_USER_HANDLER
See Also:
Constant Field Values

RA_GET_ALL_ACTION

public static final java.lang.String RA_GET_ALL_ACTION
See Also:
Constant Field Values

RA_GET_ALL_HANDLER

public static final java.lang.String RA_GET_ALL_HANDLER
See Also:
Constant Field Values

RA_CREATE_USER_ACTION

public static final java.lang.String RA_CREATE_USER_ACTION
See Also:
Constant Field Values

RA_CREATE_USER_HANDLER

public static final java.lang.String RA_CREATE_USER_HANDLER
See Also:
Constant Field Values

RA_DELETE_USER_ACTION

public static final java.lang.String RA_DELETE_USER_ACTION
See Also:
Constant Field Values

RA_DELETE_USER_HANDLER

public static final java.lang.String RA_DELETE_USER_HANDLER
See Also:
Constant Field Values

RA_UPDATE_USER_ACTION

public static final java.lang.String RA_UPDATE_USER_ACTION
See Also:
Constant Field Values

RA_UPDATE_USER_HANDLER

public static final java.lang.String RA_UPDATE_USER_HANDLER
See Also:
Constant Field Values

RA_RENAME_USER_ACTION

public static final java.lang.String RA_RENAME_USER_ACTION
See Also:
Constant Field Values

RA_RENAME_USER_HANDLER

public static final java.lang.String RA_RENAME_USER_HANDLER
See Also:
Constant Field Values

RA_DISABLE_USER_ACTION

public static final java.lang.String RA_DISABLE_USER_ACTION
See Also:
Constant Field Values

RA_DISABLE_USER_HANDLER

public static final java.lang.String RA_DISABLE_USER_HANDLER
See Also:
Constant Field Values

RA_ENABLE_USER_ACTION

public static final java.lang.String RA_ENABLE_USER_ACTION
See Also:
Constant Field Values

RA_ENABLE_USER_HANDLER

public static final java.lang.String RA_ENABLE_USER_HANDLER
See Also:
Constant Field Values

RA_CHECK_CREATE_USER_ACTION

public static final java.lang.String RA_CHECK_CREATE_USER_ACTION
See Also:
Constant Field Values

RA_CHECK_CREATE_USER_HANDLER

public static final java.lang.String RA_CHECK_CREATE_USER_HANDLER
See Also:
Constant Field Values

RA_CHECK_UPDATE_USER_ACTION

public static final java.lang.String RA_CHECK_UPDATE_USER_ACTION
See Also:
Constant Field Values

RA_CHECK_UPDATE_USER_HANDLER

public static final java.lang.String RA_CHECK_UPDATE_USER_HANDLER
See Also:
Constant Field Values

RA_CHECK_DELETE_USER_ACTION

public static final java.lang.String RA_CHECK_DELETE_USER_ACTION
See Also:
Constant Field Values

RA_CHECK_DELETE_USER_HANDLER

public static final java.lang.String RA_CHECK_DELETE_USER_HANDLER
See Also:
Constant Field Values

RA_AUTHENTICATE_ACTION

public static final java.lang.String RA_AUTHENTICATE_ACTION
See Also:
Constant Field Values

RA_AUTHENTICATE_HANDLER

public static final java.lang.String RA_AUTHENTICATE_HANDLER
See Also:
Constant Field Values

RA_GET_GROUP_ACTION

public static final java.lang.String RA_GET_GROUP_ACTION
See Also:
Constant Field Values

RA_GET_GROUP_HANDLER

public static final java.lang.String RA_GET_GROUP_HANDLER
See Also:
Constant Field Values

RA_CREATE_GROUP_ACTION

public static final java.lang.String RA_CREATE_GROUP_ACTION
See Also:
Constant Field Values

RA_CREATE_GROUP_HANDLER

public static final java.lang.String RA_CREATE_GROUP_HANDLER
See Also:
Constant Field Values

RA_DELETE_GROUP_ACTION

public static final java.lang.String RA_DELETE_GROUP_ACTION
See Also:
Constant Field Values

RA_DELETE_GROUP_HANDLER

public static final java.lang.String RA_DELETE_GROUP_HANDLER
See Also:
Constant Field Values

RA_RENAME_GROUP_ACTION

public static final java.lang.String RA_RENAME_GROUP_ACTION
See Also:
Constant Field Values

RA_RENAME_GROUP_HANDLER

public static final java.lang.String RA_RENAME_GROUP_HANDLER
See Also:
Constant Field Values

RA_UPDATE_GROUP_ACTION

public static final java.lang.String RA_UPDATE_GROUP_ACTION
See Also:
Constant Field Values

RA_UPDATE_GROUP_HANDLER

public static final java.lang.String RA_UPDATE_GROUP_HANDLER
See Also:
Constant Field Values

RA_LISTALL_ACTION

public static final java.lang.String RA_LISTALL_ACTION
See Also:
Constant Field Values

RA_LISTALL_HANDLER

public static final java.lang.String RA_LISTALL_HANDLER
See Also:
Constant Field Values

RA_ACCT_ITER_ACTION

public static final java.lang.String RA_ACCT_ITER_ACTION
See Also:
Constant Field Values

RA_ACCT_ITER_HANDLER

public static final java.lang.String RA_ACCT_ITER_HANDLER
See Also:
Constant Field Values

RA_BLCK_ACCT_ITER_ACTION

public static final java.lang.String RA_BLCK_ACCT_ITER_ACTION
See Also:
Constant Field Values

RA_BLCK_ACCT_HANDLER

public static final java.lang.String RA_BLCK_ACCT_HANDLER
See Also:
Constant Field Values

RA_SCAN_ACTION

public static final java.lang.String RA_SCAN_ACTION
See Also:
Constant Field Values

RA_SCAN_HANDLER

public static final java.lang.String RA_SCAN_HANDLER
See Also:
Constant Field Values

RA_RESULT_HANDLER

public static final java.lang.String RA_RESULT_HANDLER
See Also:
Constant Field Values

RA_SCRIPT_SOURCE

public static final java.lang.String RA_SCRIPT_SOURCE
See Also:
Constant Field Values

RA_ATTR0

public static final java.lang.String RA_ATTR0
See Also:
Constant Field Values

RA_ATTR1

public static final java.lang.String RA_ATTR1
See Also:
Constant Field Values

RA_GET_FILE_ACTION

public static final java.lang.String RA_GET_FILE_ACTION
See Also:
Constant Field Values

RA_GET_FILE_HANDLER

public static final java.lang.String RA_GET_FILE_HANDLER
See Also:
Constant Field Values

RA_GET_INFO_ACTION

public static final java.lang.String RA_GET_INFO_ACTION
See Also:
Constant Field Values

RA_GET_INFO_HANDLER

public static final java.lang.String RA_GET_INFO_HANDLER
See Also:
Constant Field Values

RA_SET_INFO_ACTION

public static final java.lang.String RA_SET_INFO_ACTION
See Also:
Constant Field Values

RA_SET_INFO_HANDLER

public static final java.lang.String RA_SET_INFO_HANDLER
See Also:
Constant Field Values

RA_TEST_CONFIG_ACTION

public static final java.lang.String RA_TEST_CONFIG_ACTION
See Also:
Constant Field Values

RA_TEST_CONFIG_HANDLER

public static final java.lang.String RA_TEST_CONFIG_HANDLER
See Also:
Constant Field Values

RESOURCE_USER_FORM

public static final java.lang.String RESOURCE_USER_FORM
See Also:
Constant Field Values

RESTYPE_DISPLAY_NAME

public static final java.lang.String RESTYPE_DISPLAY_NAME
See Also:
Constant Field Values

RA_SKEL_DIR

public static final java.lang.String RA_SKEL_DIR
See Also:
Constant Field Values

RA_MAKE_DIR

public static final java.lang.String RA_MAKE_DIR
See Also:
Constant Field Values

RA_NISSHADOW

public static final java.lang.String RA_NISSHADOW
See Also:
Constant Field Values

RA_USERADD_CREATE_GROUP

public static final java.lang.String RA_USERADD_CREATE_GROUP
Resource attribute name of the variable used to set whether the Red Hat useradd command is to create a group with the same name as the user being added to the system.

See Also:
Constant Field Values

DISABLED_ATTRIBUTE

public static final java.lang.String DISABLED_ATTRIBUTE
The special attribute name we use to represent the disable status. This should be moved to ResourceAdapterBase when we're ready to represent disable status uniformly as an attribute rather than a ResourceInfo flag.

See Also:
Constant Field Values
Constructor Detail

ShellScriptResourceAdapter

public ShellScriptResourceAdapter()
Method Detail

staticCreatePrototypeResource

public static Resource staticCreatePrototypeResource()
                                              throws WavesetException
Throws:
WavesetException

staticCreatePrototypeResource

public static Resource staticCreatePrototypeResource(java.lang.String resName,
                                                     java.lang.String resTypeDisplayName,
                                                     java.lang.String className,
                                                     java.lang.String userFormName,
                                                     java.lang.String loginModuleName,
                                                     java.lang.String loginUserAttrName,
                                                     java.lang.String loginPasswordAttrName)
                                              throws WavesetException
Converts the generic svidPrototypeXml to a specific instance (eg Solaris, HP-UX) by creating a Resource object and modifying it appropriately.

Throws:
WavesetException

createPrototypeResource

public Resource createPrototypeResource()
                                 throws WavesetException
Non-static version of staticCreatePrototypeResource()

Specified by:
createPrototypeResource in interface ResourceAdapter
Specified by:
createPrototypeResource in class ResourceAdapterBase
Throws:
WavesetException

getResultHandler

protected com.waveset.adapter.ShellScriptResultHandler getResultHandler()

setResultHandler

protected void setResultHandler(com.waveset.adapter.ShellScriptResultHandler resultHandler)

getScriptSource

protected com.waveset.adapter.ShellScriptSource getScriptSource()

setScriptSource

protected void setScriptSource(ShellScriptSourceBase scriptSource)

getFeatures

public GenericObject getFeatures()
Expose features supported by the Resource Adapter. Note: ActiveSync is considered a facet, not a feature.

Specified by:
getFeatures in interface ResourceAdapter
Overrides:
getFeatures in class GenericScriptResourceAdapter
Returns:
GenericObject containing Features, as both key and value, which are supported by this resource adapter.
See Also:
ResourceAdapter.Features

getAccountIterator

public AccountIterator getAccountIterator()
                                   throws WavesetException
Description copied from class: UnixResourceAdapter
Override the GenericScriptResourceAdapter method Returns an account iterator containing all of the users on the resource. Defers to abstract methods getAccountIteratorScript and getAccountIteratorResult for resource specific behavior.

Specified by:
getAccountIterator in interface ResourceAdapter
Overrides:
getAccountIterator in class UnixResourceAdapter
Throws:
WavesetException

getAccountIteratorScript

protected Script getAccountIteratorScript()
                                   throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Returns a script that can be run on an opened and logged in ScriptedConnection to pull a list of users out of the system. Needs to be defined in the derived class to send a command that will cause a list of users to be emitted, and to capture that list for parsing in getAccountIteratorResult. Should NOT send login or logout commands.

Specified by:
getAccountIteratorScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getAccountIteratorScript

protected Script getAccountIteratorScript(long timeout)
                                   throws WavesetException
Overrides:
getAccountIteratorScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getAccountIteratorScript

public Script getAccountIteratorScript(long timeout,
                                       boolean hasTimeout)
                                throws WavesetException
Throws:
WavesetException

getAuthenticateScript

protected Script getAuthenticateScript(java.util.HashMap loginInfo)
                                throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Generates a script for authenticating a user on the resource using the username and password in the loginInfo HashMap. Should NOT login or logout. Should be defined in the derived class to verify with the shell that the userid and password are authentic.

Specified by:
getAuthenticateScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getBlockAccountIteratorScript

public Script getBlockAccountIteratorScript(long timeout,
                                            boolean hasTimeout)

getCheckCreateAccountScript

public Script getCheckCreateAccountScript()
                                   throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Returns a shell script to check the resource and determine if a create account request is likely to succeed. Running the script through the scripted connection may cause a failure and throw, or evaluating the resulting capture list may result in a throw. The script should NOT login or logout. Must be defined in derived class to generate script.

Specified by:
getCheckCreateAccountScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getCheckDeleteAccountScript

public Script getCheckDeleteAccountScript()
                                   throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Returns a shell script to check the resource and determine if a delete account request is likely to succeed. Running the script through the scripted connection may cause a failure and throw, or evaluating the resulting capture list may result in a throw. The script should NOT login or logout. Must be defined in derived class to generate script.

Specified by:
getCheckDeleteAccountScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getCheckUpdateAccountScript

public Script getCheckUpdateAccountScript()
                                   throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Returns a shell script to check the resource and determine if an update account request is likely to succeed. Running the script through the scripted connection may cause a failure and throw, or evaluating the resulting capture list may result in a throw. The script should NOT login or logout. Must be defined in derived class to generate script.

Specified by:
getCheckUpdateAccountScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getCreateUserScript

protected Script getCreateUserScript(WSUser user)
                              throws WavesetException
Generates a script that will create an account for the passed user on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

Overrides:
getCreateUserScript in class UnixResourceAdapter
Throws:
WavesetException

getCreateGroupScript

public Script getCreateGroupScript(java.lang.String groupName,
                                   GenericObject attrs,
                                   java.util.Map options,
                                   boolean isSaveAs)
                            throws WavesetException
Description copied from class: UnixResourceAdapter
Returns a script which will create a group.

Overrides:
getCreateGroupScript in class UnixResourceAdapter
Throws:
WavesetException

getDeleteGroupScript

public Script getDeleteGroupScript(GenericObject object,
                                   java.util.Map options)
                            throws WavesetException
Description copied from class: UnixResourceAdapter
Generates a script that will delete a group on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

Overrides:
getDeleteGroupScript in class UnixResourceAdapter
Throws:
WavesetException

getDeleteUserScript

protected Script getDeleteUserScript(WSUser user)
                              throws WavesetException
Description copied from class: UnixResourceAdapter
Generates a script that will delete the account of the passed user on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

Overrides:
getDeleteUserScript in class UnixResourceAdapter
Throws:
WavesetException

getDisableUserScript

protected Script getDisableUserScript(WSUser user,
                                      java.lang.String password)
                               throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Generates a script that will disable an account for the passed user on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

Specified by:
getDisableUserScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getEnableUserScript

protected Script getEnableUserScript(WSUser user,
                                     java.lang.String password)
                              throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Generates a script that will enable an account for the passed user on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

Specified by:
getEnableUserScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getGetGroupScript

protected Script getGetGroupScript(java.lang.String objectId,
                                   java.util.List attrsToGet,
                                   java.util.Map options)
                            throws WavesetException
Description copied from class: UnixResourceAdapter
Returns a script which will retrieve a group's attributes.

Overrides:
getGetGroupScript in class UnixResourceAdapter
Throws:
WavesetException

getGetObjectScript

protected Script getGetObjectScript(java.lang.String objectType,
                                    java.lang.String objectId,
                                    java.util.List attrsToGet,
                                    java.util.Map options)
                             throws WavesetException
Description copied from class: UnixResourceAdapter
Returns a script which will retrieve the attributes of an object of the specified type from the scriptedConnection.

Overrides:
getGetObjectScript in class UnixResourceAdapter
Throws:
WavesetException

getListAllObjectsScript

protected Script getListAllObjectsScript(java.lang.String resObjType,
                                         java.util.Map options,
                                         java.lang.String runAsUser,
                                         EncryptedData runAsPassword)
                                  throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Returns a script which will return a list of objects of a specified type from the scriptedConnection. This script should login as the username and password, if specified, or login as the authoritative account.

Overrides:
getListAllObjectsScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getRenameGroupScript

protected Script getRenameGroupScript(GenericObject object)
                               throws WavesetException
Description copied from class: UnixResourceAdapter
Returns a script which will rename a group.

Overrides:
getRenameGroupScript in class UnixResourceAdapter
Throws:
WavesetException

getRenameUserScript

protected Script getRenameUserScript(GenericObject object)
                              throws WavesetException
Description copied from class: UnixResourceAdapter
Returns a script which will rename a user account.

Overrides:
getRenameUserScript in class UnixResourceAdapter
Throws:
WavesetException

getScanningScript

protected Script getScanningScript(java.util.Map scanArgs)
                            throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Generates a script that will return a list of all the users and interesting attributes for scanning.

Resources which support scanning will have to implement both a genScanningScript and getScanningResult along the "_supportsScanning" attribute to true. ( in the prototype xml )

Overrides:
getScanningScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getUpdateGroupScript

protected Script getUpdateGroupScript(GenericObject object)
                               throws WavesetException
Description copied from class: UnixResourceAdapter
Returns a script which will update a group.

Overrides:
getUpdateGroupScript in class UnixResourceAdapter
Throws:
WavesetException

getUserScript

protected Script getUserScript(WSUser user)
                        throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Returns a script that sends commands to check for existence of the passed user on the resource. Upon execution, captures necessary text for analysis by getUserResult method.

Specified by:
getUserScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getUpdateUserScript

protected Script getUpdateUserScript(java.lang.String accountId,
                                     java.lang.String password)
                              throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Generates a script that will update an account for the passed user on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

Overrides:
getUpdateUserScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getUpdateUserScript

protected Script getUpdateUserScript(WSUser user,
                                     java.lang.String password)
                              throws WavesetException
Description copied from class: UnixResourceAdapter
Generates a script that will create an account for the passed user on the resource. The script can be executed on a ScriptedConnection. Should NOT login or logout.

If the userID is passed in, the update will fail if the Id is in use by another user, but will succeed if the userId is the same or is a new value. Changing the user's ID will not change the files owned by that user.

If you make changes here, check to see if the changes should be applied to implementations in subclasses (eg HPUXResourceAdapter)

Overrides:
getUpdateUserScript in class UnixResourceAdapter
Throws:
WavesetException

getAccountIteratorResult

protected AccountIterator getAccountIteratorResult(CaptureList captureList)
                                            throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Generates an account iterator from the capture list that was built from running the getAccountIteratorScript generated script through the ScriptedConnection. Should be defined in the derived class to wade through the captured script output, extract out the users, and build up an AccountIterator implementation covering them all.

Specified by:
getAccountIteratorResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getAuthenticateResult

protected WavesetResult getAuthenticateResult(java.util.HashMap loginInfo,
                                              CaptureList captureList)
                                       throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Takes the capture list from running the authenticate script through the resource and validates it. Throws if it is invalid. Should be defined in the derived class to evaluate the captured output of running the authenticate script through the ScriptedConnection

Specified by:
getAuthenticateResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getCheckCreateAccountResult

protected WavesetResult getCheckCreateAccountResult(CaptureList captureList)
                                             throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Validates the capture list returned from the check create account script execution. Returns a result if create account is likely to succeed, otherwise throws. The executing script may also throw if check fails. Derived class must define this to evaluate the capture list and throw if it is invalid.

Specified by:
getCheckCreateAccountResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getCheckDeleteAccountResult

protected WavesetResult getCheckDeleteAccountResult(CaptureList captureList)
                                             throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Validates the capture list returned from the check delete account script execution. Returns a result if delete account is likely to succeed, otherwise throws. The executing script may also throw if check fails. Derived class must define this to evaluate the capture list and throw if it is invalid.

Specified by:
getCheckDeleteAccountResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getCheckUpdateAccountResult

protected WavesetResult getCheckUpdateAccountResult(CaptureList captureList)
                                             throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Validates the capture list returned from the check update account script execution. Returns a result if update account is likely to succeed, otherwise throws. The executing script may also throw if check fails. Derived class must define this to evaluate the capture list and throw if it is invalid.

Specified by:
getCheckUpdateAccountResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getCreateUserResult

protected void getCreateUserResult(CaptureList captureList,
                                   WavesetResult result)
                            throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the capture list generated by executing the create user script on the scripted connection. Throws if the capture list indicates failure. The executing script may throw on failure also.

Specified by:
getCreateUserResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getDeleteUserResult

protected void getDeleteUserResult(CaptureList captureList)
                            throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the capture list generated by executing the delete user script on the scripted connection. Throws if the capture list indicates failure. The executing script may throw on failure also.

Specified by:
getDeleteUserResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getDisableUserResult

protected boolean getDisableUserResult(CaptureList captureList)
                                throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the capture list generated by executing the disable user script on the scripted connection. Returns a boolean indicating if the operation was successful. Throws if the capture list indicates failure. The executing script may throw on failure also.

Specified by:
getDisableUserResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getEnableUserResult

protected boolean getEnableUserResult(CaptureList captureList)
                               throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the capture list generated by executing the enable user script on the scripted connection. Returns a boolean indicating if the operation was successful. Throws if the capture list indicates failure. The executing script may throw on failure also.

Specified by:
getEnableUserResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getUpdateUserResult

protected void getUpdateUserResult(WSUser user,
                                   CaptureList captureList,
                                   WavesetResult result)
                            throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the capture list generated by executing the update user script on the scripted connection. Throws if the capture list indicates failure. The executing script may throw on failure also.

Specified by:
getUpdateUserResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getUserResult

protected WSUser getUserResult(CaptureList captureList,
                               WSUser targetUser)
                        throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the capture list generated by executing the get user script on the scripted connection. Returns null if the capture list indicates failure. Otherwise returns the new user. Should probably be called getGetUserResult for consistency, but that would look funny.

Specified by:
getUserResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getCreateGroupResult

public WavesetResult getCreateGroupResult(CaptureList captureList)
                                   throws WavesetException
Overrides:
getCreateGroupResult in class UnixResourceAdapter
Throws:
WavesetException

getGetGroupResult

public GenericObject getGetGroupResult(java.lang.String groupName,
                                       java.util.List attrsToGet,
                                       CaptureList captureList)
                                throws WavesetException
Overrides:
getGetGroupResult in class UnixResourceAdapter
Throws:
WavesetException

getGetUserResult

public GenericObject getGetUserResult(java.lang.String objectName,
                                      java.util.List attrsToGet,
                                      CaptureList captureList)
                               throws WavesetException
Overrides:
getGetUserResult in class UnixResourceAdapter
Throws:
WavesetException

getListAllObjectsResult

public java.util.ArrayList getListAllObjectsResult(java.lang.String objectType,
                                                   CaptureList captureList)
                                            throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Analyzes the captrure list generated by executing the listAllObjects script on the scripted connection. Throws if the capture list indicates failure. The executing script may throw on failure also.

Overrides:
getListAllObjectsResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getRenameGroupResult

public WavesetResult getRenameGroupResult(GenericObject object,
                                          CaptureList captureList)
                                   throws WavesetException
Overrides:
getRenameGroupResult in class UnixResourceAdapter
Throws:
WavesetException

getRenameUserResult

public WavesetResult getRenameUserResult(GenericObject object,
                                         CaptureList captureList)
                                  throws WavesetException
Overrides:
getRenameUserResult in class UnixResourceAdapter
Throws:
WavesetException

getScanningResult

public WavesetResult getScanningResult(CaptureList captureList,
                                       java.util.Map args)
                                throws WavesetException
Description copied from class: GenericScriptResourceAdapter
Based on the result of the scan routine's capturelist and the arguments passed into the routine, generate some output. You may or may not use the scanArgs in the processing of the results, it depends on what mechanisms are available on each resource.

Resources which support scanning will have to implement both a genScanningScript and getScanningResult along the "_supportsScanning" attribute to true. ( in the prototype xml )

Overrides:
getScanningResult in class GenericScriptResourceAdapter
Throws:
WavesetException

getUpdateGroupResult

public WavesetResult getUpdateGroupResult(GenericObject object,
                                          CaptureList captureList)
                                   throws WavesetException
Overrides:
getUpdateGroupResult in class UnixResourceAdapter
Throws:
WavesetException

getUpdateUserResult

public WavesetResult getUpdateUserResult(GenericObject object,
                                         CaptureList captureList)
                                  throws WavesetException
Overrides:
getUpdateUserResult in class UnixResourceAdapter
Throws:
WavesetException

getAccountIterator

public AccountIterator getAccountIterator(long timeout)
                                   throws WavesetException
Description copied from class: UnixResourceAdapter
Note: Overrides the method in GenericScriptAdapter. The runScript method invokes methods which have a timeout built in and these need to be overridden in order to have valid timeout implementations.

Returns an account iterator containing all of the users on the resource. Defers to abstract methods getAccountIteratorScript and getAccountIteratorResult for resource specific behavior.

Specified by:
getAccountIterator in interface ResourceAdapter
Overrides:
getAccountIterator in class UnixResourceAdapter
Throws:
WavesetException

getConnectionTestScript

protected Script getConnectionTestScript()
                                  throws WavesetException
Creates a script to test the connection, does NOT login or logout.

Specified by:
getConnectionTestScript in class UnixResourceAdapter
Throws:
WavesetException

getConnectionTestResult

protected WavesetResult getConnectionTestResult(CaptureList captureList)
                                         throws WavesetException
Evaluates capture list from execution of generic test connection script.

Specified by:
getConnectionTestResult in class UnixResourceAdapter
Throws:
WavesetException

getLoginScript

protected Script getLoginScript()
                         throws WavesetException
Returns a script that will log the administrative user into the system and set up the shell if necessary.

Specified by:
getLoginScript in class GenericScriptResourceAdapter
Throws:
WavesetException

getLogoutScript

protected Script getLogoutScript()
                          throws WavesetException
Returns a script that will log the administrative user out of the resource.

Specified by:
getLogoutScript in class GenericScriptResourceAdapter
Throws:
WavesetException

constructUserAttributeParameter

protected java.lang.String constructUserAttributeParameter(java.lang.String key,
                                                           java.lang.String value)
Not usefull yet for generic shell scripts.

Specified by:
constructUserAttributeParameter in class GenericScriptResourceAdapter

isAllowableUserAttribute

protected boolean isAllowableUserAttribute(java.lang.String name)
Reports whether a given attribute name is legal on the resource.

Specified by:
isAllowableUserAttribute in class GenericScriptResourceAdapter

supportsResourceAccount

public boolean supportsResourceAccount()
Description copied from class: ResourceAdapterBase
Returns true if the resource adapter supports modifications to the resource account.

Specified by:
supportsResourceAccount in interface ResourceAdapter
Overrides:
supportsResourceAccount in class ResourceAdapterBase

supportsAccountDisable

public boolean supportsAccountDisable()
Description copied from interface: ResourceAdapter
Indicates whether or not this resource supports account disable. If it does not, the provisioning engine will attempt to simulate disable by generating random passwords. If we end up with more of these "can you do this" methods, we might want to generalize it into a more extensible way to describe features and levels of support.

Specified by:
supportsAccountDisable in interface ResourceAdapter
Overrides:
supportsAccountDisable in class ResourceAdapterBase

supportsExcludedAccounts

public boolean supportsExcludedAccounts()
Specified by:
supportsExcludedAccounts in interface ResourceAdapter
Overrides:
supportsExcludedAccounts in class UnixResourceAdapter

startConnection

protected void startConnection()
                        throws WavesetException
Starts a scripted connection up and logs into it.

Overrides:
startConnection in class UnixResourceAdapter
Throws:
WavesetException