简单说清楚什么是SQL Injection?

最近看完了《The Pragmatic Programmer: 20th Anniversary Edition, 2nd Edition: Your Journey to Mastery》,在第7章:While You Are Coding的footnotes中,提到了一幅漫画:

这不仅用简单的方式说清楚了什么是SQL Injection,而且这个网站还提供各种编程语言下的SQL Injection示例。

其实如果你熟悉Shell脚本,我也一个更简单的例子来演示injection。虽然不是SQL Injection,而是Shell脚本注入,但意思是一样的。

bash 复制代码
$ ls *.out
a.out

$ cat a.sh
eval "ls -l $*"

$ ./a.sh "*.c;rm *.out"
-rw-r--r-- 1 oracle oinstall 67 Mar  1 05:29 a.c

$ ls *.out
ls: cannot access '*.out': No such file or directory
相关推荐
叫我阿柒啊13 小时前
从Java全栈到前端框架:一次真实面试的深度复盘
java·spring boot·typescript·vue·database·testing·microservices
mooyuan天天13 天前
sqli-labs靶场安装与使用指导教程(3种方法:通用版、php7版、Docker版)
web安全·sql注入·数据库安全·sql注入漏洞·sqli-labs·sqli-labs靶场
DONG91315 天前
《三驾马车:MySQL、MongoDB、Redis对比与融合实战》
数据库·redis·sql·mysql·mongodb·database
DONG91317 天前
Redis内存架构解析与性能优化实战
数据库·redis·sql·database
水涵幽树18 天前
MySQL 时间筛选避坑指南:为什么格式化字符串比较会出错?
数据库·后端·sql·mysql·database
我科绝伦(Huanhuan Zhou)21 天前
KINGBASE集群日常维护管理命令总结
数据库·database
Demonsong_22 天前
在职老D渗透日记day19:sqli-labs靶场通关(第26a关)get布尔盲注 过滤or和and基础上又过滤了空格和注释符 ‘)闭合
sql注入
菜根Sec25 天前
Sqli-labs靶场搭建及报错处理
web安全·网络安全·渗透测试·sql注入·网络安全靶场