码迷,mamicode.com
首页 > 其他好文 > 详细

simplecheck

时间:2019-08-29 23:56:00      阅读:204      评论:0      收藏:0      [点我收藏+]

标签:lse   code   style   bre   flag   ati   查看   相同   it!   

环境:win10

工具:jadx 、夜神模拟器、pycharm

下载好了之后加载到模拟器

技术图片

 输入正确的flag验证

加载到jadx。查看MainAtivity if语句进行验证是否正确,如果正确就输出you get it!调用了a函数,查看一下a函数

技术图片

 技术图片

 看到定义了四个数组a b c d

其中对arr数组的长度进行验证是否和a数组的长度相同,定义一个长度i2初始化为0,if语句判断如果不正确就返回FALSE,继续i2++

技术图片

 计算出a数组的长度为35

a = [0, 146527998, 205327308, 94243885, 138810487, 408218567, 77866117, 71548549, 563255818, 559010506, 449018203, 576200653, 307283021, 467607947, 314806739, 341420795, 341420795, 469998524, 417733494, 342206934, 392460324, 382290309, 185532945, 364788505, 210058699, 198137551, 360748557, 440064477, 319861317, 676258995, 389214123, 829768461, 534844356, 427514172, 864054312]
b = [13710, 46393, 49151, 36900, 59564, 35883, 3517, 52957, 1509, 61207, 63274, 27694, 20932, 37997, 22069, 8438, 33995, 53298, 16908, 30902, 64602, 64028, 29629, 26537, 12026, 31610, 48639, 19968, 45654, 51972, 64956, 45293, 64752, 37108]
c = [38129, 57355, 22538, 47767, 8940, 4975, 27050, 56102, 21796, 41174, 63445, 53454, 28762, 59215, 16407, 64340, 37644, 59896, 41276, 25896, 27501, 38944, 37039, 38213, 61842, 43497, 9221, 9879, 14436, 60468, 19926, 47198, 8406, 64666]
d = [0, -341994984, -370404060, -257581614, -494024809, -135267265, 54930974, -155841406, 540422378, -107286502, -128056922, 265261633, 275964257, 119059597, 202392013, 283676377, 126284124, -68971076, 261217574, 197555158, -12893337, -10293675, 93868075, 121661845, 167461231, 123220255, 221507, 258914772, 180963987, 107841171, 41609001, 276531381, 169983906, 276158562]
flag="";
for m in range(1,34):
    for n in range(0,127):
        if(a[m]==b[m]*n*n+c[m]*n+d[m])|(a[m]==b[m-1]*n*n+c[m-1]*n+d[m-1]):
            flag+=chr(n)
            break
        else:
            pass
print(flag+"}")

 

simplecheck

标签:lse   code   style   bre   flag   ati   查看   相同   it!   

原文地址:https://www.cnblogs.com/chuxinbubian/p/11432404.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!