0

I freshly installed Apache Tomcat via ansible on CentOS 7 VM but it seems that I can't access anything. I tried editing the tomcat-users.xml with

<?xml version="1.0" encoding="UTF-8"?>

<tomcat-users>  
    <role rolename="admin"/>  
    <role rolename="admin-gui"/>  
    <role rolename="manager"/>  
    <role rolename="manager-gui"/>  

    <user username="hultanu" password="hultanu" roles="admin,admin-gui,manager,manager-gui"/>  
</tomcat-users>

Still nothing, it keep giving me 403 when I try to access "Server Status, Manager App or Host Manager". Any ideas?

Thank you !

Kohei TAMURA
  • 4,970
  • 7
  • 25
  • 49

1 Answers1

0

I have just downloaded and installed a fresh/clean version of Apache 8.5.16, copied your tomcat-users.xml into my conf folder and able to browse to the server and login to the management/admin pages using the defined user (hultanu) perfectly fine. However this was done on my Windows 10 machine.

This plus the fact you are getting a 403 (Forbidden) rather than a 401 (Unauthorized) would make me think that your user settings are fine, but there is something more fundamentally wrong with your installation of Tomcat.

Are you able to browse to the tomcat instance when running and see the standard welcome screen (by default that would be localhost:8080)?

At what point do you get the 403 response (do you get asked for login details)?

Also - not sure if this is a duplicate of this question here

welshGaz
  • 680
  • 7
  • 8