Function at 0x4068e0
Capabilities:
Copy file
Create directory

Disassembly:
sub esp, 0x830
push ebx
push ebp
push esi
push edi
call fcn.0040adf0
mov ebp, dword [esp + 0x848]
mov esi, 1
push esi
mov dword [esp + 0x20], eax
lea eax, [esp + 0x18]
push 0x465064
push eax
mov dword [ebp + 8], 0
mov dword [ebp + 0x10], str.CFail
mov dword [ebp + 0x14], str.Canary_Failed
call fcn.00408dd0
mov ecx, dword [esp + 0x20]
push esi
lea edx, [esp + 0x20]
push 0x465064
push edx
mov dword [ecx + 0x10], esi
call fcn.00408dd0
mov eax, dword [esp + 0x28]
mov dword [eax + 0x10], esi
mov ecx, dword [esp + 0x28]
push ecx
call fcn.004083a0
mov ebx, dword [esp + 0x868]
push ebx
push 0x465730
lea edx, [esp + 0x44]
push 0x104
push edx
call fcn.00432fb7
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 + 0x478010]
push edx
push ebx
push 0x4651f4
push 0x104
push edi
call fcn.00432fb7
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 0x406a58
mov edx, dword [esi*4 + 0x478010]
push edx
call fcn.00408360
push eax
mov eax, dword [esp + 0x18]
push eax
call fcn.004088f0
mov ecx, dword [esp + 0x1c]
mov edx, dword [esi*4 + 0x478010]
add esp, 0xc
push 0x46572c
push str.DYNAMORIO_RUNUNDER
push ecx
push edx
call fcn.004082c0
add esp, 8
push eax
call fcn.00408560
inc esi
add esp, 0xc
add edi, 0x208
cmp esi, 3
jb 0x406990
mov edx, dword [esp + 0x10]
push edx
call fcn.0040a420
add esp, 4
call fcn.0040add0
test byte [ebp], 1
mov esi, dword [esp + 0x844]
je 0x406ad8
test byte [ebp + 0xa48], 1
je 0x406a8f
mov eax, dword [ebp + 0xa4c]
mov dword [esp + 0x18], eax
jmp 0x406a97
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.00432c6c
add esp, 0x10
mov dword [ebp + 8], 1
jmp 0x406daf
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 0x464770
lea edx, [esp + 0x38]
push edx
push esi
mov edx, edi
call fcn.004063c0
add esp, 0x20
test eax, eax
js 0x406af8
inc edi
add ebx, 0x208
cmp edi, 3
jb 0x406aa0
call fcn.0040ad90
test byte [ebp], 2
je 0x406ba4
test byte [ebp + 0xa48], 2
je 0x406b0c
mov ebx, dword [ebp + 0xa4c]
jmp 0x406b11
test byte [ebp + 2], 1
jne 0x406ad8
shl eax, 0x10
or eax, 1
mov dword [ebp + 8], eax
jmp 0x406daf
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.004063c0
add esp, 0x20
test eax, eax
js 0x406b85
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.004063c0
add esp, 0x20
test eax, eax
js 0x406b85
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x406b20
mov ebp, dword [esp + 0x848]
jmp 0x406ba4
mov edx, dword [esp + 0x848]
test byte [edx + 2], 2
jne 0x406ba2
shl eax, 0x10
or eax, 1
mov ecx, edx
mov dword [ecx + 8], eax
jmp 0x406dad
mov ebp, edx
test byte [ebp], 4
je 0x406c33
test byte [ebp + 0xa48], 4
je 0x406bbf
mov ebx, dword [ebp + 0xa4c]
jmp 0x406bc4
mov ebx, 0x464770
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.004063c0
add esp, 0x20
test eax, eax
js 0x406c4e
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.004063c0
add esp, 0x20
test eax, eax
js 0x406c4e
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x406bd0
mov ebp, dword [esp + 0x848]
test byte [ebp], 8
je 0x406d04
test byte [ebp + 0xa48], 8
je 0x406c6d
mov ebx, dword [ebp + 0xa4c]
jmp 0x406c72
mov ecx, dword [esp + 0x848]
test byte [ecx + 2], 4
mov ebp, ecx
jne 0x406c33
shl eax, 0x10
or eax, 1
mov edx, ecx
mov dword [edx + 8], eax
jmp 0x406daf
mov ebx, 0x464770
xor edi, edi
lea ebp, [esp + 0x228]
jmp 0x406c80
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.004063c0
add esp, 0x20
test eax, eax
js 0x406ce5
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.004063c0
add esp, 0x20
test eax, eax
js 0x406ce5
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x406c80
mov ebp, dword [esp + 0x848]
jmp 0x406d04
mov edx, dword [esp + 0x848]
test byte [edx + 2], 8
jne 0x406d02
shl eax, 0x10
or eax, 1
mov ecx, edx
mov dword [ecx + 8], eax
jmp 0x406dad
mov ebp, edx
test byte [ebp], 0x10
je 0x406daf
test byte [ebp + 0xa48], 0x10
je 0x406d1f
mov ebx, dword [ebp + 0xa4c]
jmp 0x406d24
mov ebx, 0x464770
xor edi, edi
lea ebp, [esp + 0x228]
lea ecx, [ecx]
mov ecx, dword [esp + 0x10]
push 0
push 0x465604
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.004063c0
add esp, 0x20
test eax, eax
js 0x406d95
mov ecx, dword [esp + 0x10]
push 1
push 0x465604
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.004063c0
add esp, 0x20
test eax, eax
js 0x406d95
inc edi
add ebp, 0x208
cmp edi, 3
jb 0x406d30
mov ebp, dword [esp + 0x848]
jmp 0x406daf
mov ecx, dword [esp + 0x848]
test byte [ecx + 2], 0x10
jne 0x406dad
shl eax, 0x10
or eax, 1
mov edx, ecx
mov dword [edx + 8], eax
mov ebp, ecx
cmp dword [esp + 0x1c], 0
je 0x406dbd
call fcn.0040ad90
jmp 0x406dc2
call fcn.0040add0
mov eax, dword [esp + 0x10]
push eax
call fcn.00408430
mov ecx, dword [esp + 0x18]
push ecx
call fcn.0040a420
mov edx, dword [esp + 0x1c]
push edx
call fcn.00408430
mov eax, dword [ebp + 8]
push eax
push str.Canary_code_0x_08x_n
push esi
call fcn.00432c6c
mov eax, dword [ebp + 8]
add esp, 0x18
test eax, eax
js 0x406e07
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