![]() |
Copyright © Cloud Software Group, Inc. All Rights Reserved |
Task A Create a shared resourceTask C Create policyTIBCO API Exchange Gateway provides a sample properties file XmlAsp.properties for the shared resource. Use this file as a template and edit the properties, as required.ASG_CONFIG_HOME/BookQuerySecurity/security/resource/XmlAsp.properties
Specifies the name of the XML file containing the credentials of the user(s) required for authentication. The location of the XML file can be either a relative path or an absolute file path. The relative file path is relative to the ASG_CONFIG_HOME/ASGProjectConfiguration/security/resource directory.For example, XmlAspUsers.xml is found in the following directory: ASG_CONFIG_HOME/BookQuerySecurity/security/resource. See Create XML File for Credentials.The username and password used during authentication are set in an XML file. Refer to the ASG_CONFIG_HOME/BookQuerySecurity/security/resource/XmlAspUsers.xml file as a template.
<realm xmlns="http://xsd.tns.tibco.com/trinity/realm/2013" hashAlgorithm="PBKDF2WithHmacSHA256" repetitionCount="1000">
• Plain text passwords can be specified using the <plaintext> element in the XML file. Any plain text passwords inside <plaintext> elements are converted automatically. The file is rewritten and all plain text entries are replaced with hashed passwords according to the hashAlgorithm and repetitionCount attributes defined in the same XML file.
• To generate the password hashes, you can use the asg-password-hasher.exe utility provided by TIBCO API Exchange Gateway. See asg-password-hasher Tool.
−
−
−
− The default value is PBKDF2WithHmacSHA256repetitionCount is the number of iterations used to compute the hash for the password. The higher the repetitionCount, the harder it becomes for an attacker to crack the password. However, using a higher repetition consumes more CPU time during the password verification.The default value is 1000
The values of hashAlgorithm and repetitionCount apply to all hashed passwords in the XML file.
TIBCO API Exchange Gateway provides a command-line asg-password-hasher.exe utility to generate hash passwords which is located in the ASG_HOME/bin directory.The asg-password-hasher.exe utility prompts you to specify the following parameters:The HashAlgorithm parameter is configured as hashAlgorithm attribute in the XML file. The possible values are as follows:
−
−
−
− If you do not specify any value, the default value PBKDF2WithHmacSHA256 is accepted.The Iteration count parameter specifies the repetitionCount attribute in the XML file. If you do not specify any value, the default value 1000 is accepted.
• The asg-password-hasher.exe utility generates the password with the salt and hash. The generated hashed password is configured in the XML file.
Ensure that the values of HashAlgorithm and Iteration count parameters for the asg-password-hasher utility match the hashAlgorithm and repetitionCount attributes specified in the XML file.Before you create a policy, ensure that you have created the shared resource properties file. See Create a Shared Resource Properties File for details.ASG_CONFIG_HOME/BookQuerySecurity/security/policy/AuthenticationByXml.policy
2. Edit the parameters in the file, as required. For example, change the ResourceInstance parameter to match the shared resource name as follows:The properties for the XmlAsp shared resource are defined in the XmlAsp.properties file which is found in the ASG_CONFIG_HOME/BookQuerySecurity/security/resource directory.
ASG_CONFIG_HOME/BookQuerySecurity/security/policy/AuthenticationByXml.policy
4. Click the SECURITY tab.
5. Click the Policy Mapping tab on the top menu.
6. Click the Add Property icon to add a new policy mapping.
Table 112 Policy Mapping Parameters Set the intent for the policy. Select Authentication from the drop-down list. Set the qualifier for policy intent. Select UsernameToken or Basic from the drop-down list, as per your requirement. Specifies the policy definition file. Browse to choose a new policy file. See Create Policy File to create the policy definition file. Specifies an existing policy definition file. The policy file must exist in the gateway ASG_CONFIG_HOME/ASGProjectConfiguration/policy folder. For example, for the BookQuerySecurity project configuration, the policy file must exist in the ASG_CONFIG_HOME/BookQuerySecurity/policy folder. Select AuthenticationByXml.policy from the drop-down list to use the example policy file.
4.
5. Click the Policy Binding tab on the top menu.
6. Click the Add Property icon to add a new policy binding.
Table 113 Policy Binding Parameters Specifies a name for the policy. The policy name must be configured under the Policy Mapping tab. Specifies the binding component that the policy is applied to. The possible values are service and reference.Select service from the drop-down list. Specifies the flow of the request. Select IN from the drop-down list as this is applicable only to the facade operation (service).
![]() |
Copyright © Cloud Software Group, Inc. All Rights Reserved |