Function at 0x402ba0
Capabilities:
Copy file
Create directory
Delete file
Move file
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x4114a3
mov eax, dword fs:[0]
push eax
sub esp, 0x268
mov eax, dword [0x4187e4]
xor eax, esp
mov dword [esp + 0x264], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4187e4]
xor eax, esp
push eax
lea eax, [esp + 0x27c]
mov dword fs:[0], eax
mov dword [esp + 0x284], 3
cmp dword [esp + 0x2d8], 0
mov esi, 8
jne 0x402c3d
mov edx, dword [esp + 0x290]
cmp dword [esp + 0x2a4], esi
jae 0x402c0c
lea edx, [esp + 0x290]
lea ecx, [esp + 0x4c]
call fcn.004025e0
push eax
lea ecx, [esp + 0x2c8]
mov byte [esp + 0x288], 4
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__]
lea ecx, [esp + 0x4c]
mov byte [esp + 0x284], 3
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
cmp dword [esp + 0x2f4], 0
jne 0x402c8f
mov edx, dword [esp + 0x2ac]
cmp dword [esp + 0x2c0], esi
jae 0x402c5e
lea edx, [esp + 0x2ac]
lea ecx, [esp + 0x4c]
call fcn.004025e0
push eax
lea ecx, [esp + 0x2e4]
mov byte [esp + 0x288], 5
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__]
lea ecx, [esp + 0x4c]
mov byte [esp + 0x284], 3
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea eax, [esp + 0x2e0]
push eax
lea ecx, [esp + 0x2c8]
call dword [sym.imp.MSVCP90.dll_public:_int___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::compare_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__const]
test eax, eax
je 0x403206
mov eax, dword [esp + 0x2ac]
cmp dword [esp + 0x2c0], esi
jae 0x402cc3
lea eax, [esp + 0x2ac]
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
lea ecx, [esp + 0x4c]
push ecx
push 0
push eax
call edi
mov ebp, dword [sym.imp.MSVCR90.dll_rand]
cmp eax, 1
jne 0x402e13
mov eax, dword [esp + 0x2ac]
cmp dword [esp + 0x2c0], esi
jae 0x402cf9
lea eax, [esp + 0x2ac]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x402e13
push eax
call dword [sym.imp.MSVCR90.dll__time64]
push eax
call dword [sym.imp.MSVCR90.dll_srand]
add esp, 8
lea ecx, [esp + 0x4c]
mov esi, 5
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
mov byte [esp + 0x284], 6
mov edi, dword [sym.imp.KERNEL32.dll_MoveFileW]
mov bl, 7
push str.RHSN
call ebp
push eax
push str.__d._s
lea edx, [esp + 0x7c]
push 0x104
push edx
call fcn.00403a30
add esp, 0x14
test eax, eax
jge 0x402d81
push eax
push str.StringCchPrintf_fail_err_X
push 0x9a
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 2
push 0x418bd8
call fcn.00407780
add esp, 0x1c
jmp 0x402dc1
lea eax, [esp + 0x70]
push eax
lea ecx, [esp + 0x2ac]
push ecx
lea edx, [esp + 0x1c]
push edx
call dword [sym.imp.MSVCP90.dll_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t_____cdecl_std::operator_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const___wchar_t_const__]
add esp, 0xc
push eax
lea ecx, [esp + 0x50]
mov byte [esp + 0x288], bl
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__]
lea ecx, [esp + 0x14]
mov byte [esp + 0x284], 6
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
dec esi
mov ecx, dword [esp + 0x50]
mov eax, 8
cmp dword [esp + 0x64], eax
jae 0x402dd4
lea ecx, [esp + 0x50]
cmp dword [esp + 0x2c0], eax
mov eax, dword [esp + 0x2ac]
jae 0x402deb
lea eax, [esp + 0x2ac]
push ecx
push eax
call edi
test eax, eax
jne 0x402dfb
test esi, esi
jne 0x402d38
lea ecx, [esp + 0x4c]
mov byte [esp + 0x284], 3
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
lea ecx, [esp + 0x30]
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
mov byte [esp + 0x284], 8
mov esi, 5
mov bl, 9
lea esp, [esp]
dec esi
call ebp
push eax
push 0x413394
lea eax, [esp + 0x78]
push 0x104
push eax
call fcn.00403a30
add esp, 0x10
test eax, eax
jge 0x402e75
push eax
push str.StringCchPrintf_fail_err_X
push 0xb2
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 2
push 0x418bd8
call fcn.00407780
add esp, 0x1c
jmp 0x402ed1
lea ecx, [esp + 0x70]
push ecx
lea edx, [esp + 0x2ac]
push edx
lea eax, [esp + 0x54]
push eax
call dword [sym.imp.MSVCP90.dll_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t_____cdecl_std::operator_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const___wchar_t_const__]
add esp, 0xc
push eax
lea ecx, [esp + 0x34]
mov byte [esp + 0x288], bl
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t___const__]
lea ecx, [esp + 0x4c]
mov byte [esp + 0x284], 8
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
cmp dword [esp + 0x48], 8
mov eax, dword [esp + 0x34]
jae 0x402ec3
lea eax, [esp + 0x34]
lea ecx, [esp + 0x4c]
push ecx
push 0
push eax
call edi
test eax, eax
je 0x402ed9
test esi, esi
jne 0x402e30
lea eax, [esp + 0x30]
call fcn.004035a0
mov edx, dword [sym.imp.MSVCP90.dll_unsigned_int_const_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::npos]
mov eax, dword [edx]
push eax
push 0x5c
lea ecx, [esp + 0x38]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_int___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::rfind_wchar_t__unsigned_int_const]
mov ecx, dword [sym.imp.MSVCP90.dll_unsigned_int_const_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::npos]
mov edi, eax
cmp dword [ecx], edi
jne 0x402f3f
mov eax, dword [esp + 0x34]
mov edi, 8
cmp dword [esp + 0x48], edi
jae 0x402f16
lea eax, [esp + 0x34]
push eax
push str.Cant_find_fileName_from__s
push 0xc3
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 2
push 0x418bd8
call fcn.00407780
add esp, 0x1c
jmp 0x403008
xor eax, eax
mov ebp, vtable.ATL::CSecurityDesc.0
mov dword [esp + 0x20], ebp
mov dword [esp + 0x24], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
lea edx, [esp + 0x14]
push 0x10000000
mov bl, 0xa
push edx
mov byte [esp + 0x28c], bl
call fcn.0040c8a0
add esp, 8
push edi
mov esi, eax
push 0
lea eax, [esp + 0x54]
push eax
lea ecx, [esp + 0x3c]
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t_____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::substr_unsigned_int__unsigned_int_]
mov byte [esp + 0x284], 0xb
mov eax, dword [esp + 0x50]
mov edi, 8
cmp dword [esp + 0x64], edi
jae 0x402fa4
lea eax, [esp + 0x50]
push esi
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
mov ecx, dword [esp + 0x50]
cmp dword [esp + 0x64], edi
jae 0x402fbc
lea ecx, [esp + 0x50]
push eax
push esi
push ecx
push str.SHCreateDirectoryExW__s___p____d
push 0xcb
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 5
push 0x418bd8
call fcn.00407780
add esp, 0x24
lea ecx, [esp + 0x4c]
mov byte [esp + 0x284], bl
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
mov byte [esp + 0x284], 8
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], ebp
call fcn.00402950
mov ecx, dword [esp + 0x34]
cmp dword [esp + 0x48], edi
jae 0x403016
lea ecx, [esp + 0x34]
mov eax, dword [esp + 0x290]
cmp dword [esp + 0x2a4], edi
jae 0x40302d
lea eax, [esp + 0x290]
push 0
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x403102
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x34]
mov esi, eax
cmp dword [esp + 0x48], edi
jae 0x403055
lea ecx, [esp + 0x34]
mov eax, dword [esp + 0x290]
cmp dword [esp + 0x2a4], edi
jae 0x40306c
lea eax, [esp + 0x290]
push esi
push ecx
push eax
push str.CopyDll2IM_Error___s_____s__err_u
push 0xd2
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 2
push 0x418bd8
call fcn.00407780
add esp, 0x24
lea ecx, [esp + 0x30]
mov byte [esp + 0x284], 3
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x28c]
mov byte [esp + 0x284], 2
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x2a8]
mov byte [esp + 0x284], 1
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x2c4]
mov byte [esp + 0x284], 0
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x2e0]
mov dword [esp + 0x284], 0xffffffff
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
mov eax, esi
jmp 0x40325f
mov ecx, dword [esp + 0x34]
cmp dword [esp + 0x48], edi
jae 0x403110
lea ecx, [esp + 0x34]
mov eax, dword [esp + 0x290]
cmp dword [esp + 0x2a4], edi
jae 0x403127
lea eax, [esp + 0x290]
push ecx
push eax
push str.CopyDll2IM_success___s_____s_
push 0xd6
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 5
push 0x418bd8
call fcn.00407780
mov ecx, dword [esp + 0x2cc]
add esp, 0x20
cmp dword [esp + 0x2c0], edi
jae 0x403163
lea ecx, [esp + 0x2ac]
mov eax, dword [esp + 0x34]
cmp dword [esp + 0x48], edi
jae 0x403171
lea eax, [esp + 0x34]
mov ebx, dword [sym.imp.KERNEL32.dll_MoveFileExW]
push 1
push ecx
push eax
call ebx
test eax, eax
jne 0x4031f4
mov ebp, dword [esp + 0x2ac]
cmp dword [esp + 0x2c0], edi
jae 0x403198
lea ebp, [esp + 0x2ac]
cmp dword [esp + 0x48], 8
mov edi, dword [esp + 0x34]
jae 0x4031a7
lea edi, [esp + 0x34]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
push eax
push ebp
push edi
push str.CopyDll2IM_Error___s_____s__err_u
push 0xdc
push str.SDCtrl::SDCopyFile
push str..SDCtrl.cpp
push 2
push 0x418bd8
call fcn.00407780
mov eax, dword [esp + 0x58]
add esp, 0x24
cmp dword [esp + 0x48], 8
jae 0x4031e4
lea eax, [esp + 0x34]
push 4
push 0
push eax
call ebx
call esi
mov esi, eax
jmp 0x403092
lea ecx, [esp + 0x30]
mov byte [esp + 0x284], 3
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x28c]
mov byte [esp + 0x284], 2
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x2a8]
mov byte [esp + 0x284], 1
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x2c4]
mov byte [esp + 0x284], 0
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x2e0]
mov dword [esp + 0x284], 0xffffffff
call dword [sym.imp.MSVCP90.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
xor eax, eax
mov ecx, dword [esp + 0x27c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x264]
xor ecx, esp
call fcn.0040f466
add esp, 0x274
ret