[web]-sql注入-白云搜索引擎

ctrl+u查看源代码,发现前端有js过滤

<script>

	function myFunction()
	{
		var x=document.getElementById("number").value;
    var a=document.getElementById("word").value;
    var b=a.replace(/[\ |\~|\`|\!|\@|\#|\$|\%|\^|\&|\*|\(|\)|\-|\_|\+|\=|\||\\|\[|\]|\{|\}|\;|\:|\"|\'|\,|\<|\.|\>|\/|\?|\·|\!|\(|\)|\¥|\——|\……|\【|\】|\、|\;|\:|\‘|\“|\”|\’|\,|\。|\、|\《|\》|\?|\ ]/g,"");
    if(a.length!=b.length)
    {
      alert("请输入正确字符。");
      document.getElementById("number").value = '';
      document.getElementById("word").value = '';
    }
    else if(isNaN(x))
    {
      alert("请输入数字。");
      document.getElementById("number").value = '';
    }

  }


</script>

禁用js,尝试命令执行和sql注入,payload为

1'union all select 1,database(),3#

执行结果如下:可以看到数据库名称,简单的联合注入,获取库、表、列、数据内容,都是固定的脚本。不一一罗列了。

最终得到:flag{fabbf4abe040f2fdac8234099facdccb}

当然也可以用sqlmap爆破,不用考虑前端过滤的因素。

相关推荐

最近更新

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

    2024-07-13 17:26:01       67 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-07-13 17:26:01       72 阅读
  3. 在Django里面运行非项目文件

    2024-07-13 17:26:01       58 阅读
  4. Python语言-面向对象

    2024-07-13 17:26:01       69 阅读

热门阅读

  1. Flink实时开发添加水印的案例分析

    2024-07-13 17:26:01       19 阅读
  2. json保存文件乱码

    2024-07-13 17:26:01       21 阅读
  3. 神经网络——数据预处理

    2024-07-13 17:26:01       21 阅读
  4. C 标准库 - <stdio.h>

    2024-07-13 17:26:01       19 阅读
  5. 等保2.0对云计算有哪些特定的安全要求?

    2024-07-13 17:26:01       20 阅读
  6. [Spring Boot]Rest服务调用远程Get、Post请求

    2024-07-13 17:26:01       21 阅读
  7. 今日科技圈最新时事新闻(2024年7月12日

    2024-07-13 17:26:01       21 阅读
  8. Leetcode刷题4--- 寻找两个正序数组的中位数 Python

    2024-07-13 17:26:01       21 阅读
  9. 网络安全那些梗

    2024-07-13 17:26:01       20 阅读
  10. lntroducing Machine Learning

    2024-07-13 17:26:01       21 阅读