joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10005970
Capabilities:
Create http request
Read data from internet
Receive data

Disassembly:
push 0xffffffffffffffff
push 0x10006cab
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x224
push ebx
xor ebx, ebx
push edi
push ebx
push ebx
push ebx
push ebx
push str.iexplore
mov dword [esp + 0x20], ebx
call dword [sym.imp.WININET.dll_InternetOpenW]
mov edi, eax
cmp edi, ebx
mov dword [esp + 0x14], edi
je 0x10005ad5
mov eax, dword [esp + 0x23c]
push esi
push ebx
push ebx
push ebx
push ebx
push eax
push edi
call dword [sym.imp.WININET.dll_InternetOpenUrlW]
mov esi, eax
cmp esi, ebx
mov dword [esp + 0xc], esi
je 0x10005ab4
lea ecx, [esp + 0x1c]
push ebx
lea edx, [esp + 0x2c]
push ecx
push edx
push 5
push esi
mov dword [esp + 0x30], 0x208
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
je 0x10005aad
lea eax, [esp + 0x28]
push ebp
push eax
call dword [sym.imp.MSVCRT.dll__wtol]
mov ebp, eax
mov dword [esp + 0x1c], ebx
lea esi, [ebp + 1]
push esi
mov dword [esp + 0x30], esi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov ecx, esi
mov ebx, eax
mov edx, ecx
xor eax, eax
mov edi, ebx
add esp, 8
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
mov dword [esp + 0x24], ebx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x18]
push eax
push ebp
push ebx
push ecx
mov dword [esp + 0x24c], 0
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
pop ebp
je 0x10005a98
push esi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov edx, eax
add esp, 4
test edx, edx
mov dword [esp + 0x10], edx
je 0x10005a98
mov ecx, esi
xor eax, eax
mov edi, edx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, esi
and ecx, 3
rep stosb byte es:[edi], al
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
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]
push ebx
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x10]
mov ebx, dword [esp + 0x14]
add esp, 4
push esi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
push edi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
pop esi
mov eax, ebx
pop edi
pop ebx
mov ecx, dword [esp + 0x224]
mov dword fs:[0], ecx
add esp, 0x230
ret
mov ecx, dword [esp + 0x22c]
mov eax, ebx
pop edi
pop ebx
mov dword fs:[0], ecx
add esp, 0x230
ret
Function at 0x10005b50
Capabilities:
Create thread
Query or enumerate registry value
Read .ini file

Disassembly:
sub esp, 0x218
push ebx
push esi
mov esi, ecx
push str._ftlive.dll__update_do
call fcn.10001880
mov eax, dword [esi]
add esp, 4
test eax, eax
je 0x10005b90
push 0
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
je 0x10005ca9
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi], 0
lea ecx, [esp + 0x14]
push edi
lea edx, [esp + 0x10]
push ecx
push edx
push 0
push str.PreCheckDay
push str.SoftwareFeiteng5
push SysReAllocStringLen
mov dword [esp + 0x24], 0
mov dword [esp + 0x30], 4
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
lea eax, [esp + 0xc]
push eax
call dword [sym.imp.MSVCRT.dll_time]
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
push ecx
push edx
call dword [sym.imp.MSVCRT.dll_difftime]
fmul qword [0x100072f8]
add esp, 0xc
call sub.MSVCRT.dll__ftol
mov ebx, eax
mov ax, word [0x1000b448]
mov word [esp + 0x1c], ax
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0x1e]
rep stosd dword es:[edi], eax
push 0x104
lea ecx, [esp + 0x20]
push 0x1000bb84
push ecx
stosw word es:[edi], ax
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
mov edi, dword [sym.imp.MSVCRT.dll_wcsncat]
push 0x104
lea edx, [esp + 0x20]
push 0x100090d8
push edx
call edi
push 0x104
lea eax, [esp + 0x2c]
push str.pgkl.cab
push eax
call edi
add esp, 0x18
lea ecx, [esp + 0x1c]
push ecx
push 1
push str.span
push str.New_0
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
mov ecx, eax
mov eax, ebx
cdq
xor eax, edx
pop edi
sub eax, edx
cmp eax, ecx
jl 0x10005ca9
push ebx
push str.span___d_n
call fcn.10001880
lea edx, [esp + 0x18]
mov dword [esp + 0x18], 0
push edx
push 0
push esi
push 0x10005d80
push 0
push 0
call dword [sym.imp.MSVCRT.dll__beginthreadex]
add esp, 0x20
mov dword [esi], eax
mov eax, 1
pop esi
pop ebx
add esp, 0x218
ret
pop esi
xor eax, eax
pop ebx
add esp, 0x218
ret

