Red Gate forums :: View topic - Multiple dependencies obfuscation
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SmartAssembly 5
SmartAssembly 5 forum

Multiple dependencies obfuscation

Search in SmartAssembly 5 forum
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.
Jump to:  
Author Message
rcd.guerra



Joined: 13 Sep 2010
Posts: 10

PostPosted: Tue Sep 14, 2010 9:59 am    Post subject: Multiple dependencies obfuscation Reply with quote

Hello,

we are in the process of evaluating SA.
What is the best way of obfuscating dependant assemblies ?

We have a main application that will hold about a hundred referenced assemblies.
As a requirement we need to keep each reference as a separate file to ease the process of updating each reference.

If we use this main app as the base for SA, but without dependencies merging or embedding it seems we cannot obfuscate the referenced assemblies.
A solution would be to have an .saproj file for each assembly. Maybe using MSBuild support would be the best option.

We would also like to ask if there is a chance of having a master generic .saproj file that could be used for a set of assemblies because we want to apply the same obfuscation configuration to all, and creating a .saproj file seems a bit overwhelming.

Can you provide us some hint on this topic ?

Thanks in advance!

Kind regards,
Ricardo
Back to top
View user's profile Send private message
Brian Donahue



Joined: 23 Aug 2004
Posts: 6647

PostPosted: Fri Sep 17, 2010 11:21 am    Post subject: Reply with quote

Hi Ricardo,

What I have recommended in the past is to set up a SmartAssembly project containing all of the settings that you want to use and add a task to the VS project file to do the build, changing the input and output tags to the name of the assembly. For example:
Code:
 <Target Name="Obfuscate" Condition=" '$(Configuration)' == 'Release'">
    <SmartAssembly.MSBuild.Tasks.Build ProjectFile="Build for MyProject DLL.saproj" Input="..\bin\release\MyAssembly.DLL" Output="..\build\MyAssembly.DLL"/>
The full set of options you can use with MSBUILD and VS Projects are documented here:
http://www.red-gate.com/supportcenter/Content.aspx?p=SmartAssembly&c=SmartAssembly/help/5.0/SA_UsingSmartAssemblyWithMSBuild.htm&toc=SmartAssembly/help/5.0/toc1032253.htm
Back to top
View user's profile Send private message
olcay



Joined: 29 Nov 2010
Posts: 1

PostPosted: Mon Nov 29, 2010 5:00 pm    Post subject: Multiple dependencies obfuscation Reply with quote

We have the same problem but slightly different. We have a smart client app. that uses about 37 sub project which are DLLs and we use Click Once. The main program loads required assembly with reflection so we didnt reference other projects to main project. I dont want to build all assemblies one by one and the prior solution didnt work for me. Can you provide some clues about that and do i need to redirect all output file to obj\release folder?
Back to top
View user's profile Send private message
Brian Donahue



Joined: 23 Aug 2004
Posts: 6647

PostPosted: Wed Dec 01, 2010 10:55 am    Post subject: Reply with quote

I've been informed recently that changing the input and output of SmartAssembly doesn't work (any more?) for different assemblies. When I asked what those arguments could possibly be used for, the answer was that you can use them when you want to protect the same assembly specified in the project, but after you have moved the assembly to a different folder.

For different assemblies, you have to create new projects.
Back to top
View user's profile Send private message
Display posts from previous:   
This topic is locked: you cannot edit posts or make replies. All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group