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

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 8]
mov eax, dword [ecx + 0x10]
mov edx, dword [ecx]
mov eax, dword [eax]
cmp edx, 3
ja case.default.0x4540c2
jmp dword [edx*4 + 0x454118]
mov dword [ebp + 8], ecx
pop ebp
jmp fcn.00453c00
mov dword [ebp + 8], ecx
pop ebp
jmp fcn.004539b0
mov dword [ebp + 8], ecx
pop ebp
jmp fcn.004542c0
push str.TFTP_finished
push 0x47ff34
push eax
call fcn.00444fa0
add esp, 0xc
xor eax, eax
pop ebp
ret
push str.Internal_state_machine_error
push 0x488658
push eax
call fcn.00444f00
add esp, 0xc
mov eax, 0x47
pop ebp
ret
Function at 0x45a130
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x49d2e0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov eax, dword [esi + 0x158]
mov ebx, dword [esi]
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x14]
push ecx
push eax
mov dword [ebp - 0x1c], eax
or edi, 0xffffffff
mov dword [ebp - 0x18], 0x10
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x45a188
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x1c]
mov dword [ebp - 0x18], 0x10
call dword [sym.imp.WS2_32.dll_accept]
mov edi, eax
push dword [ebp - 0x1c]
push esi
call fcn.004454e0
add esp, 8
cmp edi, 0xffffffff
jne 0x45a1bd
push str.Error_accept__ing_server_connect
push ebx
call fcn.00444f00
add esp, 8
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041dee3
mov esp, ebp
pop ebp
ret
push str.Connection_accepted_from_server_n
push ebx
call fcn.00444fa0
push 1
mov dword [esi + 0x1f4], 0
push edi
mov dword [esi + 0x158], edi
call fcn.004632b0
mov dword [esi + 0x168], 1
mov eax, dword [ebx + 0x1b0]
add esp, 0x10
test eax, eax
je 0x45a233
push 1
push edi
push dword [ebx + 0x1b4]
call eax
add esp, 0xc
test eax, eax
je 0x45a233
push edi
push esi
call fcn.004454e0
add esp, 8
mov dword [esi + 0x158], 0xffffffff
pop edi
pop esi
mov eax, 0x2a
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041dee3
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
xor eax, eax
pop ebx
call fcn.0041dee3
mov esp, ebp
pop ebp
ret

Function at 0x45c5e0
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0xc]
mov eax, 0x51eb851f
imul ecx
sar edx, 5
push ebx
push esi
mov eax, edx
shr eax, 0x1f
push edi
mov edi, dword [ebp + 8]
add eax, edx
mov ebx, dword [edi]
xor esi, esi
cmp eax, 2
je 0x45c61c
push str.Couldnt_set_desired_mode
push ebx
call fcn.00444f00
add esp, 8
lea eax, [esi + 0x11]
pop edi
pop esi
pop ebx
pop ebp
ret
cmp ecx, 0xc8
je 0x45c633
push ecx
push str.Got_a__03d_response_code_instead_of_the_assumed_200_n
push ebx
call fcn.00444fa0
add esp, 0xc
mov eax, dword [ebp + 0x10]
cmp eax, 0x13
jne 0x45c64b
push edi
call fcn.0045c390
add esp, 4
mov esi, eax
pop edi
pop esi
pop ebx
pop ebp
ret
cmp eax, 0x14
jne 0x45c660
push edi
call fcn.0045b4c0
add esp, 4
mov esi, eax
pop edi
pop esi
pop ebx
pop ebp
ret
cmp eax, 0x15
jne 0x45c675
push edi
call fcn.0045c370
add esp, 4
mov esi, eax
pop edi
pop esi
pop ebx
pop ebp
ret
cmp eax, 0x16
jne 0x45c685
push edi
call fcn.0045c4d0
mov esi, eax
add esp, 4
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret
Function at 0x460a60
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x49d2e0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push eax
call fcn.004280da
add esp, 4
mov byte [ebp - 0x108], 0
test eax, eax
je 0x460ac4
push 0x104
lea ecx, [ebp - 0x108]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
cmp byte [ebp - 0x108], 0
je 0x460ac4
lea eax, [ebp - 0x108]
push eax
call dword [0x49e210]
add esp, 4
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041dee3
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor ecx, ebp
xor eax, eax
call fcn.0041dee3
mov esp, ebp
pop ebp
ret

