joyce8/EMBER2024-capa huggingface dataset:
Function at 0x47f9b5
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x10], 0
push 0x80000301
push 0
push 0x200
push 1
mov ebx, 0x1bc
call fcn.004effa0
add esp, 0x10
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
push eax
mov ebx, dword [ebp - 4]
test ebx, ebx
je 0x47fa0f
push ebx
call fcn.004eed45
add esp, 4
pop eax
mov dword [ebp - 4], eax
lea eax, [ebp - 4]
push eax
call fcn.0040146e
mov dword [ebp - 8], eax
mov dword [ebp - 0x14], esp
push 0x200
push dword [ebp - 8]
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_GetWindowTextW]
nop
nop
nop
nop
cmp dword [ebp - 0x14], esp
je 0x47fa53
push 0x83
push 0x4024b3c
push 6
call fcn.004eed57
add esp, 0xc
mov dword [ebp - 0xc], eax
fild dword [ebp - 0xc]
fstp qword [ebp - 0x18]
fld qword [ebp - 0x18]
fmul qword [0x562780]
fstp qword [ebp - 0x20]
fld qword [ebp - 0x20]
call fcn.00401495
push 0x80000301
push 0
push eax
push 0x80000301
push 0
push dword [ebp - 8]
push 2
mov ebx, 0x910
call fcn.004f0940
add esp, 0x1c
mov dword [ebp - 0x24], eax
push 0x5731ce
push dword [ebp - 0x24]
mov ecx, 2
call fcn.00410b79
add esp, 8
mov dword [ebp - 0x28], eax
mov ebx, dword [ebp - 0x24]
test ebx, ebx
je 0x47fabf
push ebx
call fcn.004eed45
add esp, 4
mov dword [ebp - 0x2c], 0
push 0
push dword [ebp - 0x2c]
lea eax, [ebp - 0x28]
push eax
call fcn.00405c43
mov dword [ebp - 0x30], eax
mov ebx, dword [ebp - 0x28]
test ebx, ebx
je 0x47fae7
push ebx
call fcn.004eed45
add esp, 4
mov eax, dword [ebp - 0x30]
push eax
mov ebx, dword [ebp - 0x10]
test ebx, ebx
je 0x47fafb
push ebx
call fcn.004eed45
add esp, 4
pop eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x47fb1b
push eax
mov ebx, eax
call fcn.0040106b
inc eax
push eax
call fcn.004eed3f
pop ecx
pop esi
mov edi, eax
rep movsb byte es:[edi], byte [esi]
jmp 0x47fb20
push eax
mov ebx, dword [ebp - 4]
test ebx, ebx
je 0x47fb31
push ebx
call fcn.004eed45
add esp, 4
mov ebx, dword [ebp - 0x10]
test ebx, ebx
je 0x47fb41
push ebx
call fcn.004eed45
add esp, 4
pop eax
mov esp, ebp
pop ebp
ret 4
Function at 0x4ef880
Capabilities:
Set registry value

