## ============================================================ ## nonsense.s ## A Nonsensical Program to Support the Buffer Overrun ## Assignment ## ============================================================ ## ============================================================ .section ".bss" ## ============================================================ cChar: .skip 1 ## ============================================================ .section ".text" ## ============================================================ .globl main .type main,@function main: pushl %ebp movl %esp, %ebp movb $'A', cChar jmp mylabel ## Skip over some memory so the assembler will ## translate the previous jmp instruction into the kind that ## contains a 4-byte displacement. .skip 256 mylabel: ## return 0; movl $0, %eax movl %ebp, %esp popl %ebp ret