Function at 0x4035c0
Capabilities:
Copy file
Create directory

Disassembly:
sub esp, 0x830
push ebx
push ebp
push esi
push edi
call fcn.00407000
mov ebp, dword [esp + 0x848]
mov esi, 1
push esi
mov dword [esp + 0x20], eax
lea eax, [esp + 0x18]
push 0x461214
push eax
mov dword [ebp + 8], 0
mov dword [ebp + 0x10], str.CFail
mov dword [ebp + 0x14], str.Canary_Failed
call fcn.00404fe0
mov ecx, dword [esp + 0x20]
push esi
lea edx, [esp + 0x20]
push 0x461214
push edx
mov dword [ecx + 0x10], esi
call fcn.00404fe0
mov eax, dword [esp + 0x28]
mov dword [eax + 0x10], esi
mov ecx, dword [esp + 0x28]
push ecx
call fcn.004045b0
mov ebx, dword [esp + 0x868]
push ebx
push 0x461910
lea edx, [esp + 0x44]
push 0x104
push edx
call fcn.00431593
add esp, 0x2c
xor eax, eax
push eax
lea ecx, [esp + 0x24]
push ecx
mov word [esp + 0x22e], ax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
xor esi, esi
lea edi, [esp + 0x228]
lea ebx, [ebx]
mov edx, dword [esi*4 + 0x474004]
push edx
push ebx
push 0x4613a4
push 0x104
push edi
call fcn.00431593
mov ecx, dword [esp + 0x864]
add esp, 0x14
xor eax, eax
push eax
push edi
push ecx
mov word [edi + 0x206], ax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x403738
mov edx, dword [esi*4 + 0x474004]
push edx
call fcn.00404570
push eax
mov eax, dword [esp + 0x18]
push eax
call fcn.00404b00
mov ecx, dword [esp + 0x1c]
mov edx, dword [esi*4 + 0x474004]
add esp, 0xc
push 0x46190c
push str.DYNAMORIO_RUNUNDER
push ecx
push edx
call fcn.004044d0
add esp, 8
push eax
call fcn.00404770
inc esi
add esp, 0xc
add edi, 0x208
cmp esi, 3
jb 0x403670
mov edx, dword [esp + 0x10]
push edx
call fcn.00406630
add esp, 4
call fcn.00406fe0
test byte [ebp], 1
mov esi, dword [esp + 0x844]
je 0x4037b8
test byte [ebp + 0xa48], 1
je 0x40376f
mov eax, dword [ebp + 0xa4c]
mov dword [esp + 0x18], eax
jmp 0x403777
mov ecx, dword [esp + 0x850]
imul esi, esi, 0x208
lea eax, [esp + esi + 0x228]
mov esi, dword [esp + 0x844]
push eax
push ecx
push str.Failed_to_copy_canary_file__S_to__S_n
push esi
call fcn.0043011a
add esp, 0x10
mov dword [ebp + 8], 1
jmp 0x403a8f
mov dword [esp + 0x18], str.__list_modules__check_for_hooked_mods_list_ntdll.dll
xor edi, edi
lea ebx, [esp + 0x228]
mov ecx, dword [esp + 0x18]
push 0
push str.native
push 0
push ecx
mov ecx, dword [esp + 0x20]
push ebx
push 0x461158
lea edx, [esp + 0x38]
push edx
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x4037d8
inc edi
add ebx, 0x208
cmp edi, 3
jb 0x403780
call fcn.00406fa0
test byte [ebp], 2
je 0x403884
test byte [ebp + 0xa48], 2
je 0x4037ec
mov ebx, dword [ebp + 0xa4c]
jmp 0x4037f1
test byte [ebp + 2], 1
jne 0x4037b8
shl eax, 0x10
or eax, 1
mov dword [ebp + 8], eax
jmp 0x403a8f
mov ebx, str._wait
xor edi, edi
lea ebp, [esp + 0x228]
lea ebx, [ebx]
mov ecx, dword [esp + 0x10]
push 0
push str._thin_client
push 1
push ebx
push ebp
push str._thin_client__syslog_mask_0
lea eax, [esp + 0x38]
push eax
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x403865
push 1
push str._thin_client
push 1
push ebx
push ebp
push str._thin_client__syslog_mask_0
lea ecx, [esp + 0x38]
push ecx
mov ecx, dword [esp + 0x2c]
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x403865
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x403800
mov ebp, dword [esp + 0x848]
jmp 0x403884
mov edx, dword [esp + 0x848]
test byte [edx + 2], 2
jne 0x403882
shl eax, 0x10
or eax, 1
mov ecx, edx
mov dword [ecx + 8], eax
jmp 0x403a8d
mov ebp, edx
test byte [ebp], 4
je 0x403913
test byte [ebp + 0xa48], 4
je 0x40389f
mov ebx, dword [ebp + 0xa4c]
jmp 0x4038a4
mov ebx, 0x461158
xor edi, edi
lea ebp, [esp + 0x228]
lea ecx, [ecx]
mov ecx, dword [esp + 0x10]
push 0
push str._thin_client
push 0
push ebx
push ebp
push str._thin_client__syslog_mask_0
lea edx, [esp + 0x38]
push edx
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x40392e
mov ecx, dword [esp + 0x10]
push 1
push str._thin_client
push 0
push ebx
push ebp
push str._thin_client__syslog_mask_0
lea eax, [esp + 0x38]
push eax
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x40392e
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x4038b0
mov ebp, dword [esp + 0x848]
test byte [ebp], 8
je 0x4039e4
test byte [ebp + 0xa48], 8
je 0x40394d
mov ebx, dword [ebp + 0xa4c]
jmp 0x403952
mov ecx, dword [esp + 0x848]
test byte [ecx + 2], 4
mov ebp, ecx
jne 0x403913
shl eax, 0x10
or eax, 1
mov edx, ecx
mov dword [edx + 8], eax
jmp 0x403a8f
mov ebx, 0x461158
xor edi, edi
lea ebp, [esp + 0x228]
jmp 0x403960
mov ecx, dword [esp + 0x10]
push 0
push str._client
push 0
push ebx
push ebp
push str._client__syslog_mask_0
lea eax, [esp + 0x38]
push eax
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x4039c5
push 1
push str._client
push 0
push ebx
push ebp
push str._client__syslog_mask_0
lea ecx, [esp + 0x38]
push ecx
mov ecx, dword [esp + 0x2c]
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x4039c5
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x403960
mov ebp, dword [esp + 0x848]
jmp 0x4039e4
mov edx, dword [esp + 0x848]
test byte [edx + 2], 8
jne 0x4039e2
shl eax, 0x10
or eax, 1
mov ecx, edx
mov dword [ecx + 8], eax
jmp 0x403a8d
mov ebp, edx
test byte [ebp], 0x10
je 0x403a8f
test byte [ebp + 0xa48], 0x10
je 0x4039ff
mov ebx, dword [ebp + 0xa4c]
jmp 0x403a04
mov ebx, 0x461158
xor edi, edi
lea ebp, [esp + 0x228]
lea ecx, [ecx]
mov ecx, dword [esp + 0x10]
push 0
push 0x4617b4
push 0
push ebx
push ebp
push str._apc_policy_0__syslog_mask_0
lea edx, [esp + 0x38]
push edx
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x403a75
mov ecx, dword [esp + 0x10]
push 1
push 0x4617b4
push 0
push ebx
push ebp
push str._apc_policy_0__syslog_mask_0
lea eax, [esp + 0x38]
push eax
push esi
mov edx, edi
call fcn.004030a0
add esp, 0x20
test eax, eax
js 0x403a75
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x403a10
mov ebp, dword [esp + 0x848]
jmp 0x403a8f
mov ecx, dword [esp + 0x848]
test byte [ecx + 2], 0x10
jne 0x403a8d
shl eax, 0x10
or eax, 1
mov edx, ecx
mov dword [edx + 8], eax
mov ebp, ecx
cmp dword [esp + 0x1c], 0
je 0x403a9d
call fcn.00406fa0
jmp 0x403aa2
call fcn.00406fe0
mov eax, dword [esp + 0x10]
push eax
call fcn.00404640
mov ecx, dword [esp + 0x18]
push ecx
call fcn.00406630
mov edx, dword [esp + 0x1c]
push edx
call fcn.00404640
mov eax, dword [ebp + 8]
push eax
push str.Canary_code_0x_08x_n
push esi
call fcn.0043011a
mov eax, dword [ebp + 8]
add esp, 0x18
test eax, eax
js 0x403ae7
mov dword [ebp + 0x10], str.ctest
mov dword [ebp + 0x14], str.Canary_success
xor ecx, ecx
test eax, eax
setns cl
pop edi
pop esi
pop ebp
pop ebx
mov eax, ecx
add esp, 0x830
ret