大神论坛

找回密码
快速注册
查看: 137 | 回复: 0

[其他] 逆向分析库迪汽车品牌小程序详细教程

主题

帖子

0

积分

初入江湖

UID
649
积分
0
精华
威望
0 点
违规
大神币
68 枚
注册时间
2023-10-14 10:43
发表于 2024-06-15 22:06
本帖最后由 fsjsyg 于 2024-06-15 22:06 编辑

手痒想试一试,刚好想做某迪汽车品牌的自动签到,就盯向了他!!!

一、工具准备

  • Reqable (抓包工具)

  • unveilr (解包工具)

  • vscode

  • Wechat 3.9.11.15


二、分析请求

1、配置抓包软件

抓包软件的配置见官方文档

2、启动软件抓包

3、启动小程序并抓包

我这边微信版本为3.9.11.15,应该是最新版的

请求可能会比较多,我们可以在控制台筛选只显示微信的请求

三、分析目标

1、目标一:返回值

启动小程序后就会看到很多的请求,随便点击一个即可

我们可以看到他的返回值是加密的

这种返回值后面有两个等号,一般是base64或者AES,我这边测试了base64不可以,那么就只能进行逆向分析了

2、目标二:请求头

查看请求头发现有几个请求头是非标准http协议的请求头,那么大概率也是需要逆向的,因为这几个请求头每一个请求都有!!!

x-clienttraceid:暂时不知道是什么,但是是一个什么id,可能是固定值

Nonce:暂时不知道是什么

Curtime:很明显的时间戳

Checksum:暂时不知道是什么,不过很像md5之类的摘要算法生成的

目标确定后,开始动手!!!!!!!

四、解包

1、找到wxapkg文件

在pc微信上将目标小程序打开之后,尽量把所有能点的页面都先点一遍,防止部分小程序存在分包的情况导致未能完全加载(直接复制大佬的话,我肯定没有偷懒[认真脸])

大佬发的文章中wxapkg文件是在微信的保存文件下,我这边不知道是版本问题还是设置问题,我这边是在电脑的文档目录下

我担心不好确定小程序的id,就直接全部删除了,重新加载后出现的肯定是我想要的

随便点了几下后的结果,其实每个接口都需要的内容,不点应该没啥问题(纯属推测,没试过)

2、使用unveilr解包

执行命令:

unveilr.exe "D:\Backup\Documents\WeChat Files\Applet\wxf62054ec313d6f53\58"

D:\Backup\Documents\WeChat Files\Applet\wxf62054ec313d6f53\58是我这边小程序的目录,自己替换为自己本地目录,路径一定要用双引号引起来!

执行完成:

命令执行后的结果

文件输出:

五、开始分析

直接使用vscode打开项目(因为这个项目不需要跑起来,所以就不需要微信开发工具)

一、返回值解密

1、找到关键代码

因为我们前文已经说明了,返回值可能是base64或者AES,base64的可能被我们暂时pass掉了,所以先搜索AES碰碰运气

看这个文件名,我感觉我运气还是很不错的!!!

点进来后代码是压缩过的,直接找个网页格式化一下(我试了vscode的格式化,效果不太行。。。)

格式化后的代码:

代码结构如此清晰,位置如此正确,我感觉没必要写下去了!!!(不是)

2、分析解密代码

根据函数名,我们直接看解密的函数

exports.aesDecrypt = function(e) {
var r = t.AES.decrypt({
ciphertext: t.enc.Base64.parse(e)
}, a, {
iv: n,
mode: t.mode.CBC,
padding: t.pad.Pkcs7
}).toString(t.enc.Utf8);
return JSON.parse(r)
}

代码太清晰了,真不知道说啥了。。。

加密模式是CBC,填充方法是pkcs7,接下来找到偏移量和密钥就可以了

3、找到密钥和偏移量

密钥是变量a,偏移量是n,可以直接在下面看到对应的代码。。。

根据代码,我们去constant-obfuscated.js文件里面继续找

同样先把代码格式化一下,方便我们观看

1、找密钥

搜索aes_key,可以搜索到两个结果,

第一个看着不太像。。。先试暂时确定为第二个

2、找偏移量

我们发现aes_iv是一个函数的运行结果!可以大展拳脚了!!

然后发现没啥可扣的。。。

感兴趣的可以去试一试,我这边直接说结果,偏移量为:uDEHPGzSIHIWBlNT