Function at 0x10005cc0
Capabilities:
Delete registry key

Disassembly:
push 0xffffffffffffffff
push 0x10006cc8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xc
mov dword [esp + 4], 0
lea eax, [esp + 8]
lea ecx, [esp]
push eax
push ecx
push 0
push 0xf003f
push 0
push 0
push 0
push str.SoftwareFeitengRight
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x38], 0
mov dword [esp + 0x24], 0
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x10005d5d
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push esi
mov esi, dword [esp + 8]
test esi, esi
je 0x10005d30
push esi
call ebx
xor esi, esi
push str.SoftwareFeitengRight
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
test esi, esi
je 0x10005d47
push esi
call ebx
pop esi
mov eax, 1
pop ebx
mov ecx, dword [esp + 0xc]
mov dword fs:[0], ecx
add esp, 0x18
ret
push eax
push str._ftopt.exe__create_key_return__d_n
call fcn.10001880
mov ecx, dword [esp + 0x14]
add esp, 8
xor eax, eax
mov dword fs:[0], ecx
add esp, 0x18
ret
Function at 0x10006870
Capabilities:
Terminate thread

Disassembly:
push esi
mov esi, ecx
mov eax, dword [esi]
test eax, eax
je 0x10006894
push 0
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x10006894
mov eax, dword [esi]
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
pop esi
ret

Function at 0x401090
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
mov ebp, esp
push esi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x4032ec], eax
mov eax, dword [ebp + 4]
mov dword [0x40313a], eax
xor eax, eax
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
xor eax, eax
mov ecx, 0x16
push eax
dec ecx
jne 0x4010bb
push 0x7f00
push esi
call dword [sym.imp.USER32.dll_LoadIconA]
push 0x7f00
push esi
call dword [sym.imp.USER32.dll_LoadCursorA]
lea ecx, [ebp - 0x5c]
push ecx
mov eax, 0x30
mov dword [ecx], eax
mov eax, dword [0x40313a]
mov dword [ebp - 0x48], eax
mov eax, 0x4021c7
mov dword [ebp - 0x54], eax
mov ecx, 0x4031e6
mov dword [ebp - 0x34], ecx
call dword [sym.imp.USER32.dll_RegisterClassExA]
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
push 0
push 0
push str.Riched32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
xor ecx, ecx
push ecx
push dword [0x40313a]
push ecx
push ecx
push 0x12e
push 0x7a
push 0x34c
push 0x2aa
push 0x40000
lea eax, str.bananas
push eax
mov eax, str.secondclass
push eax
push ecx
call dword [sym.imp.USER32.dll_CreateWindowExW]
mov dword [0x403338], eax
push 0
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [0x403338]
push eax
call dword [sym.imp.USER32.dll_UpdateWindow]
xor ebx, ebx
lea edi, [ebp - 0x50]
jmp 0x401179
push edi
call dword [sym.imp.USER32.dll_TranslateMessage]
push edi
call dword [sym.imp.USER32.dll_DispatchMessageA]
push ebx
push ebx
push ebx
push edi
call dword [sym.imp.USER32.dll_GetMessageA]
test al, al
jne 0x40116b
mov esp, ebp
ret
Function at 0x403683
Capabilities:
Get file size
Read file via mapping

