joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4041fc
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffdf4
mov ebx, edx
mov esi, eax
mov eax, ebx
call fcn.004069bc
test esi, esi
jne 0x404232
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.00406b14
jmp 0x404250
call sub.kernel32.dll_GetCommandLineW
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00404140
mov edi, eax
test esi, esi
je 0x404250
cmp dword [ebx], 0
je 0x404250
dec esi
jmp 0x404239
add esp, 0x20c
pop edi
pop esi
pop ebx
ret

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

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

Function at 0x405b7c
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffff0
mov edi, edx
mov esi, eax
mov ebp, dword [esi + 0x10]
mov eax, esi
call fcn.00405e18
mov byte [esp], al
cmp byte [esp], 0
jne 0x405d06
test edi, edi
je 0x405d06
mov byte [esp + 1], 0
test ebp, ebp
jle 0x405c46
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
xor eax, eax
mov dword [esp + 0xc], eax
test ebp, ebp
jle 0x405c21
cmp edi, 0xffffffff
je 0x405be1
call sub.kernel32.dll_GetTickCount
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x405be1
mov byte [esp], 0
jmp 0x405d06
mov ebx, dword [esi]
cmp ebx, 1
jg 0x405c21
test ebx, ebx
jne 0x405c13
xor eax, eax
mov edx, 1
lock cmpxchg dword [esi], edx
test eax, eax
jne 0x405c13
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
mov byte [esp], 1
jmp 0x405d06
lea eax, [esp + 0xc]
call fcn.00405910
dec ebp
test ebp, ebp
jg 0x405bc6
cmp edi, 0xffffffff
je 0x405c46
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x405c44
mov byte [esp], 0
jmp 0x405d06
sub edi, eax
mov ebx, dword [esi]
test ebx, ebx
je 0x405b8a
lea edx, [ebx + 2]
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x405c46
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
mov eax, esi
call fcn.00405d74
mov edx, eax
mov ebx, dword [0x4598f4]
mov ecx, edi
xor eax, eax
call dword [ebx + 0x10]
test eax, eax
sete byte [esp]
cmp edi, 0xffffffff
je 0x405caa
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
jbe 0x405ca8
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
sub edi, eax
jmp 0x405caa
xor edi, edi
cmp byte [esp], 0
je 0x405cd0
mov ebx, dword [esi]
test bl, 1
jne 0x405ce6
mov edx, ebx
sub edx, 2
or edx, 1
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x405cb0
mov byte [esp + 1], 1
jmp 0x405ce6
mov ebx, dword [esi]
mov edx, ebx
sub edx, 2
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x405cd0
mov byte [esp + 1], 1
cmp byte [esp + 1], 0
je 0x405c5d
cmp byte [esp], 0
je 0x405d06
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
movzx eax, byte [esp]
add esp, 0x10
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x4066e8
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x459054], 0
je 0x40674f
cmp word [0x459340], 0xd7b2
jne 0x406711
cmp dword [0x459348], 0
jbe 0x406711
mov eax, 0x45933c
call dword [0x459358]
push 0
lea eax, [esp + 4]
push eax
push 0x1d
push str.Runtime_error_____at_00000000
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
mov eax, 0x40677c
call fcn.00407208
push eax
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x453032], 0
jne 0x40676b
push 0
push 0x4539c2
push str.Runtime_error_____at_00000000
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret

Function at 0x408adc
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe98
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x160], ecx
mov dword [ebp - 0x164], ecx
mov dword [ebp - 0x168], ecx
mov dword [ebp - 4], edx
mov esi, eax
xor eax, eax
push ebp
push 0x408c41
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
call fcn.004069bc
cmp si, word [0x453a00]
jb 0x408b74
cmp si, word [0x453c00]
ja 0x408b74
mov edi, 0x40
xor eax, eax
mov dword [ebp - 8], eax
cmp edi, dword [ebp - 8]
jb 0x408b74
mov ebx, edi
add ebx, dword [ebp - 8]
shr ebx, 1
cmp si, word [ebx*8 + 0x453a00]
jae 0x408b4e
mov edi, ebx
dec edi
jmp 0x408b6f
cmp si, word [ebx*8 + 0x453a00]
jbe 0x408b5e
inc ebx
mov dword [ebp - 8], ebx
jmp 0x408b6f
mov edx, dword [ebp - 4]
mov eax, dword [ebx*8 + 0x453a04]
call fcn.004089fc
jmp 0x408b74
cmp edi, dword [ebp - 8]
jae 0x408b38
mov eax, dword [ebp - 4]
cmp dword [eax], 0
jne 0x408c23
push 2
movzx eax, si
push eax
call sub.kernel32.dll_IsValidLocale
test eax, eax
je 0x408c23
push 0x55
lea eax, [ebp - 0xb2]
push eax
push 0x59
movzx ebx, si
push ebx
call sub.kernel32.dll_GetLocaleInfoW
push 0x55
lea eax, [ebp - 0x15c]
push eax
push 0x5a
push ebx
call sub.kernel32.dll_GetLocaleInfoW
lea eax, [ebp - 0x160]
lea edx, [ebp - 0xb2]
mov ecx, 0x55
call fcn.004075ac
push dword [ebp - 0x160]
push 0x408c5c
lea eax, [ebp - 0x164]
lea edx, [ebp - 0x15c]
mov ecx, 0x55
call fcn.004075ac
push dword [ebp - 0x164]
push 0x408c6c
lea eax, [ebp - 0x168]
lea edx, [ebp - 0xb2]
mov ecx, 0x55
call fcn.004075ac
push dword [ebp - 0x168]
mov eax, dword [ebp - 4]
mov edx, 5
call fcn.00407778
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408c48
lea eax, [ebp - 0x168]
mov edx, 3
call fcn.00406a1c
ret
Function at 0x408df4
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
push 0
push ebx
push esi
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x408ef8
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x45bb84
call sub.kernel32.dll_EnterCriticalSection
cmp bx, word [0x45bb9c]
jne 0x408e40
mov eax, esi
mov edx, 0x45bb9e
mov ecx, 0x55
call fcn.004075ac
push 0x45bb84
call sub.kernel32.dll_LeaveCriticalSection
jmp 0x408ee2
push 0x45bb84
call sub.kernel32.dll_LeaveCriticalSection
mov eax, esi
call fcn.004069bc
push 2
movzx eax, bx
push eax
call sub.kernel32.dll_IsValidLocale
test eax, eax
je 0x408eaf
cmp byte [0x45bb80], 0
je 0x408e74
mov edx, esi
mov eax, ebx
call fcn.00408cd8
jmp 0x408eaf
mov edx, esi
mov eax, ebx
call fcn.00408adc
call sub.kernel32.dll_GetSystemDefaultUILanguage
cmp bx, ax
je 0x408eaf
cmp dword [esi], 0
je 0x408e98
mov eax, esi
mov edx, 0x408f10
call fcn.00407698
call sub.kernel32.dll_GetSystemDefaultUILanguage
lea edx, [ebp - 4]
call fcn.00408adc
mov edx, dword [ebp - 4]
mov eax, esi
call fcn.00407698
push 0x45bb84
call sub.kernel32.dll_EnterCriticalSection
mov word [0x45bb9c], bx
mov eax, dword [esi]
call fcn.00407508
mov ecx, eax
mov eax, 0x45bb9e
mov edx, 0xaa
call fcn.0040895c
push 0x45bb84
call sub.kernel32.dll_LeaveCriticalSection
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408eff
lea eax, [ebp - 4]
call fcn.004069bc
ret
Function at 0x40963c
Capabilities:
Get geographical location
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
xor ecx, ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x10], ecx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00406aa0
xor eax, eax
push ebp
push 0x4096fc
push dword fs:[eax]
mov dword fs:[eax], esp
push 4
lea eax, [ebp - 0xc]
push eax
push 3
call sub.kernel32.dll_GetUserDefaultUILanguage
movzx eax, ax
push eax
call sub.kernel32.dll_GetLocaleInfoW
lea eax, [ebp - 0x10]
lea edx, [ebp - 0xc]
mov ecx, 4
call fcn.004075ac
mov ecx, dword [ebp - 0x10]
mov eax, ebx
mov edx, dword [ebp - 4]
call fcn.004076f0
mov eax, dword [ebx]
call fcn.00409504
test al, al
jne 0x4096d9
mov word [ebp - 8], 0
lea eax, [ebp - 0x14]
lea edx, [ebp - 0xc]
mov ecx, 4
call fcn.004075ac
mov ecx, dword [ebp - 0x14]
mov eax, ebx
mov edx, dword [ebp - 4]
call fcn.004076f0
mov eax, dword [ebx]
call fcn.00409504
test al, al
jne 0x4096d9
mov eax, ebx
call fcn.004069bc
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x409703
lea eax, [ebp - 0x14]
mov edx, 2
call fcn.00406a1c
lea eax, [ebp - 4]
call fcn.004069bc
ret

Function at 0x409df8
Capabilities:
Get system information on windows

Disassembly:
add esp, 0xffffffdc
push esp
call sub.kernel32.dll_GetSystemInfo
mov eax, dword [esp + 0x14]
add esp, 0x24
ret

Function at 0x413f3c
Capabilities:
Encrypt data using rc4 prga

Disassembly:
cmp eax, edx
je 0x413f95
test eax, edx
je 0x413f98
movzx ecx, word [edx]
cmp cx, word [eax]
je 0x413f53
movzx eax, word [eax]
sub eax, ecx
jmp 0x413f7a
push ebx
mov ebx, dword [eax - 4]
xor ecx, ecx
sub ebx, dword [edx - 4]
push ebx
adc ecx, 0xffffffff
and ecx, ebx
sub ecx, dword [eax - 4]
shl ecx, 1
sub eax, ecx
sub edx, ecx
mov ebx, dword [ecx + eax]
xor ebx, dword [ecx + edx]
jne 0x413f7b
add ecx, 4
js 0x413f6b
pop eax
pop ebx
ret
bsf ebx, ebx
shr ebx, 4
add ebx, ebx
add ecx, ebx
jns 0x413f78
movzx eax, word [ecx + eax]
movzx edx, word [ecx + edx]
sub eax, edx
pop ebx
pop ebx
jmp 0x413f7a
xor eax, eax
ret
test eax, eax
je 0x413fa4
test edx, edx
jne 0x413f44
mov eax, dword [eax - 4]
ret
sub eax, dword [edx - 4]
ret

Function at 0x414c80
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, ecx
mov esi, edx
mov ebx, eax
push 0
lea eax, [ebp - 4]
push eax
mov eax, dword [ebp + 8]
push eax
mov eax, dword [esi]
add eax, edi
push eax
push ebx
call sub.kernel32.dll_ReadFile_1
test eax, eax
jne 0x414cad
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret 4
Function at 0x414d50
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov byte [ebp - 1], dl
mov edi, eax
xor ebx, ebx
mov eax, edi
call fcn.00407508
push eax
call sub.kernel32.dll_GetFileAttributesW
mov esi, eax
cmp esi, 0xffffffff
je 0x414e05
test esi, 0x400
jne 0x414d8c
test esi, 0x10
setne bl
jmp 0x414e35
cmp byte [ebp - 1], 0
je 0x414dc7
push 0
push 0x2000000
push 3
push 0
push 1
push 0x80000000
mov eax, edi
call fcn.00407508
push eax
call sub.kernel32.dll_CreateFileW_1
cmp eax, 0xffffffff
je 0x414e35
push eax
call sub.kernel32.dll_CloseHandle_1
test esi, 0x10
setne bl
jmp 0x414e35
test esi, 0x10
je 0x414dd3
mov bl, 1
jmp 0x414e35
push 0
push 0x2000000
push 3
push 0
push 1
push 0x80000000
mov eax, edi
call fcn.00407508
push eax
call sub.kernel32.dll_CreateFileW_1
cmp eax, 0xffffffff
je 0x414e01
push eax
call sub.kernel32.dll_CloseHandle_1
xor ebx, ebx
jmp 0x414e35
mov bl, 1
jmp 0x414e35
call sub.kernel32.dll_GetLastError_2
cmp eax, 2
je 0x414e2f
cmp eax, 3
je 0x414e2f
cmp eax, 0xa1
je 0x414e2f
cmp eax, 0x7b
je 0x414e2f
cmp eax, 0x35
je 0x414e2f
cmp eax, 0x15
je 0x414e2f
cmp eax, 0x43
jne 0x414e33
xor ebx, ebx
jmp 0x414e35
mov bl, 1
mov eax, ebx
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret

Function at 0x418ae0
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe00
push ebx
push esi
mov esi, ecx
mov ebx, dword [ebp + 8]
push pe_nt_image_headers32
lea ecx, [ebp - 0x200]
push ecx
push edx
push eax
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x418b19
mov ecx, eax
dec ecx
lea edx, [ebp - 0x200]
mov eax, ebx
call fcn.00406b14
jmp 0x418b22
mov eax, ebx
mov edx, esi
call fcn.00406d6c
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x418b2c
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, ecx
mov esi, edx
mov ebx, eax
push 2
lea eax, [ebp - 4]
push eax
push esi
push ebx
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x418b50
movzx eax, word [ebp - 4]
jmp 0x418b52
mov eax, edi
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret
Function at 0x419acc
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff778
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 4], ecx
xor ecx, ecx
push ebp
push 0x419bf1
push dword fs:[ecx]
mov dword fs:[ecx], esp
push 0x400
lea ecx, [ebp - 0x888]
call fcn.004198d4
mov esi, eax
mov eax, dword [0x458954]
cmp byte [eax], 0
je 0x419b99
mov eax, dword [0x458708]
call fcn.00404704
call fcn.00403ff0
push 0
push 0
push 0
push 0
push esi
lea eax, [ebp - 0x888]
push eax
push 0
push 1
call sub.kernel32.dll_WideCharToMultiByte_1
mov ebx, eax
push ebx
lea eax, [ebp - 4]
mov ecx, 1
mov edx, dword [0x419a9c]
call fcn.00408538
add esp, 4
push 0
push 0
push ebx
mov eax, dword [ebp - 4]
push eax
push esi
lea eax, [ebp - 0x888]
push eax
push 0
push 1
call sub.kernel32.dll_WideCharToMultiByte_1
push 0
lea eax, [ebp - 8]
push eax
push ebx
mov eax, dword [ebp - 4]
push eax
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
push 0
lea eax, [ebp - 8]
push eax
push 2
push 0x419c0c
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
jmp 0x419bd5
push 0x40
lea eax, [ebp - 0x88]
push eax
mov eax, dword [0x4586c4]
mov eax, dword [eax + 4]
push eax
mov eax, dword [0x45bc4c]
call fcn.004085fc
push eax
call sub.user32.dll_LoadStringW_1
push 0x2010
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x888]
push eax
push 0
call sub.user32.dll_MessageBoxW
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x419bf8
lea eax, [ebp - 4]
mov edx, dword [0x419a9c]
call fcn.00408544
ret

Function at 0x41b140
Capabilities:
Encode data using xor

Disassembly:
push esi
push ebx
mov esi, eax
xor eax, eax
push esi
rol eax, 5
mov bl, byte [esi]
test bl, 0x80
jne 0x41b16c
cmp bl, 0
je 0x41b168
cmp bl, 0x41
jl 0x41b163
cmp bl, 0x5a
jg 0x41b163
or bl, 0x20
xor al, bl
inc esi
jmp 0x41b147
pop ecx
pop ebx
pop esi
ret
pop eax
pop ebx
pop esi
jmp fcn.0041b09c
Function at 0x422a4c
Capabilities:
Accept command line arguments
Query environment variable

