joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401460
Capabilities:
Get common file path

Disassembly:
mov edx, dword [0x41281c]
sub esp, 0x104
test edx, edx
push ebx
push esi
push edi
jne 0x401539
push 0x104
push 2
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
test eax, eax
mov dword [0x41281c], eax
jne 0x4014a1
pop edi
pop esi
or eax, 0xffffffff
pop ebx
add esp, 0x104
ret
lea eax, [esp + 0xc]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
mov ecx, dword [0x41281c]
lea edx, [esp + 0xc]
push ecx
push 0
push 0x40f0d0
push edx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
mov eax, dword [0x41281c]
push eax
call fcn.004053f4
mov edx, dword [0x41281c]
add esp, 4
cmp byte [edx], 0
je 0x401539
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp byte [ecx + edx - 1], 0x5c
je 0x401539
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp byte [ecx + edx - 1], 0x3a
je 0x401539
mov edi, 0x40f038
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [0x41281c]
lea esi, [esp + 0xc]
mov eax, edx
sub esi, edx
mov cl, byte [eax]
mov byte [esi + eax], cl
inc eax
test cl, cl
jne 0x401541
lea edi, [esp + 0xc]
or ecx, 0xffffffff
xor eax, eax
mov esi, dword [esp + 0x114]
repne scasb al, byte es:[edi]
mov al, byte [esi]
not ecx
dec ecx
test al, al
mov edi, ecx
je 0x4015c8
lea ebx, [esp + 0xc]
dec ebx
mov cl, byte [ebx + edi]
lea edx, [esp + 0xc]
mov byte [esp + 0x10f], cl
push edx
mov byte [ebx + edi], 0
call fcn.004053ff
mov al, byte [esp + 0x113]
add esp, 4
mov byte [ebx + edi], al
cmp edi, 0x102
jae 0x401494
cmp byte [esi], 0x2f
jne 0x4015a6
mov byte [esi], 0x5c
movzx cx, byte [esi]
mov al, byte [esi + 1]
mov word [esp + edi + 0xc], cx
inc edi
inc esi
test al, al
je 0x4015c8
mov al, byte [esi - 1]
cmp al, 0x5c
je 0x4015c3
cmp al, 0x2f
jne 0x401592
cmp byte [esi], 0
jne 0x40156d
lea edx, [esp + 0xc]
push edx
call section..text
add esp, 4
pop edi
pop esi
pop ebx
add esp, 0x104
ret
Function at 0x407cfd
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x40f948
cmp edx, dword [eax]
je 0x407d1f
add eax, 8
inc ecx
cmp eax, 0x40f9d8
jl 0x407d10
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x40f948]
jne 0x407e4d
mov eax, dword [0x4124ac]
cmp eax, 1
je 0x407e27
test eax, eax
jne 0x407d50
cmp dword [0x40f474], 1
je 0x407e27
cmp edx, 0xfc
je 0x407e4d
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x407d87
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00409670
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00409aa0
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x407dca
lea eax, [ebp - 0x1a4]
push eax
call fcn.00409aa0
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x40d59c
push edi
call fcn.0040acc0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00409670
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00409680
lea eax, [ebp - 0xa0]
push 0x40d57c
push eax
call fcn.00409680
push dword [esi + 0x40f94c]
lea eax, [ebp - 0xa0]
push eax
call fcn.00409680
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.0040ac2f
add esp, 0x2c
pop edi
jmp 0x407e4d
lea eax, [ebp + 8]
lea esi, [esi + 0x40f94c]
push 0
push eax
push dword [esi]
call fcn.00409aa0
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
Function at 0x401150
Capabilities:
Terminate thread

Disassembly:
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov dword [0x41236c], eax
mov eax, dword [0x4123b4]
test eax, eax
mov dword [0x412364], 3
mov dword [0x412378], 0x3e8
mov dword [0x412370], ecx
je 0x401189
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
call fcn.004012e0
call fcn.00401210
call fcn.004012e0
push 0
push 0
push 1
push 4
mov dword [0x412364], 1
call fcn.004011c0
add esp, 0x10
jmp fcn.004012e0

Function at 0x4011c0
Capabilities:
Access the windows event log

