当前位置:网站首页>xctf attack and defense world web master advanced area web2
xctf attack and defense world web master advanced area web2
2022-08-01 22:07:00 【l8947943】
0x01. 进入环境,查看问题
如图,给了一串代码:
0x02. 问题分析
可以很清楚的看到,The problem is to decipher the ciphertextok了.Mainly code auditing,先解释一下phpfunction meaning in :
strrev(string): 反转字符串
strlen(string): 返回字符串的长度
substr(string, start, length): 返回字符串的一部分
string: the desired string
start: where the string starts
length: 可选.规定被返回字符串的长度.默认是直到字符串的结尾
ord(string): Returns the first character of the string ASCII 值
chr(): 从指定的 ASCII 值返回对应的字符
str_rot13(string): 对字符串执行 ROT13 编码.
ROT13 编码把每一个字母在字母表中向前移动 13 个字母.数字和非字母字符保持不变
Both encoding and decoding are done by this function.If you take an encoded string as a parameter,then the original string will be returned
base64_encode(string): 使用 MIME base64 对数据进行编码.
进行反解密,Thrown into the online run:
<?php
$miwen="a1zLbgQsCESEIqRLwuQAyMwLyq2L5VwBxqGA3RQAyumZ0tmMvSGM2ZwB4tws";
$flag="";
$a = base64_decode(strrev(str_rot13($miwen)));
for($_0=0;$_0<strlen($a);$_0++){
$_c=substr($a,$_0,1);
$__=ord($_c)-1;
$_c=chr($__);
$flag=$flag.$_c;
}
$b = strrev($flag);
echo($b);
?>
into the online operating address:https://www.dooccn.com/php/
solve the final answer:flag:{NSCTF_b73d5adfb819c64603d7237fa0d52977}
边栏推荐
- 小程序毕设作品之微信美食菜谱小程序毕业设计成品(6)开题答辩PPT
- SOM网络1:原理讲解
- 漫长的投资生涯
- The must-have "fishing artifact" for programmers is here!
- ModuleNotFoundError: No module named 'yaml'
- familiar friend
- The Microsoft campus ambassador to shout you to autumn recruit!
- 线上故障排查方案
- Kubernetes第零篇:认识kubernetes
- _ _ determinant of a matrix is higher algebra eigenvalue of the product, the characteristic value of matrix trace is combined
猜你喜欢

深度学习Course2第二周Optimization Algorithms习题整理

19 Lectures on Disassembly of Multi-merchant Mall System Functions - Invoice Management on the Platform

力扣第 304 场周赛复盘

不卷了!入职字节跳动一周就果断跑了。

【C语言实现】两种计算平均成绩题型,博主精心整理,值得一读

论文解读(GSAT)《Interpretable and Generalizable Graph Learning via Stochastic Attention Mechanism》

SOM Network 2: Implementation of the Code

Homework 8.1 Orphans and Zombies

(翻译)按钮的对比色引导用户操作的方式

感觉自己好傻
随机推荐
AI应用第一课:支付宝刷脸登录
HCIP---Architecture of Enterprise Network
使用Jenkins做持续集成,这个知识点必须要掌握
9. SAP ABAP OData 服务如何支持删除(Delete)操作
深度学习Course2第一周Practical aspects of Deep Learning习题整理
The thing about npm
shell programming conventions and variables
威纶通触摸屏如何打开并升级EB8000旧版本项目并更换触摸屏型号?
The Microsoft campus ambassador to shout you to autumn recruit!
Small program -- subcontracting
线上故障排查方案
feel so stupid
第3讲:MySQL数据库中常见的几种表字段数据类型
Dichotomy Medium LeetCode6133. Maximum Number of Groups
[@synthesize in Objective-C]
数据分析面试手册《指标篇》
Today's sleep quality record 74 points
小程序毕设作品之微信美食菜谱小程序毕业设计成品(8)毕业设计论文模板
ImportError: `save_weights` requires h5py. Problem solved
Ten years after graduation, financial freedom: those things that are more important than hard work, no one will ever teach you