<?php
include('config.php');
session_start();
if($_SESSION['time'] && time() - $_SESSION['time'] > 60) {
session_destroy();
die('timeout');
} else {
$_SESSION['time'] = time();
}
echo rand();
if (isset($GET['go'])) {
$_SESSION['rand'] = array();
$i = 5;
$d = '';
while($i--){
$r = (string)rand();
$_SESSION['rand'][] = $r;
$d .= $r;
}
echo md5($d);
} else if (isset($_GET['check'])) {
if ($_GET['check'] === $_SESSION['rand']) {
echo $flag;
} else {
echo 'die';
session_destroy();
}
} else {
show_source(FILE_);
}
?>
1
virusdefender 2016-03-12 21:41:35 +08:00
0ctf 啊 很简单的,自己想想
|
2
yxwzaxns OP @virusdefender 能给个关键词么,我去查
|
3
yxwzaxns OP 自己顶一下
|