+3 votes
1.1k views
How to edit executable file resources (exe, dll, scr, etc)

in Guides by (445k points)
edited by | 1.1k views

2 Answers

+4 votes
Best answer

How to edit executable file resources (exe, dll, scr, etc).
IMPORTANT!

If you have any interest in knowing what is hidden behind the Windows executable files, you have reached the right place. In this small tutorial we will discuss basic concepts to be able to use the different programs that allow us to edit resources of executable files (exe, dll, scr, etc).

image

Executable files are not designed to allow modification, but to run in the operating system. This is because they are the result of compiling a source code into machine code.

Despite this, there are techniques that allow us to modify executable files, some are advanced and require extensive knowledge of reverse engineering. Others are simpler and we can address them using specific programs for this.

How to edit executable file resources (exe, dll, scr, etc).

To begin, we are going to do a little exercise to learn how to edit .exe file resources, since practice is the best way to learn. First, we will need a program that allows us to edit resources. There are currently several alternatives, but the best known program is Resource Hacker (formerly known as ResHack or ResHacker) .

At the end of this tutorial I will leave you with other programs with similar functionality, so that you at least know some alternative to Resource Hacker. At the moment, we go to the official website of the program and download it.

Once installed, we run Resource Hacker and see that we need an executable file to examine. For my tests I will use the executable file of the ResourceHacker.exe program, so I open it through the File → Open menu.

My first goal will be to extract the icon from the ResourceHacker.exe executable. For this I go to the list I find on the left side and double click on «Icon Group» . We see that two groups of icons are shown, we are going to extract the one called «MAINICON: 1033» by right clicking and selecting the option «Save * .ico resource"¦» , which will ask us to enter the name with the You save the icon to disk.

image

With these simple steps we have already managed to extract the icon from an .exe file, something very basic but that serves as a contact.

I leave a small list with other alternative programs to Resource Hacker and they have taken me out of more than a hurry:

IMPORTANT!

I did not want to finish this article without warning you about two programs similar to Resource Hacker that you can find on the internet, but that will install malware on your computer. This is http://www.resedit.net/ and http://www.freeresourceextractor.com/ , both programs have viruses and install malware Beware!


by (2.8m points)
+3 votes

How to use Resource Hacker?
Windows system files that can be hacked
Practical examples of using Resource Hacker
Where to download Resource Hacker?

How to use Resource Hacker?


Resource Hacker is a portable application, so it is not necessary to install, just unzip it and run its EXE file.
To edit any file open it from the application or drag and drop it on top of it.
When a file is opened according to what it contains, the following directories will be displayed in the sidebar:

• AVI = Contains videos.
• Cursor = Cursors.
• Bitmap = Images in BMP.
• Icon = Icons.
• Menu = Menus.
• Dialog = Contains the dialog boxes.
• String Table = String tables or text sequence.
• Accelerators = Contains the shortcut keys available in applications.
• Message Table = Contains default messages returned by applications.
• Version Info = Version and file information.

To extract, edit or modify any resource, select it and choose from the menu: Action the possible options or in the context menu of the mouse.
 

Windows system files that can be hacked


Location of some of the Windows files that can be modified to change the appearance or useful resources can be extracted, they are only examples, the amount of files possible to edit is immense, you only need to explore the system in your search.

File Location Use
C: \ Windows \ System32 \ imageres.dll Contains icons, images, sounds and other operating system resources
C: \ Windows \ System32 \ wmploc.dll Contains Windows Media Player resources
C: \ Windows \ System32 \ ieframe.dll Contains Internet Explorer and network connection resources
C: \ Windows \ Branding \ Basebrd Logos, messages and dialog boxes of the installed version of Windows
C: \ Windows \ Explorer.exe Bitmap 6801-6812 Windows Start Menu logo
C: \ Windows \ System32 \ en-ES Several MUI files of Windows applications, it is possible to transform them completely, for example:
calc.exe.mui -> The Calculator
ieframe.dll.mui -> All dialog boxes in Internet Explorer, Printers, etc.
shell32.dll.mui -> Main system dialog boxes.
inetcpl.cpl.mui -> Internet options

Practical examples of using Resource Hacker


Change a dialog box with Resource Hacker

─ In some cases when you try to modify files in use by the browser, it is necessary to finish the explorer.exe process with the Task Manager (Control + Shift + Escape), then to start it in the Administrator itself, select in the menu: File - > New task: explorer.exe
─ In other cases it is necessary to take possession of the file, that is to have the necessary permissions to modify it. Read how to do it:
◄ Add options to change permissions in the context menu

Resource Hacker limitations and errors

✖ The application has been compiled using Delphi 3.02, so it will cause error when trying to edit any application or file made with recent versions of Delphi.
✖ Many EXE applications or executables after they are created are packaged or compressed with EXE compressors, in that case it will be impossible to open them with Resource Hacker and an error message will be received.
✖ Does not read 16-bit executable applications.

Precautions when using Resource Hacker on Windows


Always make sure before opening any system file to extract resources, to do it in a copy, if you are going to modify the contents of one, then create and have a safe copy.
 

Where to download Resource Hacker?


• You can download Resource Hacker for free, directly from its author's page at:
HOME PAGE Resource Hacker http://www.angusj.com/resourcehacker/
Version 4.0.0 and 4.1.1 is available
• Another application recommended by the Resource Hacker author and similar can be found at: Resource Editor - (http://www.wilsonc.demon.co.uk/d10resourceeditor.htm)

Use Resource Hacker in a portable way
Install the program using setup.exe
After installation copy the "Resource Hacker" folder of "C: \ Program Files" to the USB storage device and then run the EXE from there.


by (445k points)

Related questions

+5 votes
1 answer
asked Sep 23, 2020 in Windows 10 by backtothefuture (445k points) | 166 views
+5 votes
1 answer
+4 votes
1 answer
asked Nov 17 in Guides by backtothefuture (445k points) | 3 views
+5 votes
1 answer
asked Aug 9, 2019 in Guides by backtothefuture (445k points) | 148 views
+4 votes
1 answer
8,518 questions
8,621 answers
407 comments
2 users