joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403f10
Capabilities:
Send data
Send data on socket

Disassembly:
push ebx
mov ebx, ecx
push ebp
push esi
mov eax, dword [ebx + 0x44]
push edi
test eax, eax
jne 0x403f26
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
mov edi, dword [esp + 0x18]
mov ebp, dword [esp + 0x14]
mov eax, dword [ebx + 0x40]
push 4
push edi
push ebp
push eax
call sub.WSOCK32.dll_send
mov esi, eax
cmp esi, edi
je 0x403f64
call sub.WSOCK32.dll_WSAGetLastError
cmp eax, 0x2733
mov dword [esp + 0x18], eax
jne 0x403f70
mov ecx, dword [ebx + 0x40]
push 4
push edi
push ebp
push ecx
call sub.WSOCK32.dll_send
mov esi, eax
cmp esi, edi
jne 0x403f41
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
ret 8
cmp esi, edi
je 0x403f64
mov edx, dword [ebx + 0x20]
push edx
call dword [sym.imp.USER32.dll_GetParent]
push eax
call sub.MFC42.DLL_CWnd::FromHandle
mov ecx, dword [esp + 0x18]
mov edx, dword [ebx + 0x48]
mov eax, dword [eax + 0x20]
push ecx
push edx
push 0x7403
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
Function at 0x403fb0
Capabilities:
Send data
Send data on socket

Disassembly:
sub esp, 0x1c
push ebx
push esi
mov esi, ecx
push edi
mov eax, dword [esi + 0x44]
test eax, eax
jne 0x403fca
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x1c
ret 8
mov eax, dword [esi + 0x1ff08]
test eax, eax
jne 0x404011
mov ecx, dword [esp + 0x2c]
mov edx, dword [esi + 0x1fd6c]
lea eax, [esp + 0x30]
push eax
push ecx
push edx
mov ecx, esi
call fcn.00404bf0
test eax, eax
jne 0x403ff9
pop edi
pop esi
pop ebx
add esp, 0x1c
ret 8
mov eax, dword [esi + 0x1fd6c]
mov ecx, dword [esp + 0x30]
mov byte [ecx + eax], 1
mov eax, dword [esp + 0x30]
inc eax
jmp 0x40410e
mov eax, dword [esi + 0x48]
test eax, eax
jne 0x4040b3
cmp byte [esi + 0x1ff10], 2
jae 0x4040b3
mov eax, dword [esi + 0x1ff0c]
test eax, eax
jne 0x404067
mov edi, dword [sym.imp.USER32.dll_GetMessageA]
mov ebx, dword [sym.imp.USER32.dll_DispatchMessageA]
push 0
push 0
lea edx, [esp + 0x14]
push 0
push edx
call edi
cmp dword [esp + 0x10], 0x466
je 0x404067
lea eax, [esp + 0xc]
push eax
call ebx
mov eax, dword [esi + 0x1ff0c]
test eax, eax
je 0x40403f
mov edx, dword [esp + 0x2c]
mov eax, dword [esi + 0x1fd6c]
lea ecx, [esp + 0x30]
push ecx
push edx
push eax
mov ecx, esi
call fcn.00404bf0
test eax, eax
jne 0x40408c
pop edi
pop esi
pop ebx
add esp, 0x1c
ret 8
mov ecx, dword [esi + 0x1fd6c]
mov edx, dword [esp + 0x30]
mov byte [edx + ecx], 1
mov eax, dword [esp + 0x30]
mov cl, byte [esi + 0x1ff10]
inc eax
inc cl
mov dword [esp + 0x30], eax
mov byte [esi + 0x1ff10], cl
jmp 0x404112
mov eax, dword [esi + 0x1ff0c]
test eax, eax
jne 0x4040f1
mov edi, dword [sym.imp.USER32.dll_GetMessageA]
mov ebx, dword [sym.imp.USER32.dll_DispatchMessageA]
push 0
push 0
lea eax, [esp + 0x14]
push 0
push eax
call edi
cmp dword [esp + 0x10], 0x466
je 0x4040f1
lea ecx, [esp + 0xc]
push ecx
call ebx
mov eax, dword [esi + 0x1ff0c]
test eax, eax
je 0x4040c9
mov eax, dword [esp + 0x2c]
push 1
mov cx, word [eax]
mov dx, word [eax + 2]
add eax, 4
push eax
push edx
push ecx
mov ecx, esi
call fcn.00404e90
add eax, 8
mov dword [esp + 0x30], eax
mov edx, dword [esi + 0x1fd6c]
push 4
push eax
mov eax, dword [esi + 0x40]
push edx
push eax
call sub.WSOCK32.dll_send
mov edi, eax
mov eax, dword [esp + 0x30]
cmp edi, eax
je 0x40415f
call sub.WSOCK32.dll_WSAGetLastError
mov ebx, eax
cmp ebx, 0x2733
jne 0x40416d
mov ecx, dword [esp + 0x30]
mov edx, dword [esi + 0x1fd6c]
mov eax, dword [esi + 0x40]
push 4
push ecx
push edx
push eax
call sub.WSOCK32.dll_send
mov edi, eax
mov eax, dword [esp + 0x30]
cmp edi, eax
jne 0x40412f
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x1c
ret 8
cmp edi, dword [esp + 0x30]
je 0x40415f
mov ecx, dword [esi + 0x20]
push ecx
call dword [sym.imp.USER32.dll_GetParent]
push eax
call sub.MFC42.DLL_CWnd::FromHandle
mov edx, dword [esi + 0x48]
mov eax, dword [eax + 0x20]
push ebx
push edx
push 0x7403
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x1c
ret 8
Function at 0x404690
Capabilities:
Connect socket
Get hostname
Initialize winsock library
Resolve dns
Set socket configuration

