Authenticating the username, password by using filters in Java (contacting with database)

后端 未结 4 898
夕颜
夕颜 2020-11-29 02:21

The following is the piece of Java code by using filters that shows the error page at every time if the username and password is also correct. Please help me, I don\'t have

4条回答
  •  余生分开走
    2020-11-29 03:15

    First of all, you really should use parameterized queries for this. If the user enters '";DROP TABLE reg; as a username you will be in big trouble.

    Also, are you sure the username and password are correct? How about capitalization?

提交回复
热议问题