joyce8/EMBER2024-capa huggingface dataset:
Function at 0x5648fc
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x6c
mov dword [ebp - 0x4c], ecx
dec ecx
cmp ecx, 0x7f
jbe 0x564918
add esp, 0x6c
pop ebx
pop esi
pop edi
leave
ret
lea ecx, [ebp - 0x39]
mov dword [ebp - 0x5c], ecx
mov ecx, 4
mov edi, dword [ebp - 0x5c]
mov esi, dword [ebp + 0xc]
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp + 8]
mov dword [esp + 8], ecx
mov ecx, dword [ebp + 0xc]
mov dword [esp + 4], ecx
mov dword [esp], ecx
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x54], edx
call dword [ebp + 0x14]
mov esi, dword [ebp - 0x4c]
add esi, 7
sar esi, 3
mov eax, dword [ebp + 0x10]
test eax, eax
mov eax, dword [ebp - 0x50]
mov edx, dword [ebp - 0x54]
je 0x5649c0
xor ecx, ecx
mov edi, dword [ebp + 0xc]
mov bl, byte [edi + ecx]
xor bl, byte [eax + ecx]
mov byte [ebp + ecx - 0x29], bl
mov byte [edx + ecx], bl
inc ecx
cmp esi, ecx
jg 0x564960
mov edx, dword [ebp - 0x4c]
sar edx, 3
mov eax, dword [ebp - 0x4c]
and eax, 7
mov dword [ebp - 0x4c], eax
je 0x5649dc
mov ebx, 8
sub ebx, dword [ebp - 0x4c]
lea ecx, [ebp - 0x39]
lea edx, [ecx + edx]
xor eax, eax
mov edi, ebx
lea esi, [esi]
movzx esi, byte [edx + 1]
mov ecx, edi
sar esi, cl
movzx ebx, byte [edx]
mov cl, byte [ebp - 0x4c]
shl ebx, cl
or ebx, esi
mov ecx, dword [ebp + 0xc]
mov byte [ecx + eax], bl
inc eax
inc edx
cmp eax, 0x10
jne 0x564998
add esp, 0x6c
pop ebx
pop esi
pop edi
leave
ret
xor ecx, ecx
mov edi, dword [ebp + 0xc]
lea esi, [esi]
mov bl, byte [eax + ecx]
mov byte [ebp + ecx - 0x29], bl
xor bl, byte [edi + ecx]
mov byte [edx + ecx], bl
inc ecx
cmp esi, ecx
jg 0x5649c8
jmp 0x564972
lea esi, [ebp - 0x39]
add esi, edx
mov ecx, 4
mov edi, dword [ebp + 0xc]
rep movsd dword es:[edi], dword [esi]
jmp 0x56490e
Function at 0x564cfc
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov ecx, dword [ebp + 0xc]
mov ebx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x1c]
mov edx, dword [eax]
test edx, edx
je 0x564d46
mov esi, dword [ebp + 0x10]
test esi, esi
je 0x564df0
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0x10]
jmp 0x564d30
test edi, edi
je 0x564df0
mov al, byte [ebx + edx]
xor al, byte [esi]
mov byte [ecx], al
inc ecx
inc esi
dec edi
inc edx
and edx, 0xf
jne 0x564d28
mov dword [ebp + 8], esi
mov dword [ebp + 0x10], edi
cmp dword [ebp + 0x10], 0xf
jbe 0x564db7
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x24], ecx
mov edi, dword [ebp - 0x24]
sub edi, dword [ebp - 0x1c]
mov esi, dword [ebp + 8]
sub esi, dword [ebp - 0x1c]
mov eax, dword [ebp + 0x14]
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], ebx
call dword [ebp + 0x20]
xor eax, eax
nop
mov edx, dword [ebx + eax]
xor edx, dword [esi + eax]
mov dword [edi + eax], edx
add eax, 4
cmp eax, 0x10
jne 0x564d7c
sub dword [ebp - 0x20], 0x10
sub dword [ebp - 0x1c], 0x10
cmp dword [ebp - 0x20], 0xf
ja 0x564d5c
mov ecx, dword [ebp - 0x24]
mov eax, dword [ebp + 0x10]
sub eax, 0x10
mov edx, eax
and edx, 0xf
mov dword [ebp + 0x10], edx
and eax, 0xfffffff0
add eax, 0x10
add ecx, eax
add dword [ebp + 8], eax
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x564dfd
mov eax, dword [ebp + 0x14]
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], ebx
mov dword [ebp - 0x28], ecx
call dword [ebp + 0x20]
mov esi, dword [ebp + 0x10]
xor eax, eax
mov edi, dword [ebp + 8]
mov ecx, dword [ebp - 0x28]
lea esi, [esi]
mov dl, byte [ebx + eax]
xor dl, byte [edi + eax]
mov byte [ecx + eax], dl
inc eax
dec esi
jne 0x564de0
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp + 0x1c]
mov dword [eax], edx
add esp, 0x2c
pop ebx
pop esi
pop edi
leave
ret
xor edx, edx
mov eax, dword [ebp + 0x1c]
mov dword [eax], edx
add esp, 0x2c
pop ebx
pop esi
pop edi
leave
ret
Function at 0x56dd70
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov ebx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebx + 4]
mov eax, dword [edx + 4]
cmp ecx, eax
jl 0x56de1c
mov eax, ecx
mov esi, edx
mov edx, dword [ebp + 8]
cmp dword [edx + 8], eax
jl 0x56de2c
mov eax, dword [esi + 4]
test eax, eax
jle 0x56de59
mov ecx, dword [ebp + 8]
mov edi, dword [ecx]
mov ecx, dword [ebx]
mov edx, dword [esi]
xor eax, eax
mov dword [ebp - 0x1c], ebx
mov ebx, edx
mov edx, dword [ebx + eax*4]
xor edx, dword [ecx + eax*4]
mov dword [edi + eax*4], edx
inc eax
cmp dword [esi + 4], eax
jg 0x56ddb8
mov ebx, dword [ebp - 0x1c]
mov edx, dword [ebx + 4]
cmp eax, edx
jge 0x56dde6
mov edx, dword [ebp + 8]
mov esi, dword [edx]
mov ecx, dword [ebx]
mov edx, dword [ecx + eax*4]
mov dword [esi + eax*4], edx
inc eax
mov edx, dword [ebx + 4]
cmp edx, eax
jg 0x56ddd8
mov ecx, dword [ebp + 8]
mov dword [ecx + 4], edx
test edx, edx
jle 0x56de4c
lea eax, [edx*4 - 4]
add eax, dword [ecx]
lea esi, [esi]
mov ecx, dword [eax]
sub eax, 4
test ecx, ecx
jne 0x56de08
dec edx
jne 0x56ddfc
mov eax, dword [ebp + 8]
mov dword [eax + 4], edx
mov eax, 1
add esp, 0x2c
pop ebx
pop esi
pop edi
leave
ret
mov esi, ebx
mov ebx, edx
mov edx, dword [ebp + 8]
cmp dword [edx + 8], eax
jge 0x56dd9d
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.00508e8c
test eax, eax
jne 0x56dd9d
xor eax, eax
add esp, 0x2c
pop ebx
pop esi
pop edi
leave
ret
mov eax, 1
add esp, 0x2c
pop ebx
pop esi
pop edi
leave
ret
xor eax, eax
jmp 0x56ddca
Function at 0x57b9a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x1c
mov ebx, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov esi, dword [ebp + 0x10]
test ebx, ebx
je 0x57b9bc
cmp byte [ebx + 0x5c], 0x77
je 0x57b9d0
add esp, 0x1c
mov eax, 0xfffffffe
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [ebx], edi
test esi, esi
mov ecx, esi
mov dword [ebx + 4], esi
je 0x57ba4c
mov edx, dword [ebx + 0x10]
nop
test edx, edx
jne 0x57ba21
mov eax, dword [ebx + 0x48]
mov ecx, 0x4000
mov edx, dword [ebx + 0x40]
mov dword [ebx + 0xc], eax
mov dword [esp + 0xc], edx
mov edx, 1
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.msvcrt.dll_fwrite
cmp eax, 0x4000
jne 0x57ba71
mov dword [ebx + 0x10], 0x4000
mov ecx, dword [ebx + 4]
mov edx, 0x4000
add dword [ebx + 0x64], ecx
xor eax, eax
add dword [ebx + 0x68], edx
mov dword [esp + 4], eax
mov dword [esp], ebx
call fcn.0057c9e0
mov dword [ebx + 0x38], eax
mov ecx, dword [ebx + 4]
mov edx, dword [ebx + 0x10]
sub dword [ebx + 0x64], ecx
sub dword [ebx + 0x68], edx
test eax, eax
jne 0x57ba4c
test ecx, ecx
jne 0x57b9e0
mov dword [esp + 8], esi
mov dword [esp + 4], edi
mov edi, dword [ebx + 0x4c]
mov dword [esp], edi
call fcn.0057f570
mov dword [ebx + 0x4c], eax
mov eax, esi
mov esi, dword [ebx + 4]
add esp, 0x1c
pop ebx
sub eax, esi
pop esi
pop edi
pop ebp
ret
mov dword [ebx + 0x38], 0xffffffff
jmp 0x57ba4c
Function at 0x57c330
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x1c
mov ebx, dword [ebp + 8]
test ebx, ebx
je 0x57c4c9
cmp byte [ebx + 0x5c], 0x77
je 0x57c358
add esp, 0x1c
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
jmp fcn.0057abf0
mov dword [ebx + 4], 0
mov edx, dword [ebx + 0x10]
xor edi, edi
lea esi, [esi]
lea edi, [edi]
mov eax, 0x4000
mov esi, eax
sub esi, edx
jne 0x57c480
test edi, edi
jne 0x57c4b5
mov ecx, dword [ebx + 0x10]
mov edi, 4
add dword [ebx + 0x68], ecx
mov dword [esp + 4], edi
mov dword [esp], ebx
call fcn.0057c9e0
mov edx, dword [ebx + 0x10]
sub dword [ebx + 0x68], edx
test esi, esi
jne 0x57c3b1
cmp eax, 0xfffffffb
je 0x57c450
mov dword [ebx + 0x38], eax
xor edi, edi
test edx, edx
jne 0x57c470
mov eax, dword [ebx + 0x38]
cmp eax, 1
je 0x57c473
cmp eax, 1
jbe 0x57c370
cmp eax, 1
je 0x57c3dc
test eax, eax
jne 0x57c34a
mov esi, dword [ebx + 0x40]
mov edi, 3
mov dword [ebp - 0x10], esi
mov esi, dword [ebx + 0x4c]
lea esi, [esi]
mov edx, dword [ebp - 0x10]
mov eax, esi
and eax, 0xff
mov dword [esp], eax
shr esi, 8
mov dword [esp + 4], edx
call fcn.0059fd00
dec edi
jns 0x57c3f0
mov edi, dword [ebx + 0x40]
mov esi, dword [ebx + 0x64]
mov dword [ebp - 0x14], edi
mov edi, 3
lea esi, [esi]
mov eax, dword [ebp - 0x14]
mov ecx, esi
and ecx, 0xff
mov dword [esp], ecx
shr esi, 8
mov dword [esp + 4], eax
call fcn.0059fd00
dec edi
jns 0x57c420
add esp, 0x1c
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
jmp fcn.0057abf0
mov dword [ebx + 0x38], 0
xor edi, edi
test edx, edx
je 0x57c3be
jmp 0x57c470
mov eax, dword [ebx + 0x38]
mov edi, 1
jmp 0x57c3ca
mov eax, dword [ebx + 0x40]
mov ecx, 1
mov dword [esp + 8], esi
mov dword [esp + 4], ecx
mov dword [esp + 0xc], eax
mov edx, dword [ebx + 0x48]
mov dword [esp], edx
call sub.msvcrt.dll_fwrite
cmp eax, esi
jne 0x57c4bd
mov dword [ebx + 0x10], 0x4000
mov edx, dword [ebx + 0x48]
mov dword [ebx + 0xc], edx
jmp 0x57c37f
mov eax, dword [ebx + 0x38]
jmp 0x57c3cf
mov dword [ebx + 0x38], 0xffffffff
jmp 0x57c34a
add esp, 0x1c
mov eax, 0xfffffffe
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x57e3f0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, eax
push esi
push ebx
sub esp, 0x1c
mov eax, dword [eax + 0x2c]
mov edx, dword [edi + 0x74]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x1c], edx
jmp 0x57e4c9
mov ebx, dword [edi]
mov edx, dword [ebx + 4]
mov dword [ebp - 0x18], ebx
test edx, edx
je 0x57e580
mov eax, dword [edi + 0x38]
mov ebx, edx
add esi, eax
mov eax, dword [edi + 0x74]
add esi, eax
cmp edx, dword [ebp - 0x10]
jbe 0x57e434
mov ebx, dword [ebp - 0x10]
xor ecx, ecx
test ebx, ebx
je 0x57e47e
mov eax, dword [ebp - 0x18]
sub edx, ebx
mov ecx, dword [eax + 0x1c]
mov dword [eax + 4], edx
mov edx, eax
mov eax, dword [ecx + 0x18]
cmp eax, 1
je 0x57e588
cmp eax, 2
je 0x57e5a8
mov edx, dword [ebp - 0x18]
mov eax, dword [edx]
mov dword [esp], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
call sub.msvcrt.dll_memcpy
mov esi, dword [ebp - 0x18]
mov ecx, ebx
mov eax, dword [edi + 0x74]
add dword [esi], ebx
add dword [esi + 8], ebx
lea esi, [eax + ecx]
cmp esi, 2
mov dword [ebp - 0x1c], esi
mov dword [edi + 0x74], esi
jbe 0x57e4ad
mov ebx, dword [edi + 0x38]
mov edx, dword [edi + 0x6c]
mov ecx, dword [edi + 0x58]
movzx eax, byte [ebx + edx]
mov dword [edi + 0x48], eax
shl eax, cl
movzx ecx, byte [ebx + edx + 1]
mov ebx, dword [edi + 0x54]
xor eax, ecx
and eax, ebx
mov dword [edi + 0x48], eax
cmp esi, 0x105
ja 0x57e580
mov eax, dword [edi]
mov esi, dword [eax + 4]
test esi, esi
je 0x57e580
mov eax, dword [edi + 0x2c]
mov ecx, dword [edi + 0x3c]
mov ebx, dword [ebp - 0x1c]
mov esi, dword [edi + 0x6c]
sub ecx, ebx
sub ecx, esi
mov dword [ebp - 0x10], ecx
mov ecx, dword [ebp - 0x14]
lea eax, [eax + ecx - 0x106]
cmp esi, eax
jb 0x57e410
mov dword [esp + 8], ecx
mov esi, dword [edi + 0x38]
lea ebx, [esi + ecx]
mov dword [esp], esi
mov dword [esp + 4], ebx
call sub.msvcrt.dll_memcpy
mov eax, dword [ebp - 0x14]
mov esi, dword [edi + 0x6c]
mov ecx, dword [edi + 0x4c]
sub dword [edi + 0x70], eax
mov edx, dword [edi + 0x44]
sub esi, eax
sub dword [edi + 0x5c], eax
mov dword [edi + 0x6c], esi
lea eax, [edx + ecx*2]
nop
lea esi, [esi]
sub eax, 2
xor ebx, ebx
movzx edx, word [eax]
cmp edx, dword [ebp - 0x14]
jb 0x57e534
mov ebx, edx
mov edx, dword [ebp - 0x14]
sub ebx, edx
mov word [eax], bx
dec ecx
jne 0x57e520
mov ecx, dword [ebp - 0x14]
mov eax, dword [edi + 0x40]
lea eax, [eax + ecx*2]
lea esi, [esi]
lea edi, [edi]
sub eax, 2
xor ebx, ebx
movzx edx, word [eax]
cmp edx, dword [ebp - 0x14]
jb 0x57e564
mov ebx, edx
mov edx, dword [ebp - 0x14]
sub ebx, edx
mov word [eax], bx
dec ecx
jne 0x57e550
mov ebx, dword [edi]
mov ecx, dword [ebp - 0x14]
add dword [ebp - 0x10], ecx
mov edx, dword [ebx + 4]
mov dword [ebp - 0x18], ebx
test edx, edx
jne 0x57e420
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 8], ebx
mov eax, dword [edx]
mov dword [esp + 4], eax
mov ecx, dword [edx + 0x30]
mov dword [esp], ecx
call fcn.00584530
mov ecx, dword [ebp - 0x18]
mov dword [ecx + 0x30], eax
jmp 0x57e45c
mov dword [esp + 8], ebx
mov edx, dword [ebp - 0x18]
mov eax, dword [edx]
mov dword [esp + 4], eax
mov ecx, dword [edx + 0x30]
mov dword [esp], ecx
call fcn.0057f570
jmp 0x57e59d
Function at 0x58c7cc
Capabilities:
Resolve function by parsing pe exports

