Presentation is loading. Please wait.

Presentation is loading. Please wait.

ESP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. } EIP 100: 200: 250: 300: 350:

Similar presentations


Presentation on theme: "ESP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. } EIP 100: 200: 250: 300: 350:"— Presentation transcript:

1 ESP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. } EIP 100: 200: 250: 300: 350:

2 1 ESP EIP 100: 200: 250: 300: 350: int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

3 1 return address to main ESP EIP 100: 200: 250: 300: 350: int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

4 1 return address to main ESP EIP 100: 200: 250: 300: 350: int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

5 1 return address to main Old EBP ESP EIP 100: 200: 250: 300: 350: int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

6 1 return address to main Old EBP ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

7 1 return address to main Old EBP ESI EDI EBX Local Variables ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

8 1 return address to main Old EBP ESI EDI EBX Local Variables ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

9 1 return address to main Old EBP ESI EDI EBX Local Variables 2 ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

10 1 return address to main Old EBP ESI EDI EBX Local Variables 2 return address to g ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

11 1 return address to main Old EBP ESI EDI EBX Local Variables 2 return address to g ESP 100: 200: 250: 300: 350: EBP EIP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

12 1 return address to main Old EBP ESI EDI EBX Local Variables 2 return address to g Old EBP ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

13 1 return address to main Old EBP ESI EDI EBX Local Variables 2 return address to g Old EBP ESP EIP 100: 200: 250: 300: 350: EBP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. }

14 1 return address to main Old EBP ESI EDI EBX Local Variables 2 return address to g Old EBP ESI EDI EBX Local Variables ESP 100: 200: 250: 300: 350: EIP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. } EBP

15 1 return address to main Old EBP ESI EDI EBX Local Variables 2 return address to g Old EBP ESI EDI EBX Local Variables ESP 100: 200: 250: 300: 350: EIP Function Frames int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. } EBP


Download ppt "ESP int f(int x) {.... } int g(int y) { …. f(2); …. } int main() { …. g(1); …. } EIP 100: 200: 250: 300: 350:"

Similar presentations


Ads by Google