Disassembly:
push esi
mov ecx, 0x4123c8
call fcn.00403010
push eax
push 0
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceA]
mov esi, eax
test esi, esi
je 0x401204
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
push 0
push eax
mov eax, dword [esp + 0x10]
push 0
push ecx
push 0
push edx
push 0
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_ReportEventA]
push esi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
pop esi
ret

Function at 0x401210
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40bb30
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xa8
mov eax, dword [0x4123b8]
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
push 0
push eax
mov dword [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
jne 0x4012a3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.subprocess_being_unable_to_be_killed
lea ecx, [ebp - 0xb4]
call fcn.004033f0
mov ecx, 0x14
mov esi, eax
lea edi, [ebp - 0x64]
push 0x40cbb0
rep movsd dword es:[edi], dword [esi]
lea ecx, [ebp - 0x64]
push ecx
call fcn.00404ff7
mov esi, dword [ebp - 0x14]
mov ecx, esi
call fcn.00403570
push eax
mov ecx, esi
call fcn.00403560
push eax
push 0x64
push 1
call fcn.004011c0
add esp, 0x10
mov eax, 0x4012a3
ret
mov eax, dword [0x4123bc]
test eax, eax
je 0x4012b3
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x4123b8]
test eax, eax
je 0x4012c3
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x401920
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40bb80
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x15c
push ebx
push esi
push edi
mov ecx, 0x11
xor eax, eax
lea edi, [ebp - 0x78]
rep stosd dword es:[edi], eax
mov edi, dword [ebp + 8]
mov eax, 1
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x24], eax
mov dword [0x4123b8], 0xffffffff
mov eax, dword [edi + 0x30]
xor esi, esi
mov ecx, 0xc
cmp eax, 3
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x78], 0x44
mov dword [ebp - 0x74], esi
mov dword [ebp - 0x6c], esi
mov dword [ebp - 0x70], esi
mov dword [ebp - 0x68], esi
mov dword [ebp - 0x64], esi
mov dword [ebp - 0x60], esi
mov dword [ebp - 0x5c], esi
mov word [ebp - 0x48], si
mov dword [ebp - 0x44], esi
mov word [ebp - 0x46], si
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x28], esi
ja case.0x4019ad.0
jmp dword [eax*4 + 0x401aec]
mov ebx, 0x40
jmp 0x4019ce
mov ebx, 0x80
jmp 0x4019ce
mov ebx, 0x100
jmp 0x4019ce
mov ebx, 0x20
lea eax, [ebp - 0x78]
push 0x4123b8
push eax
lea ecx, [edi + 0x10]
call fcn.00403010
push eax
push esi
push ebx
lea ecx, [ebp - 0x2c]
push 1
lea edx, [ebp - 0x20]
push ecx
push edx
mov ecx, edi
call fcn.00403010
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov ebx, eax
cmp ebx, esi
mov dword [ebp - 0x14], ebx
je 0x401ad8
cmp dword [edi + 0x2c], esi
je 0x401ad8
mov edx, dword [0x4123b8]
lea eax, [ebp + 8]
lea ecx, [ebp - 0x34]
push eax
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_GetProcessAffinityMask]
test eax, eax
je 0x401ad8
mov eax, dword [edi + 0x2c]
mov ecx, dword [ebp + 8]
cmp eax, ecx
mov dword [ebp - 4], esi
jbe 0x401a68
push esi
push eax
lea ecx, [ebp - 0x168]
call fcn.00403440
mov esi, eax
mov ecx, 0x14
lea edi, [ebp - 0x118]
lea eax, [ebp - 0x118]
push 0x40cbb0
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.00404ff7
mov ecx, dword [0x4123b8]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetProcessAffinityMask]
test eax, eax
jne 0x401ad8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [edi + 0x2c]
push eax
push edx
lea ecx, [ebp - 0x168]
call fcn.00403440
mov esi, eax
mov ecx, 0x14
lea edi, [ebp - 0xc8]
lea eax, [ebp - 0xc8]
push 0x40cbb0
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.00404ff7
mov esi, dword [ebp - 0x30]
mov ecx, esi
call fcn.00403570
push eax
mov ecx, esi
call fcn.00403560
push eax
push 0x33
push 2
call fcn.004011c0
add esp, 0x10
mov eax, 0x401ad5
ret
mov ecx, dword [ebp - 0xc]
pop edi
mov eax, ebx
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403330
Capabilities:
Read file on windows