Disassembly:
mov eax, dword [esp + 0x28]
sub esp, 0x18
push ebx
push ebp
xor ebx, ebx
xor ebp, ebp
cmp eax, 0x80000301
ja 0x4ef900
je 0x4ef8f1
cmp eax, 0x80000101
ja 0x4ef8ea
je 0x4ef8f1
cmp eax, reloc.WS2_32.dll_connect
je 0x4ef8cc
cmp eax, reloc.WS2_32.dll_getpeername
jne 0x4ef915
mov eax, dword [esp + 0x40]
mov dword [esp + 8], 3
test eax, eax
je 0x4ef962
mov ebx, dword [eax + 4]
lea ebp, [eax + 8]
jmp 0x4ef962
mov eax, dword [esp + 0x40]
mov dword [esp + 8], 1
push eax
call fcn.004f8640
mov ebp, dword [esp + 0x44]
mov ebx, eax
add esp, 4
inc ebx
jmp 0x4ef962
cmp eax, 0x80000201
jne 0x4ef915
mov ebx, 4
lea ebp, [esp + 0x40]
mov dword [esp + 8], ebx
jmp 0x4ef962
cmp eax, 0x80000401
je 0x4ef94d
cmp eax, 0x80000501
je 0x4ef935
cmp eax, 0x80000601
je 0x4ef91d
pop ebp
xor eax, eax
pop ebx
add esp, 0x18
ret
fld qword [esp + 0x40]
mov ebx, 4
mov dword [esp + 8], ebx
call fcn.00532bb8
mov dword [esp + 0xc], eax
jmp 0x4ef95e
fld dword [esp + 0x40]
mov ebx, 4
mov dword [esp + 8], ebx
call fcn.00532bb8
mov dword [esp + 0xc], eax
jmp 0x4ef95e
mov ecx, dword [esp + 0x40]
mov ebx, 4
mov dword [esp + 8], ebx
mov dword [esp + 0xc], ecx
lea ebp, [esp + 0xc]
mov edx, dword [esp + 0x28]
push esi
push edx
call fcn.004f8710
mov esi, eax
mov eax, dword [esp + 0x3c]
push eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x20], 0
call fcn.004f8640
add esp, 8
test esi, esi
je 0x4efa3a
test eax, eax
je 0x4efa3a
inc eax
push edi
push eax
call fcn.00532ba7
mov edi, dword [esp + 0x40]
mov edx, eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x5c
mov eax, ecx
mov esi, edi
mov edi, edx
push edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov dword [esp + 0x2c], edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.00532b80
mov esi, eax
add esp, 0xc
test esi, esi
je 0x4ef9dc
mov byte [esi], 0
inc esi
mov edi, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x18]
push 0
push ecx
push 0
push 0x20006
push 0
push 0
push 0
push edi
push edx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x4efa30
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x18]
push ebx
push ebp
push eax
push 0
push esi
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x4efa25
mov dword [esp + 0x1c], 1
mov edx, dword [esp + 0x18]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push edi
call fcn.00532b70
add esp, 4
pop edi
mov eax, dword [esp + 0x18]
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
Function at 0x4f15f0
Capabilities:
Enumerate files on windows

Disassembly:
sub esp, 0x140
push ebx
mov ebx, dword [esp + 0x154]
push ebp
push esi
mov esi, dword [ebx]
push edi
mov edi, dword [esp + 0x154]
xor ebp, ebp
test edi, edi
je 0x4f166f
push edi
call fcn.004f8640
add esp, 4
test eax, eax
jbe 0x4f166f
test esi, esi
je 0x4f162d
cmp esi, 0xffffffff
je 0x4f162d
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
lea eax, [esp + 0x10]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebx], esi
je 0x4f16b1
mov eax, dword [esp + 0x15c]
test eax, eax
je 0x4f165b
mov ecx, dword [esp + 0x10]
and ecx, 0x10
cmp cl, 0x10
je 0x4f166f
jmp 0x4f166a
mov edx, dword [esp + 0x158]
mov eax, dword [esp + 0x10]
test edx, eax
je 0x4f166f
mov ebp, 1
test esi, esi
je 0x4f16b1
cmp esi, 0xffffffff
je 0x4f16b1
test ebp, ebp
jne 0x4f16e8
mov eax, dword [esp + 0x15c]
mov edi, dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
lea eax, [esp + 0x10]
push eax
push esi
je 0x4f16be
call edi
test eax, eax
je 0x4f16b1
mov ecx, dword [esp + 0x10]
and ecx, 0x10
cmp cl, 0x10
jne 0x4f16e8
lea edx, [esp + 0x10]
push edx
push esi
call edi
test eax, eax
jne 0x4f1699
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x140
ret
call edi
test eax, eax
je 0x4f16b1
mov ebx, dword [esp + 0x158]
test dword [esp + 0x10], ebx
jne 0x4f16e8
lea ecx, [esp + 0x10]
push ecx
push esi
call edi
test eax, eax
jne 0x4f16cb
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x140
ret
lea edx, [esp + 0x3c]
push edx
call fcn.004f8640
inc eax
push eax
call fcn.004ef550
mov edx, eax
lea edi, [esp + 0x44]
or ecx, 0xffffffff
xor eax, eax
add esp, 8
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x140
ret

Function at 0x4f1750
Capabilities:
Create directory

Disassembly:
sub esp, 0xc
mov ecx, dword [esp + 0x14]
xor eax, eax
mov dword [esp + 4], eax
mov dword [esp + 8], eax
lea eax, [esp]
mov dword [esp], 0xc
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
add esp, 0xc
ret

Function at 0x4f30d0
Capabilities:
Resolve dns

Disassembly:
mov eax, dword [esp + 4]
push eax
call sub.WS2_32.dll_gethostbyname
test eax, eax
je 0x4f30e6
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
ret
or eax, 0xffffffff
ret

