WAS v8.5 > Script the application serving environment (wsadmin) > Use properties files to manage system configuration > Manage specific configuration objects using properties files > Work with security properties filesWork with LTPA properties files
We can use properties files to modify or delete Lightweight Third Party Authentication (LTPA) properties.
Determine the changes to make to your LTPA configuration.
Start the wsadmin scripting tool. To start wsadmin using the Jython language, run the wsadmin -lang jython command from the bin directory of the server profile. Using a properties file, we can modify or delete a LTPA object.
Run administrative commands using wsadmin to change a properties file for a LTPA object, validate the properties, and apply them to your configuration.
Actions for LTPA properties. We can modify or delete LTPA properties.
Action Procedure create Not applicable modify Edit property values in the LTPA properties file and then run the applyConfigProperties command. delete Run the deleteConfigProperties command to delete one or more properties. If a deleted property has a default value, the property is set to the default value. Otherwise, the deleted property is removed. create Property Not applicable delete Property Not applicable Optionally, we can use interactive mode with the commands:
AdminTask.command_name('-interactive')
- Modify an existing properties file.
- Obtain a properties file for the LTPA object to change.
We can extract a properties file for an LTPA object using the extractConfigProperties command.
- Open the properties file in an editor and change the properties as needed.
Ensure the environment variables in the properties file match your system. To specify a custom property, edit the AttributeInfo value and properties values. An example LTPA properties file follows:
# # Header # ResourceType=LTPA ImplementingResourceType=Security ResourceId=Cell=!{cellName}:Security=:LTPA= # # #Properties # simpleAuthConfig=system.LTPA keySetGroup=CellLTPAKeySetGroup #ObjectName(KeySetGroup) authContextImplClass=com.ibm.ISecurityLocalObjectTokenBaseImpl.WSSecurityContextLTPAImpl authConfig=system.LTPA isCredentialForwardable=false #boolean,default(false) timeout=120 #long,required,default(0) OID="oid:1.3.18.0.2.30.2" password=null #required authValidationConfig=system.LTPA # # Header SingleSignon Section # ResourceType=SingleSignon ImplementingResourceType=Security ResourceId=Cell=!{cellName}:Security=:LTPA=:SingleSignon= AttributeInfo=singleSignon # # #Properties # enabled=true #boolean,default(false) domainName= requiresSSL=false #boolean,default(false) EnvironmentVariablesSection #Environment Variables cellName=myCell
- Run the applyConfigProperties command to create or change an LTPA object.
Running the applyConfigProperties command applies the properties file to the configuration. In this Jython example, the optional -reportFileName parameter produces a report named report.txt:
AdminTask.applyConfigProperties(['-propertiesFileName myObjectType.props -reportFileName report.txt'])
- If you no longer need a property, we can delete the LTPA property.
To delete one or more properties, specify only the properties to be deleted in the properties file and then run the deleteConfigProperties command; for example:
AdminTask.deleteConfigProperties('[-propertiesFileName myObjectType.props -reportFileName report.txt]')
Results
We can use the properties file to manage the LTPA properties.
Save the changes to your configuration.
Related
Extracting properties files using wsadmin.sh
Create server, cluster, application, or authorization group objects using properties files and wsadmin scripting
Delete server, cluster, application, or authorization group objects using properties files
Reference:
PropertiesBasedConfiguration command group for AdminTask using wsadmin.sh