### -------------------------------------------------------------------- ### nonsense.s ### Author: Bob Dondero ### 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 128 mylabel: ## return 0 movl $0, %eax movl %ebp, %esp popl %ebp ret