Disassembly:
push edi
push ebx
sub esp, 0x14
mov ebx, ecx
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
mov ecx, dword [ebx + 0x254]
cmp ecx, 1
jne 0x403369
lea ecx, [esp]
push 0
push ecx
push edx
push eax
push dword [ebx + 0x258]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp]
add esp, 0x14
pop ebx
pop edi
ret 8
cmp ecx, 2
je 0x40337b
mov eax, 0xffffffff
add esp, 0x14
pop ebx
pop edi
ret 8
cmp eax, dword [ebx + 0x18]
je 0x403414
mov edi, edx
test edx, edx
je 0x403400
mov dword [esp + 4], esi
mov dword [esp + 8], ebp
mov ebp, ebx
mov ebx, eax
mov esi, dword [ebp + 0x1c]
cmp esi, edi
cmovae esi, edi
test esi, esi
jne 0x4033b4
mov esi, dword [esp + 4]
xor eax, eax
mov ebp, dword [esp + 8]
add esp, 0x14
pop ebx
pop edi
ret 8
mov edx, dword [ebp + 0x14]
mov dword [esp], edx
mov dword [edx], 1
mov dword [edx + 4], esi
push dword [ebp]
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0xffffffffffffffff
push dword [ebp + 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [esp]
mov eax, dword [edx + 8]
test eax, eax
jle 0x40340a
push esi
push dword [ebp + 0x18]
push ebx
call fcn.00407a30
add esp, 0xc
add ebx, esi
sub edi, esi
jne 0x403396
mov edx, dword [esp + 0x24]
mov esi, dword [esp + 4]
mov ebp, dword [esp + 8]
mov eax, edx
add esp, 0x14
pop ebx
pop edi
ret 8
mov esi, dword [esp + 4]
mov ebp, dword [esp + 8]
jmp 0x4033ac
mov edi, dword [ebx + 0x14]
mov dword [edi], 1
mov dword [edi + 4], edx
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0xffffffffffffffff
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [edi + 8]
add esp, 0x14
pop ebx
pop edi
ret 8
Function at 0x403500
Capabilities:
Get memory capacity

Disassembly:
push esi
push edi
push ebx
push ebp
sub esp, 0xcc
mov ebp, edx
mov esi, eax
cmp dword [ebp], 0
je 0x403523
xor eax, eax
xor edx, edx
add esp, 0xcc
pop ebp
pop ebx
pop edi
pop esi
ret
mov eax, esi
mov edx, ebp
mov ecx, 0x6d
call fcn.00403440
cmp dword [ebp], 0
je 0x4036a1
movsx ecx, byte [esi]
xor ebx, ebx
lea edi, [ecx - 0x30]
cmp edi, 9
ja 0x40355b
inc esi
lea ebx, [ebx + ebx*4]
lea ebx, [ecx + ebx*2 - 0x30]
movsx ecx, byte [esi]
lea edi, [ecx - 0x30]
cmp edi, 9
jbe 0x403548
cmp ecx, 0x25
je 0x403569
cmp ecx, 0x70
jne 0x40368b
movsx ecx, byte [esi + 1]
test ecx, ecx
jne 0x403686
mov dword [ebp], 0
xor edi, edi
mov dword [esp + 0x4c], 0x40
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push 0x422cc9
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x4035b6
lea edx, [esp + 0x4c]
push edx
call eax
test eax, eax
je 0x4035b6
mov esi, dword [esp + 0x5c]
mov ebp, dword [esp + 0x60]
jmp 0x4035cf
mov dword [esp + 0xc], 0x20
lea edx, [esp + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatus]
mov esi, dword [esp + 0x18]
xor ebp, ebp
mov dword [esp + 0x8c], 0x40
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push 0x422cc9
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x403613
lea edx, [esp + 0x8c]
push edx
call eax
test eax, eax
je 0x403613
mov ecx, dword [esp + 0xbc]
mov edx, dword [esp + 0xc0]
jmp 0x40362c
mov dword [esp + 0x2c], 0x20
lea edx, [esp + 0x2c]
push edx
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatus]
mov ecx, dword [esp + 0x48]
xor edx, edx
mov eax, ecx
sub eax, esi
mov eax, edx
sbb eax, ebp
jae 0x40363a
mov ebp, edx
jmp 0x40363c
mov ecx, esi
xor edx, edx
push edx
push 0x64
push ebp
push ecx
call fcn.0040ac60
push edx
push eax
mov eax, ebx
cdq
push edx
push ebx
call fcn.0040ac20
mov ebp, eax
mov ebx, edx
xor ecx, ecx
sub ebp, edi
sbb ebx, ecx
jb 0x403664
or ebp, ebx
jne 0x403676
mov eax, 0x2000000
xor edx, edx
add esp, 0xcc
pop ebp
pop ebx
pop edi
pop esi
ret
sub eax, edi
sbb edx, 0
add esp, 0xcc
pop ebp
pop ebx
pop edi
pop esi
ret
cmp ecx, 0x2d
je 0x4036ae
xor eax, eax
mov dword [ebp], 1
xor edx, edx
add esp, 0xcc
pop ebp
pop ebx
pop edi
pop esi
ret
xor edx, edx
add esp, 0xcc
pop ebp
pop ebx
pop edi
pop esi
ret
add esi, 2
mov edx, ebp
mov eax, esi
mov ecx, 0x6d
mov dword [ebp], 0
call fcn.00403440
mov edi, eax
jmp 0x40357e
Function at 0x405a80
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x1c
mov edx, dword [ecx + 0x254]
mov eax, dword [esp + 0x20]
cmp edx, 1
jne 0x405ab2
lea edx, [esp]
push 0
push edx
push dword [esp + 0x2c]
push eax
push dword [ecx + 0x25c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp]
add esp, 0x1c
ret 8
cmp edx, 2
je 0x405ac2
mov eax, 0xffffffff
add esp, 0x1c
ret 8
mov edx, dword [esp + 0x24]
test edx, edx
je 0x405b3d
mov dword [esp + 0x10], ecx
mov dword [esp], esi
mov dword [esp + 4], edi
mov dword [esp + 8], ebx
mov ebx, edx
mov dword [esp + 0xc], ebp
mov ebp, eax
mov ecx, dword [esp + 0x10]
mov esi, dword [ecx + 0x24]
cmp esi, ebx
mov edi, dword [ecx + 0x14]
cmovae esi, ebx
push esi
push ebp
push dword [ecx + 0x20]
call fcn.00407a30
add esp, 0xc
mov ecx, dword [esp + 0x10]
mov dword [edi], 2
mov dword [edi + 4], esi
push dword [ecx]
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0xffffffffffffffff
mov ecx, dword [esp + 0x14]
push dword [ecx + 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [edi + 8]
test eax, eax
jle 0x405b47
add ebp, esi
sub ebx, esi
jne 0x405ae1
mov esi, dword [esp]
mov edi, dword [esp + 4]
mov ebx, dword [esp + 8]
mov ebp, dword [esp + 0xc]
mov eax, dword [esp + 0x24]
add esp, 0x1c
ret 8
mov esi, dword [esp]
mov edi, dword [esp + 4]
mov ebx, dword [esp + 8]
mov ebp, dword [esp + 0xc]
add esp, 0x1c
ret 8

Function at 0x4062f0
Capabilities:
Read .ini file

Disassembly:
push ebp
sub esp, 0x18
mov ebp, ecx
mov ecx, dword [ebp + 0x134]
cmp ecx, 1
jle 0x406331
mov edx, dword [ebp + 0x138]
mov eax, 1
mov dword [esp + 4], esi
mov dword [esp + 8], edi
mov dword [esp + 0xc], ebx
mov edi, dword [edx + eax*4]
cmp byte [edi], 0x2d
je 0x40635b
inc eax
cmp eax, ecx
jl 0x406318
mov esi, dword [esp + 4]
mov edi, dword [esp + 8]
mov ebx, dword [esp + 0xc]
lea eax, [ebp + 0x150]
add ebp, 0x140
push eax
push 0x104
push dword [esp + 0x2c]
push 0
push dword [esp + 0x30]
push ebp
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
add esp, 0x18
pop ebp
ret 8
mov dword [esp], ebp
xor esi, esi
mov ebp, dword [esp + 0x20]
movsx ebx, byte [esi + ebp]
inc esi
test ebx, ebx
je 0x406377
cmp bl, byte [esi + edi]
je 0x406364
mov ebp, dword [esp]
jmp 0x406320
mov eax, esi
mov edx, edi
mov esi, dword [esp + 4]
mov edi, dword [esp + 8]
mov ebx, dword [esp + 0xc]
cmp byte [eax + edx], 0x3d
jne 0x406394
inc eax
cmp byte [eax + edx], 0x3d
je 0x40638d
add eax, edx
xor ecx, ecx
movsx edx, byte [eax]
test edx, edx
je 0x4063af
mov ebp, dword [esp + 0x24]
mov byte [ecx + ebp], dl
inc ecx
movsx edx, byte [ecx + eax]
test edx, edx
jne 0x4063a3
mov edx, dword [esp + 0x24]
mov eax, ecx
mov byte [ecx + edx], 0
add esp, 0x18
pop ebp
ret 8
Function at 0x406c80
Capabilities:
Read file via mapping
Terminate process

Disassembly:
sub esp, 0x18
mov ebx, dword [esp + 0x1c]
push 2
call fcn.0040e29d
push str._n__ERROR_
push eax
call fcn.00406760
push 2
call fcn.0040e29d
mov ebp, eax
add esp, 0x10
call fcn.00403770
mov edx, dword [esp + 0x20]
lea ecx, [esp + 0x24]
movq xmm0, qword [eax]
movq qword [esp], xmm0
mov dword [esp + 8], ebp
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], ecx
call fcn.00411292
push 2
call fcn.0040e29d
push 0x423070
push eax
call fcn.00406760
add esp, 0xc
push ebx
call fcn.0040f76e
nop
Function at 0x407be0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
endbr32
push esi
push edi
push esi
mov esi, eax
mov ecx, edx
and esi, 0xfff
and ecx, 0xfff
neg esi
neg ecx
add esi, 0x1000
add ecx, 0x1000
movdqu xmm3, xmmword [0x424700]
movdqu xmm2, xmmword [0x424710]
cmp esi, 0x10
jl 0x407cb8
cmp ecx, 0x10
jl 0x407cb8
mov dword [esp], ebx
movdqu xmm1, xmmword [eax]
movdqu xmm0, xmmword [edx]
movdqu xmm4, xmmword [0x424720]
movdqa xmm5, xmm1
movdqu xmm6, xmmword [0x424720]
movdqa xmm7, xmm0
pcmpgtb xmm5, xmm2
pcmpgtb xmm4, xmm1
pcmpgtb xmm7, xmm2
pcmpgtb xmm6, xmm0
pand xmm5, xmm4
pand xmm7, xmm6
pand xmm5, xmm3
pand xmm7, xmm3
paddb xmm1, xmm5
paddb xmm0, xmm7
pxor xmm4, xmm4
pcmpeqb xmm4, xmm1
pcmpeqb xmm1, xmm0
pmovmskb edi, xmm1
xor edi, 0xffff
jne 0x407d18
pmovmskb ebx, xmm4
test ebx, ebx
jne 0x407d5f
add esi, 0xfffffff0
add eax, 0x10
add edx, 0x10
add ecx, 0xfffffff0
cmp esi, 0x10
jl 0x407cbb
cmp ecx, 0x10
jge 0x407c2c
jmp 0x407cbb
mov dword [esp], ebx
movzx ebx, byte [eax]
lea ecx, [ebx - 0x41]
cmp ecx, 0x19
lea esi, [ebx + 0x20]
jbe 0x407ccb
mov esi, ebx
movzx ebx, byte [edx]
lea edi, [ebx - 0x41]
cmp edi, 0x19
lea ecx, [ebx + 0x20]
jbe 0x407cdb
mov ecx, ebx
cmp esi, ecx
jne 0x407d6a
test esi, esi
je 0x407d5f
inc eax
inc edx
mov esi, eax
mov ecx, edx
and esi, 0xfff
and ecx, 0xfff
neg esi
neg ecx
add esi, 0x1000
add ecx, 0x1000
cmp esi, 0x10
jl 0x407cbb
cmp ecx, 0x10
jl 0x407cbb
jmp 0x407c2c
pmovmskb esi, xmm4
bsf ecx, edi
mov ebx, dword [esp]
test esi, esi
je 0x407d35
bsf esi, esi
cmp esi, ecx
jae 0x407d35
xor eax, eax
add esp, 4
pop edi
pop esi
ret
movzx edi, byte [ecx + eax]
movzx ecx, byte [ecx + edx]
lea esi, [edi - 0x41]
cmp esi, 0x19
lea eax, [edi + 0x20]
lea edx, [ecx - 0x41]
jbe 0x407d4d
mov eax, edi
cmp edx, 0x19
lea esi, [ecx + 0x20]
jbe 0x407d57
mov esi, ecx
sub eax, esi
add esp, 4
pop edi
pop esi
ret
mov ebx, dword [esp]
xor eax, eax
add esp, 4
pop edi
pop esi
ret
sub esi, ecx
mov ebx, dword [esp]
mov eax, esi
add esp, 4
pop edi
pop esi
ret
Function at 0x40dd5d
Capabilities:
Allocate thread local storage

