joyce8/EMBER2024-capa huggingface dataset:
Function at 0x41d9f2
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x90]
sub esp, 0x110
mov eax, dword [0x42b48c]
mov ecx, dword [ebp + 0x98]
push ebx
xor eax, ebp
push esi
mov dword [ebp + 0x8c], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x42be00]
je 0x41da29
inc eax
cmp eax, 0x13
jb 0x41da1a
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x42be00]
jne 0x41db4c
mov eax, dword [0x42c5b4]
cmp eax, 1
je 0x41db27
cmp eax, edx
jne 0x41da59
cmp dword [0x42b4f4], 1
je 0x41db27
cmp ecx, 0xfc
je 0x41db4c
push 0x104
lea eax, [ebp - 0x7c]
push eax
push edx
mov byte [ebp + 0x88], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x41da8f
lea eax, [ebp - 0x7c]
push str._program_name_unknown_
push eax
call fcn.0041a4d0
pop ecx
pop ecx
lea edi, [ebp - 0x7c]
mov eax, edi
push eax
call fcn.0041a5d0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x41dac3
mov eax, edi
push eax
call fcn.0041a5d0
mov edi, eax
lea eax, [ebp - 0x7c]
sub eax, 0x3b
push 3
add edi, eax
push 0x426a34
push edi
call fcn.00416230
add esp, 0x10
push edi
call fcn.0041a5d0
push dword [esi + 0x42be04]
mov ebx, eax
call fcn.0041a5d0
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00416c70
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.0041a4d0
push edi
push ebx
call fcn.0041a4e0
push 0x426a30
push ebx
call fcn.0041a4e0
push dword [esi + 0x42be04]
push ebx
call fcn.0041a4e0
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.0041e865
add esp, 0x2c
jmp 0x41db4c
push edx
lea eax, [ebp - 0x80]
push eax
lea esi, [esi + 0x42be04]
push dword [esi]
call fcn.0041a5d0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea esp, [ebp - 0x8c]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x8c]
xor ecx, ebp
call fcn.00415d1a
add ebp, 0x90
leave
ret
Function at 0x41e865
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x42c990], ebx
push esi
push edi
jne 0x41e8e5
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x41e920
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
mov dword [0x42c990], eax
je 0x41e920
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x42c994], eax
call esi
cmp dword [0x42c55c], 2
mov dword [0x42c998], eax
jne 0x41e8e5
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x42c9a0], eax
je 0x41e8e5
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x42c99c], eax
mov eax, dword [0x42c99c]
test eax, eax
je 0x41e92a
call eax
test eax, eax
je 0x41e911
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x42c9a0]
test eax, eax
je 0x41e911
test byte [ebp - 8], 1
jne 0x41e92a
cmp dword [0x42c568], 4
jb 0x41e924
or byte [ebp + 0x12], 0x20
jmp 0x41e949
xor eax, eax
jmp 0x41e959
or byte [ebp + 0x12], 4
jmp 0x41e949
mov eax, dword [0x42c994]
test eax, eax
je 0x41e949
call eax
mov ebx, eax
test ebx, ebx
je 0x41e949
mov eax, dword [0x42c998]
test eax, eax
je 0x41e949
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x42c990]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x41eab6
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x3a4]
sub esp, 0x424
mov eax, dword [0x42b48c]
xor ecx, ecx
xor eax, ebp
cmp dword [ebp + 0x3b4], ecx
push edi
mov edi, dword [ebp + 0x3b0]
mov dword [ebp + 0x3a0], eax
mov dword [ebp - 0x7c], edi
mov dword [ebp - 0x74], ecx
mov dword [ebp - 0x78], ecx
jne 0x41eaf2
xor eax, eax
jmp 0x41ec5c
mov eax, dword [ebp + 0x3ac]
push ebx
mov ebx, dword [ebp + 0x3ac]
and eax, 0x1f
sar ebx, 5
push esi
lea esi, [eax + eax*8]
lea ebx, [ebx*4 + 0x42cb80]
mov eax, dword [ebx]
shl esi, 2
test byte [eax + esi + 4], 0x20
je 0x41eb30
push 2
push ecx
push ecx
push dword [ebp + 0x3ac]
call fcn.004205cc
add esp, 0x10
xor ecx, ecx
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x41ebca
cmp dword [ebp + 0x3b4], ecx
mov dword [ebp - 0x70], edi
mov dword [ebp - 0x68], ecx
jbe 0x41ec2d
jmp 0x41eb54
xor ecx, ecx
mov dword [ebp - 0x6c], ecx
mov ecx, dword [ebp - 0x70]
sub ecx, dword [ebp - 0x7c]
lea eax, [ebp - 0x64]
cmp ecx, dword [ebp + 0x3b4]
jae 0x41eb8f
mov edx, dword [ebp - 0x70]
inc dword [ebp - 0x70]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x41eb80
inc dword [ebp - 0x78]
mov byte [eax], 0xd
inc eax
inc dword [ebp - 0x6c]
mov byte [eax], dl
inc eax
inc dword [ebp - 0x6c]
cmp dword [ebp - 0x6c], 0x400
jl 0x41eb60
mov edi, eax
lea eax, [ebp - 0x64]
sub edi, eax
push 0
lea eax, [ebp - 0x80]
push eax
push edi
lea eax, [ebp - 0x64]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x41ebee
mov eax, dword [ebp - 0x80]
add dword [ebp - 0x74], eax
cmp eax, edi
jl 0x41ebf7
mov eax, dword [ebp - 0x70]
sub eax, dword [ebp - 0x7c]
cmp eax, dword [ebp + 0x3b4]
jb 0x41eb52
jmp 0x41ebf7
push ecx
lea ecx, [ebp - 0x80]
push ecx
push dword [ebp + 0x3b4]
push edi
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x41ebee
mov eax, dword [ebp - 0x80]
and dword [ebp - 0x68], 0
mov dword [ebp - 0x74], eax
jmp 0x41ebf7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x74]
test eax, eax
jne 0x41ec57
cmp dword [ebp - 0x68], eax
je 0x41ec2a
push 5
pop esi
cmp dword [ebp - 0x68], esi
jne 0x41ec1f
call fcn.0041d4e5
mov dword [eax], 9
call fcn.0041d4ee
mov dword [eax], esi
jmp 0x41ec52
push dword [ebp - 0x68]
call fcn.0041d4f7
pop ecx
jmp 0x41ec52
mov edi, dword [ebp - 0x7c]
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x41ec3f
cmp byte [edi], 0x1a
jne 0x41ec3f
xor eax, eax
jmp 0x41ec5a
call fcn.0041d4e5
mov dword [eax], 0x1c
call fcn.0041d4ee
and dword [eax], 0
or eax, 0xffffffff
jmp 0x41ec5a
sub eax, dword [ebp - 0x78]
pop esi
pop ebx
mov ecx, dword [ebp + 0x3a0]
xor ecx, ebp
pop edi
call fcn.00415d1a
add ebp, 0x3a4
leave
ret
Function at 0x42064f
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
and dword [ebp - 8], 0
cmp dword [ebp + 0x10], 0
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edx, ebx
je 0x420825
mov eax, dword [ebp + 8]
mov ecx, eax
and eax, 0x1f
sar ecx, 5
lea esi, [eax + eax*8]
lea edi, [ecx*4 + 0x42cb80]
mov eax, dword [edi]
shl esi, 2
add eax, esi
mov cl, byte [eax + 4]
test cl, 2
jne 0x420825
test cl, 0x48
je 0x4206ba
cmp byte [eax + 5], 0xa
je 0x4206ba
mov eax, dword [edi]
mov al, byte [eax + esi + 5]
dec dword [ebp + 0x10]
mov byte [ebx], al
mov eax, dword [edi]
lea edx, [ebx + 1]
mov dword [ebp - 8], 1
mov byte [eax + esi + 5], 0xa
push 0
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 0x10]
mov eax, dword [edi]
push edx
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x42070c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 5
pop esi
cmp eax, esi
jne 0x4206f4
call fcn.0041d4e5
mov dword [eax], 9
call fcn.0041d4ee
mov dword [eax], esi
jmp 0x420704
cmp eax, 0x6d
je 0x420825
push eax
call fcn.0041d4f7
pop ecx
or eax, 0xffffffff
jmp 0x420827
mov eax, dword [ebp - 0xc]
mov ecx, dword [edi]
add dword [ebp - 8], eax
test byte [ecx + esi + 4], 0x80
je 0x420820
test eax, eax
je 0x420733
cmp byte [ebx], 0xa
jne 0x420733
mov eax, ecx
lea eax, [eax + esi + 4]
or byte [eax], 4
jmp 0x42073c
mov eax, dword [edi]
lea eax, [eax + esi + 4]
and byte [eax], 0xfb
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 8]
add ecx, eax
cmp eax, ecx
mov dword [ebp + 0x10], eax
mov dword [ebp - 8], ecx
jae 0x42081a
mov eax, dword [ebp + 0x10]
mov al, byte [eax]
cmp al, 0x1a
je 0x42080a
cmp al, 0xd
je 0x42076e
mov byte [ebx], al
inc ebx
inc dword [ebp + 0x10]
jmp 0x4207fc
dec ecx
cmp dword [ebp + 0x10], ecx
jae 0x420788
mov eax, dword [ebp + 0x10]
inc eax
cmp byte [eax], 0xa
jne 0x420783
add dword [ebp + 0x10], 2
jmp 0x4207dc
mov dword [ebp + 0x10], eax
jmp 0x4207f8
inc dword [ebp + 0x10]
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [edi]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4207b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x4207f8
cmp dword [ebp - 0xc], 0
je 0x4207f8
mov eax, dword [edi]
test byte [eax + esi + 4], 0x48
je 0x4207d1
mov al, byte [ebp - 1]
cmp al, 0xa
je 0x4207dc
mov byte [ebx], 0xd
mov ecx, dword [edi]
mov byte [ecx + esi + 5], al
jmp 0x4207fb
cmp ebx, dword [ebp + 0xc]
jne 0x4207e1
cmp byte [ebp - 1], 0xa
jne 0x4207e1
mov byte [ebx], 0xa
jmp 0x4207fb
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.004205cc
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x4207fc
mov byte [ebx], 0xd
inc ebx
mov ecx, dword [ebp - 8]
cmp dword [ebp + 0x10], ecx
jb 0x420752
jmp 0x42081a
mov eax, dword [edi]
test byte [eax + esi + 4], 0x40
jne 0x42081a
lea esi, [eax + esi + 4]
or byte [esi], 2
sub ebx, dword [ebp + 0xc]
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 8]
jmp 0x420827
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x421a85
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebp + 8]
push ebx
xor ebx, ebx
cmp eax, ebx
push edi
mov dword [ebp - 0x10], ebx
jne 0x421a9e
or eax, 0xffffffff
jmp 0x421aff
push esi
mov esi, dword [eax]
cmp esi, ebx
mov dword [ebp - 8], esi
je 0x421afb
push 0x3d
push esi
call fcn.0041640d
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0xc], eax
je 0x421afb
cmp esi, eax
je 0x421afb
xor ecx, ecx
cmp byte [eax + 1], cl
mov eax, dword [0x42c57c]
sete cl
cmp eax, dword [0x42c580]
mov dword [ebp - 4], ecx
jne 0x421ae1
mov edi, eax
call fcn.00421a24
mov dword [0x42c57c], eax
cmp eax, ebx
jne 0x421b3a
cmp dword [ebp + 0xc], ebx
je 0x421b03
cmp dword [0x42c584], ebx
je 0x421b03
call fcn.00420b4a
test eax, eax
je 0x421b3a
or eax, 0xffffffff
pop esi
pop edi
pop ebx
leave
ret
cmp dword [ebp - 4], ebx
je 0x421b0c
xor eax, eax
jmp 0x421afe
push 4
call fcn.004163fb
cmp eax, ebx
pop ecx
mov dword [0x42c57c], eax
je 0x421afb
mov dword [eax], ebx
cmp dword [0x42c584], ebx
jne 0x421b3a
push 4
call fcn.004163fb
cmp eax, ebx
pop ecx
mov dword [0x42c584], eax
je 0x421afb
mov dword [eax], ebx
mov edi, dword [ebp - 0xc]
mov ebx, dword [0x42c57c]
sub edi, esi
push esi
call fcn.004219d7
mov edi, eax
test edi, edi
pop ecx
jl 0x421ba1
cmp dword [ebx], 0
je 0x421ba1
lea esi, [ebx + edi*4]
push dword [esi]
call fcn.00415731
xor eax, eax
cmp dword [ebp - 4], eax
pop ecx
jne 0x421b81
mov ecx, dword [ebp - 8]
mov dword [esi], ecx
mov ecx, dword [ebp + 8]
mov esi, dword [ebp - 8]
mov dword [ecx], eax
jmp 0x421be2
mov ecx, dword [esi + 4]
inc edi
mov dword [esi], ecx
lea esi, [ebx + edi*4]
cmp dword [esi], eax
jne 0x421b78
mov eax, edi
shl eax, 2
push eax
push dword [0x42c57c]
call fcn.00416eca
test eax, eax
mov esi, dword [ebp - 8]
pop ecx
pop ecx
je 0x421be2
jmp 0x421bdd
cmp dword [ebp - 4], 0
jne 0x421c49
test edi, edi
jge 0x421bb1
neg edi
lea eax, [edi*4 + 8]
push eax
push dword [0x42c57c]
call fcn.00416eca
test eax, eax
pop ecx
pop ecx
je 0x421afb
lea ecx, [eax + edi*4]
and dword [ecx + 4], 0
mov dword [ecx], esi
mov ecx, dword [ebp + 8]
and dword [ecx], 0
mov dword [0x42c57c], eax
cmp dword [ebp + 0xc], 0
je 0x421c34
push esi
call fcn.0041a5d0
inc eax
inc eax
push eax
call fcn.004163fb
mov edi, eax
test edi, edi
pop ecx
pop ecx
je 0x421c34
push esi
push edi
call fcn.0041a4d0
mov eax, edi
sub eax, esi
add eax, dword [ebp - 0xc]
pop ecx
pop ecx
mov ecx, dword [ebp - 4]
mov byte [eax], 0
inc eax
neg ecx
sbb ecx, ecx
not ecx
and ecx, eax
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
test eax, eax
jne 0x421c2d
or dword [ebp - 0x10], 0xffffffff
push edi
call fcn.00415731
pop ecx
cmp dword [ebp - 4], 0
je 0x421c41
push esi
call fcn.00415731
pop ecx
mov eax, dword [ebp - 0x10]
jmp 0x421afe
push esi
call fcn.00415731
mov eax, dword [ebp + 8]
and dword [eax], 0
pop ecx
jmp 0x421b08
Function at 0x401000
Capabilities:
Get geographical location