4、测试一下

返回值:

G0U/dA4AACHbVhH3n1yNJOc4bn0i4VomHKG3oCubQfB1AlKXWDb/l9WXd9GAApVUKCX2mdO20aKLBN6LztlpxNISnrJR/uGK00AZ2tNHYnrD7sX5zO/DnYGOnrbu0ZRo5yBbbZuIkqO5vvyYQOijwrSZhpFf6YNNBXkJfh3VyU/E0ZyrrliLIlvZRsT5Q5s1n/4Cn5riTvYA7ALex05mnGOTL2+vBXtWKmwid6GdOpeVTzY/7CuOMB4bE2qYmCfqGxvX9WfaJd9OugrX58s+jbNJ7TyBI267qPYMAxuo5cQfGV+QnY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Cr/YwasL+rRUHZBrBafcAG/HMbOUD6JdI8RFP44twFiLIYzzWrMWrMKuXxtuwNbBECGPd0rqdwHgLpMKOigs6M7NUU8TEt6qG91AyT0t9lC73NStNNPmuIl0gERXhTbj29LYHesuBDJ1Mp3f43qdrDsZxKI9OJT2xc7vpB4pgMEg6wXyBy79g3yPo4BmLc/RS8/1xuojcgowOtueVitJiKRPDSS0R4M1vXnCId5Yv7hdhg2yjRPYOZXGU/WLd8oVg0pvTKuQ2viyVdku6IwC+BBzzmNuizrWKpyA0pnBcZyXHwvC32GdMeEa6+SSpnawtrGAvIMokObSZ8hqRFeEp5pPdTutZyODToIy+Tc6UEcdqVJ2ql0STfpvvdS2E1o1pAQQNi33kRrYYUyysj2XizolwDgqLVTTPLbkbmvNTNenjaUw2h6Nra0mgF3Z4vH4UkVKOUF8JLMqWRGdznK43QT5UI6o2JI4Urw8rfY9Fiy8J/pyGezUoQtDe6synaXZPWXY6/b6jC3Nr45NHJkHcjZLrWe11vjlyDzBSRYA2uHAi2L1bgKDCAO7KgmHlkikuBIwEyRmDPDSVvGmoIVgkAP4Kibt6SjWgWMBkYQcVXFc8SoKvUjIB2TdsEp3kcRZXkhIqPdFq4LnjDqV1cTfZ0h59v2JuiKqfAJbgYoVMriDp/QfdRoopeP0VOnLSDgvFcvgJtbxEpXb0asWokWAPHBk2XslfcZnmlLwiiZLMSZKrpPsKrcMwVbgko5iFoyPF17bKsqZDHzsQ/pP3T+rGlBlQeQKLEM51nWxdos+/fA1zAd+g+ftliiPa7Qgv8zZ8Q8YEffYVHL4yBFGwVZqyQlOuBmkywxrahOvQEwQLIw==

解密后:

{
"ret": 200,
"data": [
{
"specialId": 9,
"special_title": "海狮07EV",
"post_count_total": 27,
"postList": [
{
"pid": 3972288,
"post_special_title": " 海狮07EV | 到店打卡悦美海狮",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/attachment\/20240513\/1715565830JM3QJmUc.jpg",
"comments": 280,
"views": 1855,
"type": 2
},
{
"pid": 3953153,
"post_special_title": "海狮07EV | 纯正用品推荐",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240517\/1715938378l4dl2Vbz.jpg",
"comments": 3894,
"views": 30486,
"type": 1
},
{
"pid": 3952880,
"post_special_title": "海狮07EV|实拍细节体验🕹️",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240520\/1716177929e5aPP9tv.jpg",
"comments": 2064,
"views": 15173,
"type": 2
},
{
"pid": 3942941,
"post_special_title": "海狮07EV | 邀您品鉴,参与话题获好礼!",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240515\/1715768410nLlVtrBD.jpg",
"comments": 744,
"views": 14626,
"type": 1
},
{
"pid": 3926202,
"post_special_title": "海狮07EV|比亚迪的对手只有比亚迪",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/attachment\/20240512\/1715524181lJA0CYw4.jpeg",
"comments": 1287,
"views": 10035,
"type": 2
},
{
"pid": 3916346,
"post_special_title": "海狮07EV|凛冽极寒,挑战冷车快充",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240513\/1715531435mnKjCmVp.jpg",
"comments": 1170,
"views": 5296,
"type": 1
},
{
"pid": 3907998,
"post_special_title": "海狮07EV | 全能实力 一图看懂",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240511\/1715422955VdPGE3W1.png",
"comments": 4995,
"views": 49431,
"type": 1
},
{
"pid": 3907785,
"post_special_title": "海狮07EV | 乘风探索新境,破浪驭享新狮,携手戚薇冲破想象边界,共赴智美新生",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240511\/17154183036g0Q2GMs.jpg",
"comments": 2107,
"views": 16081,
"type": 1
}
]
},
{
"specialId": 3,
"special_title": "海豹06DM-i",
"post_count_total": 10,
"postList": [
{
"pid": 4091548,
"post_special_title": "海豹06 DM-i | 寻迹优雅,唯美独型;豹款耀世,实力尽释",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240605\/1717576016qkvFOOQo.jpg",
"comments": 538,
"views": 6299,
"type": 1
},
{
"pid": 4046130,
"post_special_title": "海豹06DM-i | 细品全新B级混动家轿",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/attachment\/20240530\/1717030259tD7J4Lm0.jpg",
"comments": 518,
"views": 5274,
"type": 2
},
{
"pid": 4043177,
"post_special_title": "海豹06DM-i |各版本选购指南来了!",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/attachment\/20240529\/17169749193CfRckDn.jpg",
"comments": 681,
"views": 11466,
"type": 2
},
{
"pid": 4036123,
"post_special_title": "9.98万元起,油耗2.9L,续航2100km,海豹06 DM-i正式上市",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240528\/1716903955DQTHHbxf.jpg",
"comments": 10886,
"views": 229673,
"type": 1
},
{
"pid": 4032109,
"post_special_title": "今晚19:30,比亚迪第五代DM技术暨海豹06 DM-i发布,不见不散",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240528\/1716856724dxTEg0dR.jpg",
"comments": 2277,
"views": 30976,
"type": 1
},
{
"pid": 4022858,
"post_special_title": "倒计时1天丨比亚迪第五代DM技术发布暨秦L、海豹06上市发布会",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240527\/1716775208UiTsCtAS.jpg",
"comments": 3893,
"views": 30646,
"type": 1
},
{
"pid": 4011266,
"post_special_title": "倒计时2天丨比亚迪第五代DM技术发布暨秦L、海豹06上市发布会",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240526\/1716692897bayUkDqm.jpg",
"comments": 4818,
"views": 33093,
"type": 1
},
{
"pid": 4006000,
"post_special_title": "倒计时3天丨比亚迪第五代DM技术发布暨秦L、海豹06上市发布会",
"post_special_cover_image": "https:\/\/cache.bydoceanauto.com\/manage\/20240525\/1716601124aq4oHSep.jpg",
"comments": 3947,
"views": 35863,
"type": 1
}
]
}
],
"msg": ""
}

证明我们找的没有问题,开始下一个!

二、请求头加密

返回header.js文件,继续找请求头的加密,人家都叫header了,不直接找他太不给面子了啊!!

1、x-clienttraceid

直接搜索找到结果

2、Nonce

直接搜索找到结果

3、Curtime

直接搜索找到结果,证明是时间戳

4、Checksum

直接搜索找到结果,这个是appSecret+Nonce+时间戳计算出来的sha256

appSecret和偏移量一样存在一个列表内,可以直接算出来,感兴趣可以自己看一下,结果是:%4_CA*U$GM6N#0EP

5、测试一下

直接用抓包时的请求进行重发:

预料内的结果,返回值不一样,解密一下结果是

{
"ret": 401,
"data": [],
"msg": "请在设置中将手机时间调成北京时间"
}

Curtime修改为当前的时间戳重新请求,返回结果

{
"ret": 401,
"data": [],
"msg": "checkSum error"
}

x-clienttraceid和Nonce是随机值,我这里就不修改了,直接计算Checksum

组合结果:

%4_CA*U$GM6N#0EPm28fRzhXxcGcJJb31718350950

计算结果:

81353d1e9f31e6763c35279853312ad5faa95e5b7355edfd4d04a3fe778c4530

返回正常:

六、结语

这个还是很简单的一种,刚好他的代码都被我猜中了,完全没有太难得到部分

完美完结撒花~


注:若转载请注明大神论坛来源(本贴地址)与作者信息。

返回顶部