Disassembly:
push ebx
push esi
push edi
mov ebx, eax
mov edi, 0x46d49c
xor esi, esi
push 0x2001
push edi
push ebx
call sub.kernel32.dll_GetEnvironmentVariableW
test eax, eax
je 0x422a6f
mov esi, edi
jmp 0x422b8e
mov eax, dword [0x4586c0]
cmp byte [eax], 0
je 0x422b8e
mov edx, 0x422b94
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422a9d
mov eax, edi
xor edx, edx
call fcn.004247dc
mov esi, edi
jmp 0x422b8e
mov edx, 0x422b9c
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422ac7
push 0xa
push edi
mov eax, dword [0x45890c]
mov eax, dword [eax]
push eax
call sub.msvcrt.dll__ltow
add esp, 0xc
mov esi, edi
jmp 0x422b8e
mov edx, 0x422bb4
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422aeb
push 0xa
push edi
push 2
call sub.msvcrt.dll__ultow
add esp, 0xc
mov esi, edi
jmp 0x422b8e
mov edx, 0x422bd0
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422b07
call sub.kernel32.dll_GetCommandLineW_1
mov esi, eax
jmp 0x422b8e
mov edx, 0x422be8
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422b34
push 0x2001
mov ecx, edi
mov edx, 1
xor eax, eax
call fcn.0041ea6c
mov word [edi + eax*2], 0
mov esi, edi
jmp 0x422b8e
mov edx, 0x422bf4
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422b61
push 0x2001
mov ecx, edi
mov edx, 1
xor eax, eax
call fcn.0041efe8
mov word [edi + eax*2], 0
mov esi, edi
jmp 0x422b8e
mov edx, 0x422c00
mov eax, ebx
call fcn.00415204
test eax, eax
jne 0x422b8e
call fcn.0040425c
mov eax, 0x7fff
call fcn.00404284
push 0xa
push edi
push eax
call sub.msvcrt.dll__ultow
add esp, 0xc
mov esi, edi
mov eax, esi
pop edi
pop esi
pop ebx
ret