Disassembly:
sub esp, 0x38
push ebx
push ebp
push esi
mov esi, dword [esp + 0x48]
push edi
xor edi, edi
push 0x416084
push esi
mov dword [esp + 0x18], edi
mov dword [esi + 8], edi
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
add esp, 8
lea eax, [esi + 4]
mov dword [esp + 0x14], eax
push 0x416080
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
add esp, 8
lea ebx, [esi + 0xc]
push 0x41607c
push ebx
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
add esp, 8
lea ebp, [esi + 0x10]
push str.:_._
push ebp
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
add esp, 8
lea eax, [esi + 0x18]
mov dword [esi + 0x14], edi
mov dword [esp + 0x4c], eax
push 0x416084
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
mov edi, dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
add esp, 8
lea eax, [esp + 0x18]
push 0x10
push eax
push 3
push 0x400
call edi
test eax, eax
jne 0x401095
mov dword [esp + 0x10], 0xffffffff
jmp 0x4010a5
lea ecx, [esp + 0x18]
push ecx
call fcn.00401180
add esp, 4
mov dword [esi + 0x1c], eax
lea edx, [esp + 0x28]
push 0x20
push edx
push 0x21
push 0x400
call edi
test eax, eax
jne 0x4010c3
mov dword [esp + 0x10], 0xffffffff
jmp 0x4010d3
lea eax, [esp + 0x28]
push eax
call sym.testlock.exe_public:_static_long_int___cdecl_MSSTR::Atol_char_const__
add esp, 4
mov dword [esi + 8], eax
push 4
push ebx
push 0x1d
push 0x400
call edi
test eax, eax
jne 0x4010ec
or ebx, 0xffffffff
mov dword [esp + 0x10], ebx
jmp 0x4010ef
or ebx, 0xffffffff
lea ecx, [esp + 0x28]
push 0x20
push ecx
push 0x23
push 0x400
call edi
test eax, eax
jne 0x401109
mov dword [esp + 0x10], ebx
jmp 0x401119
lea edx, [esp + 0x28]
push edx
call sym.testlock.exe_public:_static_long_int___cdecl_MSSTR::Atol_char_const__
add esp, 4
mov dword [esi + 0x14], eax
push 4
push ebp
push 0x1e
push 0x400
call edi
test eax, eax
jne 0x40112d
mov dword [esp + 0x10], ebx
push 4
push esi
push 0xf
push 0x400
call edi
test eax, eax
jne 0x401141
mov dword [esp + 0x10], ebx
mov eax, dword [esp + 0x4c]
push 4
push eax
push 0xc
push 0x400
call edi
test eax, eax
jne 0x401159
mov dword [esp + 0x10], ebx
mov ecx, dword [esp + 0x14]
push 4
push ecx
push 0xe
push 0x400
call edi
test eax, eax
jne 0x401171
mov dword [esp + 0x10], ebx
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret
Function at 0x402cb0
Capabilities:
Get common file path

