Skip to content

Commit fa884f6

Browse files
authored
Merge pull request #61 from sunnamed434/dev
Bump new version 0.6.0-alpha.15
2 parents d616c1c + ff68a65 commit fa884f6

File tree

164 files changed

+2213
-2235
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

164 files changed

+2213
-2235
lines changed

BitMono.sln

Lines changed: 6 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
1212
README.md = README.md
1313
EndProjectSection
1414
EndProject
15-
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "standalone", "standalone", "{76169FB9-B5F2-44B3-BF48-CCF10C3F9341}"
16-
EndProject
17-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.Standalone", "src\BitMono.Standalone\BitMono.Standalone.csproj", "{FE748DBC-2CE5-42D6-B192-D8222B103E0F}"
18-
EndProject
19-
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "submodules", "submodules", "{627F81D7-6C42-4AE8-9D96-A7F1BB3B2475}"
20-
EndProject
2115
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{D87066C4-1144-4BD8-96E9-9F4676001397}"
2216
EndProject
23-
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "crackmes", "crackmes", "{2FE1199C-34CC-4AC8-AAB9-F1EF76883EE3}"
24-
EndProject
25-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.Unturned-RocketMod-Crackme", "src\BitMono.Unturned-RocketMod-Crackme\BitMono.Unturned-RocketMod-Crackme.csproj", "{63224ECB-DC65-4908-87AB-8016DF7EC243}"
26-
EndProject
2717
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.API", "src\BitMono.API\BitMono.API.csproj", "{AF23CAB0-659E-4444-9D31-7F4D06BDA5C4}"
2818
EndProject
2919
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.CLI", "src\BitMono.CLI\BitMono.CLI.csproj", "{BD0789BC-F351-44CC-B58C-F91DBE778D56}"
@@ -34,8 +24,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.GUI", "src\BitMono.
3424
EndProject
3525
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.GUI.API", "src\BitMono.GUI.API\BitMono.GUI.API.csproj", "{7C0EBB47-7DB0-4110-A39B-7659AB70649F}"
3626
EndProject
37-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.GUI.Utilities", "src\BitMono.GUI.Utilities\BitMono.GUI.Utilities.csproj", "{1F964CE2-3E32-4B34-B69E-991E8E4DA01D}"
38-
EndProject
3927
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.Host", "src\BitMono.Host\BitMono.Host.csproj", "{41B9E388-392E-4AD3-8678-2A5AFF3A1F50}"
4028
EndProject
4129
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.Obfuscation", "src\BitMono.Obfuscation\BitMono.Obfuscation.csproj", "{8D86C77B-40D5-4234-8DC0-FE129F730B7A}"
@@ -50,22 +38,14 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.Shared", "src\BitMo
5038
EndProject
5139
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.Utilities", "src\BitMono.Utilities\BitMono.Utilities.csproj", "{34C08A60-E141-4FAD-975F-F447317CDA79}"
5240
EndProject
53-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dnlib", "src\dnlib\src\dnlib.csproj", "{41A5C3DF-744E-47E6-84F2-671260AB651B}"
41+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "BitMono.GUI.Utilities", "src\BitMono.GUI.Utilities\BitMono.GUI.Utilities.csproj", "{452E19E6-E967-47BC-8F0D-04FD372BBC79}"
5442
EndProject
5543
Global
5644
GlobalSection(SolutionConfigurationPlatforms) = preSolution
5745
Debug|Any CPU = Debug|Any CPU
5846
Release|Any CPU = Release|Any CPU
5947
EndGlobalSection
6048
GlobalSection(ProjectConfigurationPlatforms) = postSolution
61-
{FE748DBC-2CE5-42D6-B192-D8222B103E0F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
62-
{FE748DBC-2CE5-42D6-B192-D8222B103E0F}.Debug|Any CPU.Build.0 = Debug|Any CPU
63-
{FE748DBC-2CE5-42D6-B192-D8222B103E0F}.Release|Any CPU.ActiveCfg = Release|Any CPU
64-
{FE748DBC-2CE5-42D6-B192-D8222B103E0F}.Release|Any CPU.Build.0 = Release|Any CPU
65-
{63224ECB-DC65-4908-87AB-8016DF7EC243}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
66-
{63224ECB-DC65-4908-87AB-8016DF7EC243}.Debug|Any CPU.Build.0 = Debug|Any CPU
67-
{63224ECB-DC65-4908-87AB-8016DF7EC243}.Release|Any CPU.ActiveCfg = Release|Any CPU
68-
{63224ECB-DC65-4908-87AB-8016DF7EC243}.Release|Any CPU.Build.0 = Release|Any CPU
6949
{AF23CAB0-659E-4444-9D31-7F4D06BDA5C4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
7050
{AF23CAB0-659E-4444-9D31-7F4D06BDA5C4}.Debug|Any CPU.Build.0 = Debug|Any CPU
7151
{AF23CAB0-659E-4444-9D31-7F4D06BDA5C4}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -88,10 +68,6 @@ Global
8868
{7C0EBB47-7DB0-4110-A39B-7659AB70649F}.Debug|Any CPU.Build.0 = Debug|Any CPU
8969
{7C0EBB47-7DB0-4110-A39B-7659AB70649F}.Release|Any CPU.ActiveCfg = Release|Any CPU
9070
{7C0EBB47-7DB0-4110-A39B-7659AB70649F}.Release|Any CPU.Build.0 = Release|Any CPU
91-
{1F964CE2-3E32-4B34-B69E-991E8E4DA01D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
92-
{1F964CE2-3E32-4B34-B69E-991E8E4DA01D}.Debug|Any CPU.Build.0 = Debug|Any CPU
93-
{1F964CE2-3E32-4B34-B69E-991E8E4DA01D}.Release|Any CPU.ActiveCfg = Release|Any CPU
94-
{1F964CE2-3E32-4B34-B69E-991E8E4DA01D}.Release|Any CPU.Build.0 = Release|Any CPU
9571
{41B9E388-392E-4AD3-8678-2A5AFF3A1F50}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
9672
{41B9E388-392E-4AD3-8678-2A5AFF3A1F50}.Debug|Any CPU.Build.0 = Debug|Any CPU
9773
{41B9E388-392E-4AD3-8678-2A5AFF3A1F50}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -120,31 +96,28 @@ Global
12096
{34C08A60-E141-4FAD-975F-F447317CDA79}.Debug|Any CPU.Build.0 = Debug|Any CPU
12197
{34C08A60-E141-4FAD-975F-F447317CDA79}.Release|Any CPU.ActiveCfg = Release|Any CPU
12298
{34C08A60-E141-4FAD-975F-F447317CDA79}.Release|Any CPU.Build.0 = Release|Any CPU
123-
{41A5C3DF-744E-47E6-84F2-671260AB651B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
124-
{41A5C3DF-744E-47E6-84F2-671260AB651B}.Debug|Any CPU.Build.0 = Debug|Any CPU
125-
{41A5C3DF-744E-47E6-84F2-671260AB651B}.Release|Any CPU.ActiveCfg = Release|Any CPU
126-
{41A5C3DF-744E-47E6-84F2-671260AB651B}.Release|Any CPU.Build.0 = Release|Any CPU
99+
{452E19E6-E967-47BC-8F0D-04FD372BBC79}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
100+
{452E19E6-E967-47BC-8F0D-04FD372BBC79}.Debug|Any CPU.Build.0 = Debug|Any CPU
101+
{452E19E6-E967-47BC-8F0D-04FD372BBC79}.Release|Any CPU.ActiveCfg = Release|Any CPU
102+
{452E19E6-E967-47BC-8F0D-04FD372BBC79}.Release|Any CPU.Build.0 = Release|Any CPU
127103
EndGlobalSection
128104
GlobalSection(SolutionProperties) = preSolution
129105
HideSolutionNode = FALSE
130106
EndGlobalSection
131107
GlobalSection(NestedProjects) = preSolution
132-
{FE748DBC-2CE5-42D6-B192-D8222B103E0F} = {76169FB9-B5F2-44B3-BF48-CCF10C3F9341}
133-
{63224ECB-DC65-4908-87AB-8016DF7EC243} = {2FE1199C-34CC-4AC8-AAB9-F1EF76883EE3}
134108
{AF23CAB0-659E-4444-9D31-7F4D06BDA5C4} = {D87066C4-1144-4BD8-96E9-9F4676001397}
135109
{BD0789BC-F351-44CC-B58C-F91DBE778D56} = {D87066C4-1144-4BD8-96E9-9F4676001397}
136110
{76B85164-08C4-4D79-B331-F220967529BD} = {D87066C4-1144-4BD8-96E9-9F4676001397}
137111
{BBD90469-32A2-4F72-B022-6496E9BB1800} = {D87066C4-1144-4BD8-96E9-9F4676001397}
138112
{7C0EBB47-7DB0-4110-A39B-7659AB70649F} = {D87066C4-1144-4BD8-96E9-9F4676001397}
139-
{1F964CE2-3E32-4B34-B69E-991E8E4DA01D} = {D87066C4-1144-4BD8-96E9-9F4676001397}
140113
{41B9E388-392E-4AD3-8678-2A5AFF3A1F50} = {D87066C4-1144-4BD8-96E9-9F4676001397}
141114
{8D86C77B-40D5-4234-8DC0-FE129F730B7A} = {D87066C4-1144-4BD8-96E9-9F4676001397}
142115
{67AC5ED0-B443-4098-B0D9-6B5F0761F599} = {D87066C4-1144-4BD8-96E9-9F4676001397}
143116
{5B46A891-BF1A-487F-AF68-0AF045F8EC96} = {D87066C4-1144-4BD8-96E9-9F4676001397}
144117
{7A7E46BE-5210-4E0B-8FF6-71B82012E51A} = {D87066C4-1144-4BD8-96E9-9F4676001397}
145118
{40615C80-C80C-4C95-ABC3-3291C32197D8} = {D87066C4-1144-4BD8-96E9-9F4676001397}
146119
{34C08A60-E141-4FAD-975F-F447317CDA79} = {D87066C4-1144-4BD8-96E9-9F4676001397}
147-
{41A5C3DF-744E-47E6-84F2-671260AB651B} = {627F81D7-6C42-4AE8-9D96-A7F1BB3B2475}
120+
{452E19E6-E967-47BC-8F0D-04FD372BBC79} = {D87066C4-1144-4BD8-96E9-9F4676001397}
148121
EndGlobalSection
149122
GlobalSection(ExtensibilityGlobals) = postSolution
150123
SolutionGuid = {7DA0BB43-C1D4-4688-BE43-A9ED2D6F78EE}

CHANGELOG.md

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
| Versions: |
22
| - |
3-
| [v0.5.0-alpha](#v050-alpha14) |
3+
| [v0.6.0-alpha](#v060-alpha15) |
44
| [v0.4.4-alpha](#v044-alpha13) |
55
| [v0.4.3-alpha](#v043-alpha12) |
66
| [v0.4.2-alpha](#v042-alpha11) |
@@ -17,6 +17,29 @@
1717
| [v0.1.0](#v010) |
1818

1919
---
20+
### v0.6.0-alpha.15:
21+
#### Added:
22+
* New protection AntiDecompiler
23+
* As more as possible errors logging
24+
25+
#### Changed:
26+
* Migrate dnlib to AsmResolver or Mono.Cecil [#50](https://github.com/sunnamed434/BitMono/issues/50)
27+
28+
#### Fixed:
29+
* BitMethodDotnet Protection
30+
* StringsEncryption Protection
31+
* CallToCalli Protection
32+
* DotNetHook Protection
33+
* Load Runtime Module via file instead of typeof(SomeRuntime).Module [#55](https://github.com/sunnamed434/BitMono/issues/55)
34+
* Rewrite Custom Attributes Resolve as less as a possible reflection [#57](https://github.com/sunnamed434/BitMono/issues/57)
35+
* System.BadImageFormatException: Invalid DOS signature [#45](https://github.com/sunnamed434/BitMono/issues/45)
36+
* Whole Protections execution process
37+
* Protections execution information
38+
* Obfuscation
39+
* Optimized file writing
40+
* Ignoring of targets with [ObfuscationAttribute] and [MethodImpl(MethodImplOptions.NoInlining)]
41+
* Runtime injection and even became better
42+
2043
### v0.5.0-alpha.14:
2144
#### Added:
2245
* Before obfuscation optmizes all method bodies (macros)
@@ -25,7 +48,6 @@
2548
* BitMethodDotnet Protection
2649
* StringsEncryption Protection
2750

28-
2951
### v0.4.4-alpha.13:
3052
#### Fixed:
3153
* DotNetHook Protection

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ Open **[wiki](https://github.com/sunnamed434/BitMono/wiki)** to read protections
5151
* NoNamespaces
5252
* FullRenamer
5353
* AntiDebugBreakpoints
54+
* AntiDecompiler
5455
* BitDateTimeStamp
5556

5657
## Usage
@@ -70,4 +71,4 @@ Credits
7071

7172
**[ConfuserEx and their Forks](https://github.com/yck1509/ConfuserEx)** for most things that I watched for the architecture of BitMono and the obfuscator engine as an application and solving plenty of User solutions which I would be knew in the very long future after much fail usage of BitMono and reports by other Users. Day-by-day I'm looking for something interesting there to improve myself in knowledge and BitMono also.
7273

73-
**[Kao and his blogs](https://lifeinhex.com/) thanks a lot of these blogs.
74+
**[Kao and his blogs](https://lifeinhex.com/)** thanks a lot of these blogs.

src/BitMono.API/BitMono.API.csproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
</PropertyGroup>
2323

2424
<ItemGroup>
25+
<PackageReference Include="AsmResolver" Version="5.0.0" />
26+
<PackageReference Include="AsmResolver.DotNet" Version="5.0.0" />
2527
<PackageReference Include="Autofac" Version="6.4.0" />
2628
<PackageReference Include="Autofac.Extensions.DependencyInjection" Version="8.0.0" />
2729
<PackageReference Include="Microsoft.Extensions.Configuration" Version="7.0.0-rc.2.22472.3" />
@@ -34,7 +36,7 @@
3436
</ItemGroup>
3537

3638
<ItemGroup>
37-
<ProjectReference Include="..\dnlib\src\dnlib.csproj" />
39+
<ProjectReference Include="..\BitMono.Shared\BitMono.Shared.csproj" />
3840
</ItemGroup>
3941

4042
</Project>

src/BitMono.API/GlobalUsings.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
global using Autofac.Extensions.DependencyInjection;
1+
global using AsmResolver.DotNet;
2+
global using AsmResolver.DotNet.Builder;
3+
global using AsmResolver.DotNet.Serialized;
4+
global using AsmResolver.PE.File.Headers;
5+
global using Autofac.Extensions.DependencyInjection;
26
global using BitMono.API.Protecting.Contexts;
3-
global using BitMono.API.Protecting.Pipeline;
4-
global using dnlib.DotNet;
5-
global using dnlib.DotNet.Writer;
67
global using Microsoft.Extensions.Configuration;
78
global using Microsoft.Extensions.DependencyInjection;
89
global using NullGuard;
910
global using System;
1011
global using System.Collections.Generic;
11-
global using System.Reflection;
12-
global using System.Runtime.CompilerServices;
1312
global using System.Threading;
1413
global using System.Threading.Tasks;
14+
global using IAssemblyResolver = AsmResolver.DotNet.IAssemblyResolver;
1515
global using IModule = Autofac.Core.IModule;

src/BitMono.API/Protecting/Contexts/ProtectionContext.cs

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,19 @@
22

33
public class ProtectionContext
44
{
5-
[AllowNull] public ModuleDefMD ModuleDefMD { get; set; }
6-
[AllowNull] public ModuleCreationOptions ModuleCreationOptions { get; set; }
7-
[AllowNull] public ModuleWriterOptions ModuleWriterOptions { get; set; }
8-
[AllowNull] public ModuleDefMD RuntimeModuleDefMD { get; set; }
9-
[AllowNull] public Importer Importer { get; set; }
10-
[AllowNull] public Importer RuntimeImporter { get; set; }
5+
[AllowNull] public ModuleDefinition Module { get; set; }
6+
[AllowNull] public ModuleReaderParameters ModuleReaderParameters { get; set; }
7+
[AllowNull] public IPEImageBuilder PEImageBuilder { get; set; }
8+
[AllowNull] public ModuleDefinition RuntimeModule { get; set; }
9+
[AllowNull] public ReferenceImporter RuntimeImporter { get; set; }
1110
[AllowNull] public BitMonoContext BitMonoContext { get; set; }
12-
[AllowNull] public byte[] ModuleDefMDOutput { get; set; }
11+
[AllowNull] public CancellationToken CancellationToken { get; set; }
1312

14-
[AllowNull] public ModuleContext ModuleContext => ModuleCreationOptions.Context;
15-
[AllowNull] public AssemblyResolver AssemblyResolver => (AssemblyResolver)ModuleContext.AssemblyResolver;
13+
[AllowNull] public IAssemblyResolver AssemblyResolver => Module.MetadataResolver.AssemblyResolver;
14+
[AllowNull] public ReferenceImporter Importer => Module.DefaultImporter;
15+
16+
public void ThrowIfCancellationRequested()
17+
{
18+
CancellationToken.ThrowIfCancellationRequested();
19+
}
1620
}

src/BitMono.API/Protecting/Contexts/ProtectionParameters.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
{
33
public class ProtectionParameters
44
{
5-
public ProtectionParameters(List<IDnlibDef> targets)
5+
public ProtectionParameters(List<IMetadataMember> members)
66
{
7-
Targets = targets;
7+
Members = members;
88
}
99

10-
public List<IDnlibDef> Targets { get; private set; }
10+
public List<IMetadataMember> Members { get; }
1111
}
1212
}

src/BitMono.API/Protecting/IProtection.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22

33
public interface IProtection
44
{
5-
Task ExecuteAsync(ProtectionContext context, ProtectionParameters parameters, CancellationToken cancellationToken = default);
5+
Task ExecuteAsync(ProtectionContext context, ProtectionParameters parameters);
66
}

src/BitMono.API/Protecting/IStageProtection.cs

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/BitMono.API/Protecting/Injection/IInjector.cs

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)