sfl-examples/slide-examples/assembly/ex24.asm

27 lines
516 B
NASM
Raw Normal View History

2023-12-14 14:12:51 +01:00
; assembly obfuscation
bits 64
SECTION .data
; empty
SECTION .text
global _start
_start:
int3
jmp s0 ; ---------|
dd 0x841f0f66 ; | prefix for a 9-byte-wide NOP
; | --> will consume the next 5B
s0: xor eax, eax ; <--+
jmp s1 ; ---------|
dd 0x841f0f66 ; | again, consumes a few bytes
s1: xor rbx, rbx ; <--+
inc rbx
jmp s2 ; ---------|
dd 0x841f0f66 ; | again, consumes a few bytes
s2: mov rcx, 2 ; <----|
nop
nop
nop
nop