This section is the last one. In fact, there are many other things in the PE format, such as resources, which are also very complicated, but I am not interested in it, write something you are interested in-Base Relocations of PE files ). As we have mentioned above, each module has a priority loading address ImageBase. This value is provided by the connector, therefore, the address in the connector Generatio
The PE file structure in the previous article (2) a large array appears at the end of the executable file header, and each item in this array is a specific structure, you can use the rtlimagedirectoryentrytodata function to obtain the items in the array through the function. Each item in datadirectory can be obtained using this function. The function prototype is as follows:
Pvoid ntapi rtlimagedirectoryentrytodata (pvoid base, Boolean mappedasimage,
If a male X falls in love with a female, he will want to explore any part of her body. However, for female friends with flat breasts and small breasts, Princess Taiping's identity will produce a sense of inferiority. How many Shao women are willing to let the nearest Child Care of other parts of the body rather than show a flat chest? It is undoubtedly a huge defect to have a pair of breasts jumping like a bunny. What should I do if I want to show him a perfect person? What breast
If we say that the ancient man's yearning for women's breast milk is more restrained and implicit, then modern people's desire for "huge breasts" is undoubtedly more direct and explicit. As a result, "girly breast enhancement" has become a social hot spot, female seeking for its Da case, male in order to make the beloved female more attractive, but also have to encourage the other half to try. What have you eaten? Are you still worried about your airp
(Note: The leftmost is the offset of the file header.) )Image_dos_header STRUCT{+0h WORD e_magic//Magic DOS signature MZ (4Dh 5Ah) DOS executable tag+2h WORD E_CBLP//bytes on last page of file+4h WORD e_cp//pages in file+6h WORD E_CRLC//relocations+8h WORD e_cparhdr//size of header in paragraphs+0ah WORD E_minalloc//minimun Extra paragraphs needs+0ch WORD E_maxalloc//maximun Extra paragraphs needs+0eh WORD e_ss//intial (relative) SS valueinitialization of the DOS code stack SS+10h WORD e_sp//int
-------- Patch PE files --------
We all know that there are many gaps in PE files, so we may patch PE files.
The practice is to insert our patch code in the gap.
In the following example, I want to teach you how to fill in the notepad.exe (Notepad) Program of win97.
Ding, run my pach.exe program at notepad.exeruntime:
1.insert in section gap of notepad.exe
ShellE
For incremental enhancement and elegant degradation, incremental enhancement and elegant degradation
Graceful degradation: Build the complete functionality of the site from the beginning, and then test and fix the browser. Progressive enhancement (progressive enhancement): At the beginning, only the least features of t
Spring Learning (7)-enhancement class and spring Learning Enhancement class
Spring cut point
What is a cut point? Pointcut, each program class has multiple connection points, for example, a class with two methods, both methods are connection points, that is, the connection points are objective things in the program class. But how can we locate a certain number of connection points from multiple connection p
During the test, I felt that the efficiency was not very good. So I would like to express my gratitude to anyone who can provide valuable suggestions!
1. Traverse PE files on the disk
[CPP]
View plaincopyprint?
/*************************************** *********************************/
/* Function Description: traverses all EXE files in the specified drive.
/* Parameter: Drive name, such as C:
/* Return value: the number of traversal tasks.
/*
[C/C ++ school] (4) c ++ class and object/namespace/type enhancement/Three-object operator/const topic/Reference topic/function enhancement, namespace const1. Classes and objects
Member functions, member variables, and abstract encapsulation capabilities.
Calculates the area of the circle;
# Include
2. Command Space
Namespace; c ++ extensions to c. Resolves the identifier conflict. Std: out: domain identi
Study Dip 70th DayReprint please indicate the source of this article:Http://blog.csdn.net/tonyshengtan , out of respect for the work of the author, reprint please indicate the source! Article code is hosted, Welcome to co-development:Https://github.com/Tony-Tan/DIPproThe opening crap.To continue the simple introduction of color image processing related knowledge, today to simply say the histogram enhancement in color image application, gray-scale imag
PE Study Notes
PE means portable executable (portable execution body ). Overall hierarchical distribution of PE file structure:--------------| Dos MZ header || -------------- || Dos Stub || -------------- || PE Header || -------------- || Section Table || -------------- || Section 1 || -------------- || Section 2 || --
Summary of this chapter
· PE file Format overview
· PE file structure
· How to get Oep in a PE file
· How to get resources in a PE file
· How to modify the PE file to display an instance of the MessageBox 2.1 introduction
Typically, EXE files under windows are in
Detailed description of PE File Format (Part 1)
Summary
Windows NT 3.1 introduces a new executable file format named PE file format. The PE file format specification is included in the msdn Cd (specs and strategy, specifications, Windows NT file format specifications), but it is very obscure.However, this document does not provide sufficient information, so devel
Author: msdnAuthor: Li Ma (http://home.nuc.edu.cn /~ Titilima)
Summary
Windows NT 3.1 introduces a new executable file format named PE file format. The PE file format specification is included in the msdn Cd (specs and strategy, specifications, Windows NT file format specifications), but it is very obscure.However, this document does not provide sufficient information, so developers cannot understand the
Turn: http://hi.baidu.com/cqulwq/blog/item/2be170d6dbb03d2906088b26.html
We all know that in Windows 9x, NT, and 2000, All executable files are based on a new file format portable designed by Microsoft.Executable FileFormat (portable execution body), that is, PE format. In some cases, we need to modify these executable files. The following text attempts to describe the PE file format in detail andModify.
1, positioning standard PE headDos stub length is not fixed, so DOS header is not a fixed-size data structure. The DOS head is located in the starting position of the PE, and the position of the standard PE head after the DOS head is e_lfanew by the field.The value of the E_lfanew field is a relative offset, and the base address of the DOS MZ header is required f
In Windows 9x, NT, and 2000, All executable files are based on a new file format portable Executable File designed by Microsoft.
Format(Portable execution body), that is, PE format. In some cases, we need to modify these executable files. The following text attempts to describe the PE file format and modify the PE format file in detail.
1.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.