Disassembly:
test ecx, ecx
je 0x58c7e4
cmp dword [eax + 0x118], 0
jne 0x58c7e0
jmp fcn.00586944
ret
mov dword [eax + 0x118], 1
ret

Function at 0x58cdd4
Capabilities:
Resolve function by parsing pe exports

Disassembly:
cmp dword [ecx], 0x2d
je 0x58cdf0
cmp dword [eax + 0x118], 0
jne 0x58cdef
jmp fcn.00586944
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
mov edx, dword [ecx + 4]
mov edi, dword [edx + 8]
mov ebp, dword [edx + 4]
test edi, edi
je 0x58cde8
mov edx, dword [eax + 0x100]
xor ebx, ebx
jmp 0x58ce27
mov esi, edx
inc edx
mov byte [eax + esi], cl
mov dword [eax + 0x100], edx
mov byte [eax + 0x104], cl
inc ebx
cmp edi, ebx
je 0x58cde8
mov cl, byte [ebp + ebx]
cmp edx, 0xff
jne 0x58ce10
mov byte [eax + 0xff], 0
mov edx, dword [eax + 0x10c]
mov dword [esp + 8], edx
mov dword [esp + 4], 0xff
mov dword [esp], eax
mov dword [esp + 0x18], eax
mov byte [esp + 0x1c], cl
call dword [eax + 0x108]
mov eax, dword [esp + 0x18]
inc dword [eax + 0x120]
mov edx, 1
xor esi, esi
mov cl, byte [esp + 0x1c]
jmp 0x58ce13
Function at 0x591590
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x28
mov ebx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [esp + 0x34]
mov dword [esp + 8], 0x17
mov dword [esp + 4], 1
add ebx, 0x40
mov dword [esp + 0xc], ebx
mov dword [esp], str.Mingw_runtime_failure:_n
mov dword [esp + 0x1c], eax
call sub.msvcrt.dll_fwrite
mov eax, dword [esp + 0x1c]
mov dword [esp], ebx
mov dword [esp + 8], eax
mov eax, dword [esp + 0x30]
mov dword [esp + 4], eax
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
lea esi, [esi]
lea edi, [edi]