Function at 0x460ae0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
pop ebp
jmp fcn.00460a60
Function at 0x464260
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov eax, dword [esi]
cmp dword [eax + 4], 2
jne 0x46428c
mov ecx, dword [esi + 0xc]
test ecx, ecx
jne 0x46427d
pop edi
xor eax, eax
pop esi
pop ebp
ret
push dword [eax + 8]
push dword [ebp + 0x10]
push 1
push dword [ebp + 0xc]
call ecx
jmp 0x4642c0
cmp dword [esi + 8], 0
jne 0x4642b0
push 0x47e7a4
push dword [eax + 8]
call fcn.0042130f
add esp, 8
mov dword [esi + 8], eax
test eax, eax
jne 0x4642b0
pop edi
or eax, 0xffffffff
pop esi
pop ebp
ret
push dword [esi + 8]
push dword [ebp + 0x10]
push 1
push dword [ebp + 0xc]
call fcn.0046b953
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4642e2
mov eax, dword [esi + 8]
test eax, eax
je 0x4642dc
push eax
call fcn.0041fdc3
add esp, 4
mov dword [esi + 8], edi
mov eax, dword [esi]
mov eax, dword [eax]
mov dword [esi], eax
mov eax, edi
pop edi
pop esi
pop ebp
ret

Function at 0x466c00
Capabilities:
Hash data with md5
Initialize hashing via wincrypt

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push 0xf0000000
push 1
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
je 0x466c32
lea eax, [esi + 4]
push eax
push 0
push 0
push 0x8003
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
pop esi
pop ebp
ret

