Function at 0x5d7bbe
Capabilities:
Create directory
Write file on windows

Disassembly:
push ebp
sub esp, 0x64
mov eax, 0x684cb3
call fcn.0062921c
sub esp, 0x124
push esi
mov esi, ecx
push edi
mov dword [ebp + 0x64], esi
lea edi, [esi + 0x16c]
push edi
call fcn.0047f706
push dword [0x76417c]
mov ecx, edi
call fcn.0043429b
test eax, eax
jne 0x5d7c35
call fcn.005e0389
test al, al
je 0x5d7c35
push dword [ebp + 0x70]
push esi
call fcn.005d77ac
cmp dword [edi + 0x14], 8
jb 0x5d7bfc
mov edi, dword [edi]
add esi, 0xdc
cmp dword [esi + 0x14], 0x10
jb 0x5d7c0a
mov esi, dword [esi]
push edi
call fcn.00476cf7
push eax
push 0xffffffffffffffff
push esi
call fcn.00476bb6
push eax
push 0x8020
push dword [0x7a12c8]
call dword [sym.imp.USER32.dll_PostMessageW]
mov eax, 0x666
jmp 0x5d8142
push ebx
push dword [0x764180]
mov ecx, edi
call fcn.0043429b
or dword [ebp + 0x40], 0xffffffff
xor ebx, ebx
inc ebx
test eax, eax
jne 0x5d7c75
call fcn.005c50d6
test eax, eax
je 0x5d7d06
mov ecx, dword [0x77ddd0]
push 0x2710
call fcn.005c4fe5
test al, al
jne 0x5d7d06
jmp 0x5d7ced
lea eax, [esi + 0xf4]
cmp dword [eax + 0x10], 0
je 0x5d7d06
push eax
lea eax, [ebp + 0x48]
push eax
call fcn.0043beee
and dword [ebp - 4], 0
cmp dword [ebp + 0x5c], 8
mov eax, dword [ebp + 0x48]
jae 0x5d7c9f
lea eax, [ebp + 0x48]
mov dword [ebp + 0x30], eax
lea eax, [ebp + 0x30]
push eax
mov dword [ebp + 0x34], 0x6e68b4
call fcn.0045e07a
test al, al
je 0x5d7cf7
push str.inprocess
lea ecx, [ebp]
call fcn.0040a58f
lea eax, [esi + 4]
xor ebx, ebx
push eax
lea eax, [ebp]
xor esi, esi
push eax
inc ebx
push esi
mov byte [ebp - 4], bl
call fcn.005d78fc
push esi
push ebx
lea ecx, [ebp]
call fcn.0040abbf
push esi
push ebx
lea ecx, [ebp + 0x48]
call fcn.0042386b
mov eax, 0x666
jmp 0x5d8141
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x48]
push 0
push ebx
call fcn.0042386b
lea ecx, [ebp - 0xa4]
call fcn.00609a45
xor eax, eax
mov dword [ebp - 4], 2
push eax
push eax
push eax
push eax
push eax
push str.BtAppInstallTail
lea ecx, [ebp - 0xa4]
call fcn.0057ddac
lea ecx, [ebp - 0xa4]
call fcn.00609b39
push 0x14
lea eax, [ebp - 0x5c]
push eax
call fcn.00467924
lea eax, [ebp - 0x5c]
push eax
push 0x29
lea eax, [ebp - 0x130]
push eax
call fcn.0046b894
lea eax, [esi + 0x34]
push eax
lea ecx, [ebp - 0x3c]
call fcn.00423207
cmp dword [ebp - 0x2c], 0
mov byte [ebp - 4], 3
jne 0x5d7dab
add esi, 4
cmp dword [esi + 0x14], 8
jb 0x5d7d7a
mov eax, dword [esi]
jmp 0x5d7d7c
mov eax, esi
push 0x5c
push eax
call fcn.0062e51b
pop ecx
pop ecx
test eax, eax
je 0x5d7d8f
lea esi, [eax + 2]
jmp 0x5d7d97
cmp dword [esi + 0x14], 8
jb 0x5d7d97
mov esi, dword [esi]
push esi
call fcn.00423ad9
pop ecx
push eax
push esi
lea ecx, [ebp - 0x3c]
call fcn.004340c0
mov esi, dword [ebp + 0x64]
cmp dword [edi + 0x14], 8
jb 0x5d7db5
mov ecx, dword [edi]
jmp 0x5d7db7
mov ecx, edi
cmp dword [ebp - 0x28], 8
mov eax, dword [ebp - 0x3c]
jae 0x5d7dc3
lea eax, [ebp - 0x3c]
push ecx
or ecx, 0xffffffff
push ecx
push ecx
push eax
lea eax, [ebp - 0x5c]
push eax
call fcn.004790ec
lea eax, [esi + 0x10c]
push eax
lea eax, [ebp - 0xbc]
push eax
call fcn.0043beee
cmp dword [eax + 0x14], 8
mov byte [ebp - 4], 4
jb 0x5d7df2
mov eax, dword [eax]
push eax
push 0x76c5e8
lea eax, [ebp + 0x18]
push 0x694790
push eax
call fcn.004607f4
add esp, 0x10
push 0
push ebx
lea ecx, [ebp - 0xbc]
mov byte [ebp - 4], 6
call fcn.0042386b
cmp dword [ebp + 0x2c], 8
mov eax, dword [ebp + 0x18]
jae 0x5d7e27
lea eax, [ebp + 0x18]
push eax
call fcn.0045c1b0
cmp dword [ebp + 0x2c], 8
mov eax, dword [ebp + 0x18]
jae 0x5d7e39
lea eax, [ebp + 0x18]
push 0
push eax
call dword [sym.imp.KERNEL32.DLL_CreateDirectoryW]
mov esi, dword [esi]
lea eax, [ebp - 0x48]
push eax
lea ecx, [esi + 0x24]
call fcn.004200b1
lea eax, [ebp + 0xc]
push eax
lea ecx, [esi + 0x24]
call fcn.00420099
mov edx, dword [ebp - 0x40]
mov esi, dword [ebp + 0x64]
jmp 0x5d8003
mov eax, dword [ebp - 0x48]
test eax, eax
je 0x5d7e70
mov eax, dword [eax]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
dec ecx
and ecx, edx
mov eax, dword [eax + ecx*4]
mov dword [ebp + 0x60], eax
cmp dword [eax + 0x14], 0x10
jb 0x5d7e8a
mov eax, dword [eax]
mov dword [ebp + 0x60], eax
push eax
lea eax, [ebp - 0xd4]
push eax
call fcn.004785a1
cmp dword [eax + 0x14], 8
mov byte [ebp - 4], 7
jb 0x5d7ea3
mov eax, dword [eax]
cmp dword [ebp + 0x2c], 8
mov ecx, dword [ebp + 0x18]
jae 0x5d7eaf
lea ecx, [ebp + 0x18]
push eax
push ecx
lea eax, [ebp + 0x48]
push 0x694790
push eax
call fcn.004607f4
add esp, 0x10
push 0
push ebx
lea ecx, [ebp - 0xd4]
mov byte [ebp - 4], 9
call fcn.0042386b
mov edx, dword [ebp + 0x60]
mov ecx, edx
lea eax, [ecx + 1]
mov dword [ebp + 0x64], eax
mov al, byte [ecx]
inc ecx
test al, al
jne 0x5d7edf
sub ecx, dword [ebp + 0x64]
push 0x2f
push edx
mov dword [ebp + 0x64], ecx
call fcn.0062c620
sub eax, dword [ebp + 0x60]
pop ecx
pop ecx
mov ecx, dword [ebp + 0x64]
dec ecx
cmp eax, ecx
mov eax, dword [ebp + 0x48]
jne 0x5d7f1b
cmp dword [ebp + 0x5c], 8
jae 0x5d7f0d
lea eax, [ebp + 0x48]
push 0
push eax
call dword [sym.imp.KERNEL32.DLL_CreateDirectoryW]
jmp 0x5d7ff0
cmp dword [ebp + 0x5c], 8
jae 0x5d7f24
lea eax, [ebp + 0x48]
xor ecx, ecx
push ecx
push 0x80
push 2
push ecx
push ecx
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov dword [ebp + 0x64], eax
cmp eax, 0xffffffff
jne 0x5d7f7f
push 0
lea eax, [ebp + 0x48]
push eax
call fcn.0045ba8d
cmp dword [ebp + 0x5c], 8
mov eax, dword [ebp + 0x48]
jae 0x5d7f5b
lea eax, [ebp + 0x48]
xor ecx, ecx
push ecx
push 0x80
push 2
push ecx
push ecx
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov dword [ebp + 0x64], eax
cmp eax, 0xffffffff
je 0x5d8155
mov eax, dword [esi]
push dword [ebp + 0x60]
mov dword [ebp + 0x3c], eax
lea eax, [ebp - 0xec]
push eax
call fcn.004785a1
cmp dword [eax + 0x14], 8
mov byte [ebp - 4], 0xb
jb 0x5d7f9f
mov eax, dword [eax]
lea ecx, [ebp + 0x38]
push ecx
push eax
push dword [ebp + 0x3c]
call fcn.0047d089
push 0
push ebx
lea ecx, [ebp - 0xec]
mov dword [ebp + 0x60], eax
mov byte [ebp - 4], 9
call fcn.0042386b
push 0
lea eax, [ebp + 0x34]
push eax
push dword [ebp + 0x38]
push dword [ebp + 0x60]
push dword [ebp + 0x64]
call dword [sym.imp.KERNEL32.DLL_WriteFile]
test eax, eax
je 0x5d81ae
push ebx
push dword [ebp + 0x60]
call fcn.0045b404
push dword [ebp + 0x64]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
push 0
push ebx
lea ecx, [ebp + 0x48]
mov byte [ebp - 4], 6
call fcn.0042386b
mov edx, dword [ebp + 0x44]
inc edx
mov dword [ebp + 0x44], edx
cmp edx, dword [ebp + 0x14]
jne 0x5d7e67
lea eax, [esi + 0x1c]
cmp dword [eax + 0x14], 8
jb 0x5d801a
mov eax, dword [eax]
lea ecx, [ebp - 0x130]
push ecx
push eax
lea eax, [ebp - 0x104]
push str.BTAPPS__s__PAIRINGKEY__S_
push eax
call fcn.004607f4
add esp, 0x10
push dword [ebp + 0x70]
mov byte [ebp - 4], 0xd
push esi
call fcn.005d77ac
call fcn.0046fc62
lea ecx, [ebp - 0xa4]
call fcn.00609b80
push dword [ebp - 0xa0]
call dword [sym.imp.USER32.dll_DestroyWindow]
call fcn.00409944
cmp dword [edi + 0x14], 8
jb 0x5d806c
mov edi, dword [edi]
lea eax, [esi + 0xdc]
cmp dword [eax + 0x14], 0x10
mov dword [ebp + 0x70], eax
jb 0x5d8080
mov eax, dword [eax]
mov dword [ebp + 0x70], eax
push edi
call fcn.00476cf7
push eax
push 0xffffffffffffffff
push dword [ebp + 0x70]
call fcn.00476bb6
push eax
push 0x8020
push dword [0x7a12c8]
call dword [sym.imp.USER32.dll_PostMessageW]
mov edi, 0x68eb70
push edi
call fcn.00423ad9
pop ecx
push eax
push edi
lea ecx, [esi + 0x188]
call fcn.004340c0
add esi, 4
cmp dword [esi + 0x14], 8
jb 0x5d80c7
mov esi, dword [esi]
push esi
call fcn.0045b811
push eax
lea ecx, [ebp]
call fcn.00424ff1
push str.install
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 0xe
call fcn.0040a58f
lea eax, [ebp]
mov byte [ebp - 4], 0xf
push eax
lea eax, [ebp - 0x24]
push eax
push ebx
call fcn.005d78fc
xor esi, esi
lea ecx, [ebp - 0x24]
push esi
push ebx
call fcn.0040abbf
push esi
push ebx
lea ecx, [ebp]
call fcn.0042386b
push esi
push ebx
lea ecx, [ebp - 0x104]
call fcn.0042386b
mov dword [ebp + 0x40], esi
push esi
push ebx
lea ecx, [ebp + 0x18]
call fcn.0042386b
push esi
push ebx
lea ecx, [ebp - 0x3c]
call fcn.0042386b
lea ecx, [ebp - 0xa4]
call fcn.00609a87
mov eax, dword [ebp + 0x40]
pop ebx
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
lea esp, [ebp + 0x68]
pop ebp
ret 4
push 0x6b3e24
lea ecx, [ebp - 0x24]
call fcn.0040a58f
lea eax, [ebp + 0x48]
mov byte [ebp - 4], 0xa
push eax
lea eax, [ebp - 0x24]
xor esi, esi
push eax
push esi
call fcn.005d78fc
push esi
push ebx
lea ecx, [ebp - 0x24]
call fcn.0040abbf
push esi
push ebx
lea ecx, [ebp + 0x48]
call fcn.0042386b
push esi
push ebx
lea ecx, [ebp + 0x18]
call fcn.0042386b
push esi
push ebx
lea ecx, [ebp - 0x3c]
call fcn.0042386b
lea ecx, [ebp - 0xa4]
call fcn.00609a87
or eax, 0xffffffff
jmp 0x5d8141
push 0x6e68e8
lea ecx, [ebp - 0x24]
call fcn.0040a58f
lea eax, [ebp + 0x48]
mov byte [ebp - 4], 0xc
push eax
lea eax, [ebp - 0x24]
xor esi, esi
push eax
push esi
call fcn.005d78fc
push esi
push ebx
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 9
call fcn.0040abbf
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push dword [ebp + 0x64]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
push ebx
push dword [ebp + 0x60]
call fcn.0045b404
push esi
push ebx
lea ecx, [ebp + 0x48]
call fcn.0042386b
jmp 0x5d811f