Function at 0x5915f0
Capabilities:
Allocate or change rwx memory

Disassembly:
sub esp, 0x5c
mov dword [esp + 0x4c], ebx
mov ebx, eax
lea eax, [esp + 0x24]
mov dword [esp + 8], 0x1c
mov dword [esp + 4], eax
mov dword [esp], ebx
mov dword [esp + 0x50], esi
mov esi, edx
mov dword [esp + 0x54], edi
mov edi, ecx
mov dword [esp + 0x58], ebp
call sub.KERNEL32.dll_VirtualQuery
sub esp, 0xc
test eax, eax
je 0x5916e6
mov eax, dword [esp + 0x38]
cmp eax, 4
jne 0x591660
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], ebx
call sub.msvcrt.dll_memcpy
mov ebx, dword [esp + 0x4c]
mov esi, dword [esp + 0x50]
mov edi, dword [esp + 0x54]
mov ebp, dword [esp + 0x58]
add esp, 0x5c
ret
cmp eax, 0x40
je 0x591635
mov eax, dword [esp + 0x30]
lea ebp, [esp + 0x20]
mov dword [esp + 0xc], ebp
mov dword [esp + 8], 0x40
mov dword [esp + 4], eax
mov eax, dword [esp + 0x24]
mov dword [esp], eax
call sub.KERNEL32.dll_VirtualProtect
sub esp, 0x10
mov eax, dword [esp + 0x38]
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], ebx
cmp eax, 0x40
setne byte [esp + 0x1e]
cmp eax, 4
setne byte [esp + 0x1f]
call sub.msvcrt.dll_memcpy
cmp byte [esp + 0x1f], 0
je 0x591645
cmp byte [esp + 0x1e], 0
je 0x591645
mov eax, dword [esp + 0x20]
mov dword [esp + 0xc], ebp
mov dword [esp + 8], eax
mov eax, dword [esp + 0x30]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x24]
mov dword [esp], eax
call sub.KERNEL32.dll_VirtualProtect
sub esp, 0x10
jmp 0x591645
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x1c
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
call fcn.00591590
nop

