-
题目提醒
Build With Smarty,猜测应该是smarty ssti,右上角显示了IP,猜测注入点应该再X-Forwarded-For -
设置
X-Forwarded-For为{7+7},在current ip处回显14,确实在这里存在ssti
查阅smarty手册,发现{$smarty.version},返回版本信息3.1.30,这里smarty的版本是,${smarty.template}返回当前模板的文件名4ed582e9244071180a8f7bf5488bbe35a977987esmarty中的{if}标签中可以执行php语句,得flag:{if readfile('/flag')}{/if}
tips: smarty中还有{literal}、{php}(smarty 2可用),试试{literal}或许还有别的解题思路。
{literal}可以让块中间的内容忽略Smarty的解析,paylaod: {literal}alert('xss');{/literal} 可以产生 xss