├── KRS-Gui
├── obj
│ ├── Release
│ │ └── netcoreapp3.1
│ │ │ ├── KRS-Gui.csproj.CopyComplete
│ │ │ ├── KRS-Gui.AssemblyInfoInputs.cache
│ │ │ ├── KRS-Gui.genruntimeconfig.cache
│ │ │ ├── KRS-Gui.csproj.CoreCompileInputs.cache
│ │ │ ├── KRS-Gui.dll
│ │ │ ├── KRS-Gui.pdb
│ │ │ ├── apphost.exe
│ │ │ ├── KRS-Gui.assets.cache
│ │ │ ├── KRS_Gui.GuiForm.resources
│ │ │ ├── KRS-Gui.csproj.GenerateResource.cache
│ │ │ ├── KRS-Gui.csproj.AssemblyReference.cache
│ │ │ ├── KRS_Gui.Properties.Resources.resources
│ │ │ ├── KRS-Gui.GeneratedMSBuildEditorConfig.editorconfig
│ │ │ ├── .NETCoreApp,Version=v3.1.AssemblyAttributes.cs
│ │ │ ├── KRS-Gui.AssemblyInfo.cs
│ │ │ └── KRS-Gui.csproj.FileListAbsolute.txt
│ ├── KRS-Gui.csproj.nuget.g.targets
│ ├── project.nuget.cache
│ ├── KRS-Gui.csproj.nuget.g.props
│ ├── KRS-Gui.csproj.nuget.dgspec.json
│ └── project.assets.json
├── KRS.ico
├── AgentPlug.jar
├── .vs
│ └── KRS-Gui
│ │ ├── v16
│ │ └── .suo
│ │ └── DesignTimeBuild
│ │ └── .dtbcache.v2
├── Resources
│ ├── class_obj.png
│ ├── package_obj.png
│ └── field_public_obj.png
├── KRSFinder
│ ├── .vs
│ │ └── KRS-Gui
│ │ │ ├── v16
│ │ │ └── .suo
│ │ │ └── DesignTimeBuild
│ │ │ └── .dtbcache.v2
│ ├── MessageSaver
│ │ ├── SaverConfig.cs
│ │ ├── SourceNameSaver.cs
│ │ └── RelationSaver.cs
│ ├── Base
│ │ ├── Config.cs
│ │ ├── Method.cs
│ │ └── Var.cs
│ ├── Handler
│ │ ├── IBaseHandler.cs
│ │ ├── MethodNameHandler.cs
│ │ ├── NewInstanceOpCodeHandler.cs
│ │ ├── InstanceOfOpCodeHandler.cs
│ │ ├── KlazzNameHandler.cs
│ │ ├── GotoOpCodeHandler.cs
│ │ ├── CalcOpCodeHandler.cs
│ │ ├── CmpOpCodeHandler.cs
│ │ ├── FieldOpCodeHandler.cs
│ │ ├── ArrayOpCodeHandler.cs
│ │ ├── LocalNameHandler.cs
│ │ ├── SourceNameHandler.cs
│ │ ├── ConstOpCodeHandler.cs
│ │ ├── GetOpCodeHandler.cs
│ │ ├── IfOpCodeHandler.cs
│ │ ├── PutOpCodeHandler.cs
│ │ ├── MoveOpCodeHandler.cs
│ │ └── InvokeOpCodeHandler.cs
│ ├── LogPrinter
│ │ └── Log.cs
│ ├── KRS-Gui.sln
│ ├── Module
│ │ ├── Smali
│ │ │ ├── Utils.cs
│ │ │ ├── TempRegister.cs
│ │ │ ├── TempRegisterMap.cs
│ │ │ └── OpCode.cs
│ │ ├── SmaliFileAnalyseModule.cs
│ │ └── MethodCodeAnalyseModule.cs
│ └── SmaliHandler.cs
├── bin
│ └── Release
│ │ └── netcoreapp3.1
│ │ ├── KRS-Gui.dll
│ │ ├── KRS-Gui.exe
│ │ ├── KRS-Gui.pdb
│ │ ├── AgentPlug.jar
│ │ ├── Newtonsoft.Json.dll
│ │ ├── KRS-Gui.runtimeconfig.json
│ │ ├── KRS-Gui.runtimeconfig.dev.json
│ │ └── KRS-Gui.deps.json
├── GuiForm.cs
├── KRS-Gui.csproj.user
├── KRS-Gui.sln
├── KRS-Gui.csproj
├── JadxConfig.cs
├── Program.cs
├── GuiForm.resx
├── Properties
│ ├── Resources.Designer.cs
│ └── Resources.resx
├── JadxConfig.Designer.cs
├── GuiForm.Designer.cs
└── GuiForm.Method.cs
├── KRS.png
├── KRS1.png
├── KRS2.png
├── KRS3.png
├── KRS4.png
└── README.md
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.csproj.CopyComplete:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/KRS.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS.png
--------------------------------------------------------------------------------
/KRS1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS1.png
--------------------------------------------------------------------------------
/KRS2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS2.png
--------------------------------------------------------------------------------
/KRS3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS3.png
--------------------------------------------------------------------------------
/KRS4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS4.png
--------------------------------------------------------------------------------
/KRS-Gui/KRS.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/KRS.ico
--------------------------------------------------------------------------------
/KRS-Gui/AgentPlug.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/AgentPlug.jar
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.AssemblyInfoInputs.cache:
--------------------------------------------------------------------------------
1 | d073f054e5aa9fab89fc3775411398a7b8ab131e
2 |
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.genruntimeconfig.cache:
--------------------------------------------------------------------------------
1 | 58d2e5d88e54959b91e831f47ceae6f3f278a267
2 |
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.csproj.CoreCompileInputs.cache:
--------------------------------------------------------------------------------
1 | 756966ed73c0042b2662ab4e9ec0738fceae5a5a
2 |
--------------------------------------------------------------------------------
/KRS-Gui/.vs/KRS-Gui/v16/.suo:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/.vs/KRS-Gui/v16/.suo
--------------------------------------------------------------------------------
/KRS-Gui/Resources/class_obj.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/Resources/class_obj.png
--------------------------------------------------------------------------------
/KRS-Gui/Resources/package_obj.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/Resources/package_obj.png
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/.vs/KRS-Gui/v16/.suo:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/KRSFinder/.vs/KRS-Gui/v16/.suo
--------------------------------------------------------------------------------
/KRS-Gui/Resources/field_public_obj.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/Resources/field_public_obj.png
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.dll
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.exe
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.pdb:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.pdb
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.dll
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.pdb:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.pdb
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/apphost.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/apphost.exe
--------------------------------------------------------------------------------
/KRS-Gui/.vs/KRS-Gui/DesignTimeBuild/.dtbcache.v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/.vs/KRS-Gui/DesignTimeBuild/.dtbcache.v2
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/AgentPlug.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/bin/Release/netcoreapp3.1/AgentPlug.jar
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/Newtonsoft.Json.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/bin/Release/netcoreapp3.1/Newtonsoft.Json.dll
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.assets.cache:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.assets.cache
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/.vs/KRS-Gui/DesignTimeBuild/.dtbcache.v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/KRSFinder/.vs/KRS-Gui/DesignTimeBuild/.dtbcache.v2
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS_Gui.GuiForm.resources:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS_Gui.GuiForm.resources
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.csproj.GenerateResource.cache:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.csproj.GenerateResource.cache
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.csproj.AssemblyReference.cache:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.csproj.AssemblyReference.cache
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS_Gui.Properties.Resources.resources:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/MG1937/AntiProguard-KRSFinder/HEAD/KRS-Gui/obj/Release/netcoreapp3.1/KRS_Gui.Properties.Resources.resources
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.runtimeconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "runtimeOptions": {
3 | "tfm": "netcoreapp3.1",
4 | "framework": {
5 | "name": "Microsoft.WindowsDesktop.App",
6 | "version": "3.1.0"
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.GeneratedMSBuildEditorConfig.editorconfig:
--------------------------------------------------------------------------------
1 | is_global = true
2 | build_property.RootNamespace = KRS_Gui
3 | build_property.ProjectDir = D:\VisualStudioWorkSpace\CSharpWorkSpace\AntiProguard-KRSFinder\KRS-Gui\
4 |
--------------------------------------------------------------------------------
/KRS-Gui/GuiForm.cs:
--------------------------------------------------------------------------------
1 | using System.Windows.Forms;
2 |
3 | namespace KRS_Gui
4 | {
5 | public partial class GuiForm : Form
6 | {
7 | public GuiForm()
8 | {
9 | InitializeComponent();
10 | }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/.NETCoreApp,Version=v3.1.AssemblyAttributes.cs:
--------------------------------------------------------------------------------
1 | //
2 | using System;
3 | using System.Reflection;
4 | [assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v3.1", FrameworkDisplayName = "")]
5 |
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.runtimeconfig.dev.json:
--------------------------------------------------------------------------------
1 | {
2 | "runtimeOptions": {
3 | "additionalProbingPaths": [
4 | "C:\\Users\\Administrator\\.dotnet\\store\\|arch|\\|tfm|",
5 | "C:\\Users\\Administrator\\.nuget\\packages",
6 | "E:\\Microsoft Visual Studio\\Shared\\NuGetPackages"
7 | ]
8 | }
9 | }
--------------------------------------------------------------------------------
/KRS-Gui/obj/KRS-Gui.csproj.nuget.g.targets:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath)
5 |
6 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/MessageSaver/SaverConfig.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Text;
4 |
5 | namespace KRS_Gui.KRSFinder.MessageSaver
6 | {
7 | //TODO:模式控制
8 | class SaverConfig
9 | {
10 | public static bool saveMembership = true;
11 |
12 | public static bool saveDataFlow = true;
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Base/Config.cs:
--------------------------------------------------------------------------------
1 | using System.Collections;
2 |
3 | namespace KlazzRelationShipFinder.KRSFinder.Base
4 | {
5 | ///
6 | /// 此公共类的内容任何模块都可以获取或修改
7 | /// 用于储存一些处理对象的基础值,如储存路径一类
8 | ///
9 | class Config
10 | {
11 | public static ArrayList smaliFiles { set; get; }
12 |
13 | public static int totalFiles { set; get; }
14 |
15 | public static bool isBakSmali = true;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/KRS-Gui/obj/project.nuget.cache:
--------------------------------------------------------------------------------
1 | {
2 | "version": 2,
3 | "dgSpecHash": "Qs+ih+QFtLP1EjnA0dFjLrTa9+iWGsD/UBNn1BT+FQY/56XJf14LkYO76J/IO9bhsQ3m6ZBf2x3w8Krz4LoQzg==",
4 | "success": true,
5 | "projectFilePath": "D:\\VisualStudioWorkSpace\\CSharpWorkSpace\\AntiProguard-KRSFinder\\KRS-Gui\\KRS-Gui.csproj",
6 | "expectedPackageFiles": [
7 | "C:\\Users\\Administrator\\.nuget\\packages\\newtonsoft.json\\13.0.1\\newtonsoft.json.13.0.1.nupkg.sha512"
8 | ],
9 | "logs": []
10 | }
--------------------------------------------------------------------------------
/KRS-Gui/KRS-Gui.csproj.user:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Form
6 |
7 |
8 | Form
9 |
10 |
11 | Form
12 |
13 |
14 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/IBaseHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 |
4 | namespace KlazzRelationShipFinder.KRSFinder.Handler
5 | {
6 | interface IBaseHandler
7 | {
8 | ///
9 | /// 处理单行Smali代码
10 | ///
11 | /// 单行Smali代码
12 | /// 返回处理结果
13 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null);
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/MethodNameHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 | using System.Text.RegularExpressions;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.Handler
6 | {
7 | class MethodNameHandler : IBaseHandler
8 | {
9 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
10 | {
11 | //.method public A(III)LA/B/C;
12 | Regex reg = new Regex("(\\w+\\(.*\\))");
13 | if (lineCode.Contains("constructor"))
14 | {
15 | reg = new Regex("constructor\\s+(.+\\(.*\\))");
16 | }
17 | Match match = reg.Match(lineCode);
18 | return match.Groups[1].Value;
19 | }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/LogPrinter/Log.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Base;
2 | using KRS_Gui;
3 | using System;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.LogPrinter
6 | {
7 | class Log
8 | {
9 | public static void log(string log)
10 | {
11 | //Console.WriteLine("[" + TAG + "]" + ":" + log);
12 | Program.gui.AppendText(log);
13 | }
14 |
15 | public static void log(string TAG, string log)
16 | {
17 | //Console.WriteLine("[" + TAG + "]" + ":" + log);
18 | //Program.gui.AppendText("[" + TAG + "]" + ":" + log);
19 | }
20 |
21 | public static void show(int sum)
22 | {
23 | Program.gui.ShowText(sum + "/" + Config.totalFiles);
24 | }
25 |
26 | public static void show(string sum)
27 | {
28 | Program.gui.ShowText(sum + "/" + Config.totalFiles);
29 | }
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/NewInstanceOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 |
4 | namespace KlazzRelationShipFinder.KRSFinder.Handler
5 | {
6 | class NewInstanceOpCodeHandler : IBaseHandler
7 | {
8 | ///
9 | /// 处理instance操作码
10 | ///
11 | /// NEED
12 | /// NONEED
13 | /// NEED
14 | /// NULL
15 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
16 | {
17 | //new-instance vx,type
18 | string register = lineCode.Replace("new-instance", "").Split(",")[0].Trim();
19 | tempRegister.removeRegister(register);
20 | return null;
21 | }
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/InstanceOfOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 |
4 | namespace KlazzRelationShipFinder.KRSFinder.Handler
5 | {
6 | class InstanceOfOpCodeHandler : IBaseHandler
7 | {
8 | ///
9 | /// 处理instance操作码
10 | ///
11 | /// NEED
12 | /// NONEED
13 | /// NEED
14 | /// null
15 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
16 | {
17 | //instance-of vx,vy,type_id
18 | string register = lineCode.Replace("instance-of", "").Split(",")[0].Trim();
19 | tempRegister.removeRegister(register);
20 | return null;
21 | }
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/KlazzNameHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 |
4 | namespace KlazzRelationShipFinder.KRSFinder.Handler
5 | {
6 | class KlazzNameHandler : IBaseHandler
7 | {
8 | ///
9 | /// 提取.class操作码包含的类名
10 | ///
11 | ///
12 | /// (string)当前的klazz名称
13 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
14 | {
15 | //.class public LA/B/C;
16 | string opCode = ".class";
17 | lineCode = lineCode.Replace(opCode, "").Trim();
18 | lineCode = lineCode.Substring(lineCode.IndexOf("L") + 1);
19 | lineCode = lineCode.Substring(0, lineCode.Length - 1);
20 | //return A/B/C
21 | return lineCode;
22 | }
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/GotoOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 | using System.Text.RegularExpressions;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.Handler
6 | {
7 | class GotoOpCodeHandler : IBaseHandler
8 | {
9 | ///
10 | /// GOTO相关操作码处理
11 | ///
12 | /// NEED
13 | /// NONEED
14 | /// NONEED
15 | /// GOTO_target
16 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
17 | {
18 | string head = lineCode.Split(" ")[0].Trim();
19 | lineCode = lineCode.Replace(head + " ", "").Trim();
20 |
21 | Regex reg = new Regex(":(.+)");
22 | return reg.Match(lineCode).Groups[1].Value.Trim();
23 | }
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/KRS-Gui/obj/Release/netcoreapp3.1/KRS-Gui.AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | using System;
12 | using System.Reflection;
13 |
14 | [assembly: System.Reflection.AssemblyCompanyAttribute("KRS-Gui")]
15 | [assembly: System.Reflection.AssemblyConfigurationAttribute("Release")]
16 | [assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
17 | [assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
18 | [assembly: System.Reflection.AssemblyProductAttribute("KRS-Gui")]
19 | [assembly: System.Reflection.AssemblyTitleAttribute("KRS-Gui")]
20 | [assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
21 |
22 | // Generated by the MSBuild WriteCodeFragment class.
23 |
24 |
--------------------------------------------------------------------------------
/KRS-Gui/KRS-Gui.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 16.0.31702.278
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "KRS-Gui", "KRS-Gui.csproj", "{45761D6B-E334-4485-99B0-C299DD800622}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {45761D6B-E334-4485-99B0-C299DD800622}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {45761D6B-E334-4485-99B0-C299DD800622}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {45761D6B-E334-4485-99B0-C299DD800622}.Release|Any CPU.ActiveCfg = Release|Any CPU
17 | {45761D6B-E334-4485-99B0-C299DD800622}.Release|Any CPU.Build.0 = Release|Any CPU
18 | EndGlobalSection
19 | GlobalSection(SolutionProperties) = preSolution
20 | HideSolutionNode = FALSE
21 | EndGlobalSection
22 | GlobalSection(ExtensibilityGlobals) = postSolution
23 | SolutionGuid = {75CADFA8-98F1-4823-ABC3-45DCC4E47D91}
24 | EndGlobalSection
25 | EndGlobal
26 |
--------------------------------------------------------------------------------
/KRS-Gui/bin/Release/netcoreapp3.1/KRS-Gui.deps.json:
--------------------------------------------------------------------------------
1 | {
2 | "runtimeTarget": {
3 | "name": ".NETCoreApp,Version=v3.1",
4 | "signature": ""
5 | },
6 | "compilationOptions": {},
7 | "targets": {
8 | ".NETCoreApp,Version=v3.1": {
9 | "KRS-Gui/1.0.0": {
10 | "dependencies": {
11 | "Newtonsoft.Json": "13.0.1"
12 | },
13 | "runtime": {
14 | "KRS-Gui.dll": {}
15 | }
16 | },
17 | "Newtonsoft.Json/13.0.1": {
18 | "runtime": {
19 | "lib/netstandard2.0/Newtonsoft.Json.dll": {
20 | "assemblyVersion": "13.0.0.0",
21 | "fileVersion": "13.0.1.25517"
22 | }
23 | }
24 | }
25 | }
26 | },
27 | "libraries": {
28 | "KRS-Gui/1.0.0": {
29 | "type": "project",
30 | "serviceable": false,
31 | "sha512": ""
32 | },
33 | "Newtonsoft.Json/13.0.1": {
34 | "type": "package",
35 | "serviceable": true,
36 | "sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
37 | "path": "newtonsoft.json/13.0.1",
38 | "hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
39 | }
40 | }
41 | }
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/CalcOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Base;
2 | using KlazzRelationShipFinder.KRSFinder.Module;
3 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.Handler
6 | {
7 | class CalcOpCodeHandler : IBaseHandler
8 | {
9 | ///
10 | /// 处理计算相关操作码
11 | ///
12 | /// NEED
13 | /// NONEED
14 | /// NEED
15 | /// NULL
16 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
17 | {
18 | string head = lineCode.Split(" ")[0].Trim();
19 | string[] blocks = lineCode.Replace(head, "").Split(",");
20 | string register = blocks[0].Trim();
21 | object value = tempRegister.getRegister(register);
22 | if (value is Var && ((Var)value).isFuncArg) return null;
23 | tempRegister.removeRegister(register);
24 | return null;
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/KRS-Gui.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 16.0.31702.278
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "KRS-Gui", "..\KRS-Gui.csproj", "{290B4576-3B8D-4FE8-91C5-140AFF4C3A4F}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {290B4576-3B8D-4FE8-91C5-140AFF4C3A4F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {290B4576-3B8D-4FE8-91C5-140AFF4C3A4F}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {290B4576-3B8D-4FE8-91C5-140AFF4C3A4F}.Release|Any CPU.ActiveCfg = Release|Any CPU
17 | {290B4576-3B8D-4FE8-91C5-140AFF4C3A4F}.Release|Any CPU.Build.0 = Release|Any CPU
18 | EndGlobalSection
19 | GlobalSection(SolutionProperties) = preSolution
20 | HideSolutionNode = FALSE
21 | EndGlobalSection
22 | GlobalSection(ExtensibilityGlobals) = postSolution
23 | SolutionGuid = {CCA88B9E-43BB-446E-8C58-2E050A28086C}
24 | EndGlobalSection
25 | EndGlobal
26 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/CmpOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Base;
2 | using KlazzRelationShipFinder.KRSFinder.Module;
3 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.Handler
6 | {
7 | class CmpOpCodeHandler : IBaseHandler
8 | {
9 | ///
10 | /// 处理cmp相关操作码
11 | ///
12 | /// NEED
13 | /// NONEED
14 | /// NEED
15 | /// NULL
16 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
17 | {
18 | string head = lineCode.Split(" ")[0].Trim();
19 | string[] blocks = lineCode.Replace(head, "").Split(",");
20 | //cmpl-float v0, v6, v7
21 | string register = blocks[0].Trim();
22 | object value = tempRegister.getRegister(register);
23 | if (value is Var && ((Var)value).isFuncArg) return null;
24 | tempRegister.removeRegister(register);
25 | return null;
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/FieldOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Base;
2 | using KlazzRelationShipFinder.KRSFinder.Handler;
3 | using KlazzRelationShipFinder.KRSFinder.MessageSaver;
4 | using KlazzRelationShipFinder.KRSFinder.Module;
5 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
6 | using System.Text.RegularExpressions;
7 |
8 | namespace KRS_Gui.KRSFinder.Handler
9 | {
10 | class FieldOpCodeHandler : IBaseHandler
11 | {
12 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
13 | {
14 | if (!lineCode.Contains("=")) return null;
15 | string value = lineCode.Split("=")[1].Trim();
16 | if (!value.StartsWith("\""))
17 | {
18 | return null;
19 | }
20 |
21 | Regex regex = new Regex("(\\w+):L");
22 | string var_name = regex.Match(lineCode).Groups[1].Value;
23 | Var var = new Var();
24 | var.klazz = smaliFileAnalyseModule.klazz_name;
25 | var.var_name = var_name;
26 | var.addComment_setStaticField(value);
27 |
28 | RelationSaver.saveVar(var);
29 | return null;
30 | }
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Module/Smali/Utils.cs:
--------------------------------------------------------------------------------
1 | using System.Text.RegularExpressions;
2 |
3 | namespace KlazzRelationShipFinder.KRSFinder.Module.Smali
4 | {
5 | class Utils
6 | {
7 | ///
8 | /// 从代码中提取class信息
9 | ///
10 | /// xxx LA/B/C;->xxx
11 | /// A/B/C
12 | public static string getKlazz(string code)
13 | {
14 | Regex reg = new Regex("L(.*?);");
15 | return reg.Match(code).Groups[1].Value;
16 | }
17 |
18 | ///
19 | /// 从代码中提取成员名
20 | ///
21 | /// opcode LA/B/C;->xxx:LA/B/C;
22 | /// xxx
23 | public static string getReferedVar(string code)
24 | {
25 | Regex reg = new Regex(";->(.+):");
26 | return reg.Match(code).Groups[1].Value;
27 | }
28 |
29 | ///
30 | /// 从代码中提取调用的方法名
31 | ///
32 | /// invoke LA/B/C;->a()V
33 | /// a()
34 | public static string getMethodName(string code)
35 | {
36 | Regex reg = new Regex("->(.+\\(.*\\))");
37 | return reg.Match(code).Groups[1].Value;
38 | }
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/KRS-Gui/KRS-Gui.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | WinExe
5 | netcoreapp3.1
6 | KRS_Gui
7 | true
8 | KRS.ico
9 |
10 |
11 |
12 |
13 |
14 | 5
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 | True
24 | True
25 | Resources.resx
26 |
27 |
28 |
29 |
30 |
31 | PublicResXFileCodeGenerator
32 | Resources.Designer.cs
33 |
34 |
35 |
36 |
37 |
38 | Always
39 |
40 |
41 |
42 |
--------------------------------------------------------------------------------
/KRS-Gui/JadxConfig.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Diagnostics;
3 | using System.IO;
4 | using System.Windows.Forms;
5 |
6 | namespace KRS_Gui
7 | {
8 | public partial class JadxConfig : Form
9 | {
10 | public JadxConfig()
11 | {
12 | InitializeComponent();
13 | }
14 |
15 | private void button1_Click(object sender, EventArgs e)
16 | {
17 | string jadx = jadxPath.Text.ToString() + "/lib/jadx-gui-dev.jar";
18 | if (!File.Exists(jadx))
19 | {
20 | warning.Text = "jadx-gui-dev.jar no found in Jadx root path!";
21 | return;
22 | }
23 |
24 | StreamWriter writer = new StreamWriter(new FileStream("./jadxPath.txt", FileMode.Create));
25 | writer.Write(jadxPath.Text.ToString());
26 | writer.Close();
27 |
28 | string callstack = callstackPath.Text.ToString();
29 | string result = resultPath.Text.ToString();
30 | Process process = new Process();
31 | process.StartInfo.FileName = "java.exe";
32 | process.StartInfo.Arguments = "-javaagent:./AgentPlug.jar=\"" + result + "|" + callstack + "\" -jar " + jadx;
33 | process.StartInfo.UseShellExecute = false;
34 | process.Start();
35 | process.WaitForExit();
36 | }
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/ArrayOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Base;
2 | using KlazzRelationShipFinder.KRSFinder.Module;
3 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.Handler
6 | {
7 | class ArrayOpCodeHandler : IBaseHandler
8 | {
9 | ///
10 | /// 处理array操作码
11 | ///
12 | /// NEED
13 | /// NONEED
14 | /// NEED
15 | /// NULL
16 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
17 | {
18 | string head = lineCode.Split(" ")[0].Trim();
19 | string[] blocks = lineCode.Replace(head, "").Split(",");
20 | if (head.Equals("array-length") || head.Equals("new-array"))
21 | {
22 | //array-length vx,vy
23 | string register = blocks[0].Trim();
24 | object value = tempRegister.getRegister(register);
25 | if (value is Var && ((Var)value).isFuncArg) return null;
26 | tempRegister.removeRegister(register);
27 | return null;
28 | }
29 | return null;
30 | }
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/KRS-Gui/obj/KRS-Gui.csproj.nuget.g.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | True
5 | NuGet
6 | $(MSBuildThisFileDirectory)project.assets.json
7 | $(UserProfile)\.nuget\packages\
8 | C:\Users\Administrator\.nuget\packages\;E:\Microsoft Visual Studio\Shared\NuGetPackages
9 | PackageReference
10 | 5.11.0
11 |
12 |
13 |
14 |
15 |
16 |
17 | $(MSBuildAllProjects);$(MSBuildThisFileFullPath)
18 |
19 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/LocalNameHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Base;
2 | using KlazzRelationShipFinder.KRSFinder.MessageSaver;
3 | using KlazzRelationShipFinder.KRSFinder.Module;
4 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
5 |
6 | namespace KlazzRelationShipFinder.KRSFinder.Handler
7 | {
8 | class LocalNameHandler : IBaseHandler
9 | {
10 | ///
11 | /// 处理.local操作码
12 | ///
13 | /// NEED
14 | /// NEED
15 | /// NEED
16 | /// null
17 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
18 | {
19 | //.local vx,"var_name":LXXX;
20 | string[] blocks = lineCode.Replace(".local", "").Split(",");
21 | string register = blocks[0].Trim();
22 | string local_var_name = blocks[1].Split(":")[0].Trim().Replace("\"", "");
23 |
24 | //获取成员对象
25 | object var = tempRegister.getRegister(register);
26 | if (!(var is Var)) return null;
27 |
28 | //储存成员对象
29 | ((Var)var).addComment_beSetLocalName(local_var_name, smaliFileAnalyseModule.klazz_name, smaliFileAnalyseModule.method);
30 | RelationSaver.saveVar((Var)var);
31 | return null;
32 | }
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/SourceNameHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 | using System;
4 |
5 | namespace KlazzRelationShipFinder.KRSFinder.Handler
6 | {
7 | class SourceNameHandler : IBaseHandler
8 | {
9 | ///
10 | /// 获取.source操作码的原文件名
11 | /// 若获取失败或当前文件名可能被ProGuard保护则返回null
12 | ///
13 | ///
14 | /// (string)当前的sourceName,e.g:SourceName
15 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
16 | {
17 | //.source "Example.java"
18 | if (lineCode == null) return null;
19 |
20 | string opCode = ".source";
21 | lineCode = lineCode.Trim();
22 |
23 | try
24 | {
25 | lineCode = lineCode.Replace(opCode, "").Trim();
26 | //Example.java
27 | string sourceName = lineCode.Substring(lineCode.IndexOf("\"") + 1, lineCode.Length - 2);
28 | //ProGuard!!!
29 | if (!sourceName.EndsWith(".java")) return null;
30 |
31 | sourceName = sourceName.Replace(".java", "");
32 |
33 | if (sourceName != null && !string.IsNullOrEmpty(sourceName)) return sourceName;
34 | }
35 | catch (Exception)
36 | {
37 | return null;
38 | }
39 | return null;
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/Handler/ConstOpCodeHandler.cs:
--------------------------------------------------------------------------------
1 | using KlazzRelationShipFinder.KRSFinder.Module;
2 | using KlazzRelationShipFinder.KRSFinder.Module.Smali;
3 |
4 | namespace KlazzRelationShipFinder.KRSFinder.Handler
5 | {
6 | class ConstOpCodeHandler : IBaseHandler
7 | {
8 | ///
9 | /// 处理const相关操作码
10 | ///
11 | /// NEED
12 | /// NONEED
13 | /// NEED
14 | /// NULL
15 | public object lineHandler(string lineCode, SmaliFileAnalyseModule smaliFileAnalyseModule = null, TempRegisterMap tempRegister = null)
16 | {
17 | string head = lineCode.Split(" ")[0].Trim();
18 | string[] blocks = lineCode.Replace(head, "").Split(",");
19 | if (head.Contains("const-string"))
20 | {
21 | //const-string vx,"str"
22 | //若操作码设置string类型的常量,则储存相应寄存器
23 | string register = blocks[0].Trim();
24 | string conststr = blocks[1].Trim();
25 |
26 | if (register.StartsWith("p")) smaliFileAnalyseModule.polluteFuncArgReg.Add(register);
27 | tempRegister.putRegister(register, new TempRegister(conststr));
28 | return null;
29 | }
30 | else
31 | {
32 | //若储存非string类型的常量,则删除目标寄存器
33 | string register = blocks[0].Trim();
34 | if (register.StartsWith("p")) smaliFileAnalyseModule.polluteFuncArgReg.Add(register);
35 | tempRegister.removeRegister(register);
36 | return null;
37 | }
38 | }
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/KRS-Gui/KRSFinder/MessageSaver/SourceNameSaver.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Runtime.CompilerServices;
3 |
4 | namespace KlazzRelationShipFinder.KRSFinder.MessageSaver
5 | {
6 | class SourceNameSaver
7 | {
8 | ///
9 | /// Dictionary
10 | ///
11 | private static Dictionary sourceNameMap = new Dictionary();
12 |
13 | ///
14 | /// 记录每个sourceName的总和
15 | ///
16 | private static Dictionary sourceNameSum = new Dictionary();
17 |
18 |
19 | [MethodImpl(MethodImplOptions.Synchronized)]
20 | public static void saveSourceName(string origName, string sourceName)
21 | {
22 | if (origName == null || sourceName == null)
23 | {
24 | return;
25 | }
26 |
27 | sourceNameMap[origName] = sourceName;
28 | int sum = sourceNameSum.GetValueOrDefault(sourceName, 0);
29 | sum += 1;
30 | sourceNameSum[sourceName] = sum;
31 | }
32 |
33 | ///
34 | /// 获取指定sourceName出现过的次数
35 | ///
36 | ///
37 | public static int getSourceNameSum(string sourceName)
38 | {
39 | if (sourceName == null) return 0;
40 |
41 | return sourceNameSum.GetValueOrDefault(sourceName, 0);
42 | }
43 |
44 | ///
45 | /// 根据origName获取sourceName
46 | ///
47 | ///
48 | public static string getSourceName(string origName)
49 | {
50 | if (origName == null) return null;
51 |
52 | return sourceNameMap.GetValueOrDefault(origName, null);
53 | }
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/KRS-Gui/Program.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Newtonsoft.Json;
3 | using System.Collections.Generic;
4 | using System.Runtime.InteropServices;
5 | using System.Text.Json.Serialization;
6 | using System.Windows.Forms;
7 | using Newtonsoft.Json.Linq;
8 | using System.Diagnostics;
9 |
10 | namespace KRS_Gui
11 | {
12 | public static class Program
13 | {
14 | public static GuiForm gui;
15 | [DllImport("kernel32.dll")]
16 | static extern bool AllocConsole();
17 |
18 | ///
19 | /// The main entry point for the application.
20 | ///
21 | [STAThread]
22 | static void Main(string[] args)
23 | {
24 | //Console.WriteLine("Hello");
25 | //AllocConsole();
26 |
27 | //JObject json = new JObject();
28 |
29 |
30 | //Console.WriteLine("Hello");
31 | //List msgs = new List();
32 | //for (int i = 0; i < 10; i++)
33 | //{
34 | // Msg m = new Msg();
35 | // m.init();
36 | // m.key = i + "!!";
37 | // msgs.Add(m);
38 | //}
39 | //Console.WriteLine(json.ToString());
40 | //Console.ReadKey();
41 | Application.SetHighDpiMode(HighDpiMode.SystemAware);
42 | Application.EnableVisualStyles();
43 | Application.SetCompatibleTextRenderingDefault(false);
44 | gui = new GuiForm();
45 | Application.Run(gui);
46 | }
47 | }
48 |
49 | public class Msg
50 | {
51 | public string key { set; get; }
52 | public object comments;
53 | public void init()
54 | {
55 | comments = new List