joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10130590
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x14
push ebx
push ebp
push esi
mov esi, dword [esp + 0x24]
mov ebx, edx
mov edx, esi
mov dword [esp + 0xc], ebx
shr edx, 2
xor ebp, ebp
mov dword [esp + 0x10], edx
push edi
mov edi, ecx
mov dword [esp + 0x18], edi
test edx, edx
je 0x10130672
cmp edx, 0x10
jb 0x1013064a
lea eax, [ebx - 4]
lea eax, [eax + edx*4]
lea ecx, [edi - 4]
lea ecx, [ecx + edx*4]
cmp edi, eax
ja 0x101305d7
cmp ecx, ebx
jae 0x1013064a
mov eax, edx
lea ecx, [ebx + 0x30]
and eax, 0xfffffff0
mov esi, ebx
sub esi, edi
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], esi
lea eax, [edi + 0x10]
mov esi, dword [esp + 0x28]
mov edx, dword [esp + 0x1c]
movups xmm0, xmmword [eax - 0x10]
add ebp, 0x10
lea eax, [eax + 0x40]
lea ecx, [ecx + 0x40]
movups xmm1, xmmword [ecx - 0x70]
pxor xmm1, xmm0
movups xmmword [eax - 0x50], xmm1
movups xmm0, xmmword [eax - 0x40]
movups xmm1, xmmword [edx + eax - 0x40]
pxor xmm1, xmm0
movups xmmword [eax - 0x40], xmm1
movups xmm0, xmmword [eax - 0x30]
movups xmm1, xmmword [ecx - 0x50]
pxor xmm1, xmm0
movups xmmword [eax - 0x30], xmm1
movups xmm0, xmmword [eax - 0x20]
movups xmm1, xmmword [ecx - 0x40]
pxor xmm1, xmm0
movups xmmword [eax - 0x20], xmm1
cmp ebp, dword [esp + 0x20]
jb 0x101305f6
mov edx, dword [esp + 0x14]
cmp ebp, edx
jae 0x10130672
mov esi, ebx
lea ecx, [edi + ebp*4]
sub esi, edi
sub edx, ebp
mov ebp, dword [esp + 0x14]
nop dword [eax + eax]
mov eax, dword [esi + ecx]
lea ecx, [ecx + 4]
xor dword [ecx - 4], eax
sub edx, 1
jne 0x10130660
mov esi, dword [esp + 0x28]
shl ebp, 2
sub esi, ebp
mov dword [esp + 0x28], esi
je 0x10130732
add edi, ebp
add ebx, ebp
xor ecx, ecx
test esi, esi
je 0x10130732
cmp esi, 0x40
jb 0x10130713
lea eax, [ebx - 1]
lea edx, [edi - 1]
add eax, esi
add edx, esi
cmp edi, eax
ja 0x101306a6
cmp edx, ebx
jae 0x10130713
mov ebp, esi
lea eax, [edi + 0x10]
mov esi, dword [esp + 0x10]
and ebp, 0xffffffc0
add ebx, 0x30
sub esi, dword [esp + 0x18]
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x28]
mov edx, dword [esp + 0x20]
movups xmm0, xmmword [eax - 0x10]
add ecx, 0x40
lea ebx, [ebx + 0x40]
lea eax, [eax + 0x40]
movups xmm1, xmmword [ebx - 0x70]
pxor xmm1, xmm0
movups xmmword [eax - 0x50], xmm1
movups xmm0, xmmword [eax - 0x40]
movups xmm1, xmmword [edx + eax - 0x40]
pxor xmm1, xmm0
movups xmmword [eax - 0x40], xmm1
movups xmm0, xmmword [eax - 0x30]
movups xmm1, xmmword [ebx - 0x50]
pxor xmm1, xmm0
movups xmm0, xmmword [ebx - 0x40]
movups xmmword [eax - 0x30], xmm1
movups xmm1, xmmword [eax - 0x20]
pxor xmm1, xmm0
movups xmmword [eax - 0x20], xmm1
cmp ecx, ebp
jb 0x101306c5
mov edx, dword [esp + 0x10]
cmp ecx, esi
jae 0x10130732
sub edx, dword [esp + 0x18]
lea eax, [ecx + edi]
sub esi, ecx
mov cl, byte [edx + eax]
lea eax, [eax + 1]
xor byte [eax - 1], cl
sub esi, 1
jne 0x10130724
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret
Function at 0x10130740
Capabilities:
Encode data using xor

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x18]
mov ebp, edx
mov eax, esi
mov dword [esp + 0x10], ebp
shr eax, 2
xor ebx, ebx
xor edx, edx
mov dword [esp + 0xc], eax
push edi
mov edi, ecx
test eax, eax
je 0x101307fe
cmp eax, 8
jb 0x101307cf
mov ecx, eax
mov ebx, edi
and ecx, 0xfffffff8
lea eax, [ebp + 0x10]
xorps xmm3, xmm3
xorps xmm2, xmm2
sub ebx, ebp
nop
movups xmm0, xmmword [eax - 0x10]
lea eax, [eax + 0x20]
movups xmm1, xmmword [edi + edx*4]
add edx, 8
pxor xmm1, xmm0
por xmm3, xmm1
movups xmm1, xmmword [ebx + eax - 0x20]
movups xmm0, xmmword [eax - 0x20]
pxor xmm1, xmm0
por xmm2, xmm1
cmp edx, ecx
jb 0x10130780
mov eax, dword [esp + 0x10]
por xmm2, xmm3
movaps xmm0, xmm2
psrldq xmm0, 8
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 4
por xmm2, xmm0
movd ebx, xmm2
cmp edx, eax
jae 0x101307fe
lea ecx, [edx*4]
mov esi, edi
add ecx, ebp
sub esi, ebp
mov ebp, eax
sub ebp, edx
mov edx, eax
mov eax, dword [ecx + esi]
lea ecx, [ecx + 4]
xor eax, dword [ecx - 4]
or ebx, eax
sub ebp, 1
jne 0x101307e6
mov esi, dword [esp + 0x1c]
mov ebp, dword [esp + 0x14]
shl edx, 2
sub esi, edx
mov dword [esp + 0x1c], esi
jne 0x10130816
pop edi
pop esi
test ebx, ebx
pop ebp
sete al
pop ebx
add esp, 8
ret
add edi, edx
add ebp, edx
mov edx, ebx
mov eax, ebx
shr edx, 0x18
shr eax, 0x10
or dl, al
mov eax, ebx
shr eax, 8
or dl, al
or dl, bl
xor ebx, ebx
mov dword [esp + 0x14], edx
test esi, esi
je 0x101308f0
cmp esi, 0x20
jb 0x101308cd
mov ecx, esi
lea eax, [ebp + 0x10]
mov edx, edi
and ecx, 0xffffffe0
sub edx, ebp
xorps xmm3, xmm3
mov dword [esp + 0x10], edx
xorps xmm2, xmm2
mov edx, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
movups xmm0, xmmword [eax - 0x10]
lea eax, [eax + 0x20]
movups xmm1, xmmword [ebx + edi]
add ebx, 0x20
pxor xmm1, xmm0
por xmm3, xmm1
movups xmm1, xmmword [eax + esi - 0x20]
movups xmm0, xmmword [eax - 0x20]
pxor xmm1, xmm0
por xmm2, xmm1
cmp ebx, ecx
jb 0x10130864
por xmm2, xmm3
mov esi, dword [esp + 0x1c]
movaps xmm0, xmm2
psrldq xmm0, 8
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 4
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 2
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 1
por xmm2, xmm0
movd eax, xmm2
or dl, al
cmp ebx, esi
jae 0x101308f0
sub edi, ebp
lea ecx, [ebx + ebp]
sub esi, ebx
nop dword [eax + eax]
mov al, byte [ecx + edi]
lea ecx, [ecx + 1]
xor al, byte [ecx - 1]
or dl, al
sub esi, 1
jne 0x101308e0
pop edi
pop esi
test dl, dl
pop ebp
sete al
pop ebx
add esp, 8
ret
Function at 0x10132360
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10186f79
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x101e42fc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 0
mov edi, dword [ebp + 8]
lea ecx, [edi + 4]
call fcn.101282e0
mov dword [edi], vtable.CryptoPP::Integer.0
mov ecx, 2
mov dword [edi + 8], 2
call fcn.1012bcb0
mov ecx, 8
call fcn.10130970
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], 0
mov dword [eax + 4], 0
mov eax, dword [edi + 0xc]
mov dword [eax], 0
push 1
push dword [ebp + 0x10]
mov dword [ebp - 4], 0
mov esi, dword [ebx]
push dword [ebp + 0xc]
mov dword [ebp - 0x10], 1
push edi
mov esi, dword [esi + 0x30]
mov ecx, esi
call dword [0x1018a4d4]
mov ecx, ebx
call esi
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 0xc