Function at 0x591980
Capabilities:
Get thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
mov dword [esp], 0x6dc2a4
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [0x6dc2bc]
sub esp, 4
test ebx, ebx
je 0x5919cb
nop
mov eax, dword [ebx]
mov dword [esp], eax
call sub.KERNEL32.dll_TlsGetValue
sub esp, 4
mov esi, eax
call sub.KERNEL32.dll_GetLastError
test eax, eax
jne 0x5919c4
test esi, esi
je 0x5919c4
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x5919a0
mov dword [esp], 0x6dc2a4
call sub.KERNEL32.dll_LeaveCriticalSection
sub esp, 4
add esp, 0x14
pop ebx
pop esi
ret
Function at 0x594610
Capabilities:
Allocate thread local storage

Disassembly:
sub esp, 0x1c
mov dword [0x6dc2d8], 0xffffffff
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0xffff
mov dword [esp + 4], 0
mov dword [esp], 0
call sub.KERNEL32.dll_CreateSemaphoreA
sub esp, 0x10
mov dword [0x6dc2dc], eax
call sub.KERNEL32.dll_TlsAlloc
cmp eax, 0xffffffff
je 0x594670
mov dword [0x6dc2e4], eax
mov dword [esp + 4], 0x5945d4
mov dword [esp], eax
call fcn.005a02c0
test eax, eax
jne 0x594677
add esp, 0x1c
ret
call sub.KERNEL32.dll_GetLastError
jmp 0x594668
call sub.msvcrt.dll_abort
Function at 0x597490
Capabilities:
Check if file exists
Get file attributes

