吾爱破解 - 52pojie.cn

 找回密码
 注册[Register]

QQ登录

只需一步,快速开始

查看: 664|回复: 14
收起左侧

[求助] [.Net逆向] dnSpy 编辑方法、IL指令,求教

[复制链接]
wjbg2022 发表于 2024-4-23 15:11
本帖最后由 wjbg2022 于 2024-6-13 18:05 编辑

各位大佬。我有两个问题,如下:
1、有一个vb.net编译的dll文件,已去壳,去混淆,但是一但编辑方法,程序就报错,部分代码变红了(不能到编译那一步),请问是我脱壳或去混淆不干净吗?我该怎么做?谢谢!
2、通过查看代码,我找到了注册码的代码,我想通过修改IL指令,以至于输出注册码,代码是:
  Dim correctActivationCode As String = Strings.Mid(Class20.smethod_16(Class20.smethod_16(Class11.MySettings_0.sx16, "15753578", "IoonIocn"), "15753578", "IoonIocn"), 12)
  Interaction.MsgBox("激活码错误! 正确的激活码是: " & correctActivationCode, MsgBoxStyle.OkOnly, Nothing)
请问IL指令应该怎样写?

VB,net 代码

VB,net 代码

fbd9bd1e9d44929a890ea2df6439b43.png

IL指令1

IL指令1


IL指令2

IL指令2


IL指令3

IL指令3



链接:https://pan.baidu.com/s/1kbSMqd33egvCS7Q_lMgQGQ?pwd=2x32
提取码:2x32



感谢各位大佬为我解答!



发帖前要善用论坛搜索功能,那里可能会有你要找的答案或者已经有人发布过相同内容了,请勿重复发帖。

hqt 发表于 2024-4-23 21:43
代码都出来了 逻辑很简单了啊 if部分直接改一样的就行了
[Visual Basic] 纯文本查看 复制代码
' Token: 0x060005AB RID: 1451 RVA: 0x0004D770 File Offset: 0x0004B970
        Private Sub method_2(sender As Object, e As EventArgs)
            If Not(Operators.CompareString(Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 1, 12), MySettingsProperty.Settings.sx17, False) = 0 And Operators.CompareString(MySettingsProperty.Settings.sx17, "", False) <> 0) Then
                If Operators.CompareString(Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 12), Me.TextBox2.Text, False) <> 0 Then
                    Interaction.MsgBox("激活成功!", MsgBoxStyle.OkOnly, Nothing)
                    MySettingsProperty.Settings.sx17 = Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 1, 12)
                    MySettingsProperty.Settings.Save()
                Else
                    Interaction.MsgBox("激活成功!", MsgBoxStyle.OkOnly, Nothing)
                    MySettingsProperty.Settings.sx17 = Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 1, 12)
                    MySettingsProperty.Settings.Save()
                End If
            Else
                Interaction.MsgBox("您已激活", MsgBoxStyle.OkOnly, Nothing)
            End If
        End Sub
 楼主| wjbg2022 发表于 2024-4-23 20:15
byh3025 发表于 2024-4-23 20:01
改IL代码后就可以保存了,还有,你怎么确定你截图的地方是判断会员的呢?代码中没有提示啊?
[Visual Basic] 纯文本查看 复制代码
[mw_shl_code=vb,true]                ' Token: 0x06000340 RID: 832 RVA: 0x000323A8 File Offset: 0x000305A8
                Public Sub 尺寸链标注Show()
                        If Class5.smethod_24("此功能属于VIP功能,需开通VIP后使用!") Then
                                Class7.object_1 = CType(Me.SwApp.ActiveDoc, ModelDoc2)
                                If Information.IsNothing(Class7.object_1) Then
                                        Interaction.MsgBox("请在工程图环境中使用!", MsgBoxStyle.OkOnly, Nothing)
                                ElseIf CType(Class7.object_1, IModelDoc2).[GetType]() <> 3 Then
                                        Interaction.MsgBox("请在工程图环境中使用!", MsgBoxStyle.OkOnly, Nothing)
                                Else
                                        Dim form As Form = Application.OpenForms.Cast().OfType().FirstOrDefault()
                                        If form Is Nothing Then
                                                Dim chiCunLianForm As ChiCunLianForm = New ChiCunLianForm()
                                                chiCunLianForm.Show()
                                        End If
                                End If
                        End If
                End Sub
  [/mw_shl_code]
我是从这里点进去的
qq465881818 发表于 2024-4-23 19:13
 楼主| wjbg2022 发表于 2024-4-23 19:40

你好,改IL有什么用?还没有学过,请问有相关文章分享吗?谢谢!
byh3025 发表于 2024-4-23 20:01
wjbg2022 发表于 2024-4-23 19:40
你好,改IL有什么用?还没有学过,请问有相关文章分享吗?谢谢!

改IL代码后就可以保存了,还有,你怎么确定你截图的地方是判断会员的呢?代码中没有提示啊?
 楼主| wjbg2022 发表于 2024-4-23 20:20
byh3025 发表于 2024-4-23 20:01
改IL代码后就可以保存了,还有,你怎么确定你截图的地方是判断会员的呢?代码中没有提示啊?
   
[Visual Basic] 纯文本查看 复制代码
' Token: 0x060005AB RID: 1451 RVA: 0x0004D770 File Offset: 0x0004B970
        Private Sub method_2(sender As Object, e As EventArgs)
            If Not(Operators.CompareString(Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 1, 12), MySettingsProperty.Settings.sx17, False) = 0 And Operators.CompareString(MySettingsProperty.Settings.sx17, "", False) <> 0) Then
                If Operators.CompareString(Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 12), Me.TextBox2.Text, False) <> 0 Then
                    Interaction.MsgBox("激活码错误!", MsgBoxStyle.OkOnly, Nothing)
                Else
                    Interaction.MsgBox("激活成功!", MsgBoxStyle.OkOnly, Nothing)
                    MySettingsProperty.Settings.sx17 = Strings.Mid(Class9.smethod_16(Class9.smethod_16(MySettingsProperty.Settings.sx16, "15753578", "IconIcon"), "15753578", "IconIcon"), 1, 12)
                    MySettingsProperty.Settings.Save()
                End If
            Else
                Interaction.MsgBox("您已激活", MsgBoxStyle.OkOnly, Nothing)
            End If
        End Sub

大佬!这一段是注册器的,太难了,故想直接从Class5.smethod_24入手,还在尝试中!大佬,请问我算是脱壳成功了?
3yu3 发表于 2024-4-23 21:25
一楼的图 修改IL代码 返回true 就OK了,也可以按6楼图所示写KG
byh3025 发表于 2024-4-23 21:32
wjbg2022 发表于 2024-4-23 20:20
[mw_shl_code=vb,true]' Token: 0x060005AB RID: 1451 RVA: 0x0004D770 File Offset: 0x0004B970
     ...

能看到源码就可以了
nx6681 发表于 2024-4-24 11:21
反混淆这个如何处理? 好像并没有把混淆还原
您需要登录后才可以回帖 登录 | 注册[Register]

本版积分规则

返回列表

RSS订阅|小黑屋|处罚记录|联系我们|吾爱破解 - LCG - LSG ( 京ICP备16042023号 | 京公网安备 11010502030087号 )

GMT+8, 2024-12-14 02:58

Powered by Discuz!

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表