Disassembly:
push ebp
mov ebp, esp
push esi
push str.FlsAlloc
push 0x424b34
push str.FlsAlloc
push 0
call fcn.0040dcd6
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40dd8f
push dword [ebp + 8]
mov ecx, esi
call fcn.0040b5d4
call esi
pop esi
pop ebp
ret
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsAlloc]

Function at 0x40ddd1
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push esi
push str.FlsGetValue
push 0x424b58
push str.FlsGetValue
push 2
call fcn.0040dcd6
add esp, 0x10
mov esi, eax
push dword [ebp + 8]
test esi, esi
je 0x40de02
mov ecx, esi
call fcn.0040b5d4
call esi
jmp 0x40de08
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
pop esi
pop ebp
ret

Function at 0x40de0b
Capabilities:
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
push esi
push str.FlsSetValue
push 0x424b6c
push str.FlsSetValue
push 3
call fcn.0040dcd6
add esp, 0x10
mov esi, eax
push dword [ebp + 0xc]
push dword [ebp + 8]
test esi, esi
je 0x40de3f
mov ecx, esi
call fcn.0040b5d4
call esi
jmp 0x40de45
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
pop esi
pop ebp
ret

Function at 0x415846
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.004156c3

Function at 0x418ee7
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00418b89
Function at 0x402a30
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffef8
mov ebx, edx
mov esi, eax
mov eax, ebx
call fcn.00404458
test esi, esi
jne 0x402a66
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameA
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.00404548
jmp 0x402a84
call sub.kernel32.dll_GetCommandLineA
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00402944
mov edi, eax
test esi, esi
je 0x402a84
cmp dword [ebx], 0
je 0x402a84
dec esi
jmp 0x402a6d
add esp, 0x108
pop edi
pop esi
pop ebx
ret

Function at 0x403004
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x49d008], 0x8088405
inc edx
mov dword [ebx + 0x49d008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x403564
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [0x49d010]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x4035fc
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA
test eax, eax
jne 0x4035dc
xor eax, eax
push ebp
push 0x4035d5
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0xc], 4
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push 0
push 0
push 0x403618
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegQueryValueExA
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4035dc
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey
ret
mov ax, word [0x49d010]
and ax, 0xffc0
mov dx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [0x49d010], ax
mov esp, ebp
pop ebp
ret

Function at 0x4042dc
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x4a904c], 0
je 0x40433d
cmp word [0x4a9220], 0xd7b2
jne 0x404305
cmp dword [0x4a9228], 0
jbe 0x404305
mov eax, 0x4a921c
call dword [0x4a9238]
push 0
lea eax, [esp + 4]
push eax
push 0x1e
push 0x49d058
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
push 0x404364
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x49d020], 0
jne 0x404359
push 0
push 0x49d078
push 0x49d058
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret