![]() |
1
32
这表示数据库设计不好。用户不需要知道列名。创建一个包含这些“列名”的真实数据库列,并将数据存储在该列中。
无论如何,不能将列名设置为
如果您想继续这个方向,您需要清理列名并自己连接/构建SQL字符串。引用单独的列名并使用
|
![]() |
2
15
准备允许列名的白名单。使用“查询”在白名单中查找列名称是否存在。如果没有,则拒绝查询。 |
![]() |
3
2
I think this case can't work because the whole point of the prepared statement is to prevent the user from putting in unescaped query bits - so you're always going to have the text quoted or escaped. 如果要安全地影响查询结构,则需要在Java中对该输入进行消毒。 |
![]() |
4
1
|
![]() |
5
0
Use sql injection disadvantage of Statement Interface as advantage. 前任:
|
![]() |
6
-2
下面是Java中的解决方案。
|