|
Home
TOC Index |
|
Using admintool
The Java Web Services Developer Pack includes the Tomcat Web Server Administration Tool, referred to hereafter as
admintoolfor ease of reference. TheadmintoolWeb application can be used to manipulate Tomcat while it is running. For example, you can add and/or configure contexts, hosts, realms, and connectors, or set up users and roles for container-managed security.To start
admintool, follow these steps.
- Start Tomcat as described in Starting Tomcat.
- Start a Web browser.
- In the Web browser, point to the following URL:
http://localhost:8080/admin
- This command invokes the
adminWeb application. Before you can use this application you must add your user name/password combination and associate the role nameadminwith it. The initial user name and password necessary to access this tool are set up during Java WSDP installation. If you've forgotten the user name and password, you can view <JWSDP_HOME>/conf/tomcat-users.xmlwith any text editor. This file contains an element<user>for each individual user, which might look something like this:<user name="adeveloper" password="secret" roles="admin, manager" />- Log in to
admintoolusing a user name and password combination that has been assigned the role ofadmin. This user name and password must match the user name and password in thebuild.propertiesfile.- When you have finished, log out of
admintoolby selecting Logout from the upper pane.This section discussing setting up roles, groups, and users using
admintool. See , for information on usingadmintoolto create, delete, and/or configure:
- The Tomcat Server.
- Services that run on the Tomcat Server, plus the elements that are nested within the Services, such as Hosts, Contexts, Realms, Connectors, Loggers, and Valves.
- Resources such as Data Sources, Environment Entries, and User Database.
Understanding Roles, Groups, and Users
The Tomcat server authentication service includes the following components:
- Role - an abstract name for the permission to access a particular set of resources. A role can be compared to a key that can open a lock. Many people might have a copy of the key, and the lock doesn't care who you are, just that you have the right key.
- User - an individual (or application program) identity that has been authenticated (authentication was discussed in the previous section). A user can have a set of roles associated with that identity, which entitles them to access all resources protected by those roles.
- Group - a set of authenticated users classified by common traits such as job title or customer profile. Groups are also associated with a set of roles, and every user that is a member of a group inherits all of the roles assigned to that group.
- Realm - a complete database of roles, users, and groups that identify valid users of a Web application (or a set of Web applications).
These concepts are addressed in more detail in Managing Roles and Users. More information on
admintoolis available in .Adding Roles Using admintool
To set up new roles for container-managed security, follow these instructions. Additions, deletions, and changes made in
admintoolare written to thetomcat-users.xml file.
- Scroll down the left pane of
admintoolto the User and Group Administration node.- Select Role Administration.
- From the Roles List, select Create New Role.
- Enter a Role Name and Description, for example
CustomerorUser.- Select Save.
Adding Users Using admintool
To set up new users for container-managed security, follow these instructions. Additions, deletions, and changes made in
admintoolare written to thetomcat-users.xml file.
- Scroll down the left pane of
admintoolto the User and Group Administration node.- Select User Administration.
- From the Users List, select Create New User.
- Enter a User Name, Password, and select a Role for the new user. If you select the
adminrole for the new user, the user will be able to accessadmintool.- Select Save.
|
Home
TOC Index |
|
This tutorial contains information on the 1.0 version of the Java Web Services Developer Pack.
All of the material in The Java Web Services Tutorial is copyright-protected and may not be published in other works without express written permission from Sun Microsystems.