只是出于好奇:
我知道,出于SQL注入的考虑,不应该将值传递给查询。
我有一个类似于下面的查询。如何将其用于SQL注入?
select * from users u inner join departments d on u.id = d.user_id
where u.id = '#{name}'所以所做的查询是
select * from users u inner join departments d on u.id = d.user_id
where u.id = 'An'该查询只是一个示例,而不是一个有效的查询。
发布于 2018-10-04 19:59:58
对name使用以下内容
' UNION SELECT username, password /* more fields */ FROM secrettable WHERE '' = 'https://stackoverflow.com/questions/52645954
复制相似问题