Skip to content

Latest commit

 

History

History
34 lines (25 loc) · 498 Bytes

[ACTF2020 新生赛]BackupFile.md

File metadata and controls

34 lines (25 loc) · 498 Bytes

[ACTF2020 新生赛]BackupFile

知识点

备份文件

php弱类型比较

解题

找到备份文件index.php.bak

<?php
include_once "flag.php";

if(isset($_GET['key'])) {
    $key = $_GET['key'];
    if(!is_numeric($key)) {
        exit("Just num!");
    }
    $key = intval($key);
    $str = "123ffwsfwefwf24r2f32ir23jrw923rskfjwtsw54w3";
    if($key == $str) {
        echo $flag;
    }
}
else {
    echo "Try to find out source file!";
}

传入key123即可