Disassembly:
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
push esi
mov esi, dword [esp + 0xc]
push edi
push esi
push 0
push 0x416154
push esi
call ebx
test eax, eax
jne 0x402d14
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
mov edi, eax
push esi
call sym.testlock.exe_public:_static_int___cdecl_MSFS::Exist_char_const__
add esp, 4
test eax, eax
jne 0x402d48
push esi
push 0x13a5
call sym.testlock.exe_public:_static_int___cdecl_MSERR::Error_int_
add esp, 8
cmp eax, 1
jne 0x402d48
push esi
call sym.testlock.exe_public:_static_int___cdecl_MSFS::CreateDir_char_const__
add esp, 4
test eax, eax
jl 0x402d4e
push esi
push 0
push 0x416154
push esi
call ebx
test eax, eax
je 0x402ccc
push 0
push 0x20
push 3
push 0
push 0
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x402d3e
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop edi
pop esi
pop ebx
ret
push esi
push edi
call fcn.00405a70
add esp, 8
mov eax, edi
pop edi
pop esi
pop ebx
ret
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSERR::Error_int_
add esp, 4
pop edi
pop esi
pop ebx
ret

Function at 0x402d60
Capabilities:
Get file size

Disassembly:
mov eax, dword [esp + 4]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
jne 0x402d7b
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
ret

Function at 0x403010
Capabilities:
Read file on windows

Disassembly:
push ecx
push ebx
push ebp
push esi
push edi
call sym.testlock.exe_public:_static_void___cdecl_MSOS::DoYield_void_
mov esi, dword [esp + 0x20]
mov edi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x18]
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
lea eax, [esp + 0x10]
push 0
push eax
push esi
push edi
push ebx
mov dword [esp + 0x24], 0
call ebp
test eax, eax
jne 0x403093
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x10]
test ecx, ecx
jne 0x403083
cmp eax, 0xf0
je 0x403063
cmp eax, 0x3b
je 0x403063
cmp eax, 0x36
jne 0x403083
lea ecx, [esp + 0x10]
push 0
push ecx
push esi
push edi
push ebx
call ebp
test eax, eax
jne 0x403093
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
Function at 0x403100
Capabilities:
Write file on windows

Disassembly:
push ecx
call sym.testlock.exe_public:_static_void___cdecl_MSOS::DoYield_void_
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x403110
pop ecx
ret
mov edx, dword [esp + 0xc]
lea ecx, [esp]
push 0
push ecx
push eax
mov eax, dword [esp + 0x14]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x403138
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop ecx
ret
mov eax, dword [esp]
pop ecx
ret

Function at 0x403330
Capabilities:
Create directory

