Reverse Engineering for Beginners
CHAPTER 51. C++ CHAPTER 51. C++ MSVC The MSVC implementation may store the buffer in place instead of using a pointer to a buffe ...
CHAPTER 51. C++ CHAPTER 51. C++ * The reason you want _M_data pointing to the character %array and * not the _Rep is so that the ...
CHAPTER 51. C++ CHAPTER 51. C++ _main PROC sub esp, 72 push 7 push OFFSET $SG39512 lea ecx, DWORD PTR _s1$[esp+80] mov DWORD PTR ...
CHAPTER 51. C++ CHAPTER 51. C++ The compiler does not construct strings statically: it would not be possible anyway if the buffe ...
CHAPTER 51. C++ CHAPTER 51. C++ mov eax, DWORD PTR [esp+20] mov DWORD PTR [esp+4], ebx sub eax, 12 mov DWORD PTR [esp], eax call ...
CHAPTER 51. C++ CHAPTER 51. C++ Listing 51.27: MSVC 2012: this destructor function is called before exit ??Fs@@YAXXZ PROC push e ...
CHAPTER 51. C++ CHAPTER 51. C++ .hidden __dso_handle But it does not create a separate function for this, each destructor is pas ...
CHAPTER 51. C++ CHAPTER 51. C++ struct a t1; t1.x=1; t1.y=2; l.push_front (t1); t1.x=3; t1.y=4; l.push_front (t1); t1.x=5; t1.y= ...
CHAPTER 51. C++ CHAPTER 51. C++ Next Prev X=garbage Y=garbage list.begin() Variable std::list list.end() At this moment, the .be ...
CHAPTER 51. C++ CHAPTER 51. C++ operator--andoperator++just set the current iterator’s value to thecurrent_node->prevor curre ...
CHAPTER 51. C++ CHAPTER 51. C++ mov [esp], ebx call _Z14dump_List_nodeP9List_node ; dump_List_node(List_node *) mov dword ptr [e ...
CHAPTER 51. C++ CHAPTER 51. C++ call puts mov esi, [esp+14h] mov [esp], esi call _ZNSt8__detail15_List_node_base9_M_unhookEv ; s ...
CHAPTER 51. C++ CHAPTER 51. C++ Next Prev X=garbage Y=garbage Next Prev X=1st element Y=1st element Next Prev X=2nd element Y=2n ...
CHAPTER 51. C++ CHAPTER 51. C++ ; allocate new node call ??$_Buynode@ABUa@@@?$_List_buy@Ua@@V?$allocator@Ua@@@std@@@std@@QAEPAU? ...
CHAPTER 51. C++ CHAPTER 51. C++ push DWORD PTR [esi+12] push DWORD PTR [esi+8] push OFFSET $SG40864 ; '2nd element: %d %d' call ...
CHAPTER 51. C++ CHAPTER 51. C++ ptr=0x003CC288 _Next=0x003CC270 _Prev=0x003CC258 x=3 y=4 ptr=0x003CC270 _Next=0x003CC2A0 _Prev=0 ...
CHAPTER 51. C++ CHAPTER 51. C++ }; int main() { std::vector c; dump ((struct vector_of_ints)(void)&c); c.push_back(1); dump ...
CHAPTER 51. C++ CHAPTER 51. C++ As it can be seen, there is no allocated buffer whenmain()starts. After the firstpush_back()call ...
CHAPTER 51. C++ CHAPTER 51. C++ call ?dump@@YAXPAUvector_of_ints@@@Z ; dump add esp, 4 mov DWORD PTR $T5[ebp], 2 lea eax, DWORD ...
CHAPTER 51. C++ CHAPTER 51. C++ shl eax, 2 mov ecx, DWORD PTR _c$[ebp] mov edx, DWORD PTR [ecx+eax] push edx push OFFSET $SG5265 ...
«
24
25
26
27
28
29
30
31
32
33
»
Free download pdf