ASPX C# Code Security
I wire a web site using aspx and c#, and I want to encript my c# code ( .cs files) No boby see and chan开发者_JS百科ge my code.
Ho can I do this?
With ASP.NET you have the option of Publishing your web site, which will produce .aspx "placeholders" and will compile the code into binary .dlls. However you must make sure that you do not have the option "Allow this precompiled site to be updatable" checked, so that no code or markup is visible on the hosting server.
compile and publish your web site. and you can try dotfuscator
You should "Publish" your site which will compile all the files into .dll files:
http://msdn.microsoft.com/en-us/library/20yh9f1b%28v=vs.80%29.aspx
Encrypting (or even obfuscating) your code is probably the wrong way to go about it.
Instead, ensure only authorised persons have access to that machine. People accessing the site through IIS won't be able to access any .cs files.
Even if you compile your application, all .NET Assemblies can still be disassembled. Obfuscation makes it more difficult, but not impossible.
Use WebDeploy, which will make all the cs files into DLL
http://www.microsoft.com/downloads/en/details.aspx?FamilyID=cfa66d50-90ce-49cb-b021-fefbd7a302ab
精彩评论