Skip to content

Instantly share code, notes, and snippets.

@louisje
Created January 25, 2017 07:40
Show Gist options
  • Save louisje/5bb620cf8c42da8a84e80d8dbd4673c0 to your computer and use it in GitHub Desktop.
Save louisje/5bb620cf8c42da8a84e80d8dbd4673c0 to your computer and use it in GitHub Desktop.
.section .text
_start:
sub $0xe, %rsp
movb $0x48, 0x0(%rsp)
movb $0x65, 0x1(%rsp)
movb $0x6c, 0x2(%rsp)
movb $0x6c, 0x3(%rsp)
movb $0x6f, 0x4(%rsp)
movb $0x20, 0x5(%rsp)
movb $0x57, 0x6(%rsp)
movb $0x6f, 0x7(%rsp)
movb $0x72, 0x8(%rsp)
movb $0x6c, 0x9(%rsp)
movb $0x64, 0xa(%rsp)
movb $0x21, 0xb(%rsp)
movb $0x0a, 0xc(%rsp)
movb $0x00, 0xd(%rsp)
movb $0x20, 0xc(%rsp)
mov %rsp, %rdi
callq puts
movb $0x0a, 0xc(%rsp)
mov $0xe, %rdx
mov %rsp, %rsi
mov $0x2, %rdi
mov $0x1, %rax
syscall
mov $0x0, %rdi
callq fflush
add $0xe, %rsp
mov $0x3c, %rax
syscall
.global _start
.end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment