Hello All, we are trying to obfuscate our application DLLs with Dotfuscator Obfuscation tool. after compile the code, we use Dotfuscator application to obfuscate the DLL which run successfully, but after trying to run the application we have the following Error:

[InvalidOperationException: Unable to find factory method for type 'Microtech.Andalus.Master.CustInfo'. Make sure assembly 'Microtech.Andalus.Master.CustInfo' is processed by weaver. See section 2 of Manual for details.]

    Microtech.Andalus.Business.DomainManager.eval_b() +191
       Microtech.Andalus.Business.DomainManager.BuildMaster() +447
       Xtensive.Orm.Web.SessionManager.EnsureDomainIsBuilt() +162
       System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +142
       System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +96

Also, I excluded all entities & structure classes from the process, also "CustInfo" is an Entity with Database and the error happened when Querying and process data from it.

Is Obfuscation process can't be used with Dataobjects.net, Or we have to do something (in code or by other tool).

Thanks

asked Dec 17 '15 at 06:41

ahmad%20emad's gravatar image

ahmad emad
26292931


2 Answers:

Hello Alexey, Thanks for your support, it worked by excluding compiler's generated linq related classes from obfuscation process(example: classes generated due to join to Queryable created by 'Query.All<t>' method), I don't know if those classes generated by dataobjects or not but it works.

Thanks

answered Jan 09 '16 at 07:35

ahmad%20emad's gravatar image

ahmad emad
26292931

edited Jan 09 '16 at 07:36

Hello ahmad emad

The exception appears when DO tries to create an Entity, Structure or EntitySet instance. DO needs special method which is added by Weaver to every descendant of Entity, Structure and EntitySet. Make sure that model is processed by weaver.

Note that, I don't know what exactly this obfuscator does and what options you set. Some parts are based on reflection and require names of methods (or fields, or properties). Those part might be critical for obfuscation.

If you give us some demo which behaves exactly the same I'll probably give you more useful answer. I mean two assemblies (one is obfuscated and another is not) - and some project which uses it.

answered Dec 18 '15 at 05:01

Alexey%20Kulakov's gravatar image

Alexey Kulakov
58215

Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!
toggle preview

Subscription:

Once you sign in you will be able to subscribe for any updates here

Tags:

×1
×1

Asked: Dec 17 '15 at 06:41

Seen: 2,749 times

Last updated: Jan 09 '16 at 07:36

Related questions

powered by OSQA