rockstardevil

stack 0 protostar

Apr 2nd, 2020
386
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
GDB 26.44 KB | None | 0 0
  1. terminal 1
  2. gdcrsd@kali:~/Videos$ gdb qq
  3. GNU gdb (Debian 8.3.1-1) 8.3.1
  4. Copyright (C) 2019 Free Software Foundation, Inc.
  5. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
  6. This is free software: you are free to change and redistribute it.
  7. There is NO WARRANTY, to the extent permitted by law.
  8. Type "show copying" and "show warranty" for details.
  9. This GDB was configured as "x86_64-linux-gnu".
  10. Type "show configuration" for configuration details.
  11. For bug reporting instructions, please see:
  12. <http://www.gnu.org/software/gdb/bugs/>.
  13. Find the GDB manual and other documentation resources online at:
  14.     <http://www.gnu.org/software/gdb/documentation/>.
  15.  
  16. For help, type "help".
  17. Type "apropos word" to search for commands related to "word"...
  18. Reading symbols from qq...
  19. (No debugging symbols found in qq)
  20. (gdb) info address buffer
  21. No symbol "buffer" in current context.
  22. (gdb) break main
  23. Breakpoint 1 at 0x1149
  24. (gdb) r
  25. Starting program: /home/rsd/Videos/qq
  26.  
  27. Breakpoint 1, 0x0000555555555149 in main ()
  28. (gdb) info address buffer
  29. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  30. (gdb) info
  31. address                    proc
  32. all-registers              program
  33. args                       record
  34. auto-load                  registers
  35. auxv                       scope
  36. bookmarks                  selectors
  37. breakpoints                set
  38. checkpoints                sharedlibrary
  39. classes                    signals
  40. common                     skip
  41. copying                    source
  42. dcache                     sources
  43. display                    stack
  44. exceptions                 static-tracepoint-markers
  45. extensions                 symbol
  46. files                      target
  47. float                      tasks
  48. frame                      terminal
  49. frame-filter               threads
  50. functions                  tracepoints
  51. guile                      tvariables
  52. handle                     type-printers
  53. inferiors                  types
  54. (gdb) info
  55. "info" must be followed by the name of an info command.
  56. List of info subcommands:
  57.  
  58. info address -- Describe where symbol SYM is stored
  59. info all-registers -- List of all registers and their contents
  60. info args -- All argument variables of current stack frame or those matching REGEXPs
  61. info auto-load -- Print current status of auto-loaded files
  62. info auxv -- Display the inferior's auxiliary vector
  63. info bookmarks -- Status of user-settable bookmarks
  64. info breakpoints -- Status of specified breakpoints (all user-settable breakpoints if no argument)
  65. info checkpoints -- IDs of currently known checkpoints
  66. info classes -- All Objective-C classes
  67. info common -- Print out the values contained in a Fortran COMMON block
  68. info copying -- Conditions for redistributing copies of GDB
  69. info dcache -- Print information on the dcache performance
  70. info display -- Expressions to display when program stops
  71. info exceptions -- List all Ada exception names
  72. info extensions -- All filename extensions associated with a source language
  73. info files -- Names of targets and files being debugged
  74. info float -- Print the status of the floating point unit
  75. info frame -- All about the selected stack frame
  76. info frame-filter -- List all registered Python frame-filters
  77. --Type <RET> for more, q to quit, c to continue without paging--
  78. info functions -- All function names or those matching REGEXPs
  79. info guile -- Prefix command for Guile info displays
  80. info handle -- What debugger does when program gets various signals
  81. info inferiors -- Print a list of inferiors being managed
  82. info line -- Core addresses of the code for a source line
  83. info locals -- All local variables of current stack frame or those matching REGEXPs
  84. info macro -- Show the definition of MACRO
  85. info macros -- Show the definitions of all macros at LINESPEC
  86. info mem -- Memory region attributes
  87. info os -- Show OS data ARG
  88. info pretty-printer -- GDB command to list all registered pretty-printers
  89. info probes -- Show available static probes
  90. info proc -- Show additional information about a process
  91. info program -- Execution status of the program
  92. info record -- Info record options
  93. info registers -- List of integer registers and their contents
  94. info scope -- List the variables local to a scope
  95. info selectors -- All Objective-C selectors
  96. info set -- Show all GDB settings
  97. info sharedlibrary -- Status of loaded shared object libraries
  98. info signals -- What debugger does when program gets various signals
  99. info skip -- Display the status of skips
  100. --Type <RET> for more, q to quit, c to continue without paging--
  101. info source -- Information about the current source file
  102. info sources -- Source files in the program
  103. info stack -- Backtrace of the stack
  104. info static-tracepoint-markers -- List target static tracepoints markers
  105. info symbol -- Describe what symbol is at location ADDR
  106. info target -- Names of targets and files being debugged
  107. info tasks -- Provide information about all known Ada tasks
  108. info terminal -- Print inferior's saved terminal status
  109. info threads -- Display currently known threads
  110. info tracepoints -- Status of specified tracepoints (all tracepoints if no argument)
  111. info tvariables -- Status of trace state variables and their values
  112. info type-printers -- GDB command to list all registered type-printers
  113. info types -- All type names
  114. info unwinder -- GDB command to list unwinders
  115. info variables -- All global and static variable names or those matching REGEXPs
  116. info vector -- Print the status of the vector unit
  117. info vtbl -- Show the virtual function table for a C++ object
  118. info warranty -- Various kinds of warranty you do not have
  119. info watchpoints -- Status of specified watchpoints (all watchpoints if no argument)
  120. info win -- List of all displayed windows
  121. --Type <RET> for more, q to quit, c to continue without paging--
  122. info xmethod -- GDB command to list registered xmethod matchers
  123.  
  124. Type "help info" followed by info subcommand name for full documentation.
  125. Type "apropos word" to search for commands related to "word".
  126. Command name abbreviations are allowed if unambiguous.
  127. (gdb) info os
  128. Type       Description
  129. cpus       Listing of all cpus/cores on the system
  130. files      Listing of all file descriptors
  131. modules    Listing of all loaded kernel modules
  132. msg        Listing of all message queues
  133. processes  Listing of all processes
  134. procgroups Listing of all process groups
  135. semaphores Listing of all semaphores
  136. shm        Listing of all shared-memory regions
  137. sockets    Listing of all internet-domain sockets
  138. threads    Listing of all threads
  139. (gdb) info addess buffer
  140. Undefined info command: "addess buffer".  Try "help info".
  141. (gdb) info address buffer
  142. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  143. (gdb) c
  144. Continuing.
  145. aaaaaaaaaaaaaaaaaaaa
  146. Try again?
  147. [Inferior 1 (process 14831) exited normally]
  148. (gdb) info address buffer
  149. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  150. (gdb) c
  151. The program is not being run.
  152. (gdb) info address buffer
  153. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  154. (gdb) c
  155. The program is not being run.
  156. (gdb) info address buffer
  157. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  158. (gdb) p 0x7ffff7f9ff60-0x7fffffffdf5c
  159. $1 = -134602748
  160. (gdb) r
  161. Starting program: /home/rsd/Videos/qq
  162.  
  163. Breakpoint 1, 0x0000555555555149 in main ()
  164. (gdb) c
  165. Continuing.
  166. aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
  167. Try again?
  168. [Inferior 1 (process 14885) exited normally]
  169. (gdb) p 0x7ffff7f9ff60-0x7fffffffdf5c
  170. $2 = -134602748
  171. (gdb) info address modified
  172. No symbol "modified" in current context.
  173. (gdb) c
  174. The program is not being run.
  175. (gdb) info address modified
  176. No symbol "modified" in current context.
  177. (gdb) info address modified
  178. No symbol "modified" in current context.
  179. (gdb) info address buffer
  180. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  181. (gdb) c
  182. The program is not being run.
  183. (gdb) r
  184. Starting program: /home/rsd/Videos/qq
  185.  
  186. Breakpoint 1, 0x0000555555555149 in main ()
  187. (gdb) info address buffer
  188. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  189. (gdb) info address modified
  190. No symbol "modified" in current context.
  191. (gdb) c
  192. Continuing.
  193. aaaaaaaaaaaaaaaa
  194. Try again?
  195. [Inferior 1 (process 14909) exited normally]
  196. (gdb) info address modified
  197.  
  198.  
  199. terminal 2
  200. rsd@kali:~/Videos$ gdb qq
  201. GNU gdb (Debian 8.3.1-1) 8.3.1
  202. Copyright (C) 2019 Free Software Foundation, Inc.
  203. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
  204. This is free software: you are free to change and redistribute it.
  205. There is NO WARRANTY, to the extent permitted by law.
  206. Type "show copying" and "show warranty" for details.
  207. This GDB was configured as "x86_64-linux-gnu".
  208. Type "show configuration" for configuration details.
  209. For bug reporting instructions, please see:
  210. <http://www.gnu.org/software/gdb/bugs/>.
  211. Find the GDB manual and other documentation resources online at:
  212.     <http://www.gnu.org/software/gdb/documentation/>.
  213.  
  214. For help, type "help".
  215. Type "apropos word" to search for commands related to "word"...
  216. Reading symbols from qq...
  217. (No debugging symbols found in qq)
  218. (gdb) set disassembly-flavor intel
  219. (gdb) break main
  220. Breakpoint 1 at 0x1149
  221. (gdb) r
  222. Starting program: /home/rsd/Videos/qq
  223.  
  224. Breakpoint 1, 0x0000555555555149 in main ()
  225. (gdb) disassemble main
  226. Dump of assembler code for function main:
  227.    0x0000555555555145 <+0>: push   rbp
  228.    0x0000555555555146 <+1>: mov    rbp,rsp
  229. => 0x0000555555555149 <+4>: sub    rsp,0x60
  230.    0x000055555555514d <+8>: mov    DWORD PTR [rbp-0x54],edi
  231.    0x0000555555555150 <+11>:    mov    QWORD PTR [rbp-0x60],rsi
  232.    0x0000555555555154 <+15>:    mov    DWORD PTR [rbp-0x4],0x0
  233.    0x000055555555515b <+22>:    lea    rax,[rbp-0x50]
  234.    0x000055555555515f <+26>:    mov    rdi,rax
  235.    0x0000555555555162 <+29>:    mov    eax,0x0
  236.    0x0000555555555167 <+34>:    call   0x555555555040 <gets@plt>
  237.    0x000055555555516c <+39>:    mov    eax,DWORD PTR [rbp-0x4]
  238.    0x000055555555516f <+42>:    test   eax,eax
  239.    0x0000555555555171 <+44>:    je     0x555555555181 <main+60>
  240.    0x0000555555555173 <+46>:    lea    rdi,[rip+0xe8e]        # 0x555555556008
  241.    0x000055555555517a <+53>:    call   0x555555555030 <puts@plt>
  242.    0x000055555555517f <+58>:    jmp    0x55555555518d <main+72>
  243.    0x0000555555555181 <+60>:    lea    rdi,[rip+0xea9]        # 0x555555556031
  244.    0x0000555555555188 <+67>:    call   0x555555555030 <puts@plt>
  245.    0x000055555555518d <+72>:    mov    eax,0x0
  246.    0x0000555555555192 <+77>:    leave  
  247.    0x0000555555555193 <+78>:    ret    
  248. End of assembler dump.
  249. (gdb) info pro
  250. probes   proc     program  
  251. (gdb) info proc mappings
  252. process 12955
  253. Mapped address spaces:
  254.  
  255.           Start Addr           End Addr       Size     Offset objfile
  256.       0x555555554000     0x555555555000     0x1000        0x0 /home/rsd/Videos/qq
  257.       0x555555555000     0x555555556000     0x1000     0x1000 /home/rsd/Videos/qq
  258.       0x555555556000     0x555555557000     0x1000     0x2000 /home/rsd/Videos/qq
  259.       0x555555557000     0x555555558000     0x1000     0x2000 /home/rsd/Videos/qq
  260.       0x555555558000     0x555555559000     0x1000     0x3000 /home/rsd/Videos/qq
  261.       0x7ffff7de1000     0x7ffff7e06000    0x25000        0x0 /lib/x86_64-linux-gnu/libc-2.29.so
  262.       0x7ffff7e06000     0x7ffff7f4d000   0x147000    0x25000 /lib/x86_64-linux-gnu/libc-2.29.so
  263.       0x7ffff7f4d000     0x7ffff7f96000    0x49000   0x16c000 /lib/x86_64-linux-gnu/libc-2.29.so
  264.       0x7ffff7f96000     0x7ffff7f97000     0x1000   0x1b5000 /lib/x86_64-linux-gnu/libc-2.29.so
  265. --Type <RET> for more, q to quit, c to continue without paging--
  266. gnu/libc-2.29.so
  267.       0x7ffff7f9a000     0x7ffff7f9d000     0x3000   0x1b8000 /lib/x86_64-linux-gnu/libc-2.29.so
  268.       0x7ffff7f9d000     0x7ffff7fa3000     0x6000        0x0
  269.       0x7ffff7fd0000     0x7ffff7fd3000     0x3000        0x0 [vvar]
  270.       0x7ffff7fd3000     0x7ffff7fd4000     0x1000        0x0 [vdso]
  271.       0x7ffff7fd4000     0x7ffff7fd5000     0x1000        0x0 /lib/x86_64-linux-gnu/ld-2.29.so
  272.       0x7ffff7fd5000     0x7ffff7ff4000    0x1f000     0x1000 /lib/x86_64-linux-gnu/ld-2.29.so
  273.       0x7ffff7ff4000     0x7ffff7ffc000     0x8000    0x20000 /lib/x86_64-linux-gnu/ld-2.29.so
  274.       0x7ffff7ffc000     0x7ffff7ffd000     0x1000    0x27000 /lib/x86_64-linux-gnu/ld-2.29.so
  275.       0x7ffff7ffd000     0x7ffff7ffe000     0x1000    0x28000 /lib/x86_64-linux-gnu/ld-2.29.so
  276.       0x7ffff7ffe000     0x7ffff7fff000     0x1000        0x0
  277.       0x7ffffffde000     0x7ffffffff000    0x21000        0x0 [stack]
  278. (gdb) x $rbp-0x4
  279. 0x7fffffffdf5c: 0x00000000
  280. (gdb) p $rbp-0x4
  281. $1 = (void *) 0x7fffffffdf5c
  282. (gdb) clear
  283. No source file specified.
  284. (gdb) disassemble main
  285. Dump of assembler code for function main:
  286.    0x0000555555555145 <+0>: push   rbp
  287.    0x0000555555555146 <+1>: mov    rbp,rsp
  288. => 0x0000555555555149 <+4>: sub    rsp,0x60
  289.    0x000055555555514d <+8>: mov    DWORD PTR [rbp-0x54],edi
  290.    0x0000555555555150 <+11>:    mov    QWORD PTR [rbp-0x60],rsi
  291.    0x0000555555555154 <+15>:    mov    DWORD PTR [rbp-0x4],0x0
  292.    0x000055555555515b <+22>:    lea    rax,[rbp-0x50]
  293.    0x000055555555515f <+26>:    mov    rdi,rax
  294.    0x0000555555555162 <+29>:    mov    eax,0x0
  295.    0x0000555555555167 <+34>:    call   0x555555555040 <gets@plt>
  296.    0x000055555555516c <+39>:    mov    eax,DWORD PTR [rbp-0x4]
  297.    0x000055555555516f <+42>:    test   eax,eax
  298.    0x0000555555555171 <+44>:    je     0x555555555181 <main+60>
  299.    0x0000555555555173 <+46>:    lea    rdi,[rip+0xe8e]        # 0x555555556008
  300.    0x000055555555517a <+53>:    call   0x555555555030 <puts@plt>
  301.    0x000055555555517f <+58>:    jmp    0x55555555518d <main+72>
  302.    0x0000555555555181 <+60>:    lea    rdi,[rip+0xea9]        # 0x555555556031
  303.    0x0000555555555188 <+67>:    call   0x555555555030 <puts@plt>
  304.    0x000055555555518d <+72>:    mov    eax,0x0
  305.    0x0000555555555192 <+77>:    leave  
  306.    0x0000555555555193 <+78>:    ret    
  307. --Type <RET> for more, q to quit, c to continue without paging--
  308. End of assembler dump.
  309. (gdb) b *0x000055555555516c
  310. Breakpoint 2 at 0x55555555516c
  311. (gdb) r
  312. The program being debugged has been started already.
  313. Start it from the beginning? (y or n) y
  314. Starting program: /home/rsd/Videos/qq
  315. A
  316. Breakpoint 1, 0x0000555555555149 in main ()
  317. (gdb) x
  318. 0x7fffffffdf60: 0x555551a0
  319. (gdb) c
  320. Continuing.
  321. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
  322.  
  323. Breakpoint 2, 0x000055555555516c in main ()
  324. (gdb) info registers
  325. rax            0x7fffffffdf10      140737488346896
  326. rbx            0x0                 0
  327. rcx            0x7ffff7f9aa00      140737353722368
  328. rdx            0x7ffff7f9d590      140737353733520
  329. rsi            0x5555555592a1      93824992252577
  330. rdi            0x7fffffffdf11      140737488346897
  331. rbp            0x7fffffffdf60      0x7fffffffdf60
  332. rsp            0x7fffffffdf00      0x7fffffffdf00
  333. r8             0x7fffffffdf10      140737488346896
  334. r9             0x0                 0
  335. r10            0x410               1040
  336. r11            0x246               582
  337. r12            0x555555555060      93824992235616
  338. r13            0x7fffffffe040      140737488347200
  339. r14            0x0                 0
  340. r15            0x0                 0
  341. rip            0x55555555516c      0x55555555516c <main+39>
  342. eflags         0x246               [ PF ZF IF ]
  343. cs             0x33                51
  344. ss             0x2b                43
  345. ds             0x0                 0
  346. es             0x0                 0
  347. --Type <RET> for more, q to quit, c to continue without paging--q
  348. Quit
  349. (gdb) x/24wx $rsp
  350. 0x7fffffffdf00: 0xffffe048  0x00007fff  0xffffdf37  0x00000001
  351. 0x7fffffffdf10: 0x41414141  0x41414141  0x41414141  0x41414141
  352. 0x7fffffffdf20: 0x41414141  0x41414141  0x41414141  0x41414141
  353. 0x7fffffffdf30: 0x41414141  0x41414141  0x00000041  0x00000000
  354. 0x7fffffffdf40: 0x555551a0  0x00005555  0x55555060  0x00005555
  355. 0x7fffffffdf50: 0xffffe040  0x00007fff  0x00000000  0x00000000
  356. (gdb) c
  357. Continuing.
  358. Try again?
  359. [Inferior 1 (process 13337) exited normally]
  360. (gdb) r
  361. Starting program: /home/rsd/Videos/qq
  362.  
  363. Breakpoint 1, 0x0000555555555149 in main ()
  364. (gdb) r
  365. The program being debugged has been started already.
  366. Start it from the beginning? (y or n) y
  367. Starting program: /home/rsd/Videos/qq
  368.  
  369. Breakpoint 1, 0x0000555555555149 in main ()
  370. (gdb) c
  371. Continuing.
  372. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB
  373.  
  374. Breakpoint 2, 0x000055555555516c in main ()
  375. (gdb) x/24wx $rsp
  376. 0x7fffffffdf00: 0xffffe048  0x00007fff  0xffffdf37  0x00000001
  377. 0x7fffffffdf10: 0x41414141  0x41414141  0x41414141  0x41414141
  378. 0x7fffffffdf20: 0x41414141  0x41414141  0x41414141  0x41414141
  379. 0x7fffffffdf30: 0x41414141  0x41414141  0x41414141  0x42424141
  380. 0x7fffffffdf40: 0x55555100  0x00005555  0x55555060  0x00005555
  381. 0x7fffffffdf50: 0xffffe040  0x00007fff  0x00000000  0x00000000
  382. (gdb) c
  383. Continuing.
  384. Try again?
  385. [Inferior 1 (process 13736) exited normally]
  386. (gdb) r
  387. Starting program: /home/rsd/Videos/qq
  388.  
  389. Breakpoint 1, 0x0000555555555149 in main ()
  390. (gdb) c
  391. Continuing.
  392. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB        
  393.  
  394. Breakpoint 2, 0x000055555555516c in main ()
  395. (gdb) x/24wx $rsp
  396. 0x7fffffffdf00: 0xffffe048  0x00007fff  0xffffdf37  0x00000001
  397. 0x7fffffffdf10: 0x41414141  0x41414141  0x41414141  0x41414141
  398. 0x7fffffffdf20: 0x41414141  0x41414141  0x41414141  0x41414141
  399. 0x7fffffffdf30: 0x41414141  0x41414141  0x41414141  0x41414141
  400. 0x7fffffffdf40: 0x41414141  0x41414141  0x41414141  0x41414141
  401. 0x7fffffffdf50: 0x00424241  0x00007fff  0x00000000  0x00000000
  402. (gdb) c
  403. Continuing.
  404. Try again?
  405. [Inferior 1 (process 13854) exited normally]
  406. (gdb) r
  407. Starting program: /home/rsd/Videos/qq
  408.  
  409. Breakpoint 1, 0x0000555555555149 in main ()
  410. (gdb) AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB        
  411. Undefined command: "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB".  Try "help".
  412. (gdb) c
  413. Continuing.
  414. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB        
  415.  
  416. Breakpoint 2, 0x000055555555516c in main ()
  417. (gdb) c
  418. Continuing.
  419. Try again?
  420. [Inferior 1 (process 14025) exited normally]
  421. (gdb) c
  422. The program is not being run.
  423. (gdb) r
  424. Starting program: /home/rsd/Videos/qq
  425.  
  426. Breakpoint 1, 0x0000555555555149 in main ()
  427. (gdb) c
  428. Continuing.
  429. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB        
  430.  
  431. Breakpoint 2, 0x000055555555516c in main ()
  432. (gdb) r
  433. The program being debugged has been started already.
  434. Start it from the beginning? (y or n) y
  435. Starting program: /home/rsd/Videos/qq
  436.  
  437. Breakpoint 1, 0x0000555555555149 in main ()
  438. (gdb) AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
  439. Undefined command: "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".  Try "help".
  440. (gdb) r
  441. The program being debugged has been started already.
  442. Start it from the beginning? (y or n) y
  443. Starting program: /home/rsd/Videos/qq
  444.  
  445. Breakpoint 1, 0x0000555555555149 in main ()
  446. (gdb) AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
  447. Undefined command: "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".  Try "help".
  448. (gdb) c
  449. Continuing.
  450. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
  451.  
  452. Breakpoint 2, 0x000055555555516c in main ()
  453. (gdb) x/24wx $rsp
  454. 0x7fffffffdf00: 0xffffe048  0x00007fff  0xffffdf37  0x00000001
  455. 0x7fffffffdf10: 0x41414141  0x41414141  0x41414141  0x41414141
  456. 0x7fffffffdf20: 0x41414141  0x41414141  0x41414141  0x41414141
  457. 0x7fffffffdf30: 0x41414141  0x41414141  0x41414141  0x41414141
  458. 0x7fffffffdf40: 0x41414141  0x41414141  0x41414141  0x41414141
  459. 0x7fffffffdf50: 0x41414141  0x41414141  0x41414141  0x00000041
  460. (gdb) c
  461. Continuing.
  462. you have changed the 'modified' variable
  463. [Inferior 1 (process 14210) exited normally]
  464. (gdb) r
  465. Starting program: /home/rsd/Videos/qq
  466.  
  467. Breakpoint 1, 0x0000555555555149 in main ()
  468. (gdb) c
  469. Continuing.
  470. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA                    
  471.  
  472. Breakpoint 2, 0x000055555555516c in main ()
  473. (gdb) info proc mappings
  474. process 14784
  475. Mapped address spaces:
  476.  
  477.           Start Addr           End Addr       Size     Offset objfile
  478.       0x555555554000     0x555555555000     0x1000        0x0 /home/rsd/Videos/qq
  479.       0x555555555000     0x555555556000     0x1000     0x1000 /home/rsd/Videos/qq
  480.       0x555555556000     0x555555557000     0x1000     0x2000 /home/rsd/Videos/qq
  481.       0x555555557000     0x555555558000     0x1000     0x2000 /home/rsd/Videos/qq
  482.       0x555555558000     0x555555559000     0x1000     0x3000 /home/rsd/Videos/qq
  483.       0x555555559000     0x55555557a000    0x21000        0x0 [heap]
  484.       0x7ffff7de1000     0x7ffff7e06000    0x25000        0x0 /lib/x86_64-linux-gnu/libc-2.29.so
  485.       0x7ffff7e06000     0x7ffff7f4d000   0x147000    0x25000 /lib/x86_64-linux-gnu/libc-2.29.so
  486.       0x7ffff7f4d000     0x7ffff7f96000    0x49000   0x16c000 /lib/x86_64-linux-gnu/libc-2.29.so
  487.       0x7ffff7f96000     0x7ffff7f97000     0x1000   0x1b5000 /lib/x86_64-linux-gnu/libc-2.29.so
  488.       0x7ffff7f97000     0x7ffff7f9a000     0x3000   0x1b5000 /lib/x86_64-linux-gnu/libc-2.29.so
  489.       0x7ffff7f9a000     0x7ffff7f9d000     0x3000   0x1b8000 /lib/x86_64-linux-gnu/libc-2.29.so
  490.       0x7ffff7f9d000     0x7ffff7fa3000     0x6000        0x0
  491.       0x7ffff7fd0000     0x7ffff7fd3000     0x3000        0x0 [vvar]
  492.       0x7ffff7fd3000     0x7ffff7fd4000     0x1000        0x0 [vdso]
  493.       0x7ffff7fd4000     0x7ffff7fd5000     0x1000        0x0 /lib/x86_64-linux-gnu/ld-2.29.so
  494.       0x7ffff7fd5000     0x7ffff7ff4000    0x1f000     0x1000 /lib/x86_64-linux-gnu/ld-2.29.so
  495.       0x7ffff7ff4000     0x7ffff7ffc000     0x8000    0x20000 /lib/x86_64-linux-gnu/ld-2.29.so
  496.       0x7ffff7ffc000     0x7ffff7ffd000     0x1000    0x27000 /lib/x86_64-linux-gnu/ld-2.29.so
  497.       0x7ffff7ffd000     0x7ffff7ffe000     0x1000    0x28000 /lib/x86_64-linux-gnu/ld-2.29.so
  498.       0x7ffff7ffe000     0x7ffff7fff000     0x1000        0x0
  499.       0x7ffffffde000     0x7ffffffff000    0x21000        0x0 [stack]
  500. (gdb) info registers
  501. rax            0x7fffffffdf10      140737488346896
  502. rbx            0x0                 0
  503. rcx            0x7ffff7f9aa00      140737353722368
  504. rdx            0x7ffff7f9d590      140737353733520
  505. rsi            0x5555555592a1      93824992252577
  506. rdi            0x7fffffffdf11      140737488346897
  507. rbp            0x7fffffffdf60      0x7fffffffdf60
  508. rsp            0x7fffffffdf00      0x7fffffffdf00
  509. r8             0x7fffffffdf10      140737488346896
  510. r9             0x0                 0
  511. r10            0x410               1040
  512. r11            0x246               582
  513. r12            0x555555555060      93824992235616
  514. r13            0x7fffffffe040      140737488347200
  515. r14            0x0                 0
  516. r15            0x0                 0
  517. rip            0x55555555516c      0x55555555516c <main+39>
  518. eflags         0x246               [ PF ZF IF ]
  519. cs             0x33                51
  520. ss             0x2b                43
  521. ds             0x0                 0
  522. es             0x0                 0
  523. fs             0x0                 0
  524. gs             0x0                 0
  525. (gdb) info address buffer
  526. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  527. (gdb) p $rbp-0x4
  528. $2 = (void *) 0x7fffffffdf5c
  529. (gdb) x/x $rbp-0x4
  530. 0x7fffffffdf5c: 0x00000000
  531. (gdb) p 0x7ffff7f9ff60-0x7fffffffdf5c
  532. $3 = -134602748
  533. (gdb) p 0x7fffffffdf5c-0x7ffff7f9ff60
  534. $4 = 134602748
  535. (gdb) info address modified
  536. No symbol "modified" in current context.
  537. (gdb) info address buffer
  538. Symbol "buffer" is static storage at address 0x7ffff7f9ff60.
  539. (gdb) info address modified
  540. No symbol "modified" in current context.
  541. (gdb) info address rbp-0x4
  542. No symbol "rbp-0x4" in current context.
  543. (gdb) info address $rbp-0x4
  544. No symbol "$rbp-0x4" in current context.
  545. (gdb) x $rbp-0x4
  546. 0x7fffffffdf5c: 0x00000000
  547. (gdb) p 0x7ffff7f9ff60-0x7fffffffdf5c
  548. $5 = -134602748
  549. (gdb) info address $rbp-0x3
  550. No symbol "$rbp-0x3" in current context.
  551. (gdb) info address $rbp-0x5
  552. No symbol "$rbp-0x5" in current context.
  553. (gdb) x $rbp-0x3
  554. 0x7fffffffdf5d: 0xa0000000
  555. (gdb) x $rbp-0x2
  556. 0x7fffffffdf5e: 0x51a00000
  557. (gdb) x $rbp-0x1
  558. 0x7fffffffdf5f: 0x5551a000
  559. (gdb) x $rbp-0x5
  560. 0x7fffffffdf5b: 0x00000041
  561. (gdb) x $rbp-0x6
  562. 0x7fffffffdf5a: 0x00004141
  563. (gdb) x/24xb esp
  564. No symbol "esp" in current context.
  565. (gdb) x/24xb $esp
  566. 0xffffffffffffdf00: Cannot access memory at address 0xffffffffffffdf00
  567. (gdb) c
  568. Continuing.
  569. Try again?
  570. [Inferior 1 (process 14784) exited normally]
  571. (gdb) r
  572. Starting program: /home/rsd/Videos/qq
  573.  
  574. Breakpoint 1, 0x0000555555555149 in main ()
  575. (gdb) c
  576. Continuing.
  577. asdsd
  578.  
  579. Breakpoint 2, 0x000055555555516c in main ()
  580. (gdb) x/24wx $rsp
  581. 0x7fffffffdf00: 0xffffe048  0x00007fff  0xffffdf37  0x00000001
  582. 0x7fffffffdf10: 0x73647361  0x00000064  0xf7e85745  0x00007fff
  583. 0x7fffffffdf20: 0x00000000  0x00000000  0x555551e5  0x00005555
  584. 0x7fffffffdf30: 0x00000000  0x00000000  0x00000000  0x00000000
  585. 0x7fffffffdf40: 0x555551a0  0x00005555  0x55555060  0x00005555
  586. 0x7fffffffdf50: 0xffffe040  0x00007fff  0x00000000  0x00000000
  587. (gdb) c
  588. Continuing.
  589. Try again?
  590. [Inferior 1 (process 14925) exited normally]
  591. (gdb) r
  592. Starting program: /home/rsd/Videos/qq
  593.  
  594. Breakpoint 1, 0x0000555555555149 in main ()
  595. (gdb) c
  596. Continuing.
  597. AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
  598.  
  599. Breakpoint 2, 0x000055555555516c in main ()
  600. (gdb) x/24wx $rsp
  601. 0x7fffffffdf00: 0xffffe048  0x00007fff  0xffffdf37  0x00000001
  602. 0x7fffffffdf10: 0x41414141  0x41414141  0x41414141  0x41414141
  603. 0x7fffffffdf20: 0x41414141  0x41414141  0x41414141  0x41414141
  604. 0x7fffffffdf30: 0x41414141  0x41414141  0x00004141  0x00000000
  605. 0x7fffffffdf40: 0x555551a0  0x00005555  0x55555060  0x00005555
  606. 0x7fffffffdf50: 0xffffe040  0x00007fff  0x00000000  0x00000000
  607. (gdb) p 0x7fffffffdf10-0x7ffff7f9ff60
  608. $6 = 134602672
  609. (gdb) p 0x7ffff7f9ff60-0x7fffffffdf5c
  610. $7 = -134602748
  611. (gdb) info registers
  612. Display all 156 possibilities? (y or n)
  613. (gdb) info registers
  614. rax            0x7fffffffdf10      140737488346896
  615. rbx            0x0                 0
  616. rcx            0x7ffff7f9aa00      140737353722368
  617. rdx            0x7ffff7f9d590      140737353733520
  618. rsi            0x5555555592a1      93824992252577
  619. rdi            0x7fffffffdf11      140737488346897
  620. rbp            0x7fffffffdf60      0x7fffffffdf60
  621. rsp            0x7fffffffdf00      0x7fffffffdf00
  622. r8             0x7fffffffdf10      140737488346896
  623. r9             0x0                 0
  624. r10            0x410               1040
  625. r11            0x246               582
  626. r12            0x555555555060      93824992235616
  627. r13            0x7fffffffe040      140737488347200
  628. r14            0x0                 0
  629. r15            0x0                 0
  630. rip            0x55555555516c      0x55555555516c <main+39>
  631. eflags         0x246               [ PF ZF IF ]
  632. cs             0x33                51
  633. ss             0x2b                43
  634. ds             0x0                 0
  635. es             0x0                 0
  636. fs             0x0                 0
  637. gs             0x0                 0
  638. (gdb)
Add Comment
Please, Sign In to add comment