joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40aa93
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x64
push ebx
push esi
push edi
push 0x44
pop edi
push edi
lea eax, [ebp - 0x60]
mov esi, ecx
push 0
push eax
mov ebx, edx
mov dword [ebp - 4], esi
call fcn.004193f0
mov dword [ebp - 0x60], edi
lea eax, [ebp - 0x18]
push 0x10
xor edi, edi
push 0
inc edi
push eax
mov word [ebp - 0x30], di
call fcn.004193f0
and dword [ebp - 0x18], 0
add esp, 0x18
call fcn.0040aa18
test eax, eax
je 0x40aaff
push dword [ebp + 0x14]
lea eax, [ebp - 0x18]
mov edx, ebx
push dword [ebp + 0x10]
push ecx
push eax
lea eax, [ebp - 0x60]
mov ecx, esi
push eax
push dword [ebp + 8]
sub esp, 0x14
call fcn.0040aa27
add esp, 0x2c
jmp 0x40aba4
push esi
call fcn.0041c299
push ebx
mov esi, eax
call fcn.0041c299
add esi, eax
pop ecx
pop ecx
lea eax, [esi*2 + 4]
call fcn.0042da30
mov esi, esp
push dword [ebp - 4]
mov dword [ebp - 8], esi
push esi
call fcn.0041c2f7
push 0x43e830
push esi
call fcn.0041f328
push ebx
push esi
call fcn.0041f328
mov esi, dword [ebp + 8]
add esp, 0x18
xor ebx, ebx
test esi, esi
je 0x40ab58
cmp word [esi], bx
je 0x40ab58
push esi
call fcn.0041c299
pop ecx
lea edi, [eax + 1]
lea eax, [edi + edi]
call fcn.0042da30
mov edi, esp
test esi, esi
je 0x40ab71
push esi
push edi
call fcn.0041c2f7
pop ecx
pop ecx
jmp 0x40ab76
xor eax, eax
mov word [edi], ax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x60]
push eax
xor eax, eax
test esi, esi
cmovne eax, edi
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push dword [ebp - 8]
push ebx
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
cmp dword [ebp - 0x14], 0
je 0x40aba4
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x18]
lea esp, [ebp - 0x70]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x40b474
Capabilities:
Read .ini file

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2008
call fcn.0042dca0
push esi
push edi
push 0xc
mov edi, ecx
call fcn.004187d8
xor ecx, ecx
mov dword [eax], ecx
mov dword [eax + 4], ecx
mov dword [eax + 8], ecx
push dword [edi + 0xc]
mov dword [ebp - 4], eax
lea eax, [ebp - 8]
push str.R_03d
push eax
call fcn.0040b565
add esp, 0x10
lea ecx, [edi + 0x24]
call fcn.00408bd5
push eax
push 0x1000
lea eax, [ebp - 0x2008]
mov esi, 0x43e9f0
push eax
push esi
lea ecx, [ebp - 8]
call fcn.00408bd5
push eax
lea ecx, [edi + 0x20]
call fcn.00408bd5
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [ebp - 0x2008]
push esi
push eax
call fcn.0041e50b
mov esi, dword [ebp + 8]
pop ecx
pop ecx
test eax, eax
jne 0x40b509
mov eax, dword [ebp - 4]
mov edx, esi
push ecx
add eax, 8
push eax
call fcn.00401ceb
pop ecx
pop ecx
jmp 0x40b531
mov ecx, dword [ebp - 4]
lea eax, [ebp - 0x2008]
push eax
add ecx, 8
call fcn.00408d56
push ecx
mov ecx, dword [ebp - 4]
mov edx, 0x43e9f8
push 0x43e934
lea ecx, [ecx + 8]
call fcn.00408fc1
mov eax, dword [ebp - 4]
push esi
add eax, 4
push 0x43e9fc
push eax
call fcn.004090cb
mov eax, dword [ebp - 4]
lea ecx, [edi + 4]
add esp, 0xc
mov dword [eax], esi
lea eax, [ebp - 4]
push eax
call fcn.00408ac0
lea ecx, [ebp - 8]
call fcn.00408bbc
pop edi
pop esi
leave
ret 4
Function at 0x40ce10
Capabilities:
Get thread local storage value

Disassembly:
test byte [esp + 0xc], 1
push ebx
push esi
mov ebx, ecx
jne 0x40ce63
push ebp
push edi
push dword [ebx + 0x30]
xor ebp, ebp
inc ebp
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
je 0x40ce32
mov ebp, dword [edi + 4]
mov ecx, dword [esp + 0x18]
push 0x68
pop esi
cmp ecx, esi
jbe 0x40ce4f
mov esi, 0x3e8
cmp ecx, esi
jbe 0x40ce4f
xor edx, edx
call fcn.0040cbb9
mov esi, eax
push esi
push edi
push ebp
mov ecx, ebx
call fcn.0040cd4e
mov ecx, eax
pop edi
pop ebp
test ecx, ecx
jne 0x40ce82
jmp 0x40ce67
mov esi, dword [esp + 0x10]
lea eax, [esi + 0x18]
push eax
call fcn.0041e3fb
pop ecx
mov ecx, eax
test ecx, ecx
jne 0x40ce7c
push 0x64
pop eax
jmp 0x40cea0
add ecx, 0x14
mov dword [ecx - 8], esi
xor eax, eax
mov dword [ecx - 0xc], 1
mov dword [ecx - 0x10], eax
mov dword [ecx - 4], eax
mov word [ecx], ax
mov word [ecx + esi], ax
mov eax, dword [esp + 0xc]
mov dword [eax], ecx
xor eax, eax
pop esi
pop ebx
ret 0xc

Function at 0x40ceb7
Capabilities:
Get thread local storage value

Disassembly:
test byte [esp + 0xc], 1
push ebx
mov ebx, dword [esp + 8]
push ebp
push esi
push edi
mov ebx, dword [ebx]
mov ebp, ecx
jne 0x40cf4f
push dword [ebp + 0x30]
mov dword [esp + 0x20], 1
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
test esi, esi
je 0x40ceec
mov eax, dword [esi + 4]
mov dword [esp + 0x1c], eax
mov ecx, dword [esp + 0x18]
push 0x68
pop edi
cmp ecx, edi
jbe 0x40cf0a
mov edi, 0x3e8
cmp ecx, edi
jbe 0x40cf0a
mov edx, dword [ebx - 8]
call fcn.0040cbb9
mov edi, eax
push edi
push esi
push dword [esp + 0x24]
mov ecx, ebp
call fcn.0040cd4e
mov esi, eax
test esi, esi
je 0x40cf53
mov edx, ebx
mov dword [esi - 0xc], 1
mov ecx, esi
call fcn.0040964d
mov ecx, dword [ebx - 4]
mov dword [esi - 4], ecx
push dword [ebx - 4]
push ebx
push esi
call fcn.00419550
and dword [ebx - 0xc], 0
add esp, 0xc
mov eax, dword [ebp]
mov ecx, ebp
push ebx
call dword [eax + 0xc]
jmp 0x40cf73
mov edi, dword [esp + 0x18]
lea eax, [edi + 0x18]
push eax
lea eax, [ebx - 0x14]
push eax
call fcn.0041ffd6
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x40cf6d
push 0x64
pop eax
jmp 0x40cf81
add esi, 0x14
mov dword [esi - 8], edi
mov eax, dword [esp + 0x14]
mov word [esi + edi], 0
mov dword [eax], esi
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret 0xc

Function at 0x40cf9a
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
mov ebx, ecx
push edi
test byte [esi - 0x10], 2
je 0x40cfbb
push dword [esi - 8]
push 0
push esi
call fcn.004193f0
add esp, 0xc
and dword [esi - 0x10], 0xfffffffd
push dword [ebx + 0x30]
xor edi, edi
inc edi
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x40cfce
mov edi, dword [eax + 4]
push esi
push eax
push edi
mov ecx, ebx
call fcn.0040cd86
test al, al
jne 0x40cfe6
lea eax, [esi - 0x14]
push eax
call fcn.0041e3f6
pop ecx
pop edi
pop esi
pop ebx
ret 4
Function at 0x40d136
Capabilities:
Get thread local storage value