Disassembly:
sub esp, 0x13c
mov dword [esp + 0x12c], ebx
mov ebx, dword [esp + 0x140]
mov dword [esp + 0x130], esi
mov dword [esp + 0x134], edi
mov dword [esp + 0x138], ebp
call sub.msvcrt.dll__errno
test ebx, ebx
mov dword [eax], 0
je 0x59768c
cmp byte [ebx], 0
je 0x597660
mov dword [esp], ebx
call sub.KERNEL32.dll_GetFileAttributesA
sub esp, 4
cmp eax, 0xffffffff
je 0x597670
test al, 0x10
je 0x597660
lea ebp, [esp + 0x1c]
mov dword [esp + 4], ebx
mov ebx, ebp
mov dword [esp + 8], 0x104
mov dword [esp], ebp
call sub.msvcrt.dll__fullpath
mov edx, dword [ebx]
add ebx, 4
lea eax, [edx - 0x1010101]
not edx
and eax, edx
and eax, 0x80808080
je 0x59750b
test eax, 0x8080
je 0x597642
add al, al
sbb ebx, 3
sub ebx, ebp
lea eax, [ebx + 0x233]
mov dword [esp], eax
call sub.msvcrt.dll_malloc
test eax, eax
mov esi, eax
je 0x59767f
lea edi, [eax + 0x22c]
lea eax, [ebx + 1]
mov dword [esp + 8], eax
mov dword [esp + 4], ebp
mov dword [esp], edi
call sub.msvcrt.dll_memcpy
cmp byte [esi + 0x22c], 0
je 0x5975a6
mov dword [esp + 4], 0x2f
lea ebp, [esi + ebx + 0x22b]
mov dword [esp], edi
call sub.msvcrt.dll_strrchr
cmp eax, ebp
je 0x5975a6
mov dword [esp + 4], 0x5c
mov dword [esp], edi
call sub.msvcrt.dll_strrchr
cmp ebp, eax
je 0x5975a6
mov word [esi + ebx + 0x22c], 0x5c
mov eax, edi
mov ecx, dword [eax]
add eax, 4
lea edx, [ecx - 0x1010101]
not ecx
and edx, ecx
and edx, 0x80808080
je 0x5975a8
test edx, 0x8080
je 0x597650
add dl, dl
mov ecx, 0x41
sbb eax, 3
sub eax, edi
lea edx, [esi + 0x120]
mov word [esi + eax + 0x22c], 0x2a
mov edi, edx
xor eax, eax
rep stosd dword es:[edi], eax
mov dword [esi + 0x224], 0xffffffff
mov dword [esi + 0x228], 0
mov dword [esi + 0x118], 0
mov word [esi + 0x11c], 0
mov word [esi + 0x11e], 0
mov eax, esi
mov ebx, dword [esp + 0x12c]
mov esi, dword [esp + 0x130]
mov edi, dword [esp + 0x134]
mov ebp, dword [esp + 0x138]
add esp, 0x13c
ret
shr eax, 0x10
add ebx, 2
jmp 0x59752c
shr edx, 0x10
add eax, 2
jmp 0x5975cb
call sub.msvcrt.dll__errno
xor esi, esi
mov dword [eax], 0x14
jmp 0x59761d
call sub.msvcrt.dll__errno
xor esi, esi
mov dword [eax], 2
jmp 0x59761d
call sub.msvcrt.dll__errno
mov dword [eax], 0xc
jmp 0x59761d
call sub.msvcrt.dll__errno
xor esi, esi
mov dword [eax], 0xe
jmp 0x59761d
Function at 0x5cd1b8
Capabilities:
Read file on windows

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov ebp, ecx
mov edi, dword [esp + 0x30]
mov esi, dword [esp + 0x34]
mov dword [esp + 8], esi
mov dword [esp + 4], edi
mov eax, dword [ebp]
mov eax, dword [eax + 0x10]
mov dword [esp], eax
call sub.msvcrt.dll__read
mov ebx, eax
cmp eax, 0xffffffff
je 0x5cd1f4
mov eax, ebx
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret 8
call sub.msvcrt.dll__errno
cmp dword [eax], 4
je 0x5cd1c9
mov eax, ebx
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret 8

