Hi I need to encrypt the password for tomcat console access..

I've encrypted it using the digest.sh script, and I've added it to the 
tomcat-users.xml file. See below...I've X'd out the actual password.

I also need to edit the Realm tag in the server.xml file but there is already a 
Realm for Lockout and DataSource  in it.

My question is how do I add the UserDatabase Realm....is it correct how I have 
it below?

I added the Combined Realm along with the UserDatabase Realm I can't test this 
out since we only have a production environment.



##########################################################################

Tomcat-users.xml

  <role rolename="tomcat"/>

  <role rolename="role1"/>

  <user username="tomcat" password="XXXXXXXXX" roles="tomcat,manager-gui"/>

  <user username="both" password=" XXXXXXXXX" roles="tomcat,role1"/>

  <user username="role1" password=" XXXXXXXXX" roles="role1"/>





Server.xml

     <Realm className="org.apache.catalina.realm.LockOutRealm">

         <Realm className="org.apache.catalina.realm.CombinedRealm" >

             <Realm  className="org.apache.catalina.realm.DataSourceRealm"

                     dataSourceName="jdbc/authority"

                     userTable="yyyyy"

                     digest="SHA"

                     userNameCol="xxxxxxxx"

                     userCredCol="zzzzzzzzz"

                     userRoleTable="userroles"

                     roleNameCol="role"/>



             <Realm className="org.apache.catalina.realm.UserDatabaseRealm"

                    resourceName="UserDatabase"

                    digest="sha-256" />

         </Realm>

      </Realm>


cheers,
jon frank
middleware infrastructure
w: 651-662-8216    h: 952-226-3059    c: 612-715-6522    route: m125    cube: 
m1-g9-03



This email and any files transmitted with it are confidential and intended 
solely for the use of the individual or entity to whom they are addressed. If 
you are not the named addressee you must not disseminate, distribute or copy 
this e-mail. Please notify the sender immediately by e-mail if you have 
received this e-mail by mistake and delete this e-mail from your system. If you 
are not the intended recipient you are notified that disclosing, copying, 
distributing or taking any action in reliance on the contents of this 
information is strictly prohibited.

Reply via email to