Function at 0x466d90
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
push esi
push edi
mov byte [edi], 0
call dword [sym.imp.WS2_32.dll_gethostname]
mov byte [edi + esi - 1], 0
test eax, eax
jne 0x466dc3
push 0x2e
push edi
call fcn.00422310
add esp, 8
test eax, eax
je 0x466dc1
mov byte [eax], 0
xor eax, eax
pop edi
pop esi
pop ebp
ret
Function at 0x467dd0
Capabilities:
Hash data using md4
Hash data via wincrypt
Initialize hashing via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
mov esi, dword [ebp + 0xc]
push edi
lea ecx, [esi + 1]
mov edi, edi
mov al, byte [esi]
inc esi
test al, al
jne 0x467de0
sub esi, ecx
lea eax, [esi + esi]
push eax
mov dword [ebp - 0xc], eax
call dword [0x49e204]
mov edi, eax
add esp, 4
test edi, edi
jne 0x467e08
lea eax, [edi + 0x1b]
pop edi
pop esi
mov esp, ebp
pop ebp
ret
push esi
push dword [ebp + 0xc]
push edi
call fcn.00468070
add esp, 0xc
lea eax, [ebp - 8]
push 0xf0000000
push 1
push 0
push 0
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
mov esi, dword [ebp + 0x10]
test eax, eax
je 0x467e87
lea eax, [ebp - 4]
push eax
push 0
push 0
push 0x8002
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x467e7c
push 0
push dword [ebp - 0xc]
mov dword [ebp - 0x10], 0x10
push edi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
push 0
lea eax, [ebp - 0x10]
push eax
push esi
push 2
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push 0
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov dword [esi + 0x10], 0
push edi
mov byte [esi + 0x14], 0
call dword [0x49e208]
add esp, 4
xor eax, eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x4680e0
Capabilities:
Create new key via cryptacquirecontext
Encrypt data using des via winapi
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x49d2e0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 0x10]
push 0xf0000000
push 1
push 0
push 0
lea eax, [ebp - 0x1c]
push eax
mov dword [ebp - 0x20], 8
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
je 0x46817d
lea eax, [ebp - 0xc]
xorps xmm0, xmm0
push eax
movq qword [ebp - 0x18], xmm0
movq qword [ebp - 0x10], xmm0
push edi
mov dword [ebp - 8], 0
mov word [ebp - 0x18], 0x208
mov dword [ebp - 0x14], 0x6601
mov dword [ebp - 0x10], 8
call fcn.004681e0
lea eax, [ebp - 0xc]
push 8
push eax
call fcn.00469760
add esp, 0x10
lea eax, [ebp - 0x24]
push eax
push 0
push 0
push 0x14
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x46818f
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
pop edi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041dee3
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 8]
push dword [ebp - 0x20]
mov eax, dword [ecx]
mov dword [esi], eax
mov eax, dword [ecx + 4]
mov dword [esi + 4], eax
lea eax, [ebp - 0x20]
push eax
push esi
push 0
push 0
push 0
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_CryptEncrypt]
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
push 0
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
mov eax, 1
pop esi
call fcn.0041dee3
mov esp, ebp
pop ebp
ret
Function at 0x468c00
Capabilities:
Authenticate hmac
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
mov esi, dword [ebp + 8]
push edi
mov ecx, dword [esi + 0xc]
mov eax, dword [esi + 0x14]
lea eax, [eax + ecx*2]
add eax, 0xc
push eax
call dword [0x49e204]
mov edi, eax
add esp, 4
test edi, edi
jne 0x468c2d
pop edi
pop esi
mov esp, ebp
pop ebp
ret
lea ecx, [edi + 0xc]
mov dword [edi], esi
mov dword [edi + 4], ecx
mov eax, dword [esi + 0xc]
add eax, ecx
push ebx
mov ebx, dword [ebp + 0x10]
mov dword [edi + 8], eax
cmp ebx, dword [esi + 0x10]
jbe 0x468c74
mov eax, dword [esi]
push ecx
call eax
mov eax, dword [esi + 4]
push ebx
push dword [ebp + 0xc]
push dword [edi + 4]
call eax
mov eax, dword [edi + 8]
add eax, dword [esi + 0xc]
push dword [edi + 4]
mov dword [ebp - 4], eax
push eax
mov eax, dword [esi + 8]
call eax
mov ebx, dword [esi + 0x14]
add esp, 0x18
mov dword [ebp + 0x10], ebx
jmp 0x468c7a
mov eax, dword [ebp + 0xc]
mov dword [ebp - 4], eax
push dword [edi + 4]
mov eax, dword [esi]
call eax
push dword [edi + 8]
mov eax, dword [esi]
call eax
mov eax, dword [ebp + 0x10]
add esp, 8
xor ebx, ebx
test eax, eax
je 0x468cda
mov ebx, dword [ebp - 4]
mov dword [ebp - 8], eax
lea ebx, [ebx]
movzx eax, byte [ebx]
xor al, 0x36
mov byte [ebp + 0xb], al
push 1
lea eax, [ebp + 0xb]
push eax
push dword [edi + 4]
mov eax, dword [esi + 4]
call eax
movzx eax, byte [ebx]
xor al, 0x5c
mov byte [ebp + 0xb], al
push 1
lea eax, [ebp + 0xb]
push eax
push dword [edi + 8]
mov eax, dword [esi + 4]
lea ebx, [ebx + 1]
call eax
add esp, 0x18
dec dword [ebp + 0x10]
jne 0x468ca0
mov ebx, dword [ebp - 8]
cmp ebx, dword [esi + 0x10]
jae 0x468d07
nop
mov eax, dword [esi + 4]
push 1
push 0x4864e6
push dword [edi + 4]
call eax
mov eax, dword [esi + 4]
push 1
push 0x4864e7
push dword [edi + 8]
call eax
inc ebx
add esp, 0x18
cmp ebx, dword [esi + 0x10]
jb 0x468ce0
pop ebx
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x4037f0
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x443ca1
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x45d0bc]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov esi, ecx
mov dword [ebp - 0x48], 0
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x44]
xor eax, eax
mov dword [ebp - 0x34], 0
mov word [ebp - 0x44], ax
mov eax, dword [esi + 0x10]
add eax, 0x22
mov dword [ebp - 0x30], 7
push eax
mov dword [ebp - 0x48], 1
call fcn.00405cb0
push str.SYSTEMCurrentControlSetServices_
lea ecx, [ebp - 0x44]
call fcn.00405d50
push esi
lea ecx, [ebp - 0x44]
call fcn.00407ec0
cmp dword [ebp - 0x30], 8
lea eax, [ebp - 0x44]
cmovae eax, dword [ebp - 0x44]
push eax
push 0x80000002
call dword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
lea ecx, [ebp - 0x2c]
test eax, eax
jne 0x4039b8
push 0x1d
push str.CleanUpDriverRegistry_SUCSESS
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], 0xf
mov byte [ebp - 0x2c], al
call fcn.00408080
mov byte [ebp - 4], 3
lea eax, [ebp - 0x2c]
mov ecx, dword [0x45fd70]
push eax
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x18]
cmp edx, 0x10
jb 0x4038f0
mov ecx, dword [ebp - 0x2c]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x4038e6
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4039e1
push edx
push ecx
call fcn.004241cb
add esp, 8
mov edx, dword [ebp - 0x30]
cmp edx, 8
jb 0x40392a
mov ecx, dword [ebp - 0x44]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x403920
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4039e6
push edx
push ecx
call fcn.004241cb
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00424185
mov esp, ebp
pop ebp
ret
push ecx
lea ecx, [ebp - 0x2c]
call fcn.00406310
mov byte [ebp - 4], 5
lea eax, [ebp - 0x2c]
mov ecx, dword [0x45fd70]
push eax
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0x18]
cmp ecx, 0x10
jb 0x4039b2
mov eax, dword [ebp - 0x2c]
inc ecx
cmp ecx, 0x1000
jb 0x4039a8
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4039e1
mov eax, edx
push ecx
push eax
call fcn.004241cb
add esp, 8
mov eax, 0x40392a
ret
mov edx, eax
call fcn.00402880
mov ecx, eax
mov byte [ebp - 4], 2
call fcn.00406170
push eax
lea ecx, [ebp - 0x58]
call fcn.00401490
push 0x45b95c
lea eax, [ebp - 0x58]
push eax
call fcn.00425c43
call fcn.0042b37c
call fcn.0042b37c
call eax
mov ecx, eax
jmp 0x403966
Function at 0x408390
Capabilities:
Access peb ldr_data
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4442a0
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x45d0bc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
push 8
mov dword [edi], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
call fcn.0042419b
mov esi, eax
push 1
mov dword [ebp - 4], 0
call fcn.00422d7e
mov dword [esi + 4], eax
lea ecx, [edi + 8]
lea eax, [edi + 4]
mov ebx, dword [ebp + 8]
mov dword [edi + 0xc], eax
add esp, 8
mov dword [edi + 0x10], ecx
lea eax, [edi + 0x14]
mov dword [edi + 0x1c], eax
lea eax, [edi + 0x18]
mov dword [edi + 0x20], eax
lea eax, [edi + 0x24]
mov dword [edi + 0x2c], eax
lea eax, [edi + 0x28]
mov dword [edi + 0x30], eax
mov dword [edi + 0x34], esi
mov dword [ecx], 0
mov ecx, ebx
mov eax, dword [edi + 0x20]
not ecx
and ecx, 1
shl ecx, 2
mov edx, ecx
mov dword [eax], 0
or edx, 2
mov eax, dword [edi + 0x30]
mov dword [eax], 0
mov eax, dword [edi + 0xc]
mov dword [eax], 0
mov eax, dword [edi + 0x1c]
mov dword [eax], 0
mov eax, dword [edi + 0x2c]
mov dword [eax], 0
mov eax, ebx
and al, 2
mov dword [edi], vtable.std::basic_stringbuf_char__struct_std::char_traits_char___class_std::allocator_char__.0
mov eax, ebx
mov dword [edi + 0x38], 0
cmovne edx, ecx
mov ecx, edx
or ecx, 8
and al, 8
cmove ecx, edx
mov eax, ecx
or eax, 0x10
and bl, 4
cmove eax, ecx
mov dword [edi + 0x3c], eax
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x4094c0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4439a0
mov eax, dword fs:[0]
push eax
push esi
push edi
mov eax, dword [0x45d0bc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
push 8
mov dword [edi], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
call fcn.0042419b
mov esi, eax
push 1
mov dword [ebp - 4], 0
call fcn.00422d7e
mov dword [esi + 4], eax
lea ecx, [edi + 8]
lea eax, [edi + 4]
mov dword [edi + 0x34], esi
mov dword [edi + 0xc], eax
add esp, 8
lea eax, [edi + 0x14]
mov dword [edi + 0x10], ecx
mov dword [edi + 0x1c], eax
lea eax, [edi + 0x18]
mov dword [edi + 0x20], eax
lea eax, [edi + 0x24]
mov dword [edi + 0x2c], eax
lea eax, [edi + 0x28]
mov dword [edi + 0x30], eax
mov dword [ecx], 0
mov eax, dword [edi + 0x20]
mov dword [eax], 0
mov eax, dword [edi + 0x30]
mov dword [eax], 0
mov eax, dword [edi + 0xc]
mov dword [eax], 0
mov eax, dword [edi + 0x1c]
mov dword [eax], 0
mov eax, dword [edi + 0x2c]
mov dword [eax], 0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x40cf30
Capabilities:
Access peb ldr_data
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x444907
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x45d0bc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x14], ebx
cmp dword [ebp + 0xc], 0
mov dword [ebp - 0x10], 0
je 0x40cf8c
mov dword [ebx], 0x4554dc
mov dword [ebx + 0x10], 0x455490
mov dword [ebx + 0x68], vtable.std::basic_ios_wchar_t__struct_std::char_traits_wchar_t__.0
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 1
push 0
lea edi, [ebx + 0x18]
mov ecx, ebx
push edi
call fcn.0040dcb0
mov dword [ebp - 4], 1
mov eax, dword [ebx]
push 8
mov dword [ebp + 0xc], edi
mov eax, dword [eax + 4]
mov dword [ebx + eax], vtable.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
mov eax, dword [ebx]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ecx + ebx - 4], eax
mov dword [edi], vtable.std::basic_streambuf_wchar_t__struct_std::char_traits_wchar_t__.0
call fcn.0042419b
mov esi, eax
push 1
mov byte [ebp - 4], 2
call fcn.00422d7e
mov dword [esi + 4], eax
lea ecx, [edi + 8]
lea eax, [edi + 4]
mov ebx, dword [ebp + 8]
mov dword [edi + 0xc], eax
add esp, 8
mov dword [edi + 0x10], ecx
lea eax, [edi + 0x14]
mov dword [edi + 0x1c], eax
lea eax, [edi + 0x18]
mov dword [edi + 0x20], eax
lea eax, [edi + 0x24]
mov dword [edi + 0x2c], eax
lea eax, [edi + 0x28]
mov dword [edi + 0x30], eax
mov dword [edi + 0x34], esi
mov dword [ecx], 0
mov ecx, ebx
mov eax, dword [edi + 0x20]
not ecx
and ecx, 1
shl ecx, 2
mov edx, ecx
mov dword [eax], 0
or edx, 2
mov eax, dword [edi + 0x30]
mov dword [eax], 0
mov eax, dword [edi + 0xc]
mov dword [eax], 0
mov eax, dword [edi + 0x1c]
mov dword [eax], 0
mov eax, dword [edi + 0x2c]
mov dword [eax], 0
mov eax, ebx
and al, 2
mov dword [edi], vtable.std::basic_stringbuf_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
mov eax, ebx
mov dword [edi + 0x38], 0
cmovne edx, ecx
mov ecx, edx
or ecx, 8
and al, 8
cmove ecx, edx
mov eax, ecx
or eax, 0x10
and bl, 4
cmove eax, ecx
mov dword [edi + 0x3c], eax
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x412960
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x445068
mov eax, dword fs:[0]
push eax
sub esp, 0x40
mov eax, dword [0x45d0bc]
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
mov edi, ecx
mov ebx, dword [ebp + 8]
lea eax, [edi + 0x120]
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x44], esp
mov esi, dword [ebx]
push eax
call fcn.00405e70
sub esp, 0x18
mov dword [ebp - 4], 0
lea eax, [edi + 0x138]
mov ecx, esp
push eax
call fcn.00405e70
push 0
lea eax, [ebp - 0x40]
mov dword [ebp - 4], 0xffffffff
push esi
push eax
call fcn.004118e0
add esp, 0x3c
lea esi, [edi + 0x70]
mov dword [ebp - 4], 1
lea ecx, [esi + 4]
call fcn.00414100
test eax, eax
jne 0x412a14
mov eax, dword [esi]
mov ecx, dword [eax + 4]
xor eax, eax
add ecx, esi
cmp dword [ecx + 0x38], eax
sete al
lea eax, [eax*4 + 2]
or eax, dword [ecx + 0xc]
and eax, 0x17
mov dword [ecx + 0xc], eax
mov ecx, dword [ecx + 0x10]
and ecx, eax
jne 0x412b17
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x28]
push eax
call fcn.0041aaa0
add esp, 8
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
mov byte [ebp - 4], 2
cmovae eax, dword [ebp - 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
lea edx, [ebp - 0x28]
push 0x40
setne cl
mov eax, 2
cmp dword [ebp - 0x14], 0x10
cmovae edx, dword [ebp - 0x28]
test cl, cl
mov ecx, esi
cmovne eax, dword [ebp + 0xc]
push eax
push edx
call fcn.00415420
mov edx, dword [ebp - 0x14]
cmp edx, 0x10
jb 0x412a95
mov ecx, dword [ebp - 0x28]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x412a8b
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b59
push edx
push ecx
call fcn.004241cb
add esp, 8
cmp dword [edi + 0xc0], 0
mov eax, dword [ebx]
mov dword [edi + 0x15c], eax
mov eax, dword [ebp + 0xc]
mov dword [edi + 0x160], eax
je 0x412abf
mov eax, dword [esi]
mov eax, dword [eax + 4]
cmp dword [eax + edi + 0x7c], 0
jne 0x412abf
mov bl, 1
jmp 0x412ac1
xor bl, bl
mov edx, dword [ebp - 0x2c]
cmp edx, 8
jb 0x412af7
mov ecx, dword [ebp - 0x40]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x412aed
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b5e
push edx
push ecx
call fcn.004241cb
add esp, 8
mov al, bl
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.00424185
mov esp, ebp
pop ebp
ret 8
test cl, 4
je 0x412b23
mov esi, str.ios_base::badbit_set
jmp 0x412b33
test cl, 2
mov esi, str.ios_base::failbit_set
mov eax, str.ios_base::eofbit_set
cmove esi, eax
lea eax, [ebp - 0x4c]
push 1
push eax
call fcn.004019b0
add esp, 8
lea ecx, [ebp - 0x24]
push eax
push esi
call fcn.00401cf0
push 0x45ba1c
lea eax, [ebp - 0x24]
push eax
call fcn.00425c43
call fcn.0042b37c
call fcn.0042b37c
int3