Function at 0x5ee350
Capabilities:
Accept command line arguments

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push esi
push ebx
push ecx
sub esp, 0x6c
call fcn.00591960
call sub.KERNEL32.dll_GetCommandLineA
mov ebx, eax
lea eax, [ebp - 0x5c]
mov dword [esp], eax
call sub.KERNEL32.dll_GetStartupInfoA
sub esp, 4
test ebx, ebx
jne 0x5ee386
jmp 0x5ee3c5
add ebx, 1
movzx eax, byte [ebx]
cmp al, 9
je 0x5ee383
cmp al, 0x20
je 0x5ee383
cmp al, 0x22
jne 0x5ee3a9
jmp 0x5ee414
cmp al, 0x20
lea esi, [esi]
je 0x5ee3b0
test al, al
je 0x5ee3c5
add ebx, 1
movzx eax, byte [ebx]
cmp al, 9
jne 0x5ee397
movzx eax, byte [ebx]
cmp al, 0x20
jne 0x5ee42a
add ebx, 1
movzx eax, byte [ebx]
cmp al, 9
je 0x5ee3b7
cmp al, 0x20
je 0x5ee3b7
test byte [ebp - 0x30], 1
mov esi, 0xa
je 0x5ee3d4
movzx esi, word [ebp - 0x2c]
mov dword [esp], 0
call sub.KERNEL32.dll_GetModuleHandleA
sub esp, 4
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], 0
mov dword [esp], eax
call fcn.0040153b
sub esp, 0x10
lea esp, [ebp - 0xc]
pop ecx
pop ebx
pop esi
pop ebp
lea esp, [ecx - 4]
ret
cmp al, 0x22
je 0x5ee41e
add ebx, 1
movzx eax, byte [ebx]
test al, al
jne 0x5ee410
cmp al, 0x22
sete al
movzx eax, al
add ebx, eax
jmp 0x5ee3b0
cmp al, 9
je 0x5ee3b7
jmp 0x5ee3c5
Function at 0x401449
Capabilities:
Terminate process

