简单说清楚什么是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脚本注入,但意思是一样的。

$ 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

相关推荐

  1. promise什么与使用方法

    2024-04-02 07:16:04       40 阅读
  2. 什么架构?我的理解

    2024-04-02 07:16:04       34 阅读

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-04-02 07:16:04       94 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-04-02 07:16:04       101 阅读
  3. 在Django里面运行非项目文件

    2024-04-02 07:16:04       82 阅读
  4. Python语言-面向对象

    2024-04-02 07:16:04       91 阅读

热门阅读

  1. 前端安全-面试题(2024)

    2024-04-02 07:16:04       44 阅读
  2. Stable Diffusion本地部署全攻略:从概念到实战

    2024-04-02 07:16:04       34 阅读
  3. AutoGluon

    2024-04-02 07:16:04       34 阅读
  4. jvm 调优的方式

    2024-04-02 07:16:04       36 阅读
  5. 【C/C++】C语言实现串

    2024-04-02 07:16:04       27 阅读
  6. ChatGPT:打破学术写作束缚

    2024-04-02 07:16:04       33 阅读
  7. 图论做题笔记:bfs

    2024-04-02 07:16:04       39 阅读
  8. APP自动化测试-Appium元素定位之元素等待

    2024-04-02 07:16:04       36 阅读
  9. 工业互联网和云计算有关联吗

    2024-04-02 07:16:04       31 阅读
  10. 【BUG】No module named ‘dnf‘

    2024-04-02 07:16:04       36 阅读
  11. 简易聊天室

    2024-04-02 07:16:04       35 阅读