Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
S
Setup
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄树航
Setup
Commits
87c24c08
Commit
87c24c08
authored
Jul 26, 2024
by
黄树航
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加 Obfuscar 混淆
parent
8c98bccf
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
53 additions
and
0 deletions
+53
-0
Dqkj.Setup.csproj
Dqkj.Setup.csproj
+25
-0
obfuscar.xml
obfuscar.xml
+27
-0
packages.config
packages.config
+1
-0
No files found.
Dqkj.Setup.csproj
View file @
87c24c08
<?xml version="1.0" encoding="utf-8"?>
<Project
ToolsVersion=
"15.0"
xmlns=
"http://schemas.microsoft.com/developer/msbuild/2003"
>
<Import
Project=
"packages\Obfuscar.2.2.38\build\obfuscar.props"
Condition=
"Exists('packages\Obfuscar.2.2.38\build\obfuscar.props')"
/>
<Import
Project=
"$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props"
Condition=
"Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')"
/>
<PropertyGroup>
<Configuration
Condition=
" '$(Configuration)' == '' "
>
Debug
</Configuration>
...
...
@@ -15,6 +16,8 @@
<AutoGenerateBindingRedirects>
true
</AutoGenerateBindingRedirects>
<Deterministic>
true
</Deterministic>
<TargetFrameworkProfile
/>
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
</PropertyGroup>
<PropertyGroup
Condition=
" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "
>
<PlatformTarget>
AnyCPU
</PlatformTarget>
...
...
@@ -163,5 +166,27 @@
<ItemGroup>
<Resource
Include=
"Logo.ico"
/>
</ItemGroup>
<ItemGroup>
<None
Include=
"obfuscar.xml"
>
<CopyToOutputDirectory>
PreserveNewest
</CopyToOutputDirectory>
</None>
</ItemGroup>
<Import
Project=
"$(MSBuildToolsPath)\Microsoft.CSharp.targets"
/>
<Target
Name=
"EnsureNuGetPackageBuildImports"
BeforeTargets=
"PrepareForBuild"
>
<PropertyGroup>
<ErrorText>
This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.
</ErrorText>
</PropertyGroup>
<Error
Condition=
"!Exists('packages\Obfuscar.2.2.38\build\obfuscar.props')"
Text=
"$([System.String]::Format('$(ErrorText)', 'packages\Obfuscar.2.2.38\build\obfuscar.props'))"
/>
</Target>
<PropertyGroup>
<PostBuildEvent>
set "str=$(ConfigurationName)"
if "%25str%25"=="Release" (
CD $(TargetDir)
"$(Obfuscar)" obfuscar.xml
xcopy Obfuscator_Output\*.dll /y /e /i /q
xcopy Obfuscator_Output\*.exe /y /e /i /q
rmdir /s /q .\Obfuscator_Output
del obfuscar.xml
)
</PostBuildEvent>
</PropertyGroup>
</Project>
\ No newline at end of file
obfuscar.xml
0 → 100644
View file @
87c24c08
<?xml version="1.0" encoding="utf-8" ?>
<Obfuscator>
<!-- 文档: https://docs.obfuscar.com/getting-started/configuration#settings -->
<!--输入路径-->
<Var
name=
"InPath"
value=
"."
/>
<!--输出路径:加密混淆过的路径-->
<Var
name=
"OutPath"
value=
".\Obfuscator_Output"
/>
<!--混淆代码的参数-->
<Var
name=
"RegenerateDebugInfo"
value=
"false"
/>
<Var
name=
"MarkedOnly"
value=
"false"
/>
<Var
name=
"RenameProperties"
value=
"false"
/>
<Var
name=
"RenameEvents"
value=
"true"
/>
<Var
name=
"RenameFields"
value=
"true"
/>
<Var
name=
"KeepPublicApi"
value=
"true"
/>
<Var
name=
"HidePrivateApi"
value=
"true"
/>
<Var
name=
"ReuseNames"
value=
"true"
/>
<Var
name=
"UseUnicodeNames"
value=
"true"
/>
<Var
name=
"UseKoreanNames"
value=
"true"
/>
<Var
name=
"HideStrings"
value=
"true"
/>
<Var
name=
"OptimizeMethods"
value=
"true"
/>
<Var
name=
"SuppressIldasm"
value=
"true"
/>
<Var
name=
"AnalyzeXaml"
value=
"true"
/>
<!--要混淆的模块-->
<Module
file=
"$(InPath)\电趣助手Setup.exe"
>
<SkipType
name=
"*AnonymousType*"
skipProperties=
"true"
skipMethods=
"true"
skipFields=
"true"
skipEvents=
"true"
skipStringHiding=
"true"
/>
</Module>
</Obfuscator>
\ No newline at end of file
packages.config
View file @
87c24c08
<?
xml
version
=
"1.0"
encoding
=
"utf-8"
?>
<
packages
>
<
package
id
=
"HandyControl"
version
=
"3.3.0"
targetFramework
=
"net472"
/>
<
package
id
=
"Obfuscar"
version
=
"2.2.38"
targetFramework
=
"net45"
developmentDependency
=
"true"
/>
</
packages
>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment