I've encrypted a file from my local machine, but now I'm looking to make it exe file. User just double click on it and a form will be displayed to ask for the password and decrypt the file. I don't know how to embed a form with encrypted file.

Can anybody help me out
thanks in advance

Recommended Answers

All 4 Replies

You cna add the item as a resource to your application, however displaying it, maybe more complex if the user doesnt have the facilities to decrypt or use a relevant app to display it. That would be the bigger stumbling block.

Thanks LizR's for you quick response. Basically I'm developing an application for encryption and decryption of a file. User select a file inside my application and encrypt the file to destination folder, In this step I just want to create the encrypted file as a exe file.
User just double click on it without installing my application and get the decrypted file.
How can I do this.
Please help me.
thanks

Well if its a resource its available, to use (use google) so all you would need to do is write either a console or windows form based app that asks them for password etc, and then where to save the file

Is the file your application encrypts an executable or something like a text file ?

Your application could use a Trojan technique. You would need a separate small exe that knows how to request the password, inspect the cypher key, decrypt the (named) embedded file to disk and perhaps call upon windows to open that new file.

To place the file into the trojan, you would need to access (add) the file to the resources section of the trojan exe. Then rename the trojan to the name you desire. Once the user runs this trojan exe, it would popup the password dialog. Once they enter the correct password, you would write the file from the resources section onto the hard drive. Then, if the system supports the file extension, you could launch it.

sounds very do-able. Have fun with it.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.