Infralution Support Forum Index Infralution Support
Support groups for Infralution products
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Embedding dll

 
Post new topic   Reply to topic    Infralution Support Forum Index -> .NET Encryptor Support
View previous topic :: View next topic  
Author Message
hi_jack



Joined: 10 Mar 2016
Posts: 13

PostPosted: Thu Apr 13, 2017 10:56 am    Post subject: Embedding dll Reply with quote

Hello,

To simplify the deployment of my application I wish to embed my dll both managed and native.
My application is a WPF executable.
Is it possible with .NET Encryptor?

What would be the scenario embed before encryption or after?
Is there any recommended scenario or tool?

Thank you in advance
Back to top
View user's profile Send private message
Infralution



Joined: 28 Feb 2005
Posts: 4775

PostPosted: Mon Apr 17, 2017 12:16 am    Post subject: Reply with quote

Native (unmanaged) DLLs can not be embedded as resources and loaded dynamically (like managed DLLs can). You could potentially embed them as resources in the bootstrap executable and then have the bootstrap save them to disk before running the main encrypted exe. It could also delete them afterward.
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
hi_jack



Joined: 10 Mar 2016
Posts: 13

PostPosted: Fri Apr 21, 2017 1:40 pm    Post subject: Reply with quote

Hello,

Thank you for explaining that.
Could you also explain how to embed managed dlls.
The documentation states :
If your application references other assemblies these can also be encrypted using .NET Encryptor by adding a pre-build command line for each assembly. This allows you merge multiple assemblies into a single compressed executable.

I understand the first part.
Could you explain how to merge multiple assemblies int a single compressed executable?
Should I use Ilmerge or another tool?

Thank you,
Jack
Back to top
View user's profile Send private message
Infralution



Joined: 28 Feb 2005
Posts: 4775

PostPosted: Sat Apr 22, 2017 1:01 am    Post subject: Reply with quote

You add the encrypted assemblies as embedded resources to your bootstrap project (in the same way as for the main assembly). .NET Encryptor not only encrypts the assemblies it also compresses them. So the result when you compile your bootstrap executable is that you have a single executable containing the encrypted compressed assemblies.
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Infralution Support Forum Index -> .NET Encryptor Support All times are GMT
Page 1 of 1

 
Jump to:  
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