Java applications are just as prone to web vulnerabilities as all other web applications. For example, despite the fact that Java has good measures to protect against SQL Injections, developers don’t have to use these measures and SQL Injections still happen quite often.
Learn how to prevent SQL Injections in Java.