Function at 0x4f30f0
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x190
lea eax, [esp]
push esi
push eax
push 0x202
xor esi, esi
call sub.WS2_32.dll_WSAStartup
test eax, eax
jne 0x4f3140
mov ecx, dword [esp + 0x19c]
push ecx
call fcn.004f30d0
add esp, 4
cmp eax, 0xffffffff
je 0x4f313b
push eax
call sub.WS2_32.dll_inet_ntoa
mov esi, eax
push esi
call fcn.004f8640
push eax
push esi
call fcn.004f90f0
add esp, 0xc
mov esi, eax
call sub.WS2_32.dll_WSACleanup
mov eax, esi
pop esi
add esp, 0x190
ret
Function at 0x4f3160
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 4]
mov eax, dword [esp + 8]
cmp edx, 1
jle 0x4f317e
push esi
lea ecx, [esp + 0x18]
dec edx
mov esi, dword [ecx]
add ecx, 0xc
xor eax, esi
dec edx
jne 0x4f3173
pop esi
ret

Function at 0x4f3980
Capabilities:
Read .ini file

Disassembly:
push ebx
push ebp
push esi
push edi
push 0x400
call fcn.00532ba7
mov ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x40]
mov ecx, dword [esp + 0x28]
add esp, 4
mov esi, eax
mov eax, dword [esp + 0x30]
push ebx
push 0x400
push esi
push ebp
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
cmp eax, 0x3ff
jl 0x4f39ea
push esi
lea edi, [eax + 0x400]
call fcn.00532b70
push edi
call fcn.00532ba7
mov edx, dword [esp + 0x38]
add esp, 8
mov esi, eax
mov eax, dword [esp + 0x24]
push ebx
push edi
push esi
push ebp
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
dec edi
cmp eax, edi
jge 0x4f39ba
push esi
xor edi, edi
call fcn.004f8640
add esp, 4
test eax, eax
je 0x4f3a05
push eax
push esi
call fcn.004f90f0
add esp, 8
mov edi, eax
push esi
call fcn.00532b70
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x4f3a30
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x54
push esi
lea eax, [esp + 0x14]
push edi
push eax
mov dword [esp + 0x1c], 0x44
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
mov eax, dword [esp + 0x84]
xor edi, edi
cmp eax, edi
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], edi
mov dword [esp + 0x44], 1
je case.0x4f3a71.2
mov ecx, dword [esp + 0x7c]
lea eax, [ecx - 1]
cmp eax, 5
ja case.0x4f3a71.2
jmp dword [eax*4 + 0x4f3afc]
mov word [esp + 0x48], di
jmp 0x4f3aaa
mov word [esp + 0x48], 2
jmp 0x4f3aaa
mov word [esp + 0x48], 3
jmp 0x4f3aaa
mov word [esp + 0x48], 4
jmp 0x4f3aaa
mov word [esp + 0x48], 7
jmp 0x4f3aaa
mov word [esp + 0x48], 5
lea edx, [esp + 8]
mov ecx, dword [esp + 0x64]
lea eax, [esp + 0x18]
push edx
push eax
push edi
push edi
push edi
push 1
push edi
push edi
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov esi, eax
cmp esi, edi
je 0x4f3af4
cmp dword [esp + 0x70], edi
je 0x4f3ae0
mov edx, dword [esp + 8]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 8]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
call edi
mov ecx, dword [esp + 0xc]
push ecx
call edi
mov eax, esi
pop edi
pop esi
add esp, 0x54
ret
Function at 0x4f3c80
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
push esi
mov esi, dword [esp + 0x14]
test esi, esi
jne 0x4f3c93
xor eax, eax
pop esi
add esp, 8
ret
push esi
call fcn.004f9b90
add esp, 4
test eax, eax
jne 0x4f3ca5
pop esi
add esp, 8
ret
mov eax, dword [esi]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push edi
mov dword [esp + 0x10], 0
jne 0x4f3d1c
mov eax, dword [esp + 0x1c]
mov edi, dword [esi + 4]
cmp eax, ebx
mov dword [esp + 0x10], ebx
jle 0x4f3d4e
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
lea esi, [esp + 0x2c]
mov eax, dword [esi]
lea edx, [esp + 0x14]
push 0
push edx
lea ecx, [eax + 8]
mov eax, dword [eax + 4]
push eax
push ecx
push edi
call ebp
test eax, eax
je 0x4f3d08
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x4f3cd8
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 8
ret
pop edi
mov dword [esp + 0xc], 0
mov eax, dword [esp + 0xc]
pop ebp
pop ebx
pop esi
add esp, 8
ret
cmp eax, 2
jne 0x4f3d4e
mov eax, dword [esp + 0x1c]
mov esi, dword [esi + 4]
cmp eax, ebx
mov dword [esp + 0x10], ebx
jle 0x4f3d4e
lea edi, [esp + 0x2c]
lea ebx, [eax - 1]
mov eax, dword [edi]
mov edx, dword [esi]
mov ecx, dword [eax + 4]
add eax, 8
push ecx
push eax
mov ecx, esi
call dword [edx + 0x24]
add edi, 0xc
dec ebx
jne 0x4f3d37
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 8
ret