Disassembly:
push 0x21c
mov eax, 0x4204a2
call fcn.0040944e
mov edi, ecx
mov eax, dword [ebp + 8]
xor ecx, ecx
inc ecx
mov byte [edi + 0x14], cl
lea ecx, [ebp - 0x224]
push eax
call fcn.00402fc3
push ecx
push ecx
xor ebx, ebx
mov edx, esp
mov dword [ebp - 4], ebx
mov eax, dword [eax]
mov ecx, dword [eax + 8]
add eax, 0xc
mov dword [edx + 4], ecx
lea ecx, [ebp - 0x220]
mov dword [edx], eax
call fcn.00406101
pop ecx
pop ecx
mov byte [ebp - 4], 2
xor dl, dl
mov ecx, dword [ebp - 0x224]
call fcn.00402740
mov cl, byte [edi + 0x14]
xor eax, eax
mov edx, dword [ebp - 0x220]
or dword [edi + 4], 0xffffffff
add edx, 0xc
or dword [edi + 8], 0xffffffff
test cl, cl
push ebx
push 0x80
setne al
mov dword [edi + 0xc], ebx
add eax, 2
test cl, cl
push eax
push ebx
push 3
pop eax
push 1
pop esi
cmovne eax, esi
mov esi, 0x80000000
push eax
mov eax, 0xc0000000
cmovne eax, esi
push eax
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [edi + 4], eax
cmp eax, 0xffffffff
je 0x403823
cmp byte [0x439ba4], bl
jne 0x403740
call fcn.00403a7a
mov esi, dword [0x439b9c]
test esi, esi
je 0x40379e
push 0x208
lea eax, [ebp - 0x21c]
push ebx
push eax
call fcn.0040a780
add esp, 0xc
cmp byte [0x439ba4], 0
jne 0x403773
call fcn.00403a7a
mov esi, dword [0x439b9c]
push ebx
push 0x104
lea eax, [ebp - 0x21c]
push eax
push dword [edi + 4]
call esi
push ecx
push ecx
lea edx, [ebp - 0x214]
mov ecx, esp
call fcn.00401143
lea ecx, [edi + 0x18]
call fcn.00403089
jmp 0x4037ad
lea eax, [ebp - 0x220]
push eax
lea ecx, [edi + 0x18]
call fcn.00403bda
push ebx
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov cl, byte [edi + 0x14]
xor edx, edx
push ebx
mov dword [edi + 0x10], eax
test cl, cl
mov eax, 0x10000000
cmovne eax, edx
push eax
push ebx
push 4
pop eax
push 2
pop esi
cmovne eax, esi
push eax
push ebx
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
cmp dword [edi + 4], 0xffffffff
mov dword [edi + 8], eax
je 0x4037f6
test eax, eax
jne 0x4037fa
mov ecx, edi
call fcn.0040383a
jmp 0x403823
test eax, eax
je 0x403812
cmp byte [edi + 0x14], 0
push ebx
push ebx
push ebx
push 4
pop ecx
cmovne esi, ecx
push esi
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [edi + 0xc], eax
mov ebx, dword [edi + 0xc]
test ebx, ebx
jne 0x403823
mov ecx, edi
call fcn.0040383a
mov ebx, dword [edi + 0xc]
mov ecx, dword [ebp - 0x220]
xor dl, dl
call fcn.00402740
mov eax, ebx
call fcn.0040940c
ret 8
Function at 0x403a7a
Capabilities:
Get common file path

Disassembly:
push 0x210
mov eax, 0x42054f
call fcn.0040944e
cmp byte [0x439ba4], 0
je 0x403aa1
cmp dword [0x439b9c], 0
setne al
jmp 0x403ba7
push dword [0x439b94]
lea ecx, [ebp - 0x21c]
mov byte [0x439ba4], 1
call fcn.00402fc3
xor ebx, ebx
mov dword [ebp - 4], ebx
call fcn.00403602
push ebx
lea ecx, [ebp - 0x21c]
push ecx
mov ecx, eax
call fcn.00403cce
test eax, eax
je 0x403ae2
mov eax, dword [eax]
mov dword [0x439ba0], eax
jmp 0x403b65
xor eax, eax
push ebx
mov word [ebp - 0x218], ax
lea eax, [ebp - 0x218]
push 0x25
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x403b98
push 0x427d10
mov esi, 0x104
lea eax, [ebp - 0x218]
push esi
push eax
call fcn.00410aa7
push dword [0x439b94]
lea eax, [ebp - 0x218]
push esi
push eax
call fcn.00410aa7
add esp, 0x18
lea eax, [ebp - 0x218]
push 8
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov esi, eax
mov dword [0x439ba0], esi
call fcn.00403602
push 1
lea ecx, [ebp - 0x21c]
push ecx
mov ecx, eax
call fcn.00403cce
mov dword [eax], esi
mov eax, dword [0x439ba0]
test eax, eax
je 0x403b8e
push dword [0x439b98]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x439b9c], eax
test eax, eax
jne 0x403b95
mov eax, ebx
mov dword [0x439ba0], ebx
mov dword [0x439b9c], eax
jmp 0x403b93
mov eax, dword [0x439b9c]
test eax, eax
setne bl
mov ecx, dword [ebp - 0x21c]
xor dl, dl
call fcn.00402740
mov al, bl
call fcn.0040940c
ret
Function at 0x404a8c
Capabilities:
Enumerate files on windows
Enumerate files recursively

