Limited support for multiple assemblies

logandamlogandam Posts: 4
edited June 4, 2014 3:27AM in SmartAssembly
My company purchased SmartAssembly because we've had an incident where one of our ex clients started making their own version of our software. I've been tasked with using it to obfuscate our code to make it a little more difficult to do so.

Now I understand that a lot of applications generally have one main executable with one or two libraries, and SmartAssembly makes it really easy to manage everything if that's the case since you can embed your libraries within your main application. That's great for that use case. But I am struggling to come up with ideas on how to do this with our applications, which have several hundred separate executables (our applications have some main processes that monitor for work and fire off separate individual processes based on the work) and each one loads a common set of libraries (and even those can differ). This means we can't do the embedding because then we're going to increase the size of each binary several times their original size which is just a waste of size, and it also makes it a pain to set up a separate project for every single executable.

I know there is a command line interface to SmartAssembly but it still relies on having project files. Ideally I'd like to just be able to use the command line to do something along the lines of "smartassembly -i <input> -o <output> [options]" or have one SmartAssembly project for every binary we have.

I've searched on the net and had a look at the documentation and I haven't come up with anything like this. Is it possible for SA to do what I describe above or am I going to have to set a day where I just make projects for all 400+ assemblies we have?

Comments

  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    You could write a batch command that creates projects for your assemblies.
    http://documentation.red-gate.com/displ ... +line+mode

    The /create argument lets you specify an .saproj file that contains the automatically-generated project. You can try this in a batch:

    FOR %N in (*.exe) do "c:\program files\red gate\smartassembly 6\smartassembly.com" /create "c:\SAProjects\%N.saproj" /Input "%N" /output "c:\protectesassemblies\%N"

    I hope this helps.
  • Thanks, I was hoping to avoid that but it will have to do. Is there perhaps anything planned to make this simpler in a future release?
  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    You can use the command-line and it will create the projects for you with one command. Have you got any suggestions as to how to make the process easier?
  • Well I don't know how the internals of SA work but I don't see why you can't have multiple assemblies or targets in a project file, or maybe have a solution file tying up several project files like visual studio does just to consolidate things a bit better. Maybe I'm just lazy :D
  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    It would not be easy - error reporting and other functions assume a one-to-one relationship between the project and the assembly.
Sign In or Register to comment.