Disassembly:
push esi
push dword [ecx + 0x30]
xor esi, esi
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x40d149
mov esi, dword [eax + 0x1c]
mov edx, dword [esp + 8]
sub esi, 1
pop esi
push ecx
push dword [esp + 0xc]
je 0x40d15f
call fcn.0040d6f5
jmp 0x40d167
lea ecx, [eax + 0x20]
call fcn.0040d6b0
pop ecx
pop ecx
ret 0xc

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

Disassembly:
push esi
push dword [esp + 8]
mov esi, ecx
push dword [esi + 0x478]
call fcn.00411591
mov dword [esi + 0x478], eax
movzx eax, al
add eax, dword [esi + 0x47c]
imul eax, eax, 0x8088405
inc eax
mov dword [esi + 0x47c], eax
shr eax, 0x18
push eax
push dword [esi + 0x480]
call fcn.00411591
mov dword [esi + 0x480], eax
pop esi
ret 4

Function at 0x412156
Capabilities:
Hash data using djb2

Disassembly:
mov eax, dword [esp + 4]
push esi
mov esi, 0x4385c0
push edi
cmp dword [eax], 0
mov edi, 0x1505
cmovne esi, dword [eax]
movzx eax, word [esi]
test ax, ax
je 0x412190
push eax
call fcn.0041ffc3
imul edi, edi, 0x21
lea esi, [esi + 2]
pop ecx
movzx ecx, ax
add edi, ecx
movzx ecx, word [esi]
mov eax, ecx
test cx, cx
jne 0x412174
mov eax, edi
pop edi
pop esi
ret 4

Function at 0x412535
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push 4
pop edx
movzx eax, cl
shr ecx, 8
xor ecx, dword [eax*4 + 0x439320]
sub edx, 1
jne 0x412538
mov eax, ecx
ret
Function at 0x41777b
Capabilities:
Create process on windows
Get common file path
Query or enumerate registry value

Disassembly:
mov eax, 0x2644
call fcn.0042dca0
push ebx
push ebp
push esi
push edi
mov edi, dword [sym.imp.USER32.dll_GetDlgItem]
mov ebx, ecx
xor ebp, ebp
push ebp
push 0x3eb
push dword [ebx + 0xc]
call edi
mov esi, dword [sym.imp.USER32.dll_ShowWindow]
push eax
call esi
push ebp
push 0x3ed
push dword [ebx + 0xc]
call edi
push eax
call esi
mov esi, 0x104
mov dword [esp + 0x14], ebp
cmp dword [ebx + 0x870], ebp
jne 0x417842
lea eax, [ebx + 0x434]
push eax
lea eax, [esp + 0x654]
push str.SoftwareMicrosoftWindowsCurrentVersionApp_Paths_s.exe
push eax
call fcn.0040a9aa
add esp, 0xc
lea eax, [esp + 0x14]
push eax
push 0x20019
push ebp
lea eax, [esp + 0x65c]
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x417842
lea eax, [esp + 0x18]
mov dword [esp + 0x18], esi
push eax
lea eax, [esp + 0x24]
push eax
lea eax, [esp + 0x24]
push eax
push ebp
push ebp
push dword [esp + 0x28]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x417838
mov edx, dword [ebx + 4]
lea ecx, [esp + 0x20]
add edx, 0x18
push ebp
call fcn.00405e84
pop ecx
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edi, [ebx + 0x63e]
cmp word [edi], bp
je 0x417942
push 0x20a
lea eax, [esp + 0x24]
push ebp
push eax
call fcn.004193f0
add esp, 0xc
lea eax, [esp + 0x20]
push esi
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [esp + 0x230]
call fcn.00404ebd
lea ecx, [esp + 0x230]
call fcn.00404881
lea eax, [esp + 0x230]
push edi
push eax
call fcn.0041f328
mov eax, dword [ebx + 4]
lea ecx, [esp + 0x28]
push ebp
push dword [eax + 8]
call fcn.00417d55
add esp, 0x10
cmp eax, 1
jne 0x4178c3
push 0x8920
call fcn.004187d8
pop ecx
mov ecx, eax
call fcn.0040e312
jmp 0x4178d5
push 0x328
call fcn.004187d8
pop ecx
mov ecx, eax
call fcn.0040f4a1
mov esi, eax
test esi, esi
je 0x417942
mov eax, dword [ebx + 4]
mov ecx, esi
mov edx, dword [esi]
push ebp
push dword [eax + 8]
lea eax, [esp + 0x28]
push ebp
push eax
call dword [edx + 4]
test eax, eax
jne 0x41793a
mov eax, dword [esi]
lea ecx, [esp + 0x230]
push ebp
push ebp
push ebp
push ebp
push ebp
push ecx
push edi
mov ecx, esi
call dword [eax + 0x1c]
test eax, eax
jne 0x41793a
lea eax, [esp + 0x440]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 1
lea eax, [esp + 0x444]
push eax
push ebp
lea eax, [esp + 0x23c]
push eax
push ebp
push ebp
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov eax, dword [esi]
mov ecx, esi
push 1
call dword [eax]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2644
ret
Function at 0x4181ad
Capabilities:
Create process on windows
Get common file path
Set environment variable