Disassembly:
push esi
xor esi, esi
cmp dword [esp + 8], esi
jle 0x401478
mov eax, dword [esi*4 + 0x44db40]
test eax, eax
je 0x401471
push eax
call fcn.004023e4
push dword [esi*4 + 0x44cba0]
call fcn.004023e4
pop ecx
pop ecx
inc esi
cmp esi, dword [esp + 8]
jl 0x401452
push 0
call fcn.004022f1
pop esi
Function at 0x405f8d
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x426080
cmp edx, dword [eax]
je 0x405faf
add eax, 8
inc ecx
cmp eax, 0x426110
jl 0x405fa0
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x426080]
jne 0x4060dd
mov eax, dword [0x445714]
cmp eax, 1
je 0x4060b7
test eax, eax
jne 0x405fe0
cmp dword [0x425b74], 1
je 0x4060b7
cmp edx, 0xfc
je 0x4060dd
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x406017
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00402c20
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00402af0
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x40605a
lea eax, [ebp - 0x1a4]
push eax
call fcn.00402af0
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x423504
push edi
call fcn.00407120
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00402c20
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00402c30
lea eax, [ebp - 0xa0]
push 0x4234e4
push eax
call fcn.00402c30
push dword [esi + 0x426084]
lea eax, [ebp - 0xa0]
push eax
call fcn.00402c30
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00408e1d
add esp, 0x2c
pop edi
jmp 0x4060dd
lea eax, [ebp + 8]
lea esi, [esi + 0x426084]
push 0
push eax
push dword [esi]
call fcn.00402af0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret