You can configure a basic user registry in Liberty for authentication.
About this task
You can use a basic user registry by defining the users and groups information for authentication
on the Liberty server. To do this, you add
the appSecurity-2.0
Liberty feature to the
server.xml file, along with user information in the
basicRegistry
element.
Procedure
-
Add the
appSecurity-2.0
Liberty feature to the
server.xml file.
- Optional:
To use SSL, add the
transportSecurity-1.0
Liberty feature in the
server.xml file. See Enabling SSL communication in Liberty.
- Configure the basic registry for the server as follows:
<basicRegistry id="basic" realm="customRealm">
<user name="mlee" password="p@ssw0rd" />
<user name="rkumar" password="pa$$w0rd" />
<user name="gjones" password="{xor}Lz4sLCgwLTs=" />
<group name="students">
<member name="mlee" />
<member name="rkumar" />
</group>
</basicRegistry>