main.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:ructf-2017-tasks 作者: HackerDom 项目源码 文件源码
def catch_hash_page(some_hash):
    if ip_in_db(request.remote_addr):
        if some_hash in image_mappings:
            image = 'Banned!<p></p><img src="images/{}">'\
                .format(image_mappings[some_hash])
            return render_template(
                "index.html", content={"link": "", "text": image})
        else:
            return render_template(
                "index.html", content={"link": "", "text": "wrong way:("})

    add_ip(request.remote_addr)
    return render_template(
        "index.html",
        content={
            "link": next_url(some_hash),
            "text": "You're on the right way!"})
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号