且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

SQL注入prevention

更新时间:2023-02-05 21:41:26

不要落入字符串插值陷阱!它并不安全。

Don't fall into the string-interpolation trap! It's not secure.

您甚至可以在ASP经典用真实的SQL查询参数。

You can use real SQL query parameters even in ASP Classic.

我不是一个程序员ASP,但我发现这个博客用一个ADODB.Command对象参数化的SQL查询,并在执行前绑定值参数的一个明显的例子。

I'm not an ASP programmer, but I found this blog with a clear example of using an ADODB.Command object for a parameterized SQL query, and binding values to parameters before executing.

http://securestate.blogspot.com/2008/09/classic-asp-sql-injection-$p$pvention_30.html

也看到这个问题的SO使用命名参数的一些例子:

Also see this SO question for some more examples of using named parameters:

ASP Classic在Paramaterized查询命名参数:必须声明标量变量