Good morning folks!

I'm playing with my brand new tomcat installation today, and everything run pretty smoothly except that I got a weird reaction using the manager with virtualhosts.

The problem pop out when I try to deploy a webapp on my vhost A1 It's quite working, upload works but not the start of the app.

When I try to deploy another webapp on vhost A2 is not working at all, I can't even upload the archive.

The weird thing is both virtualhosts use the same manager.xml configuration file hosted under ${Catalina.base}/conf/Catalina/[engine]/[hostname]/manager.XML

This file is calling my main manager and this same manager is working perfectly.

When I said that the manager crash weirdly on my vhosts it's because it return a 503 error message which ask me to set the tomcat user roles and password on the tomcat-users.xml but the point is that this file is already set on the default file provided by tomcat.

If I upload my apps directly on the host appbase / docbase directory it's working perfectly due to the AutoDeploy and DeployOnStartup directives on the server.xml config file.

So if anyone of you have a hint, I'll take it ;-)


So, I've solve my problem by myself, I'll then explain it:

Tomcat manager and default applications are CSRF protected. Since I'm using VHosts behind a reverse-proxy which is relaying the client IP/domain informations, tomcat found something too weird for him and then throw a 403 response.

Solution: do not relay Origin IP/domain.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.