Function at 0x101359df
Capabilities:
Reference sql statements

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 8]
test ecx, ecx
je 0x10135a26
mov edx, dword [ebp + 0x10]
test edx, edx
je 0x10135a26
mov eax, dword [ebp + 0xc]
test eax, eax
js 0x10135a26
cmp eax, 3
jle 0x10135a13
cmp eax, 4
jne 0x10135a26
push str.SELECT_DISTINCT_PayloadID_FROM_payloads_ORDER_BY_installTime
push edx
push dword [ecx]
call fcn.10136c03
add esp, 0xc
pop ebp
ret
push eax
push str.SELECT_DISTINCT_PayloadID_FROM_payloads_WHERE_installState___d_ORDER_BY_installTime
push edx
push dword [ecx]
call fcn.10136c03
add esp, 0x10
pop ebp
ret
push 0xa
pop eax
pop ebp
ret

Function at 0x10135d73
Capabilities:
Create directory

Disassembly:
push 0x1c
mov eax, 0x101879f8
call fcn.1014dd2d
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x28]
push 4
pop edi
push esi
push eax
call fcn.10136f82
xor ebx, ebx
push esi
mov dword [ebp - 4], ebx
call fcn.10136132
add esp, 0xc
test al, al
jne 0x10135dbb
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
push ebx
cmovae eax, dword [ebp - 0x28]
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
neg eax
sbb eax, eax
and edi, eax
push ebx
push 1
lea ecx, [ebp - 0x28]
call fcn.10135669
mov eax, edi
call fcn.1014dce8
ret
Function at 0x10135dce
Capabilities:
Get common file path
Get startup folder

