zoukankan      html  css  js  c++  java
  • BUUCTF 梅花香自苦寒来

    梅花香自苦寒来

    打开图片可以看到,在jpg后面有大量的数据,
    在这里插入图片描述
    将它保存出来,可以看出是十六进制,将它转为ascii,写脚本

     
    with open('hex.txt','r') as h:
        h=h.read()
    tem=''
    for i in range(0,len(h),2):
        tem='0x'+h[i]+h[i+1]
        tem=int(tem,base=16)
        print(chr(tem),end='')

    得到

     
    (7,7)
    (7,8)
    (7,9)
    (7,10)
    (7,11)
    (7,12)
    (7,13)
    (7,14)
    (7,15)
    (7,16)
    (7,17)
    (7,18)
    (7,19)
    (7,20)
    (7,21)
    (7,22)
    (7,23)
    

    35019个坐标,用gnuplot绘图,但要先改为gnuplot能识别的方式,写脚本

    with open('ascii.txt','r')as a:
        a=a.read()
    a=a.split()
    tem=''
    for i in range(0,len(a)):
        tem=a[i]
        tem=tem.lstrip('(')
        tem=tem.rstrip(')')
        for j in range(0,len(tem)):
            if tem[j]==',':
                tem=tem[:j]+' '+tem[j+1:]
        print(tem)
     用gnuplot

    在这里插入图片描述
    得到
    在这里插入图片描述
    扫码得flag

  • 相关阅读:
    2014第5周一
    2014第4周日
    2014第4周六
    underscore.js
    2014第4周四
    2014第4周三
    2014年第2周二
    POj 3126 Prime Path
    Oracle EBS 入门
    HDU1698_Just a Hook(线段树/成段更新)
  • 原文地址:https://www.cnblogs.com/harmonica11/p/11365812.html
Copyright © 2011-2022 走看看