Disassembly:
sub esp, 0x5a0
push ebx
push esi
mov esi, ecx
push edi
mov eax, dword [esi + 0x44]
test eax, eax
jne 0x4046c3
lea eax, [esp + 0x1c]
push eax
push 0x101
call sub.WSOCK32.dll_WSAStartup
test eax, eax
je 0x4046d1
push 0
push 0
push str.Cannot_Find_Usable_WinSock_DLL___
call sub.MFC42.DLL_AfxMessageBox_1
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x5a0
ret 8
mov eax, dword [esi + 0x4c]
test eax, eax
jne 0x4046dd
push eax
push 1
jmp 0x4046e6
cmp eax, 1
jne 0x4046c3
push 0
push 2
push 2
call sub.WSOCK32.dll_socket
mov ebx, dword [esp + 0x5b4]
mov dword [esi + 0x40], eax
push ebx
mov word [esp + 0x10], 2
call sub.WSOCK32.dll_htons
mov edi, dword [esp + 0x5b0]
mov word [esp + 0xe], ax
push edi
call sub.WSOCK32.dll_inet_addr
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x404734
push edi
call sub.WSOCK32.dll_gethostbyname
test eax, eax
je 0x4046c3
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
mov dword [esp + 0x10], eax
mov edx, dword [esi + 0x40]
lea ecx, [esp + 0xc]
push 0x10
push ecx
push edx
call sub.WSOCK32.dll_connect
test eax, eax
jne 0x4046c3
mov eax, dword [esi + 0x20]
mov ecx, dword [esi + 0x40]
push 0x31
push 0x464
push eax
push ecx
call sub.WSOCK32.dll_WSAAsyncSelect
push edi
lea ecx, [esi + 0x1fd58]
mov dword [esi + 0x44], 1
call sub.MFC42.DLL_CString::operator_1
mov eax, dword [esi + 0x48]
mov dword [esi + 0x1fd5c], ebx
cmp eax, 7
je 0x404788
mov ecx, esi
call fcn.00404d30
mov eax, dword [0x4130f0]
test eax, eax
je 0x4047d6
lea edx, [esp + 0x1ac]
push 0x400
push edx
call sub.WSOCK32.dll_gethostname
test eax, eax
jne 0x4047e7
lea eax, [esp + 0x1ac]
push eax
call sub.WSOCK32.dll_gethostbyname
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
push eax
call sub.WSOCK32.dll_inet_ntoa
push eax
mov ecx, 0x4144a0
call sub.MFC42.DLL_CString::operator_1
mov dword [0x4130f0], 0
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x5a0
ret 8
push str.Error
mov ecx, 0x4144a0
call sub.MFC42.DLL_CString::operator_1
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x5a0
ret 8
Function at 0x408e50
Capabilities:
Query or enumerate registry value

Disassembly:
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
sub esp, 0x10c
lea eax, [esp]
push esi
push eax
push 1
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov esi, eax
test esi, esi
jne 0x408eb2
mov edx, dword [esp + 4]
lea eax, [esp + 8]
lea ecx, [esp + 0xc]
push eax
push ecx
push esi
push edx
mov dword [esp + 0x18], 0x104
call dword [sym.imp.ADVAPI32.dll_RegQueryValueA]
mov ecx, dword [esp + 0x11c]
lea eax, [esp + 0xc]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov edx, dword [esp + 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
add esp, 0x10c
ret

Function at 0x408ec0
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x208
mov eax, dword [esp + 0x20c]
push ebx
push ebp
mov ebp, dword [esp + 0x218]
push esi
xor esi, esi
push ebp
push esi
push esi
push eax
push str.open
push esi
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
cmp eax, 0x20
jg 0x408fa8
lea ecx, [esp + 0xc]
push ecx
push str..htm
push closesocket
call fcn.00408e50
add esp, 0xc
test eax, eax
jne 0x408fb7
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcatA]
lea edx, [esp + 0xc]
push str._shellopencommand
push edx
call ebx
lea eax, [esp + 0xc]
lea ecx, [esp + 0xc]
push eax
push ecx
push closesocket
call fcn.00408e50
add esp, 0xc
test eax, eax
jne 0x408fb7
push edi
mov edi, dword [sym.imp.MSVCRT.dll_strstr]
lea edx, [esp + 0x10]
push str.__1_
push edx
call edi
mov esi, eax
add esp, 8
test esi, esi
jne 0x408f80
lea eax, [esp + 0x10]
push 0x4137b8
push eax
call edi
mov esi, eax
add esp, 8
test esi, esi
jne 0x408f80
lea ecx, [esp + 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esp + eax + 0xf]
jmp 0x408f83
mov byte [esi], 0
push 0x4134c4
push esi
call ebx
mov edx, dword [esp + 0x21c]
push edx
push esi
call ebx
lea eax, [esp + 0x10]
push ebp
push eax
call dword [sym.imp.KERNEL32.dll_WinExec]
cmp eax, 0x1f
pop edi
jbe 0x408fc3
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x208
ret
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x208
ret
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x208
ret
Function at 0x40c020
Capabilities:
Packed with generic packer

Disassembly:
push 0xffffffffffffffff
push 0x40e7a8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x148
push ebx
push ebp
mov ebp, ecx
push esi
push edi
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::CString_2
xor esi, esi
mov dword [esp + 0x160], esi
call sub.MFC42.DLL_AfxGetModuleState
mov eax, dword [eax + 4]
push esi
lea ecx, [esp + 0x5c]
push esi
mov eax, dword [eax + 0x90]
lea edx, [esp + 0x28]
push ecx
push edx
push eax
call dword [sym.imp.MSVCRT.dll__splitpath]
add esp, 0x14
lea ecx, [esp + 0x58]
lea edx, [esp + 0x20]
lea eax, [esp + 0x18]
push ecx
push edx
push str._s_s
push eax
call sub.MFC42.DLL_CString::Format
add esp, 0x10
lea ecx, [esp + 0x18]
lea edx, [esp + 0x24]
push str.info.dll
push ecx
push edx
call sub.MFC42.DLL_operator_2
mov eax, dword [eax]
push esi
push eax
push 2
lea ecx, [esp + 0x40]
mov byte [esp + 0x16c], 1
call fcn.004034b0
lea ecx, [esp + 0x24]
mov byte [esp + 0x160], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x1c]
call sub.MFC42.DLL_CString::CString_2
push str.redmoon.joycity.co.kr
lea eax, [esp + 0x20]
push str.Diosa__s
push eax
mov byte [esp + 0x16c], 4
call sub.MFC42.DLL_CString::Format
add esp, 0xc
lea ecx, [esp + 0x34]
push 1
push 1
push str.Count
push 0x4140fc
call fcn.004037d0
lea ecx, [esp + 0x10]
mov edi, eax
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esp + 0x14]
mov byte [esp + 0x160], 5
call sub.MFC42.DLL_CString::CString_2
mov ebx, dword [sym.imp.USER32.dll_SendMessageA]
cmp edi, esi
mov byte [esp + 0x160], 6
jle 0x40c1e1
push esi
lea ecx, [esp + 0x18]
push 0x414100
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x20]
add esp, 0xc
lea ecx, [esp + 0x30]
push 1
push edx
push eax
push 0x4140fc
push ecx
lea ecx, [esp + 0x48]
call fcn.00403710
push 0
push 0x4140f8
lea edx, [esp + 0x34]
push eax
push edx
mov byte [esp + 0x170], 7
call fcn.00403370
add esp, 0x10
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x164], 8
call fcn.0040ce50
lea ecx, [esp + 0x2c]
mov byte [esp + 0x160], 7
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x30]
mov byte [esp + 0x160], 6
call sub.MFC42.DLL_CString::CString
mov eax, dword [esp + 0x10]
mov ecx, dword [ebp + 0x1d0]
push eax
push 0
push 0x180
push ecx
call ebx
inc esi
cmp esi, edi
jl 0x40c140
call sub.MFC42.DLL_AfxGetModuleState
mov eax, dword [eax + 4]
push 0
push str.Prev
push str.Server
mov ecx, eax
call sub.MFC42.DLL_CWinApp::GetProfileIntA
dec edi
push 0
cmp eax, edi
jle 0x40c213
mov edx, dword [ebp + 0x1d0]
push 0
push 0x186
push edx
jmp 0x40c220
push eax
mov eax, dword [ebp + 0x1d0]
push 0x186
push eax
call ebx
jmp 0x415b4a
Function at 0x40c2f0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
sub esp, 0x24
xor eax, eax
push ebx
push ebp
push esi
mov esi, ecx
mov ebx, dword [sym.imp.MSVCRT.dll_rand]
push edi
lea ebp, [esi + 0x196]
xor edi, edi
mov ecx, ebp
mov dword [ecx], eax
mov dword [ecx + 4], eax
mov word [ecx + 8], ax
call ebx
and eax, 0x800000ff
jns 0x40c324
dec eax
or eax, 0xffffff00
inc eax
test al, al
mov byte [esp + edi + 0x10], al
jne 0x40c32f
inc byte [ebp]
inc edi
cmp edi, 0xa
jl 0x40c314
mov bx, word [esp + 0x18]
movsx edx, byte [esp + 0x10]
movsx ecx, bh
imul ecx, edx
mov eax, ecx
cdq
and edx, 0xff
add eax, edx
sar eax, 8
and ecx, 0x800000ff
mov byte [esi + 0x197], al
jns 0x40c369
dec ecx
or ecx, 0xffffff00
inc ecx
movsx eax, byte [esp + 0x11]
mov byte [esi + 0x198], cl
mov ecx, 7
cdq
idiv ecx
movsx eax, byte [esp + 0x15]
mov ecx, 0xa
mov byte [esi + 0x199], dl
cdq
idiv ecx
movsx ecx, byte [esp + 0x17]
mov byte [esi + 0x19a], dl
movsx edx, byte [esp + 0x14]
imul ecx, edx
mov eax, ecx
cdq
and edx, 0xff
add eax, edx
sar eax, 8
and ecx, 0x800000ff
mov byte [esi + 0x19b], al
jns 0x40c3c6
dec ecx
or ecx, 0xffffff00
inc ecx
mov byte [esi + 0x19c], cl
xor eax, eax
cmp byte [eax + ebp], 0
jne 0x40c3da
inc byte [esi + 0x19d]
inc eax
cmp eax, 7
jl 0x40c3ce
mov al, byte [esp + 0x16]
mov cl, byte [esp + 0x13]
xor al, cl
lea edx, [esi + 0x18c]
mov cl, bl
mov byte [esi + 0x19e], al
mov eax, dword [edx]
or cl, bh
mov byte [esi + 0x19f], cl
mov dword [esp + 0x1c], eax
mov ecx, dword [edx + 4]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x20], ecx
mov ecx, dword [esp + 0x14]
mov dx, word [edx + 8]
mov dword [esp + 0x2c], ecx
mov word [esp + 0x24], dx
lea edx, [esp + 0x1c]
push edx
push 0x16
push 0
push 7
lea ecx, [esi + 0x94]
mov word [esp + 0x36], 0
mov dword [esp + 0x38], eax
mov word [esp + 0x40], bx
call fcn.00401dd0
mov eax, dword [esi + 0x20]
push 0
push 0x4e20
push 0x70
push eax
call dword [sym.imp.USER32.dll_SetTimer]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret

Function at 0x40ca60
Capabilities:
Set registry value

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push esi
mov esi, ecx
push edi
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
push ecx
mov ecx, dword [esi + 0x10]
push ebx
push 1
push eax
mov eax, dword [esp + 0x20]
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, eax
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
mov dword [esi + 4], edx
repne scasb al, byte es:[edi]
not ecx
mov dword [esi + 0xc], ecx
mov dword [esi + 8], 1
test edx, edx
pop edi
pop esi
sete al
pop ebx
ret 8
Function at 0x40cab0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 8
push esi
mov esi, ecx
lea eax, [esp + 4]
lea ecx, [esp + 8]
push eax
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x14]
push ecx
mov ecx, dword [esi + 0x10]
push edx
push 0
push eax
push ecx
mov dword [esp + 0x1c], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [esp + 0x10]
mov ecx, dword [esp + 4]
mov dword [esi + 4], eax
mov dword [esi + 8], edx
mov dword [esi + 0xc], ecx
pop esi
test eax, eax
jne 0x40cb09
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 4]
mov dword [edx], eax
mov eax, 1
add esp, 8
ret 8
xor eax, eax
add esp, 8
ret 8

Function at 0x40cb20
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x108
push esi
mov esi, ecx
lea eax, [esp + 4]
lea ecx, [esp + 0xc]
push eax
mov eax, dword [esp + 0x114]
lea edx, [esp + 0xc]
push ecx
mov ecx, dword [esi + 0x10]
push edx
push 0
push eax
push ecx
mov dword [esp + 0x1c], 0xc8
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [esp + 8]
mov ecx, dword [esp + 4]
mov dword [esi + 4], eax
mov dword [esi + 8], edx
mov dword [esi + 0xc], ecx
pop esi
test eax, eax
jne 0x40cb89
mov ecx, dword [esp + 0x110]
lea edx, [esp + 8]
push edx
call sub.MFC42.DLL_CString::operator_1
mov eax, 1
add esp, 0x108
ret 8
xor eax, eax
add esp, 0x108
ret 8
Function at 0x401488
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
push ebx
push esi
push edi
lea eax, [ebp - 4]
push eax
mov eax, dword [0x7a24f0]
or eax, 8
push eax
xor ebx, ebx
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, ebx
jne 0x40151d
mov esi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
mov edi, 0x105
jmp 0x4014da
cmp dword [ebp + 0x10], ebx
jne 0x401511
push ebx
lea eax, [ebp - 0x10c]
push eax
push dword [ebp - 4]
call fcn.00401488
test eax, eax
jne 0x4014ec
push edi
lea eax, [ebp - 0x10c]
push eax
push ebx
push dword [ebp - 4]
call esi
test eax, eax
je 0x4014c1
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 2
call fcn.004059d5
cmp eax, ebx
je 0x401524
push ebx
push dword [0x7a24f0]
push dword [ebp + 0xc]
push dword [ebp + 8]
call eax
jmp 0x40151d
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret 0xc
cmp dword [0x7a24f0], ebx
jne 0x40151a
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
jne 0x40151a
jmp 0x40151d
Function at 0x4055cb
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 0x10]
push eax
push 0x79f9f8
xor eax, eax
push eax
push eax
push eax
push eax
push eax
push eax
push dword [ebp + 8]
mov dword [0x79f9f8], 0x44
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x405606
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4

Function at 0x405742
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40575f
and eax, 0xfffffffe
push eax
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
ret 4

Function at 0x405762
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ecx, eax
inc ecx
push 0
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
ret 0xc

