Enabling security with a WebSphere file-based user registry only
You can enable WebSphere global security by using only the WebSphere Application Server file based user registry.
Procedure
- Optional: If you have WebSphere Commerce Payments
instances, complete this step:
- Open Configuration Manager.
- Click WebSphere Commerce > node_name > Payments > Instance List > instance_name > Instance Properties > instance.
- Clear the Password Required for startup check box.
- Click Apply.
- Close the Configuration Manager.
- In the WebSphere Application Server Administration Console,
modify the global security settings.
- Log on as a user with administrative authority.
- Start the WebSphere Application Server administration server.
- Open the WebSphere Integrated Solutions Console.
- Click Security and go to Global
security. Under Available realm definitions,
select Federated repositories and click Set
as current. Click Configure.Note: The assumption is that the Federated Repositories realm contains one repository: the internal file-based repository.
- Enter your primary administrative user name. This user is created in the internal file-based repository if it does not exist there.
- Enter your server user identity:
- Select Automatically generated server identity.
- Click Apply and then Save.
- Return to Global security.
- Confirm that Federated Repositories is set at current realm definition. Under Available realm definitions, select Federated repositories and click Set as current.
- Select Enable administrative security.
- Optional: Select Enable application security.
- Clear Use Java 2 security to restrict application access to local resources.
- Click Apply and then Save.
- Complete the following steps if you selected Enable
application security:
- In the navigation pane, click Applications > Application Types > WebSphere enterprise
applications
- Click Security role to user/group mapping.
- Select WCSecurity Role and click Look
up users and locate the user whose role you want to map.Note: This user name is the primary administrative user name that you specified in step 6e.
- Click OK and then Save.
- Click User RunAs roles.
- Select WCSecurityRole and specify the user name and password.
- Click Apply.
- Click OK and then Save.
- Open WebSphere Commerce Developer.
- Open the META-INF\ibm-application-bnd.xmi file in the WebSphere Commerce EAR project, and click the Design view of the file.
- Expand and select Security Role (WCSecurityRole).
- Click Add, select User and click OK.
- Under the Details heading, enter the distinguished name of the RunAs ID user, for example: uid=configadmin,o=defaultWIMFileBasedRealm.
- Save your changes.
- In the navigation pane, click Applications > Application Types > WebSphere enterprise
applications
- Enable security in the WebSphere Commerce application.
- On WebSphere Commerce:
- Open the Configuration Manager.
- Select WebSphere Commerce > node_name > Commerce > Instance List > instance_name > Instance Properties > Security.
- Select the Enable Administrative Security check box.
- Enter the Server user ID and password that you use to login to the WebSphere Application Server administrative console.
- Complete the following steps if you selected Enable
application security:
- Select the Enable Application Security check box. Click Yes to any confirmation prompts that appear.
- Enter the user ID and password for the user with the WCSecurityRole that you previously specified.
- Click Apply.
- Close the Configuration Manager.
- On WebSphere Commerce Developer:
- Modify the
wc-server.xml
file by completing these steps:- Open a command-line utility and go to the WCDE_installdir/bin directory.
- Use the wcs_encrypt command to generate an encrypted string of your password. Record the ASCII encrypted string.
- Open the file WCDE_installdir/workspace/WC/xml/config/wc-server.xml
- Update the Security section:
Where:<Security AdminPwd="WASAdminPassword" AdminUser="WASAdminUserName" AuthMode="" Realm="" RunAsID="" RunAsPwd="" enabled="false" enabledGlobal="true" passwordpolicy="true" />
- WASAdminPassword
- The ASCII encrypted string that is generated by the wcs_encrypt command, for the primary WebSphere Application Server administrative security user's password.
- WASAdminUserName
- The distinguished name of the primary WebSphere Application Server administrative security user, for example uid=configadmin,o=defaultWIMFileBasedRealm.
- Optional: If application security is enabled, you must update
the Security section with the following values, marked in bold:
Where:<Security AdminPwd="WASAdminPassword" AdminUser="WASAdminUserName" AuthMode="" Realm="" RunAsID="RunAsUserID" RunAsPwd="RunAsUserPassword" enabled="true" enabledGlobal="true" passwordpolicy="true" />
- RunAsUserID
- The distinguished name of the user that has the WCSecurityRole, for example, uid=configadmin,o=defaultWIMFileBasedRealm.
- RunAsUserPassword
- The ASCII encrypted string that is generated by the wcs_encrypt command, for the RunAs user's password.
- Save your changes and close the file.
- Manually configure these additional WebSphere Application Server
security properties:
- Configure the WebSphere Commerce Test Server properties.
- Right-click on the server and select Open.
- Go to the Security panel.
- Select Security is enabled on this server.
- Enter the user ID and plain-text password for the current active
authentication settings. Note: Enter the same user ID and password as the WebSphere Application Server Primary Administrative User specified in the wc-server.xml file.
- Configure the WebSphere Commerce Test Server properties.
- Modify the
- Restart your WebSphere Commerce instance.
What to do next
If you are working in your development environment and you enabled application security, you must also enable application security on your search server. For more information, see Securing the WebSphere Commerce search server.