Disassembly:
sub esp, 0xc50
lea eax, [esp + 0x214]
push ebx
push ebp
push esi
push edi
push eax
lea eax, [esp + 0xa58]
mov edi, edx
push eax
lea edx, [esp + 0x850]
mov ebx, ecx
call fcn.00405e49
pop ecx
lea ecx, [esp + 0x228]
call fcn.004080d3
mov ebp, dword [esp + 0xc68]
pop ecx
mov ecx, dword [ebp + 4]
and ecx, 0x10
test eax, eax
je 0x41823a
test ecx, ecx
jne 0x418202
xor eax, eax
inc eax
jmp 0x41832e
lea eax, [esp + 0x430]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 1
lea eax, [esp + 0x434]
xor esi, esi
push eax
push esi
push ebx
push esi
push esi
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
xor ecx, ecx
cmp eax, 0x20
setg cl
mov eax, ecx
jmp 0x41832e
push 0x104
lea eax, [esp + 0x1c]
xor esi, esi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push ecx
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x644]
call fcn.00405301
pop ecx
pop ecx
test eax, eax
je 0x418279
lea eax, [esp + 0x63c]
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.0041c2f7
pop ecx
pop ecx
lea eax, [esp + 0x18]
push eax
push str.ZIP_SOURCE
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push edi
lea ecx, [esp + 0x18]
call fcn.00408ba7
cmp dword [ebp + 0x222], esi
jbe 0x4182b3
lea eax, [esp + 0x18]
push eax
push edi
lea eax, [esp + 0x1c]
push str._s__ZIP_SOURCE__s_
push eax
call fcn.004090cb
add esp, 0x10
mov eax, dword [0x44551c]
test eax, eax
je 0x4182be
mov esi, dword [eax]
push esi
push ecx
lea eax, [esp + 0x850]
push eax
lea ecx, [esp + 0x20]
call fcn.00408bd5
mov edx, eax
mov ecx, ebx
call fcn.0040abaf
add esp, 0xc
mov esi, eax
cmp dword [esp + 0xc68], 0
je 0x418317
mov edi, 0x103
mov dword [esp + 0x10], edi
lea eax, [esp + 0x10]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
neg eax
push 0x3e8
sbb eax, eax
and dword [esp + 0x14], eax
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [esp + 0x10], edi
je 0x4182f2
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x14]
call fcn.00408bbc
xor eax, eax
test esi, esi
setne al
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc50
ret

Function at 0x418339
Capabilities:
Delete directory
Read .ini file

Disassembly:
push esi
mov esi, ecx
call fcn.004051a3
test eax, eax
jne 0x40519b
pop esi
ret
mov ecx, esi
pop esi
jmp fcn.004047d6
push esi
push str.INSTALL.INI
push 0
push str.GARDETEMP
push str.INSTALL
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
cmp eax, 1
jne 0x41835a
pop esi
ret
mov ecx, esi
pop esi
jmp 0x40518d
Function at 0x42913b
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00428dfb
Function at 0x401ca0
Capabilities:
Enumerate processes

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x407393
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x278
mov eax, dword [0x40d040]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x27c], esi
mov dword [ebp - 0x280], esi
xorps xmm0, xmm0
mov dword [ebp - 0x27c], 1
movups xmmword [esi], xmm0
push 0x20
movups xmmword [esi + 0x10], xmm0
mov dword [esi], 0
mov dword [esi + 4], 0
mov dword [esi + 8], 0
call fcn.0040622c
add esp, 4
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [esi + 4], eax
lea ecx, [esi + 0xc]
mov dword [ebp - 4], 0
mov dword [ecx], 0
mov dword [ecx + 4], 0
mov dword [ecx + 8], 0
mov byte [ebp - 4], 1
push dword [esi + 4]
mov dword [esi + 0x18], 7
push 0x10
mov dword [esi + 0x1c], 8
mov dword [esi], 0x3f800000
call fcn.004051c0
push 0
mov dword [ebp - 4], 2
push 2
mov dword [ebp - 0x27c], 1
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov edi, eax
cmp edi, 0xffffffff
je 0x401e88
lea eax, [ebp - 0x278]
mov dword [ebp - 0x278], 0x22c
push eax
push edi
call dword [sym.imp.KERNEL32.dll_Process32FirstW]
test eax, eax
je 0x401e81
nop
lea eax, [ebp - 0x254]
push eax
lea ecx, [ebp - 0x44]
call fcn.00404850
lea edx, [ebp - 0x44]
mov dword [ebp - 4], 3
lea ecx, [ebp - 0x2c]
call fcn.00401740
lea eax, [ebp - 0x44]
mov byte [ebp - 4], 4
push eax
lea eax, [ebp - 0x288]
mov ecx, esi
push eax
call fcn.00405740
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x18]
cmp ecx, 0xf
jbe 0x401e1f
mov edx, dword [ebp - 0x2c]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x401e15
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401ea8
push ecx
push edx
call fcn.00406371
add esp, 8
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0xf
mov byte [ebp - 0x2c], 0
cmp ecx, 7
jbe 0x401e6b
mov edx, dword [ebp - 0x44]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x401e61
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401ea8
push ecx
push edx
call fcn.00406371
add esp, 8
lea eax, [ebp - 0x278]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
jne 0x401db0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0040621e
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
Function at 0x402a00
Capabilities:
Get session user name

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40774c
mov eax, dword fs:[0]
push eax
sub esp, 0x264
mov eax, dword [0x40d040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea eax, [ebp - 0x228]
mov dword [ebp - 0x228], 0x101
push eax
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
test eax, eax
je 0x402bce
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x240]
call fcn.00404850
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x270]
xorps xmm0, xmm0
mov dword [ebp - 0x21c], 0
push str.runneradmin
movq qword [ebp - 0x224], xmm0
call fcn.00404850
push str.Lain
lea ecx, [ebp - 0x258]
mov byte [ebp - 4], 1
call fcn.00404850
lea ecx, [ebp - 0x270]
mov byte [ebp - 4], 2
push ecx
lea eax, [ebp - 0x240]
push eax
push ecx
lea ecx, [ebp - 0x224]
call fcn.00403f90
push 0x4047f0
push 2
push 0x18
lea eax, [ebp - 0x270]
mov byte [ebp - 4], 4
push eax
call fcn.0040625c
mov edi, dword [ebp - 0x224]
mov ebx, dword [ebp - 0x240]
cmp edi, dword [ebp - 0x220]
je 0x402b87
cmp dword [edi + 0x14], 7
mov eax, edi
jbe 0x402aff
mov eax, dword [edi]
cmp dword [ebp - 0x22c], 7
lea esi, [ebp - 0x240]
mov ecx, dword [ebp - 0x230]
cmova esi, ebx
cmp ecx, dword [edi + 0x10]
jne 0x402b78
mov edx, ecx
test edx, edx
je 0x402b33
sub esi, eax
mov cx, word [esi + eax]
cmp cx, word [eax]
jne 0x402b78
add eax, 2
sub edx, 1
jne 0x402b22
lea ecx, [ebp - 0x224]
call fcn.00404ff0
mov eax, dword [ebp - 0x22c]
cmp eax, 7
jbe 0x402b74
lea ecx, [eax*2 + 2]
mov eax, ebx
cmp ecx, 0x1000
jb 0x402b6a
mov ebx, dword [eax - 4]
add ecx, 0x23
sub eax, ebx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x402bbe
push ecx
push ebx
call fcn.00406371
add esp, 8
mov al, 1
jmp 0x402bd0
add edi, 0x18
cmp edi, dword [ebp - 0x220]
jne 0x402af5
lea ecx, [ebp - 0x224]
call fcn.00404ff0
mov eax, dword [ebp - 0x22c]
cmp eax, 7
jbe 0x402bce
lea ecx, [eax*2 + 2]
mov eax, ebx
cmp ecx, 0x1000
jb 0x402bc4
mov ebx, dword [eax - 4]
add ecx, 0x23
sub eax, ebx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x402bc4
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push ebx
call fcn.00406371
add esp, 8
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0040621e
mov esp, ebp
pop ebp
ret
Function at 0x403800
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
push ebx
mov ebx, ecx
push esi
push edi
cmp dword [ebx + 0x38], 0
je 0x40382c
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const___long_long___int64__]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x20]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x20], esi
mov ecx, dword [eax]
lea eax, [ebx + 0x30]
mov dword [esp + 0x24], edi
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], eax
test ecx, ecx
je 0x403854
mov eax, dword [eax]
mov ecx, dword [eax]
jmp 0x40385a
xor ecx, ecx
mov dword [esp + 0x18], eax
mov eax, ecx
cdq
mov dword [esp + 0x10], eax
mov ecx, edx
mov dword [esp + 0x14], ecx
test edi, edi
jl 0x4038e4
jg 0x403871
test esi, esi
je 0x4038e4
test ecx, ecx
jl 0x4038c7
jg 0x40387b
test eax, eax
je 0x4038c7
cmp edi, ecx
jg 0x40388f
jl 0x403885
cmp esi, eax
jae 0x40388f
mov eax, esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
push eax
push dword [ebp + 8]
push dword [esp + 0x24]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [esp + 0x24]
add esp, 0xc
mov ecx, dword [esp + 0x10]
mov edx, dword [ebp + 8]
add edx, ecx
sub esi, ecx
mov eax, dword [eax]
sbb edi, dword [esp + 0x14]
sub dword [eax], ecx
mov eax, dword [ebx + 0x20]
add dword [eax], ecx
test edi, edi
jl 0x4038e4
jg 0x4038ca
test esi, esi
je 0x4038e4
jmp 0x4038ca
mov edx, dword [ebp + 8]
mov eax, dword [ebx + 0x4c]
test eax, eax
je 0x4038e4
push eax
push esi
push 1
push edx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
sub esi, eax
sbb edi, 0
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
sub eax, esi
sbb edx, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x403900
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 4], esi
test eax, eax
jg 0x40392c
jl 0x403920
test ecx, ecx
jne 0x40392c
pop esi
xor eax, eax
xor edx, edx
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x403945
push eax
push ecx
push esi
mov ecx, ebx
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char___long_long___int64__]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
push edi
mov edi, ecx
mov eax, dword [eax]
mov dword [ebp - 8], eax
test eax, eax
je 0x403993
mov eax, dword [ebx + 0x2c]
lea edx, [ebx + 0x2c]
mov dword [ebp - 0xc], edx
mov eax, dword [eax]
test eax, eax
je 0x403999
mov edi, dword [ebp - 4]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push dword [ebp - 8]
push edi
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [ebp - 4], edi
add esp, 0xc
mov edi, dword [ebp + 0xc]
sub edi, esi
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
mov esi, dword [ebp - 4]
jmp 0x403999
lea eax, [ebx + 0x2c]
mov dword [ebp - 0xc], eax
cmp dword [ebx + 0x4c], 0
je 0x403a06
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x4039c2
mov eax, dword [ebx + 0xc]
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov dword [eax], edx
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
cmp edi, 0xfff
jbe 0x4039f4
nop
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call eax
add esp, 0x10
add esi, eax
sub edi, eax
cmp eax, 0xfff
jne 0x403a06
cmp edi, eax
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
ja 0x4039d0
test edi, edi
je 0x403a06
push dword [ebx + 0x4c]
push edi
push 1
push esi
call eax
add esp, 0x10
sub edi, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, edi
pop edi
pop esi
sbb edx, 0
pop ebx
mov esp, ebp
pop ebp
ret 0xc