Function at 0x405791
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
dec edi
mov dword [ebp + 8], 0x61736e
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
pop ecx
xor edx, edx
div ecx
push esi
push 0
lea eax, [ebp + 8]
push eax
push dword [ebp + 0xc]
add byte [ebp + 0xa], dl
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
jne 0x4057d5
test edi, edi
jne 0x40579c
mov byte [esi], 0
pop edi
pop esi
pop ebp
ret 8
mov eax, esi
jmp 0x4057cf

Function at 0x4057d9
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [ebp + 0x14]
lea eax, [ebp + 0x18]
push eax
mov eax, dword [ebp + 0x18]
xor ebx, ebx
neg eax
sbb eax, eax
and eax, 0x100
or eax, 0x20019
push eax
push ebx
push dword [ebp + 0xc]
mov byte [esi], bl
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40584a
lea eax, [ebp + 0xc]
push eax
push esi
lea eax, [ebp + 0x14]
push eax
push ebx
push dword [ebp + 0x10]
mov dword [ebp + 0xc], 0x400
push dword [ebp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x405839
cmp dword [ebp + 0x14], 1
je 0x40583b
cmp dword [ebp + 0x14], 2
je 0x40583b
mov byte [esi], bl
push dword [ebp + 0x18]
mov byte [esi + 0x3ff], bl
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop ebx
pop ebp
ret 0x14
Function at 0x405a93
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x79fa40
push esi
call fcn.004058f2
push esi
call fcn.004056d1
mov edi, eax
test edi, edi
jne 0x405ab4
xor eax, eax
jmp 0x405b0c
push edi
call fcn.00405914
test byte [0x7a2468], 0x80
je 0x405acd
mov al, byte [edi]
test al, al
je 0x405ab0
cmp al, 0x5c
je 0x405ab0
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
sub edi, esi
jmp 0x405aed
push esi
call fcn.004059ae
test eax, eax
je 0x405ae7
test byte [eax], 0x10
je 0x405b11
push esi
call fcn.00405a6c
push esi
call ebx
cmp eax, edi
jg 0x405ad8
push esi
call fcn.00405a3f
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop ebx
pop edi
pop esi
ret 4
xor eax, eax
jmp 0x405b0b
Function at 0x405dc1
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
push ebx
push ebp
push esi
push edi
push 1
call fcn.004059d5
test eax, eax
mov esi, dword [esp + 0x18]
je 0x405de5
push 5
push esi
push dword [esp + 0x1c]
call eax
test eax, eax
jne 0x405f1e
test esi, esi
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
mov dword [0x79fe40], 0x4c554e
mov edi, 0x400
mov ebp, 0x79fe40
je 0x405e29
push 1
push 0
push esi
call fcn.00405762
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x405f24
cmp eax, edi
jg 0x405f24
push edi
mov esi, 0x7a0780
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x405f24
cmp eax, edi
jg 0x405f24
push esi
push ebp
push str._s_s_r_n
push 0x7a0240
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
mov ebx, eax
mov eax, dword [0x7a2410]
push dword [eax + 0x128]
push esi
call fcn.00405b6b
push 4
push 0xc0000000
push esi
call fcn.00405762
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x14], ebp
je 0x405f1e
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x405f17
push 0
lea eax, [esp + 0x1c]
push eax
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x405f17
cmp edi, dword [esp + 0x18]
jne 0x405f17
push str._Rename__r_n
push esi
call fcn.00405b15
test eax, eax
jne 0x405f2b
push str._Rename__r_n
lea eax, [esi + edi]
push eax
call fcn.004058f2
add edi, 0xa
mov eax, edi
push ebx
push 0x7a0240
add eax, esi
push eax
call fcn.0040571e
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [esp + 0x1c]
push eax
add edi, ebx
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc dword [0x7a24d0]
pop edi
pop esi
pop ebp
pop ebx
ret 8
push 0x4076bc
add eax, 0xa
push eax
call fcn.00405b15
test eax, eax
je 0x405ee2
inc eax
lea ecx, [esi + edi]
cmp eax, ecx
mov ebp, eax
jae 0x405f52
mov dl, byte [ebp]
mov byte [ebx + ebp], dl
inc ebp
cmp ebp, ecx
jb 0x405f47
mov ebp, dword [esp + 0x14]
sub eax, esi
jmp 0x405ee4