Disassembly:
sub esp, 0x104
push esi
mov esi, dword [esp + 0x10c]
test esi, esi
jne 0x40334f
mov eax, 0xffffd846
pop esi
add esp, 0x104
ret
push esi
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Len_char_const__
add esp, 4
cmp eax, 0x103
jle 0x40336c
mov eax, 0xffffd845
pop esi
add esp, 0x104
ret
lea eax, [esp + 4]
push esi
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
add esp, 8
lea ecx, [esp + 4]
push ecx
call sym.testlock.exe_public:_static_void___cdecl_MSFS::StripSlash_char__
add esp, 4
lea edx, [esp + 4]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x4033aa
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop esi
add esp, 0x104
ret
xor eax, eax
pop esi
add esp, 0x104
ret

Function at 0x403550
Capabilities:
Delete file

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x40356a
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
ret
xor eax, eax
ret

Function at 0x403590
Capabilities:
Delete directory

Disassembly:
sub esp, 0x104
push esi
mov esi, dword [esp + 0x10c]
test esi, esi
jne 0x4035af
mov eax, 0xffffd846
pop esi
add esp, 0x104
ret
push esi
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Len_char_const__
add esp, 4
cmp eax, 0x103
jle 0x4035cc
mov eax, 0xffffd845
pop esi
add esp, 0x104
ret
lea eax, [esp + 4]
push esi
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Copy_char___char_const__
add esp, 8
lea ecx, [esp + 4]
push ecx
call sym.testlock.exe_public:_static_void___cdecl_MSFS::StripSlash_char__
add esp, 4
lea edx, [esp + 4]
push edx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x403608
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop esi
add esp, 0x104
ret
xor eax, eax
pop esi
add esp, 0x104
ret

