GhostDoc Enterprise.v2022.2.22190 for Visual Studio 2022插件漏洞分析
先安装,然后直接使用dnspy调试Visual Studio 2022,以GhostdocPro的注册对话框作为突破口进行调试。经过一些调试可以比较轻松的发现关键点在SubMain.GhostDoc.Services.clr4.dll中。这个dll是混淆过的,所以可以先用de4dot去混淆。
经过一顿调试可以找到SubMain.GhostDoc.Services.Service这个类,这个类没有被混淆。里面有三个函数,mkPrev、mk、lrk。这些函数用于判断注册信息是否有效。
把它改成:
// Token: 0x0600004F RID: 79 RVA: 0x0000232A File Offset: 0x0000052A public static bool mkPrev(string s, ref int t, ref int m, ref int n) { t = 10000; m = 5; n = 1024; return true; } // Token: 0x06000050 RID: 80 RVA: 0x0000232A File Offset: 0x0000052A public static bool mk(string s, ref int t, ref int m, ref int n) { t = 10000; m = 5; n = 1024; return true; } // Token: 0x06000051 RID: 81 RVA: 0x0000233E File Offset: 0x0000053E public static bool lrk(string s1, string s2) { return true; }
这样无论我们使用什么字符串去解锁都可以成功。
另外还有一些判断License Key有效性的代码,主要就是验证其格式。此处略过不表。
经过上面的步骤,在VS中使用如下信息进行【离线激活】解锁即可:
Licensed to : 你的名字 License Key : DE979-FE3E7-00DE0-CF142-C1770 Unlock code: 任意字符串, 例如: 123456
----
原版安装包下载
官方网站似乎是屏蔽了中国大陆和中国香港的IP,不知道怎么想的。似乎是有点看不起我们?我想其它办法给下载下来了,可以通过百度网盘下载。
原版安装包v2022.2.22190,支持vs2017到vs2022
链接: https://pan.baidu.com/s/13hrjHHn_51RDUMiIcylu-A?pwd=dxym 提取码: dxym
----------------------------------------------------------------------------------------------------------------------------