Function at 0x4f3e10
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
test ebx, ebx
push edi
jne 0x4f3e23
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
push ebx
call fcn.004f9b90
add esp, 4
test eax, eax
jne 0x4f3e35
pop edi
pop esi
pop ebp
pop ebx
ret
mov edi, dword [esp + 0x24]
test edi, edi
jg 0x4f3e44
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
mov eax, dword [ebx]
xor esi, esi
cmp eax, 1
jne 0x4f3e9b
mov ebx, dword [ebx + 4]
push edi
call fcn.00532ba7
add esp, 4
mov ebp, eax
lea eax, [esp + 0x18]
push esi
push eax
push edi
push ebp
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4f3e7e
push ebp
call fcn.00532b70
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov ecx, dword [esp + 0x18]
push ecx
push ebp
call fcn.004f90b0
push ebp
mov esi, eax
call fcn.00532b70
add esp, 0xc
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret
cmp eax, 2
jne 0x4f3edd
mov ebx, dword [ebx + 4]
lea edx, [edi + 8]
push edx
call fcn.004ef550
mov esi, eax
add esp, 4
lea ecx, [esi + 8]
mov dword [esi], 1
mov dword [esi + 4], edi
mov eax, dword [ebx]
push edi
push ecx
mov ecx, ebx
call dword [eax + 0x20]
test eax, eax
jne 0x4f3eda
push esi
call fcn.004ef610
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov dword [esi + 4], eax
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x4f3ff0
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
mov eax, dword [esp + 0x10]
push edi
push 0
push 0x20
push 2
push 0
push 0
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x4f4082
mov eax, dword [esp + 0x10]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push esi
mov dword [esp + 0x10], ebx
jle 0x4f4074
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
lea esi, [esp + 0x2c]
mov eax, dword [esi]
lea edx, [esp + 0x14]
push 0
push edx
lea ecx, [eax + 8]
mov eax, dword [eax + 4]
push eax
push ecx
push edi
call ebp
test eax, eax
je 0x4f406c
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x4f4035
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret
mov dword [esp + 0x10], 0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret

Function at 0x4f44a0
Capabilities:
Get file size
Read file on windows

Disassembly:
mov eax, dword [esp + 8]
push edi
push 0
push 0x20
push 3
push 0
push 3
push connect
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x4f4509
push ebx
lea ecx, [esp + 0x10]
push esi
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
lea edx, [ebx + 8]
push edx
call fcn.004ef550
add esp, 4
mov esi, eax
lea eax, [esp + 0x14]
push 0
push eax
lea ecx, [esi + 8]
push ebx
push ecx
push edi
mov dword [esi], 1
mov dword [esi + 4], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop esi
pop ebx
pop edi
ret
Function at 0x4f4830
Capabilities:
Get file size
Read file on windows