Function at 0x403780
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40379a
test al, 0x10
jne 0x40379a
mov eax, 1
ret
xor eax, eax
ret
Function at 0x4037a0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
test esi, esi
je 0x4037d0
push esi
call sym.testlock.exe_public:_static_int___cdecl_MSSTR::Len_char_const__
add esp, 4
cmp eax, 0x103
jg 0x4037d0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x4037d0
test al, 0x10
je 0x4037d0
mov eax, 1
pop esi
ret
xor eax, eax
pop esi
ret

Function at 0x403ba0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x403bb9
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
ret

Function at 0x403cb0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x308
push esi
mov esi, dword [esp + 0x310]
test esi, esi
jne 0x403ccf
mov eax, 0xffffd846
pop esi
add esp, 0x308
ret
lea eax, [esp + 4]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
test eax, eax
je 0x403d25
lea ecx, [esp + 0x108]
lea edx, [esp + 0x208]
push ecx
push edx
lea eax, [esp + 0xc]
push 0
push eax
call sym.testlock.exe_public:_static_int___cdecl_MSFS::ParsePath_char_const___char___char___char__
add esp, 0x10
lea ecx, [esp + 0x108]
lea edx, [esp + 0x208]
push ecx
push edx
push esi
call sym.testlock.exe_public:_static_int___cdecl_MSFS::AppendPath_char___char_const___char_const__
add esp, 0xc
xor eax, eax
pop esi
add esp, 0x308
ret
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
pop esi
add esp, 0x308
ret

Function at 0x403eb0
Capabilities:
Move file

Disassembly:
mov eax, dword [esp + 8]
mov ecx, dword [esp + 4]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
jne 0x403ecf
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
ret
xor eax, eax
ret

Function at 0x403f50
Capabilities:
Set file attributes

Disassembly:
mov eax, dword [esp + 4]
test eax, eax
jne 0x403f5e
mov eax, 0xffffd846
ret
mov ecx, dword [esp + 8]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
cmp eax, 1
jne 0x403f72
xor eax, eax
ret
push 0xffffffffffffffff
call sym.testlock.exe_public:_static_int___cdecl_MSFS::MapERS_Errno_int_
add esp, 4
ret