好友
阅读权限 10
听众
最后登录 1970-1-1
sunqv
发表于 2021-1-10 10:32
小弟刚刚接触.NET 破解 ,求大神帮忙看下这段代码,dnspy没找到 判断登录注册的过程。。。 不胜感激
using System;
using System.ComponentModel;
using System.Drawing;
using System.IO;
using System.Windows.Forms;
using Autodesk.AutoCAD.Interop;
using Autodesk.AutoCAD.Interop.Common;
using Microsoft.Win32;
namespace 地下管线
{
// Token: 0x02000002 RID: 2
public class login : Form
{
// Token: 0x06000001 RID: 1 RVA: 0x00002050 File Offset: 0x00000250
public login()
{
this.InitializeComponent();
}
// Token: 0x06000003 RID: 3 RVA: 0x00002278 File Offset: 0x00000478
protected override void Dispose(bool disposing)
{
if (disposing && this.components != null)
{
this.components.Dispose();
}
base.Dispose(disposing);
}
// Token: 0x06000004 RID: 4 RVA: 0x000022B0 File Offset: 0x000004B0
private void InitializeComponent()
{
base.SuspendLayout();
base.AutoScaleDimensions = new SizeF(6f, 12f);
base.AutoScaleMode = AutoScaleMode.Font;
base.ClientSize = new Size(650, 262);
base.MaximizeBox = false;
base.MinimizeBox = false;
base.Name = "login";
base.ShowInTaskbar = false;
base.StartPosition = FormStartPosition.CenterScreen;
base.Load += new EventHandler(this.login_Load);
base.ResumeLayout(false);
}
// Token: 0x06000002 RID: 2 RVA: 0x0000206C File Offset: 0x0000026C
private void login_Load(object sender, EventArgs e)
{
string currentDirectory = Environment.CurrentDirectory;
RegistryKey currentUser = Registry.CurrentUser;
RegistryKey registryKey = currentUser.OpenSubKey("SOFTWARE", true);
RegistryKey registryKey2 = registryKey.OpenSubKey("Autodesk", true);
RegistryKey registryKey3 = registryKey2.OpenSubKey("AutoCAD", true);
RegistryKey registryKey4 = registryKey3.OpenSubKey("R17.1", true);
RegistryKey registryKey5 = registryKey4.OpenSubKey("ACAD-6001:409", true);
RegistryKey registryKey6 = registryKey5.OpenSubKey("Applications", true);
RegistryKey registryKey7 = registryKey5.OpenSubKey("Profiles", true);
RegistryKey registryKey8 = registryKey7.OpenSubKey("<<Unnamed Profile>>", true);
RegistryKey registryKey9 = registryKey8.OpenSubKey("General", true);
string text = registryKey9.GetValue("ACAD").ToString();
text = currentDirectory + ";" + text;
registryKey9.SetValue("ACAD", text);
RegistryKey registryKey10 = registryKey6.CreateSubKey("MXCAD");
registryKey10.SetValue("LOADCTRLS", 2);
registryKey10.SetValue("LOADER", currentDirectory + "\\dataprocess.dll");
registryKey10.SetValue("MANAGED", 1);
this.BackgroundImage = Image.FromFile(Application.StartupPath + "\\image\\WELCOME.JPEG");
base.FormBorderStyle = FormBorderStyle.None;
AcadApplication acadApplication = (AcadApplication)Activator.CreateInstance(Type.GetTypeFromCLSID(new Guid("28B7AA99-C0F9-4C47-995E-8A8D729603A1")));
AcadApplication acadApplication2 = acadApplication;
int hWND = acadApplication2.HWND;
WinApi.SetWindowTextA(hWND, "系统");
hWND = acadApplication2.HWND;
string path = acadApplication2.Path;
string startupPath = Application.StartupPath;
string text2 = string.Format("{0}//image//WELCOME.ico", startupPath);
if (File.Exists(text2))
{
int num = WinApi.LoadImageA(0, text2, 1, 16, 16, 16);
if (num != 0)
{
WinApi.SendMessage(hWND, 128, 0, num);
}
}
acadApplication.WindowState = AcWindowState.acMax;
AcadDocument activeDocument = acadApplication.ActiveDocument;
activeDocument.WindowState = AcWindowState.acMax;
AcadModelSpace modelSpace = activeDocument.ModelSpace;
acadApplication.Visible = true;
base.Close();
}
// Token: 0x04000001 RID: 1
private IContainer components = null;
}
}
发帖前要善用【论坛搜索 】 功能,那里可能会有你要找的答案或者已经有人发布过相同内容了,请勿重复发帖。