Function at 0x424290
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
push ebx
push esi
push edi
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
xor ebx, ebx
push esi
mov eax, dword [ebp - 8]
push eax
call sub.kernel32.dll_FindFirstFileW_1
mov dword [edi], eax
jmp 0x4242ee
mov eax, esi
mov edx, dword [ebp - 0xc]
call dword [ebp - 4]
test al, al
je 0x4242d1
mov eax, dword [0x458938]
xor edx, edx
mov dword [eax], edx
mov bl, 1
jmp 0x4242f3
push esi
mov eax, dword [edi]
push eax
call sub.kernel32.dll_FindNextFileW
test eax, eax
jne 0x4242ee
mov eax, dword [edi]
push eax
call sub.kernel32.dll_FindClose_1
mov dword [edi], 0xffffffff
jmp 0x4242f3
cmp dword [edi], 0xffffffff
jne 0x4242b8
cmp dword [edi], 0xffffffff
je 0x424338
mov eax, dword [0x454744]
inc eax
push eax
mov eax, 0x471734
mov ecx, 1
mov edx, dword [0x42424c]
call fcn.00408538
add esp, 4
cmp dword [0x471734], 0
je 0x424336
mov eax, dword [0x471734]
mov edx, dword [0x454744]
mov ecx, dword [edi]
mov dword [eax + edx*4], ecx
inc dword [0x454744]
mov bl, 1
test bl, bl
jne 0x424349
call sub.kernel32.dll_GetLastError_2
mov edx, dword [0x458938]
mov dword [edx], eax
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x4244c4
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
push esi
push edi
mov esi, ecx
mov ebx, edx
mov edi, dword [ebp + 8]
mov dword [ebp - 0xc], esi
push eax
call sub.msvcrt.dll__get_osfhandle
pop ecx
mov dword [ebp - 0x10], eax
mov dword [ebp - 8], ebx
cmp esi, 0x4000
jbe 0x42454b
push 0
push 0
push 0x2000
mov eax, dword [0x458674]
push eax
push 0x2000
mov eax, dword [ebp - 8]
push eax
push 0
mov eax, dword [0x458898]
mov eax, dword [eax]
push eax
call sub.kernel32.dll_WideCharToMultiByte_1
mov ebx, eax
add dword [ebp - 8], 0x4000
sub esi, 0x4000
push 0
push edi
push ebx
mov eax, dword [0x458674]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_WriteFile_1
test eax, eax
je 0x42453d
cmp ebx, dword [edi]
je 0x424543
mov byte [ebp - 1], 0
jmp 0x4245a0
cmp esi, 0x4000
ja 0x4244ec
test esi, esi
je 0x424597
push 0
push 0
push 0x2000
mov eax, dword [0x458674]
push eax
push 0xffffffffffffffff
mov eax, dword [ebp - 8]
push eax
push 0
mov eax, dword [0x458898]
mov eax, dword [eax]
push eax
call sub.kernel32.dll_WideCharToMultiByte_1
mov esi, eax
dec esi
push 0
push edi
push esi
mov eax, dword [0x458674]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_WriteFile_1
test eax, eax
je 0x424591
cmp esi, dword [edi]
je 0x424597
mov byte [ebp - 1], 0
jmp 0x4245a0
mov eax, dword [ebp - 0xc]
mov dword [edi], eax
mov byte [ebp - 1], 1
movzx eax, byte [ebp - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x4247dc
Capabilities:
Get common file path

Disassembly:
push ebx
push esi
add esp, 0xfffffff8
mov ebx, edx
mov esi, eax
test bx, bx
jne 0x4247f9
push esi
push 0x104
call sub.kernel32.dll_GetCurrentDirectoryW
xor eax, eax
jmp 0x424870
mov word [esp], 0x3d
mov eax, ebx
mov edx, ebx
add edx, 0xffffff9f
sub dx, 0x1a
jae 0x424812
mov eax, ebx
and ax, 0xffdf
mov word [esp + 2], ax
mov word [esp + 4], 0x3a
mov word [esp + 6], 0
mov eax, esp
call fcn.00422a4c
test eax, eax
jne 0x424865
mov eax, ebx
mov edx, ebx
add edx, 0xffffff9f
sub dx, 0x1a
jae 0x424843
mov eax, ebx
and ax, 0xffdf
mov word [esi], ax
add esi, 2
mov word [esi], 0x3a
add esi, 2
mov word [esi], 0x5c
add esi, 2
mov word [esi], 0
mov eax, 1
jmp 0x424870
mov edx, eax
mov eax, esi
call fcn.0041c338
xor eax, eax
pop ecx
pop edx
pop esi
pop ebx
ret
Function at 0x424c7c
Capabilities:
Check if file exists
Get disk information
Get file attributes

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffff994
mov edi, eax
mov eax, edi
call fcn.0042bd58
mov ebx, eax
lea eax, [esp + 4]
push eax
lea eax, [esp + 0x25c]
push eax
push 0x208
push ebx
call sub.kernel32.dll_GetFullPathNameW
mov esi, eax
test esi, esi
je 0x424dbe
lea ebx, [esp + 0x258]
mov edx, 0x424dd0
mov ecx, 4
mov eax, ebx
call fcn.00415264
test eax, eax
jne 0x424d44
add ebx, 8
mov dword [esp + 4], ebx
mov edx, ebx
mov eax, edi
call fcn.00415358
mov dword [esp + 4], eax
cmp dword [esp + 4], 0
je 0x424d25
cmp edi, dword [esp + 4]
jae 0x424d25
mov eax, dword [esp + 4]
movzx ebx, word [eax]
mov eax, dword [esp + 4]
mov word [eax], 0
push edi
call sub.kernel32.dll_GetFileAttributesW
mov esi, eax
mov eax, dword [esp + 4]
mov word [eax], bx
cmp esi, 0xffffffff
je 0x424d1e
cmp esi, 1
sbb eax, eax
inc eax
jmp 0x424dc4
xor eax, eax
jmp 0x424dc4
push edi
call sub.kernel32.dll_GetFileAttributesW
mov esi, eax
cmp esi, 0xffffffff
je 0x424d3d
cmp esi, 1
sbb eax, eax
inc eax
jmp 0x424dc4
xor eax, eax
jmp 0x424dc4
cmp dword [esp + 4], 0
je 0x424d55
mov eax, dword [esp + 4]
cmp word [eax], 0
jne 0x424d68
push ebx
call sub.kernel32.dll_GetFileAttributesW
cmp eax, 0xffffffff
setne al
mov esi, eax
and esi, 0x7f
jmp 0x424dbe
push esp
lea ecx, [esp + 0xc]
mov edx, 0x37
mov eax, ebx
call fcn.00424354
mov esi, eax
and esi, 0x7f
mov eax, dword [esp]
call fcn.004243d8
test esi, esi
jne 0x424dbe
lea eax, [ebx + 2]
cmp word [eax], 0x5c
je 0x424dae
lea eax, [ebx + 2]
cmp word [eax], 0x3a
jne 0x424dbe
lea eax, [ebx + 4]
cmp word [eax], 0x5c
jne 0x424dbe
lea eax, [ebx + 6]
cmp word [eax], 0
jne 0x424dbe
push ebx
call sub.kernel32.dll_GetDriveTypeW
cmp eax, 1
jbe 0x424dbe
mov esi, 1
cmp esi, 1
sbb eax, eax
inc eax
add esp, 0x66c
pop edi
pop esi
pop ebx
ret
Function at 0x427828
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffbc8
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x430], ecx
mov esi, edx
mov edi, eax
xor eax, eax
push ebp
push 0x4279d6
push dword fs:[eax]
mov dword fs:[eax], esp
xor ebx, ebx
test esi, esi
jne 0x427910
xor esi, esi
push 0x20a
lea eax, [ebp - 0x212]
push eax
push esi
push edi
call sub.advapi32.dll_RegEnumKeyW
mov ebx, eax
test ebx, ebx
je 0x427886
cmp ebx, 0x103
jne 0x4279ba
xor ebx, ebx
jmp 0x4279ba
cmp word [ebp - 0x212], 0x2e
jne 0x4278f4
mov dword [ebp - 8], 0x20a
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x212]
push eax
push edi
call sub.advapi32.dll_RegQueryValueW
mov ebx, eax
test ebx, ebx
jne 0x4279ba
lea eax, [ebp - 0x212]
mov dword [ebp - 0x42c], eax
mov byte [ebp - 0x428], 0xa
lea eax, [ebp - 0x41c]
mov dword [ebp - 0x424], eax
mov byte [ebp - 0x420], 0xa
lea edx, [ebp - 0x42c]
mov eax, 0x4279e8
mov ecx, 1
call fcn.00424fc0
mov eax, dword [0x458848]
cmp dword [eax], 0
je 0x42790a
mov dword [ebp - 4], 1
jmp 0x4279bd
inc esi
jmp 0x42785a
xor edx, edx
mov eax, esi
call fcn.0042bbf0
mov esi, eax
mov dx, 0x20
mov eax, esi
call fcn.0041c2e0
test eax, eax
je 0x42792f
mov word [eax], 0
mov dword [ebp - 8], 0x20a
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x41c]
push eax
push esi
push edi
call sub.advapi32.dll_RegQueryValueW
mov ebx, eax
test ebx, ebx
jne 0x427985
mov dword [ebp - 0x42c], esi
mov byte [ebp - 0x428], 0xa
lea eax, [ebp - 0x41c]
mov dword [ebp - 0x424], eax
mov byte [ebp - 0x420], 0xa
lea edx, [ebp - 0x42c]
mov eax, 0x4279e8
mov ecx, 1
call fcn.00424fc0
jmp 0x4279ba
push 0
lea edx, [ebp - 0x430]
mov eax, dword [0x458860]
call fcn.00409d44
mov eax, dword [ebp - 0x430]
mov dword [ebp - 0x438], esi
mov byte [ebp - 0x434], 0xa
lea ecx, [ebp - 0x438]
mov edx, 1
call fcn.0042b400
mov dword [ebp - 4], ebx
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4279dd
lea eax, [ebp - 0x430]
call fcn.004069bc
ret