Disassembly:
sub esp, 0xc
push esi
mov esi, dword [esp + 0x18]
test esi, esi
jne 0x4f4846
mov eax, 1
pop esi
add esp, 0xc
ret
push esi
call fcn.004f9b90
add esp, 4
test eax, eax
jne 0x4f485d
mov eax, 1
pop esi
add esp, 0xc
ret
mov eax, dword [esi]
push ebx
push ebp
cmp eax, 1
push edi
mov dword [esp + 0x10], 1
jne 0x4f490d
mov esi, dword [esi + 4]
lea eax, [esp + 0x14]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebp, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 1
push 0
push 0
push esi
mov ebx, eax
call ebp
mov edi, eax
cmp edi, 0xffffffff
je 0x4f4975
cmp edi, ebx
jae 0x4f4975
mov eax, dword [esp + 0x38]
mov dword [esp + 0x10], 0
test eax, eax
je 0x4f4975
mov eax, dword [esp + 0x30]
test eax, eax
je 0x4f4975
lea ecx, [esp + 0x18]
push 0
push ecx
lea edx, [esp + 0x2c]
push 1
push edx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
push 0
push edi
push esi
mov ebx, eax
call ebp
test ebx, ebx
je 0x4f4975
mov al, byte [esp + 0x24]
test al, al
je 0x4f496d
cmp al, 0x1a
jne 0x4f4975
pop edi
mov dword [esp + 0xc], 1
mov eax, dword [esp + 0xc]
pop ebp
pop ebx
pop esi
add esp, 0xc
ret
cmp eax, 2
jne 0x4f4975
mov esi, dword [esi + 4]
mov ecx, esi
call fcn.004f9f10
mov ebx, eax
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x14]
mov edi, eax
cmp edi, ebx
jae 0x4f4975
mov eax, dword [esp + 0x38]
mov dword [esp + 0x10], 0
test eax, eax
je 0x4f4975
mov eax, dword [esp + 0x30]
test eax, eax
je 0x4f4975
mov edx, dword [esi]
lea eax, [esp + 0x24]
push 1
push eax
mov ecx, esi
call dword [edx + 0x20]
mov edx, dword [esi]
push 0
push edi
mov ecx, esi
mov ebp, eax
call dword [edx + 0x18]
test ebp, ebp
je 0x4f4975
mov al, byte [esp + 0x24]
test al, al
je 0x4f496d
cmp al, 0x1a
jne 0x4f4975
mov dword [esp + 0x10], 1
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 0xc
ret
Function at 0x4f4990
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1c]
test esi, esi
push edi
jne 0x4f49a9
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push esi
call fcn.004f9b90
add esp, 4
test eax, eax
jne 0x4f49be
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov eax, dword [esi]
xor edi, edi
cmp eax, 1
jne 0x4f4afe
mov edi, dword [esi + 4]
mov esi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push eax
push 0
push 0
push edi
mov dword [esp + 0x24], edi
call esi
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x4f49fc
push 2
push 0
push 0
push edi
call esi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push 0x1000
xor ebp, ebp
call fcn.005332d6
add esp, 4
mov ebx, eax
lea eax, [esp + 0x20]
mov esi, ebx
push ebp
push eax
push 0x1000
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4f4ade
mov edx, dword [esp + 0x20]
xor ecx, ecx
test edx, edx
jle 0x4f4a44
mov al, byte [esi]
cmp al, 0xd
je 0x4f4a86
cmp al, 0xa
je 0x4f4a86
inc ecx
inc esi
cmp ecx, edx
jl 0x4f4a34
add ebp, edx
cmp edx, 0x1000
jl 0x4f4a88
push 0x1000
push ebx
call fcn.00533ad6
mov ebx, eax
mov eax, dword [esp + 0x28]
add esp, 8
cmp eax, 0x1000
jne 0x4f4a88
lea ecx, [esp + 0x20]
push 0
lea esi, [ebx + ebp]
push ecx
push 0x1000
push esi
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4f4ade
jmp 0x4f4a2a
add ebp, ecx
lea edx, [ebp + 1]
push edx
call fcn.004ef550
mov ecx, dword [esp + 0x14]
mov edi, eax
mov al, byte [esi]
add esp, 4
add ecx, ebp
cmp al, 0xd
je 0x4f4aa6
cmp al, 0xa
jne 0x4f4aaf
mov al, byte [esi + 1]
inc ecx
cmp al, 0xa
jne 0x4f4aaf
inc ecx
mov eax, dword [esp + 0x14]
push 0
push 0
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebp
push ebx
push edi
call fcn.00533410
push ebx
mov byte [edi + ebp], 0
call fcn.005331ed
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
push 2
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebx
call fcn.005331ed
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp eax, 2
jne 0x4f4b8c
mov esi, dword [esi + 4]
mov ecx, esi
mov edx, dword [esi]
call dword [edx + 0x14]
lea ecx, [esp + 0x10]
lea edx, [esp + 0x20]
push ecx
mov dword [esp + 0x18], eax
mov eax, dword [esi]
push edx
push 0xffffffffffffffff
push 0
mov ecx, esi
call dword [eax + 0x30]
mov ebp, dword [esp + 0x20]
xor ebx, ebx
test eax, eax
jle 0x4f4b47
mov cl, byte [ebp]
cmp cl, 0xd
je 0x4f4b47
cmp cl, 0xa
je 0x4f4b47
inc ebx
inc ebp
cmp ebx, eax
jl 0x4f4b34
lea eax, [ebx + 1]
push eax
call fcn.004ef550
mov ecx, dword [esp + 0x18]
mov edi, eax
mov al, byte [ebp]
add esp, 4
add ecx, ebx
cmp al, 0xd
je 0x4f4b66
cmp al, 0xa
jne 0x4f4b6f
mov al, byte [ebp + 1]
inc ecx
cmp al, 0xa
jne 0x4f4b6f
inc ecx
mov edx, dword [esi]
push 0
push ecx
mov ecx, esi
call dword [edx + 0x18]
mov eax, dword [esp + 0x20]
push ebx
push eax
push edi
call fcn.00533410
add esp, 0xc
mov byte [ebx + edi], 0
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x4f51b0
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1c]
test esi, esi
push edi
jne 0x4f51c9
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push esi
call fcn.004f9b90
add esp, 4
test eax, eax
jne 0x4f51de
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ebp, dword [esp + 0x2c]
test ebp, ebp
jg 0x4f51f0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [esi]
mov dword [esp + 0x20], 0
cmp eax, 1
jne 0x4f52ce
mov edi, dword [esi + 4]
push eax
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x10], ebx
jne 0x4f5227
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push 0
push edi
mov dword [esp + 0x28], 1
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
sub esi, ebp
sub esi, ebx
test esi, esi
jle 0x4f52bb
push esi
call fcn.00532ba7
add esp, 4
mov ebx, eax
push 1
push 0
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push edi
call ebp
lea eax, [esp + 0x14]
push 0
push eax
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4f5282
push ebx
call fcn.00532b70
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ecx, dword [esp + 0x10]
push 0
push 0
push ecx
push edi
call ebp
lea edx, [esp + 0x14]
push 0
push edx
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4f52a6
mov dword [esp + 0x20], eax
push ebx
call fcn.00532b70
mov eax, dword [esp + 0x24]
add esp, 4
test eax, eax
je 0x4f5343
push edi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp eax, 2
jne 0x4f5343
mov esi, dword [esi + 4]
mov ecx, esi
mov eax, dword [esi]
call dword [eax + 0x14]
mov ecx, esi
mov ebx, eax
call fcn.004f9f10
mov edi, eax
mov dword [esp + 0x20], 1
sub edi, ebp
sub edi, ebx
test edi, edi
jle 0x4f533b
mov edx, dword [esi]
push 1
push ebp
mov ecx, esi
call dword [edx + 0x18]
push edi
call fcn.00532ba7
add esp, 4
mov ebp, eax
mov eax, dword [esi]
mov ecx, esi
push edi
push ebp
call dword [eax + 0x20]
mov edx, dword [esi]
push 0
push ebx
mov ecx, esi
call dword [edx + 0x18]
mov eax, dword [esi]
push edi
push ebp
mov ecx, esi
call dword [eax + 0x24]
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x14]
push ebp
mov ebx, eax
call fcn.00532b70
add esp, 4
mov eax, dword [esi]
push ebx
mov ecx, esi
call dword [eax + 0x1c]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x4f5350
Capabilities:
Check if file exists
Get common file path

Disassembly:
mov eax, dword [esp + 0x10]
sub esp, 0x208
test eax, eax
push ebx
push esi
push edi
jne 0x4f537b
lea eax, [esp + 0xc]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
jne 0x4f53a3
mov byte [esp + 0xc], al
jmp 0x4f53a3
mov edi, dword [esp + 0x21c]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xc]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0xc]
push ecx
call fcn.004f8640
mov cl, byte [esp + eax + 0xf]
lea eax, [esp + eax + 0x10]
add esp, 4
cmp cl, 0x5c
je 0x4f53c0
mov byte [eax], 0x5c
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
mov edi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
call edi
lea edx, [esp + 0xc]
push eax
push edx
lea eax, [esp + 0x118]
push str._s_x.tmp
push eax
call esi
add esp, 0x10
lea ecx, [esp + 0x110]
push ecx
call ebx
test eax, eax
jne 0x4f53d2
lea edx, [esp + 0x110]
push edx
call fcn.004f8640
inc eax
push eax
call fcn.004ef550
mov edx, eax
lea edi, [esp + 0x118]
or ecx, 0xffffffff
xor eax, eax
add esp, 8
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebx
add esp, 0x208
ret