问题原文
原帖链接 · xrcwrn · CC BY-SA 3.0
Is it necessary to install nginx server before using apache tomcat. Can we use only apache tomcat is there any pros cons which choice is better and why. I am using fedora 22 for deploying my application on tomcat 8 for java application
社区高分解答
原帖链接 · h22 · CC BY-SA 4.0
It is possible to use Tomcat alone, however you need to avoid some obvious mistakes. Most important
- Run your Tomcat on a separate user account with minimal rights.
- When not running as root, Tomcat will not be able to bind the privileged port that is a good security feature, not a problem. In these days I usually use xinetd to move the port. I used iptables before, it is more complex but also works fine.
- Do not forget to update both Tomcat and Java periodically.
- Block all possible ports with firewall, especially all kinds of "remote management". Only leave that you really need and use.
Do not even think about
- Running Tomcat as root.
- Leaving any of the Tomcat web management interfaces. Uninstall immediately. They have never offered anything that our could not do from the command line even faster.
- Running without firewall.
I do not see Tomcat as complex to configure and maintain, but this is maybe because I am using it for many years. Speaking about security issues, every server has them time to time, and discovered issues are periodically fixed. Just google.
摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。
