战胜卞相壹
用dirsearch扫一下,可以知道有robots.txt文件的
啊,想到当时很开心就有点想好笑,还以为发现flag了呢
,发现只有“You can’t win here! Details determine success or failure!”这段文字,
回头看那个棋谱,想着有什么信息,用py显示一下,结果写的py得到的棋盘是反的
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
| import matplotlib.pyplot as plt
sgf_moves = [ "ae", "ce", "df", "cg", "ag", "ai", "ci", "ff", "hf", "jf", "gh", "ih", "le", "lg", "li", "ni", "oh", "of", "ne" ]
coordinates = [] for move in sgf_moves: x = ord(move[0]) - ord('a') y = 19 - (ord(move[1]) - ord('a')) coordinates.append((x, y))
plt.figure(figsize=(10, 10)) for x, y in coordinates: plt.plot(x, y, 'o', markersize=10, color='black')
"""for i in range(len(coordinates) - 1): x1, y1 = coordinates[i] x2, y2 = coordinates[i + 1] plt.plot([x1, x2], [y1, y2], 'b-', linewidth=2) """
plt.xlim(0, 19) plt.ylim(0, 19) plt.gca().invert_yaxis() plt.grid(True) plt.show()
|
正确代码:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
| import matplotlib.pyplot as plt
sgf_moves = [ "ae", "ce", "df", "cg", "ag", "ai", "ci", "ff", "hf", "jf", "gh", "ih", "le", "lg", "li", "ni", "oh", "of", "ne" ]
coordinates = [] for move in sgf_moves: x = ord(move[0]) - ord('a') y = 19 - (ord(move[1]) - ord('a')) coordinates.append((x, y))
plt.figure(figsize=(10, 10)) for x, y in coordinates: plt.plot(x, y, 'o', markersize=10, color='black')
""" for i in range(len(coordinates) - 1): x1, y1 = coordinates[i] x2, y2 = coordinates[i + 1] plt.plot([x1, x2], [y1, y2], 'b-', linewidth=2) """
plt.xlim(0, 19) plt.ylim(0, 19) plt.grid(True) plt.show()
|
虽然正过来我也可能想不出这个表示:2=0
把f10g.txt改为f12g.txt就ok了
反思
首先,肯定是先要把图画对的;
其次,应该对特殊的内容比较敏感,flag->f10g,对数字敏感一点吧(虽然是自己写的,但还是感觉有点强词夺理了)
纸嫁衣6外传
还是可以先用dirsearch扫一下的,
发现是有/includes/,/upload.php/,/uploads/等文件
/upload.php是文件上传的网址,发现只能传txt文件(即使有的文件名绕过成功了,在查看文件时,发现仍然是txt格式)
后面发现,/includes/还有一个flag.php的页面
想过是用get参数包含的,但用了hammer,没成功,后面就没往这方面想了,成功错过了正确思路。。。
正确的是chuizi这个参数
这里有了文件上传+本地文件包含漏洞,——(但我没想到这个“一击打碎它”是显示php代码的意思)
即上传一个file.txt文件
1 2 3
| <?php highlight_file('includes/flag.php'); ?>
|
后用?chuizi=uploads/file.txt来包含,
之后看源代码
解一下码就可以得到flag了(Base64)
“
反思:
花了大量时间去试文件上传的绕过,结果重心不是这个;
应该要想到是有其他漏洞的,而不是死磕文件上传;