首页
社区
课程
招聘
[原创]**大师(v 2.3.2)歌曲解锁分析 + 完整源代码
发表于: 2014-5-23 14:23 6553

[原创]**大师(v 2.3.2)歌曲解锁分析 + 完整源代码

2014-5-23 14:23
6553
没有做过多测试,了解方法即可!

用IDA高版本(到官方下载DEMO即可)加载 PLClient                                     
                                                                                   
由于是要解锁歌曲,索引用关键字 “song、lock”等搜索函数列表,碰碰运气  (当然我之前用GDB调试过的,O(∩_∩)O~)             
                                                                                   
找到如下可疑函数:                                                                 
                                                                                   
GamePlay::GameConfig::IsBuyedSong(int)                                             
GamePlay::MessageManager::IsSongDiffLock(int,GamePlay::EDiffcult)                  
GamePlay::MessageManager::IsSongDiffLockBought(int,GamePlay::EDiffcult)          
GamePlay::MessageManager::IsVIPInTheSong(int)                                      
                        
                                                                                   
目测应该是其中某个了,,用theos一个个尝试,得出结论:                              
IsVIPInTheSong 函数 -- 将歌曲后面的图标由免费变成VIP -- 实际还是没解锁--放过   
IsSongDiffLock 函数 -- 没解锁                                                      
IsSongDiffLockBought -- 顺利解锁 --- 就是它了!                                    
                                                                                   
                                                                                   
所以hook IsSongDiffLockBought 返回1即可                                            
为了满足自己内心需要,你可以把上面几个全hook掉

/* 
**大师 IOS 2.3.2 歌曲解锁
By PiaoYun
http://www.dllhook.com
*/

%hook AppDelegate

// 开启VIP
BOOL (*Kernel_GamePlay_MessageManager_IsVIPInTheSong)(void* self, int Value);

// 购买标记
BOOL (*Kernel_GamePlay_GameConfig_IsBuyedSong)(void* self, int Value);

// 解锁所有歌曲
BOOL (*Kernel_GamePlay_MessageManager_IsSongDiffLockBought)(void* self, int Value);

%new
BOOL My_GamePlay_MessageManager_IsVIPInTheSong(void* self, int Value)
{
  NSLog(@"into My_GamePlay_MessageManager_IsVIPInTheSong!!!!");
  Kernel_GamePlay_MessageManager_IsVIPInTheSong(self, Value);
  return YES;
}

%new
BOOL My_GamePlay_GameConfig_IsBuyedSong(void* self, int Value)
{
  NSLog(@"into My_GamePlay_GameConfig_IsBuyedSong!!!!");
  Kernel_GamePlay_GameConfig_IsBuyedSong(self, Value);
  return YES;
}

%new
BOOL My_GamePlay_MessageManager_IsSongDiffLockBought(void* self, int Value)
{
  NSLog(@"into My_GamePlay_MessageManager_IsSongDiffLockBought!!!!");
  Kernel_GamePlay_MessageManager_IsSongDiffLockBought(self, Value);
  return YES;
}

__attribute__((constructor)) void dylibMain()
{
  NSLog(@"inject success!!!!");
  MSHookFunction(((void*)MSFindSymbol(NULL, "__ZN8GamePlay14MessageManager14IsVIPInTheSongEi")),(void*)My_GamePlay_MessageManager_IsVIPInTheSong, (void**)&Kernel_GamePlay_MessageManager_IsVIPInTheSong);
  MSHookFunction(((void*)MSFindSymbol(NULL, "__ZN8GamePlay10GameConfig11IsBuyedSongEi")),(void*)My_GamePlay_GameConfig_IsBuyedSong, (void**)&Kernel_GamePlay_GameConfig_IsBuyedSong);
  MSHookFunction(((void*)MSFindSymbol(NULL, "__ZN8GamePlay14MessageManager20IsSongDiffLockBoughtEiNS_9EDiffcultE")),(void*)My_GamePlay_MessageManager_IsSongDiffLockBought, (void**)&Kernel_GamePlay_MessageManager_IsSongDiffLockBought);
}
%end

       

[培训]内核驱动高级班,冲击BAT一流互联网大厂工作,每周日13:00-18:00直播授课

上传的附件:
收藏
免费 0
支持
分享
最新回复 (5)
雪    币: 2664
活跃值: (3401)
能力值: ( LV13,RANK:1760 )
在线值:
发帖
回帖
粉丝
2
nice...
2014-5-23 14:29
0
雪    币: 2323
活跃值: (4113)
能力值: ( LV12,RANK:530 )
在线值:
发帖
回帖
粉丝
3
赞!
2014-5-23 14:32
0
雪    币: 14983
活跃值: (5285)
能力值: ( LV15,RANK:880 )
在线值:
发帖
回帖
粉丝
4
nice
2014-5-23 15:07
0
雪    币: 256
活跃值: (41)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
5
这个是越狱之后的吧
2014-5-25 20:39
0
雪    币: 4754
活跃值: (4179)
能力值: ( LV8,RANK:138 )
在线值:
发帖
回帖
粉丝
6
默默点赞………………
2014-6-8 00:59
0
游客
登录 | 注册 方可回帖
返回
//