문제

I am using dotfuscator to obfuscate my vb.net application(myapp.exe). But i am getting error while running the obfuscated file.

Below is the error when i open the exe which is obfuscated.

"The settings property 'Import' was not found. ImportSetting"

My application uses .config(myapp.exe.config) file which has setting like below

<userSettings>
    <myapp.My.MySettings>
        <setting name="Import" serializeAs="String">
            <value>True</value>
        </setting>
    </myapp.My.MySettings>
</userSettings>

If i don't obfuscate then application works fine. The error comes only if i obfuscate the my application.

Procedure i follow during obfuscation:

First i open create new project in dotfuscator.

In add input assembly i add myapp.exe and myapp.vshost.exe file from the bin folder of my project.

In build menu i select destination directory and click on build.

Now obfuscated file will be generated which i will use.

So please help me to solve this error.

도움이 되었습니까?

해결책 2

Note that running the obfuscator will rename everything to hide it's purpose. See here, http://msdn.microsoft.com/en-US/library/ms227212(v=vs.80).aspx.

My guess is that your <myapp.My.Settings> would have to be changed to the obfuscated name. I'm not sure how you would determine that however.

Edit: It looks like dotfuscator outputs a map.xml file that specifies all the stuff that was renamed. You should be able to lookup myapp and see what it got renamed to, then update the .config file.

다른 팁

You may have to manually exclude ImportSetting from renaming. If this doesn't solve your problem you should probably contact Dotfuscator Support

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top