Disassembly:
push 0x240
mov eax, 0x10187a2b
call fcn.1014dd2d
mov esi, dword [ebp + 8]
xor ecx, ecx
xor eax, eax
mov dword [ebp - 0x21c], 7
mov bl, cl
mov dword [ebp - 0x220], ecx
mov word [ebp - 0x230], ax
lea eax, [ebp - 0x24c]
mov dword [ebp - 4], ecx
push eax
push ecx
push ecx
push 0x2b
push ecx
mov dword [ebp - 0x24c], ecx
call dword [sym.imp.SHELL32.dll_SHGetFolderLocation]
test eax, eax
lea eax, [ebp - 0x218]
push eax
js 0x10135e73
push dword [ebp - 0x24c]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListW]
test eax, eax
je 0x10135e63
cmp word [ebp - 0x218], 0
jne 0x10135e41
xor eax, eax
jmp 0x10135e4e
lea eax, [ebp - 0x218]
push eax
call fcn.1015de0b
pop ecx
push eax
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x230]
call fcn.101358d9
mov bl, 1
push dword [ebp - 0x24c]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
xor edi, edi
jmp 0x10135eb3
xor edi, edi
push edi
push edi
push 0x2b
push edi
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
js 0x10135eb3
cmp word [ebp - 0x218], di
jne 0x10135e91
mov eax, edi
jmp 0x10135e9e
lea eax, [ebp - 0x218]
push eax
call fcn.1015de0b
pop ecx
push eax
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x230]
call fcn.101358d9
mov bl, 1
mov ecx, dword [ebp - 0x220]
test ecx, ecx
je 0x10135f29
cmp dword [ebp - 0x21c], 8
lea eax, [ebp - 0x230]
cmovae eax, dword [ebp - 0x230]
cmp word [eax + ecx*2 - 2], 0x5c
jne 0x10135ee9
lea eax, [ecx - 1]
push edi
push eax
lea ecx, [ebp - 0x230]
call fcn.100e4250
lea eax, [ebp - 0x230]
push eax
lea eax, [ebp - 0x248]
push eax
call fcn.1013703a
pop ecx
pop ecx
push eax
mov ecx, esi
call fcn.101096a0
push edi
push 1
lea ecx, [ebp - 0x248]
call fcn.10135614
mov edi, 0x1018cd08
push edi
call fcn.1015e1d0
pop ecx
push eax
push edi
mov ecx, esi
call fcn.101357bc
push 0
push 1
lea ecx, [ebp - 0x230]
call fcn.10135669
mov al, bl
call fcn.1014dce8
ret

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x101e42fc]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.10136f82
cmp dword [ebp - 8], 8
lea eax, [ebp - 0x1c]
pop ecx
cmovae eax, dword [ebp - 0x1c]
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x10135f7f
test al, 0x10
jbe 0x10135f7f
mov bl, 1
jmp 0x10135f81
xor bl, bl
push 0
push 1
lea ecx, [ebp - 0x1c]
call fcn.10135669
mov ecx, dword [ebp - 4]
mov al, bl
xor ecx, ebp
pop ebx
call fcn.1014d1d5
mov esp, ebp
pop ebp
ret
Function at 0x10136132
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x101e42fc]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.10136f82
cmp dword [ebp - 8], 8
lea eax, [ebp - 0x1c]
pop ecx
cmovae eax, dword [ebp - 0x1c]
pop ecx
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push 0
push 1
lea ecx, [ebp - 0x1c]
lea ebx, [eax - 1]
neg ebx
sbb bl, bl
inc bl
call fcn.10135669
mov ecx, dword [ebp - 4]
mov al, bl
xor ecx, ebp
pop ebx
call fcn.1014d1d5
mov esp, ebp
pop ebp
ret
Function at 0x1013688c
Capabilities:
Reference sql statements