Disassembly:
push 0x27c
mov eax, 0x420653
call fcn.0040944e
push ecx
push ecx
mov ecx, esp
xor edi, edi
mov dword [ebp - 4], edi
mov eax, dword [ebp + 8]
mov dword [ecx], eax
mov eax, dword [ebp + 0xc]
mov dword [ecx + 4], eax
lea ecx, [ebp - 0x26c]
call fcn.004052b2
push str..
lea ecx, [ebp - 0x268]
mov byte [ebp - 4], 1
call fcn.00402fc3
lea ecx, [ebp - 0x26c]
mov byte [ebp - 4], 2
call fcn.00402655
test eax, eax
jne 0x404af5
lea eax, [ebp - 0x268]
push eax
lea ecx, [ebp - 0x270]
call fcn.00403bad
jmp 0x404b3a
lea ecx, [ebp - 0x268]
call fcn.00402655
test eax, eax
jne 0x404b0c
lea eax, [ebp - 0x26c]
jmp 0x404ae7
push ecx
push ecx
push esp
lea ecx, [ebp - 0x268]
call fcn.00404f23
mov eax, dword [ebp - 0x26c]
push ecx
push ecx
mov edx, esp
mov ecx, dword [eax + 8]
add eax, 0xc
mov dword [edx + 4], ecx
lea ecx, [ebp - 0x270]
mov dword [edx], eax
call fcn.00405a62
mov eax, dword [ebp - 0x270]
lea ecx, [ebp - 0x264]
add eax, 0xc
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ecx, dword [ebp - 0x270]
mov esi, eax
xor dl, dl
mov dword [ebp - 0x274], esi
call fcn.00402740
mov byte [ebp - 4], 1
xor dl, dl
mov ecx, dword [ebp - 0x268]
call fcn.00402740
cmp esi, 0xffffffff
je 0x404c73
mov ebx, edi
test byte [ebp - 0x264], 6
jne 0x404c54
cmp word [ebp - 0x238], 0x2e
je 0x404c54
mov eax, dword [ebp - 0x26c]
lea ecx, [ebp - 0x238]
push ecx
add eax, 0xc
push eax
lea eax, [ebp - 0x268]
push 0x427e74
push eax
call fcn.00404f42
add esp, 0x10
mov byte [ebp - 4], 3
test byte [ebp - 0x264], 0x10
je 0x404c15
sub esp, 0x28
mov esi, esp
mov dword [ebp - 0x278], esi
mov dword [esi + 0x24], edi
mov byte [ebp - 4], 4
mov ecx, dword [ebp + 0x34]
test ecx, ecx
je 0x404bf0
mov eax, dword [ecx]
push esi
call dword [eax]
mov dword [esi + 0x24], eax
mov byte [ebp - 4], 3
mov esi, dword [ebp - 0x268]
push ecx
push ecx
mov edx, esp
mov ecx, dword [esi + 8]
lea eax, [esi + 0xc]
mov dword [edx], eax
mov dword [edx + 4], ecx
call fcn.00404a8c
add esp, 0x30
add ebx, eax
jmp 0x404c41
mov esi, dword [ebp - 0x268]
inc ebx
mov ecx, dword [esi + 8]
lea eax, [esi + 0xc]
mov dword [ebp - 0x280], ecx
mov ecx, dword [ebp + 0x34]
mov dword [ebp - 0x284], eax
test ecx, ecx
je 0x404c90
mov eax, dword [ecx]
lea edx, [ebp - 0x284]
push edx
call dword [eax + 8]
xor dl, dl
mov byte [ebp - 4], 1
mov ecx, esi
call fcn.00402740
mov esi, dword [ebp - 0x274]
lea eax, [ebp - 0x264]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x404b82
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov edi, ebx
mov ecx, dword [ebp - 0x26c]
xor dl, dl
call fcn.00402740
lea ecx, [ebp + 0x10]
call fcn.00404ce1
mov eax, edi
call fcn.0040940c
ret
call fcn.0040847d
int3
Function at 0x4122e8
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x412327
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x412327
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x412327
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x412327
cmp dword [ecx + 0x74], 0xe
jbe 0x412327
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x415ea4
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4246d8
push 0x4246d0
push str.FlsAlloc
push 0x1f
call fcn.00415d82
mov esi, eax
add esp, 0x10
test esi, esi
je 0x415ed8
push dword [ebp + 8]
mov ecx, esi
call dword [0x421170]
call esi
jmp 0x415ede
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x415f22
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4246e8
push 0x4246e0
push str.FlsGetValue
push 0x21
call fcn.00415d82
mov esi, eax
add esp, 0x10
test esi, esi
je 0x415f59
push dword [ebp + 8]
mov ecx, esi
call dword [0x421170]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x415f61
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4246f0
push 0x4246e8
push str.FlsSetValue
push 0x22
call fcn.00415d82
mov esi, eax
add esp, 0x10
test esi, esi
je 0x415f9b
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x421170]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x417a9c
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.00417a18
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x417c0b
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x417c0b
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x417bc0
jg 0x417af8
test eax, eax
je 0x417bb6
push 1
push 0x1000
call fcn.004140e6
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x417b1b
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x417bad
push 0x8000
push ebx
call fcn.00413710
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x417b44
jg 0x417b3f
cmp ecx, 0x1000
jb 0x417b44
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.004173c8
add esp, 0x10
cmp eax, 0xffffffff
je 0x417b89
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x417b3f
jl 0x417b70
test ecx, ecx
jne 0x417b31
push dword [ebp - 0xc]
push ebx
call fcn.00413710
push esi
call fcn.0041405e
add esp, 0xc
xor ebx, ebx
jmp 0x417c19
cmp byte [edi + 0x24], 0
je 0x417ba0
cmp dword [edi + 0x20], 5
jne 0x417ba0
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x417bab
mov ebx, dword [edi + 0x18]
jmp 0x417bad
xor ebx, ebx
push esi
call fcn.0041405e
pop ecx
jmp 0x417c19
test ecx, ecx
jg 0x417b82
jl 0x417bc0
test eax, eax
jae 0x417b82
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00418886
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x417be0
cmp byte [edi + 0x1c], 0
je 0x417b82
jmp 0x417c11
push ebx
call fcn.004179ae
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x417b82
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x417c19
cmp byte [edi + 0x1c], 0
je 0x417c16
mov ebx, dword [edi + 0x18]
jmp 0x417c19
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.00418886
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x417e37
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x43aa70]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x417e77
cmp byte [ebx], 0xa
jne 0x417e77
or byte [edi + eax + 0x28], 4
jmp 0x417e7c
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x417f7b
mov dl, byte [eax]
cmp dl, 0x1a
je 0x417f5e
inc eax
cmp dl, 0xd
je 0x417ea8
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x417ece
cmp eax, ecx
jae 0x417edc
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x417e90
jmp 0x417f7b
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x417f59
cmp dword [ebp - 0x10], 0
je 0x417f59
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x43aa70]
test byte [eax + edi + 0x28], 0x48
je 0x417f33
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x417f1e
mov byte [esi], dl
jmp 0x417f2f
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x43aa70]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x417f7b
cmp byte [ebp - 1], 0xa
jne 0x417f42
cmp esi, ebx
jne 0x417f42
mov byte [esi], 0xa
jmp 0x417f7a
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00418886
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x417f7b
mov byte [esi], 0xd
jmp 0x417f7a
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x43aa70]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x417f78
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x417f7b
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x417f84
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x43aa70]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x417fca
cmp word [ebx], dx
jne 0x417fca
or byte [eax + edi + 0x28], 4
jmp 0x417fcf
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x418132
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x418112
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x418010
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x418046
cmp eax, edx
jae 0x418054
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x417feb
jmp 0x418132
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41810d
cmp dword [ebp - 0x18], 0
je 0x41810d
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x43aa70]
test byte [eax + edi + 0x28], 0x48
je 0x4180e3
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x4180a7
mov word [esi], cx
jmp 0x4180de
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x43aa70]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x43aa70]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x43aa70]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x418132
pop eax
cmp word [ebp - 4], ax
jne 0x4180f3
cmp esi, ebx
jne 0x4180f3
mov word [esi], ax
jmp 0x41812f
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00418886
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x418132
push 0xd
pop eax
jmp 0x4180ee
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x43aa70]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x41812c
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x418132
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret