Tech Xpress

Hide files in a Installer for Windows

There are tons of articles and software available that can be used to hide your secret files in windows.
Some articles are about the lame hide folder method in windows and others about encrypting files in a zip file or archive. And not to forget the plethora of softwares (most of them may not be free) available for this.

I figured a unique way to hide files while working on a software project for my client - Hiding your files in a customized professional looking installer program for windows.
For simplicity, this article is split into 2 sections; a small video section where you can quickly watch the how-to clips, and a detailed step-by-step section which includes pictures to illustrate the trick.

If you find this article boring..just scroll down and view the video and step-by-step sections directly. However, it would be sensible to read the next few lines before the actual steps.

Fine! So what exactly is this about?
This post will introduce you to a pretty obscure technique to not only hide files, but also encrypt them in a professional looking installer program for windows.
The end result? These files will be packaged into a windows installer program, making others believe it will install some software, which offcourse it dosen't.

The installer program I'll be using is Inno Setup, a free installer for Windows programs. In my experience, this one stands out as one of the very best installer programs to distribute software.

Encryption allows you to password protect the installer. A wrong password will prevent the installer from copying the files to the harddrive. The password feature is very much similar to the serial key or product key functionality used in other installers.
Also, the target computer on which the files have to be copied need not have Inno Setup installed.

After successful installation, an uninstall icon is also created in the target folder. The uninstaller can be used to delete the files with just a single click.

Before proceeding, make sure you have Inno Setup installed in your computer.
Download Inno Setup.

Video: Hiding files in a windows installer

The first video part below describes creating the setup file from Inno Setup.



The second video part shows the newly created customized setup being executed.



Third video part shows navigating to the installed folder and deleting the files using the uninstall icon.




Step-by-Step: Hiding files in a windows installer

1. Before we proceed, make sure you've installed Inno Setup.
Start Inno setup by clicking the icon from your desktop or from the start menu.
A welcome screen is displayed (see picture below).
Select the Create a new script file using the Script Wizard option and Click Ok.



2. This initiates the Inno Setup Script Wizard. Click Next to continue.


3. The next window prompts you to enter some basic information about your application. You can type any name of your choice for the Application name and Application name including version fields.
The remaining two fields or boxes can be ignored if you wish.


4. Click Next in the Application Directory window (Fig below) of the wizard with the default values. The Application Directory window is where you specify the target folder information.


5. The Application Files screen is next. Use this screen to select the files to pack inside the installer.
Don't forget to select The application dosen't have a main executable file checkbox.
Click the Add file(s) button or Add directory button to choose the files you want to pack.
Click Next.


6. Next is the Application Icons window. Uncheck all the checkboxes as shown in the picture below and click Next.


7. Click Next in the Application Documentation window.


8. Select the language in the next window. (Fig below)


9. In the Compiler Settings window, browse and select the folder where the setup file is to be created in the Custom compiler output directory box (First box in pic below).
Type the setup file name in the Compiler output base file name box (Second box in pic below).
If you want your setup to be password protected, type the password in the Setup password box (last box in fig below).
Don't forget this password as it will be required when you run the setup later.
Leave the password field blank if you don't want a password for the setup.


10. The next is the last window of the wizard. Click Finish.


11. Now, a small window pops up which prompts you to compile the script. Click Yes to compile the script.
Note: The compilation may consume a lot of time depending on the size of files specified. Inno Setup allows splitting the installation into multiple files by using disk spanning. Please check the Inno Setup help file for further assistance.

12. After compilation, the setup is created in the Custom compiler output directory that you mentioned in step 9.
In our example pictures, it is D:\Tech Xpress Testing.

You can click this compiled setup file to install the files.
Note: The setup will prompt for the password that you specified in step 9.

After the installation is complete, the files are unpacked in the target folder the user specifies. Here, an uninstall icon is also created (see picture below).
Clicking the uninstall icon will unistall i.e delete the files from the computer.


If you like this, click here to get updates by email

Click here to subscribe to my Feeds

More Reading:
View your site online in different browsers
Disable tabs in IE7
Megaupload trick to bypass country download slots
Get last updated Date & Time of a web page

Tags:

Labels: , ,

posted by Vijeesh Ravindran, Friday, January 12, 2007


1 Comments:

Do you know how to hide the welcome screen on running the setup file