开发者

how to prevent SQL Injection in c language?

开发者 https://www.devze.com 2023-03-16 05:43 出处:网络
I currently use c language to process the http event, and I need to do the SQL operation with mysql, then how to prevent the SQL injection, is th开发者_运维问答ere any c library for that,thank you? SQ

I currently use c language to process the http event, and I need to do the SQL operation with mysql, then how to prevent the SQL injection, is th开发者_运维问答ere any c library for that,thank you?


SQL Injection Attacks and Some Tips on How to Prevent Them


The way you prevent SQL injection (or shell escape injection, etc.) is not passing unquoted literal strings to an interface that treats some characters as special. You need to transform string data to a safe quoted form before including it as part of a larger "command string" that will be interpreted by an SQL database, shell, external command, API that takes URI strings, etc.

0

精彩评论

暂无评论...
验证码 换一张
取 消