Disassembly:
push 0x28
mov eax, 0x10187b98
call fcn.1014dd2d
mov edi, ecx
xor ebx, ebx
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], ebx
mov byte [ebp - 0x28], bl
lea eax, [ebp - 0x28]
mov dword [ebp - 4], ebx
push eax
lea eax, [edi + 0x30]
push eax
lea esi, [edi + 0x18]
push esi
call fcn.10136038
add esp, 0xc
test al, al
jne 0x101368cc
push 0xa
pop esi
jmp 0x10136a16
lea eax, [ebp - 0x28]
push eax
call fcn.10135f9e
pop ecx
test al, al
jne 0x10136901
lea eax, [ebp - 0x28]
push eax
call fcn.10136132
pop ecx
test al, al
je 0x101368f0
xor esi, esi
inc esi
jmp 0x10136a16
push esi
call fcn.101366f4
mov esi, eax
pop ecx
test esi, esi
jne 0x10136a16
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
push ebx
push dword [ebp + 8]
cmovae eax, dword [ebp - 0x28]
lea esi, [edi + 4]
push esi
push eax
call fcn.100dec70
add esp, 0x10
test eax, eax
je 0x10136931
push eax
mov dword [esi], ebx
call fcn.1013676e
pop ecx
mov esi, eax
jmp 0x10136a16
push 0x7d0
push dword [esi]
call fcn.100dcae0
cmp byte [edi + 0x4c], 0
mov esi, ebx
pop ecx
pop ecx
mov dword [edi], ebx
je 0x10136a16
mov eax, dword [edi + 0x50]
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x34], ebx
sub eax, ebx
je 0x1013697e
sub eax, 1
je 0x10136979
sub eax, 1
jne 0x1013697e
mov dword [ebp - 0x2c], 1
mov dword [ebp - 0x30], 1
push 3
jmp 0x10136980
xor ebx, ebx
inc ebx
jmp 0x10136981
push 2
pop ebx
push str.SELECT_value_FROM_pcd_meta_WHERE_key__schema_version
lea eax, [ebp - 0x34]
push eax
push edi
call fcn.10136dd8
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x101369c9
push dword [ebp - 0x34]
call fcn.1015d446
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x34]
mov dword [esp], str.SELECT_value_FROM_pcd_meta_WHERE_key__schema_compatibility_version
push eax
push edi
call fcn.10136dd8
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x101369c9
push dword [ebp - 0x34]
call fcn.1015d446
pop ecx
jmp 0x101369cc
mov eax, dword [ebp - 0x30]
cmp ebx, eax
jge 0x101369d5
push 0xd
pop esi
jmp 0x10136a0d
mov eax, dword [ebp - 0x2c]
inc eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
cmp eax, ebx
jg 0x10136a09
push eax
mov ecx, edi
call fcn.10136a2b
mov esi, eax
test esi, esi
jne 0x101369fe
mov eax, dword [ebp - 0x2c]
inc eax
mov dword [ebp - 0x2c], eax
cmp eax, ebx
jle 0x101369e3
jmp 0x10136a14
mov eax, dword [ebp - 0x30]
xor ecx, ecx
cmp eax, dword [ebp - 0x2c]
cmove esi, ecx
test esi, esi
je 0x10136a14
mov ecx, edi
call fcn.1013685e
xor ebx, ebx
push ebx
push 1
lea ecx, [ebp - 0x28]
call fcn.10135614
mov eax, esi
call fcn.1014dce8
ret 4
Function at 0x10137140
Capabilities:
Access peb ldr_data
Check for peb beingdebugged flag

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10187c9c
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
push edi
mov eax, dword [0x101e42fc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x14], edi
xor eax, eax
mov word [edi], 0
mov byte [edi + 2], 0
mov dword [edi + 4], 0x20000
mov dword [edi + 0x18], 0
mov dword [edi + 0x1c], 7
mov word [edi + 8], ax
mov dword [ebp - 4], eax
mov dword [edi + 0x30], eax
mov dword [edi + 0x34], 7
mov word [edi + 0x20], ax
mov dword [edi + 0x48], eax
mov dword [edi + 0x4c], 7
mov word [edi + 0x38], ax
mov dword [edi + 0x60], eax
mov dword [edi + 0x64], 7
mov word [edi + 0x50], ax
lea esi, [edi + 0x84]
mov dword [edi + 0x68], 0x200000
mov dword [edi + 0x6c], eax
mov dword [edi + 0x70], eax
mov dword [edi + 0x74], eax
mov dword [edi + 0x78], eax
mov dword [edi + 0x7c], eax
mov word [edi + 0x80], 0x100
push 0x40
mov byte [ebp - 4], 3
mov dword [ebp - 0x10], esi
mov dword [esi], eax
mov dword [esi + 4], eax
call fcn.1014d1eb
add esp, 4
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [esi], eax
mov eax, edi
mov byte [edi + 0x8c], 0
mov dword [edi + 0x90], 0x3c
mov word [edi + 0x94], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x1013a9b0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x101e42fc]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
mov eax, edi
mov byte [ebp - 9], 1
cmp dword [edi + 0x14], 8
jb 0x1013a9d7
mov eax, dword [edi]
push 0
push 0x80
push 2
push 0
push 1
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x1013aa34
call fcn.10137740
cmp dword [edi + 0x14], 8
mov ebx, eax
jb 0x1013aa06
mov edi, dword [edi]
mov esi, dword [ebx]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push str.Failed_to_create_file_at_path_:_s_Error:_d
push 0x101a4aec
push ebx
call dword [esi + 0x24]
add esp, 0x14
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1014d1d5
mov esp, ebp
pop ebp
ret
cmp dword [esi + 0x14], 0x10
mov eax, dword [esi + 0x10]
mov dword [ebp - 8], 0
jb 0x1013aa46
mov esi, dword [esi]
push 0
lea ecx, [ebp - 8]
push ecx
push eax
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x1013aa7e
call fcn.10137740
mov esi, eax
mov edi, dword [esi]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_write_in_file_ERROR_VAL:_d_n
push 0x101a4aec
push esi
call dword [edi + 0x24]
add esp, 0x10
mov byte [ebp - 9], 0
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov al, byte [ebp - 9]
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.1014d1d5
mov esp, ebp
pop ebp
ret
Function at 0x1013b700
Capabilities:
Check if file exists
Delete file

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, dword [ebp + 8]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x1013b72e
call fcn.10137740
push ebx
push str.File_does_not_exist_at__s
push eax
mov ecx, dword [eax]
call dword [ecx + 4]
add esp, 0xc
mov al, 1
pop ebx
mov esp, ebp
pop ebp
ret
push ebx
mov byte [ebp - 1], 0
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x1013b727
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push edi
call ebx
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
call fcn.10137740
mov esi, eax
mov edi, dword [esi]
call ebx
push eax
push dword [ebp + 8]
push str.Failed_to_delete_file_at_path:_ls_error:_d
push esi
call dword [edi + 4]
mov al, byte [ebp - 1]
add esp, 0x10
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x1013b780
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
push 0
push 0x80
push 3
push 0
push 1
push 0x40000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
mov dword [ebp - 8], ebx
cmp ebx, 0xffffffff
jne 0x1013b7e4
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
call fcn.10137740
mov edi, eax
mov ebx, dword [edi]
call esi
push eax
push dword [ebp + 8]
push str.Failed_to_open_the_file_handle_at__s._Error___d_
push 0x101a4aec
push edi
call dword [ebx + 0x24]
add esp, 0x14
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
call fcn.10137740
mov esi, dword [ebp + 0x14]
mov edi, dword [ebp + 0x10]
push esi
mov ecx, dword [eax]
push edi
push str.file_size_to_which_we_have_to_extend_is__llu
push eax
call dword [ecx + 4]
add esp, 0x10
push 0
push 0
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x1013b858
push ebx
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
je 0x1013b830
push ebx
mov byte [ebp - 1], 1
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
call fcn.10137740
mov edi, eax
mov ebx, dword [edi]
call esi
push eax
mov eax, dword [ebp + 0x14]
push eax
mov eax, dword [ebp + 0x10]
push eax
push str.Failed_to_set_the_end_of_the_file_to_size__llu._Error____d
jmp 0x1013b87e
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
call fcn.10137740
mov edi, eax
mov ebx, dword [edi]
call esi
push eax
mov eax, dword [ebp + 0x14]
push eax
mov eax, dword [ebp + 0x10]
push eax
push str.Failed_to_resize_the_file_to_size__ld._Error____d
push 0x101a4aec
push edi
call dword [ebx + 0x24]
mov ebx, dword [ebp - 8]
add esp, 0x18
mov byte [ebp - 1], 0
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x1013bae0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x1013baf7
xor al, al
pop esi
pop ebp
ret
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x1013bb32
push edi
call fcn.10137740
mov esi, eax
mov edi, dword [esi]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 8]
push str.Failed_to_get_the_directory_attributes_for____s._Error_is__d.
push 0x101a4aec
push esi
call dword [edi + 0x24]
add esp, 0x14
xor al, al
pop edi
pop ebx
pop esi
pop ebp
ret
call fcn.10137740
push ebx
push esi
push str.The_file_attributes_of_directory____s_is__d
mov ecx, dword [eax]
push eax
call dword [ecx + 4]
add esp, 0x10
shr ebx, 4
and bl, 1
mov al, bl
pop ebx
pop esi
pop ebp
ret

