Function at 0x402280
Capabilities:
Copy file
Create directory
Delete directory
Delete file
Enumerate files on windows

Disassembly:
mov eax, 0x81158
call fcn.0040b8d0
mov eax, dword [esp + 0x8115c]
push ebx
push ebp
push esi
xor esi, esi
xor ebp, ebp
lea edx, [esp + 0x1164]
push edi
mov dword [esp + 0x18], ebp
mov dword [esp + 0x20], esi
sub edx, eax
lea ebx, [ebx]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4022b0
mov eax, dword [esp + 0x81170]
cmp eax, esi
je 0x4022da
lea edx, [esp + 0x41168]
sub edx, eax
mov edi, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4022d0
lea ebx, [esp + 0x1168]
neg ebx
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], ebx
jmp 0x4022f0
lea eax, [esp + esi + 0x1168]
lea edx, [esp + ebx + 0xd68]
mov edi, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402300
lea edi, [esp + 0xd68]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402312
mov ax, word [0x41924c]
mov word [edi], ax
lea edi, [esp + 0xd68]
dec edi
jmp 0x402330
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402330
mov ecx, dword [0x4192f4]
lea edx, [esp + 0x828]
push edx
lea eax, [esp + 0xd6c]
push eax
mov dword [edi], ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [esp + 0x24], eax
je 0x4027be
mov eax, dword [esp + 0x81170]
test eax, eax
je 0x402380
push 0
lea ecx, [esp + esi + 0x4116c]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
jmp 0x40238e
lea eax, [esp + esi + 0x1168]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
mov eax, ebp
shl eax, 0xa
mov edx, eax
lea ecx, [esp + 0x428]
sub edx, ecx
lea ecx, [esp + 0x28]
lea edx, [esp + edx + 0x41168]
sub eax, ecx
mov dword [esp + 0x1c], edx
lea ebx, [esp + eax + 0x1168]
jmp 0x4023c0
mov edx, dword [esp + 0x828]
shr edx, 4
and edx, 1
xor eax, eax
nop
mov cl, byte [esp + eax + 0x854]
mov byte [esp + eax + 0x968], cl
inc eax
test cl, cl
jne 0x4023d0
test edx, edx
mov esi, dword [0x421044]
lea eax, [esp + 0x968]
je 0x4025d3
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x40241c
test cl, cl
je 0x402418
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x40241c
add eax, 2
add esi, 2
test cl, cl
jne 0x4023f8
xor eax, eax
jmp 0x402421
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40278c
mov esi, dword [0x421040]
lea eax, [esp + 0x968]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x40245a
test cl, cl
je 0x402456
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x40245a
add eax, 2
add esi, 2
test cl, cl
jne 0x402436
xor eax, eax
jmp 0x40245f
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40278c
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
lea eax, [esp + eax + 0x1168]
lea edx, [esp + edx + 0x28]
lea ebx, [ebx]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402480
lea eax, [esp + 0x28]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402491
mov bp, word [0x41924c]
sub eax, edx
cmp byte [esp + eax + 0x27], 0x5c
je 0x4024bb
lea edi, [esp + 0x28]
dec edi
lea ecx, [ecx]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4024b0
mov word [edi], bp
lea eax, [esp + 0x968]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4024c4
lea edi, [esp + 0x28]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4024d2
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [esp + 0x81170]
and ecx, 3
test eax, eax
rep movsb byte es:[edi], byte [esi]
je 0x40257d
mov eax, dword [esp + 0x10]
lea eax, [esp + eax + 0x41168]
lea edx, [esp + 0x428]
sub edx, eax
lea ecx, [ecx]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402510
lea eax, [esp + 0x428]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402524
sub eax, edx
cmp byte [esp + eax + 0x427], 0x5c
je 0x40254b
lea edi, [esp + 0x428]
dec edi
nop
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402540
mov word [edi], bp
lea eax, [esp + 0x968]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402554
lea edi, [esp + 0x428]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402565
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
inc edx
add ebx, 0x400
add eax, 0x400
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], edx
lea eax, [esp + 0x28]
lea ecx, [ecx]
mov cl, byte [eax]
mov byte [ebx + eax], cl
inc eax
test cl, cl
jne 0x4025a0
mov eax, dword [esp + 0x81170]
test eax, eax
je 0x40278c
mov edx, dword [esp + 0x1c]
lea eax, [esp + 0x428]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4025c4
jmp 0x40278c
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x4025f7
test cl, cl
je 0x4025f3
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x4025f7
add eax, 2
add esi, 2
test cl, cl
jne 0x4025d3
xor eax, eax
jmp 0x4025fc
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40278c
mov esi, dword [0x421040]
lea eax, [esp + 0x968]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x402635
test cl, cl
je 0x402631
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x402635
add eax, 2
add esi, 2
test cl, cl
jne 0x402611
xor eax, eax
jmp 0x40263a
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40278c
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
lea eax, [esp + eax + 0x1168]
lea edx, [esp + edx + 0x28]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402655
lea eax, [esp + 0x28]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402666
mov bp, word [0x41924c]
sub eax, edx
cmp byte [esp + eax + 0x27], 0x5c
je 0x40268d
lea edi, [esp + 0x28]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402682
mov word [edi], bp
lea eax, [esp + 0x968]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402696
lea edi, [esp + 0x28]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4026a4
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [esp + 0x81170]
and ecx, 3
test eax, eax
rep movsb byte es:[edi], byte [esi]
je 0x402781
mov eax, dword [esp + 0x10]
lea eax, [esp + eax + 0x41168]
lea edx, [esp + 0x428]
sub edx, eax
nop
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4026e0
lea eax, [esp + 0x428]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4026f4
sub eax, edx
cmp byte [esp + eax + 0x427], 0x5c
je 0x40271b
lea edi, [esp + 0x428]
dec edi
nop
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402710
mov word [edi], bp
lea eax, [esp + 0x968]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402724
lea edi, [esp + 0x428]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402735
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
push 0
lea eax, [esp + 0x42c]
rep movsb byte es:[edi], byte [esi]
push eax
lea ecx, [esp + 0x30]
push ecx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x402829
lea edx, [esp + 0x428]
push 0x180
push edx
call fcn.0040b965
add esp, 8
jmp 0x40278c
lea eax, [esp + 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x828]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4023c0
mov eax, dword [esp + 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x10]
mov ebx, dword [esp + 0x14]
mov eax, dword [esp + 0x20]
inc eax
add esi, 0x400
sub ebx, 0x400
lea ecx, [ebp + 1]
cmp eax, ecx
mov dword [esp + 0x20], eax
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], ebx
jl 0x4022f0
mov eax, dword [esp + 0x81170]
test eax, eax
jne 0x40281c
test ebp, ebp
jl 0x40281c
mov ebx, dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
mov edx, ebp
shl edx, 0xa
lea esi, [esp + edx + 0x1168]
lea edi, [ebp + 1]
lea ebx, [ebx]
push esi
call ebx
sub esi, 0x400
dec edi
jne 0x402810
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x81158
ret
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x81158
ret