Function at 0x1013bb60
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 8]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x1013bb8a
call fcn.10137740
push dword [ebp + 8]
push str.File_does_not_exist_at__s
mov ecx, dword [eax]
push eax
call dword [ecx + 4]
add esp, 0xc
xor al, al
pop ebp
ret
mov al, 1
pop ebp
ret

Function at 0x1013bbc0
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
test ebx, ebx
je 0x1013bc1f
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x1013bc1f
push ebx
push eax
call fcn.1015c056
add esp, 8
test eax, eax
je 0x1013bc1a
push esi
push edi
call fcn.1015f297
mov ecx, dword [eax]
mov eax, dword [ebp + 0x10]
mov dword [eax], ecx
call fcn.10137740
mov esi, eax
mov edi, dword [esi]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push dword [ebp + 0xc]
push str.Failed_to_rename_file_from__s_to__s._The_error_is_:_d
push 0x101a4aec
push esi
call dword [edi + 0x24]
add esp, 0x18
xor al, al
pop edi
pop esi
pop ebx
pop ebp
ret
mov al, 1
pop ebx
pop ebp
ret
call fcn.10137740
push str.invalid_params_for_renameFile
push eax
mov ecx, dword [eax]
call dword [ecx + 4]
add esp, 8
xor al, al
pop ebx
pop ebp
ret

Function at 0x1013be00
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov edi, eax
test edi, edi
je 0x1013be4c
xor ecx, ecx
lea eax, [edi + 1]
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1015bd59
mov esi, eax
add esp, 4
test esi, esi
je 0x1013be4c
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
jne 0x1013be52
push esi
call fcn.101586be
add esp, 4
pop edi
xor al, al
pop esi
pop ebp
ret
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1013be57
sub ecx, edx
sar ecx, 1
push ecx
mov ecx, dword [ebp + 8]
push esi
call fcn.10001c20
push esi
call fcn.101586be
add esp, 4
mov al, 1
pop edi
pop esi
pop ebp
ret