Function at 0x40d140
Capabilities:
Encode data using xor
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x59a49c
mov eax, dword fs:[0]
push eax
sub esp, 0x2b8
push ebx
push esi
push edi
mov eax, dword [0x6d48e0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push dword [ebp + 8]
push 0
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
je 0x40d9f1
push 0
push 0
push 0x10
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
cmp dword [0x6e51d4], 1
jne 0x40d2c8
mov dword [ebp - 0x10], 0x5a8eb4
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d1f2
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d1e9
sub edi, ecx
jmp 0x40d1d0
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [ecx + edi]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d1d0
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push 1
push 0x40
push 8
push edi
lea ecx, [ebp - 0x174]
call fcn.0040c3d0
mov dword [ebp - 0x10], 0x5a9084
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
mov dword [ebp - 4], 0
cmp byte [ebx + 0x13], 0
je 0x40d262
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d259
sub edi, ecx
mov edi, edi
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [ecx + edi]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d240
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
lea eax, [ebp - 0x174]
push edi
push eax
call fcn.0040ae60
push dword [ebp + 8]
lea eax, [ebp - 0x174]
push eax
call fcn.0040ae60
add esp, 0x10
lea ecx, [ebp - 0x170]
call fcn.00409ff0
test eax, eax
jne 0x40d2aa
push eax
mov eax, dword [ebp - 0x174]
lea ecx, [ebp - 0x174]
push 2
mov eax, dword [eax + 4]
add ecx, eax
call dword [sym.imp.MSVCP120.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
lea ecx, [ebp - 0x114]
mov dword [ebp - 4], 0xffffffff
call fcn.0040c4e0
lea ecx, [ebp - 0x114]
call dword [sym.imp.MSVCP120.dll_public_virtual:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::destructor_void_]
cmp dword [0x6e51e4], 1
jne 0x40d555
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.MSVCR120.dll__time64]
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.MSVCR120.dll__localtime64]
mov dword [ebp - 0x10], 0x5a8f00
add esp, 8
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
mov dword [ebp - 0x14], eax
cmp byte [ebx + 0x13], 0
je 0x40d344
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d33b
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d322
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push 1
push 0x40
push 8
push edi
lea ecx, [ebp - 0xcc]
call fcn.0040c3d0
mov dword [ebp - 0x10], 0x5a8f18
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
mov dword [ebp - 4], 1
cmp byte [ebx + 0x13], 0
je 0x40d3b2
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d3a9
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d390
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
lea eax, [ebp - 0xcc]
push edi
push eax
call fcn.0040ae60
push dword [ebp - 0x14]
call dword [sym.imp.MSVCR120.dll_asctime]
push eax
lea eax, [ebp - 0xcc]
push eax
call fcn.0040ae60
mov dword [ebp - 0x10], 0x5a90a8
add esp, 0x14
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d432
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d429
sub edi, ecx
jmp 0x40d410
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d410
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
lea eax, [ebp - 0xcc]
push edi
push eax
call fcn.0040ae60
push dword [ebp + 8]
lea eax, [ebp - 0xcc]
push eax
call fcn.0040ae60
mov dword [ebp - 0x10], 0x5a8f60
add esp, 0x10
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d4a6
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d49d
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d484
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
lea eax, [ebp - 0xcc]
push edi
push eax
call fcn.0040ae60
add esp, 8
lea ecx, [ebp - 0xc8]
call fcn.00409ff0
test eax, eax
jne 0x40d4df
push eax
mov eax, dword [ebp - 0xcc]
lea ecx, [ebp - 0xcc]
push 2
mov eax, dword [eax + 4]
add ecx, eax
call dword [sym.imp.MSVCP120.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
mov dword [ebp - 0x10], 0x5a8f00
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d534
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d52b
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d512
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push 2
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea ecx, [ebp - 0x6c]
mov dword [ebp - 4], 0xffffffff
call fcn.0040c4e0
lea ecx, [ebp - 0x6c]
call dword [sym.imp.MSVCP120.dll_public_virtual:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::destructor_void_]
push 0x7d0
call dword [sym.imp.KERNEL32.dll_Sleep]
push dword [ebp + 8]
push 0
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
je 0x40d9f1
push 0
push 0
push 0x10
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
cmp dword [0x6e51d4], 1
jne 0x40d718
mov dword [ebp - 0x10], 0x5a8eb4
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d5e2
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d5d9
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d5c0
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push 1
push 0x40
push 8
push edi
lea ecx, [ebp - 0x2c4]
call fcn.0040c3d0
mov dword [ebp - 0x10], 0x5a8f9c
mov edi, dword [ebp - 0x10]
mov ebx, dword [ebp - 0x10]
add ebx, 0x14
mov dword [ebp - 4], 2
mov dword [ebp - 0x14], ebx
cmp byte [edi + 0x13], 0
je 0x40d654
mov esi, dword [edi + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d64a
sub ebx, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + edi + 7]
xor al, byte [ebx + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [edi + 0xf]
jb 0x40d631
mov eax, dword [edi + 0xf]
mov dword [ebp - 0x14], ecx
mov byte [ecx + eax], 0
mov dword [ebp - 0x10], 0x5a90cc
mov ebx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x10]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d6a9
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x10], ecx
test esi, esi
je 0x40d6a0
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x10]
cmp edx, dword [ebx + 0xf]
jb 0x40d687
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push dword [ebp - 0x14]
lea eax, [ebp - 0x2c4]
push dword [ebp + 8]
push edi
push eax
call fcn.0040ae60
add esp, 8
push eax
call fcn.0040ae60
add esp, 8
push eax
call fcn.0040ae60
add esp, 8
lea ecx, [ebp - 0x2c0]
call fcn.00409ff0
test eax, eax
jne 0x40d6fa
push eax
mov eax, dword [ebp - 0x2c4]
lea ecx, [ebp - 0x2c4]
push 2
mov eax, dword [eax + 4]
add ecx, eax
call dword [sym.imp.MSVCP120.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
lea ecx, [ebp - 0x264]
mov dword [ebp - 4], 0xffffffff
call fcn.0040c4e0
lea ecx, [ebp - 0x264]
call dword [sym.imp.MSVCP120.dll_public_virtual:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::destructor_void_]
cmp dword [0x6e51e4], 1
jne 0x40d9ec
lea eax, [ebp - 0x1c]
push eax
call dword [sym.imp.MSVCR120.dll__time64]
lea eax, [ebp - 0x1c]
push eax
call dword [sym.imp.MSVCR120.dll__localtime64]
mov dword [ebp - 0x14], 0x5a8f00
add esp, 8
mov edi, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x14]
add ebx, 0x14
mov dword [ebp - 0x10], eax
cmp byte [edi + 0x13], 0
je 0x40d794
mov esi, dword [edi + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x14], ecx
test esi, esi
je 0x40d78b
sub ebx, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + edi + 7]
xor al, byte [ebx + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x14]
cmp edx, dword [edi + 0xf]
jb 0x40d772
mov eax, dword [edi + 0xf]
mov ebx, ecx
mov byte [ecx + eax], 0
push 1
push 0x40
push 8
push ebx
lea ecx, [ebp - 0x21c]
call fcn.0040c3d0
mov dword [ebp - 0x14], 0x5a8f18
mov ebx, dword [ebp - 0x14]
mov edi, dword [ebp - 0x14]
add edi, 0x14
mov dword [ebp - 4], 3
cmp byte [ebx + 0x13], 0
je 0x40d802
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x14], ecx
test esi, esi
je 0x40d7f9
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x14]
cmp edx, dword [ebx + 0xf]
jb 0x40d7e0
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
lea eax, [ebp - 0x21c]
push edi
push eax
call fcn.0040ae60
push dword [ebp - 0x10]
call dword [sym.imp.MSVCR120.dll_asctime]
push eax
lea eax, [ebp - 0x21c]
push eax
call fcn.0040ae60
mov dword [ebp - 0x14], 0x5a90f0
add esp, 0x14
mov edi, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x14]
add ebx, 0x14
mov dword [ebp - 0x10], ebx
cmp byte [edi + 0x13], 0
je 0x40d883
mov esi, dword [edi + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x14], ecx
test esi, esi
je 0x40d879
sub ebx, ecx
mov edi, edi
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + edi + 7]
xor al, byte [ebx + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x14]
cmp edx, dword [edi + 0xf]
jb 0x40d860
mov eax, dword [edi + 0xf]
mov dword [ebp - 0x10], ecx
mov byte [ecx + eax], 0
mov dword [ebp - 0x14], 0x5a90a8
mov ebx, dword [ebp - 0x14]
mov edi, dword [ebp - 0x14]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d8d8
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x14], ecx
test esi, esi
je 0x40d8cf
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x14]
cmp edx, dword [ebx + 0xf]
jb 0x40d8b6
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push dword [ebp - 0x10]
lea eax, [ebp - 0x21c]
push dword [ebp + 8]
push edi
push eax
call fcn.0040ae60
add esp, 8
push eax
call fcn.0040ae60
add esp, 8
push eax
call fcn.0040ae60
mov dword [ebp - 0x14], 0x5a8f60
add esp, 8
mov edi, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x14]
add ebx, 0x14
cmp byte [edi + 0x13], 0
je 0x40d955
mov esi, dword [edi + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x14], ecx
test esi, esi
je 0x40d94c
sub ebx, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + edi + 7]
xor al, byte [ebx + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x14]
cmp edx, dword [edi + 0xf]
jb 0x40d933
mov eax, dword [edi + 0xf]
mov ebx, ecx
mov byte [ecx + eax], 0
lea eax, [ebp - 0x21c]
push ebx
push eax
call fcn.0040ae60
add esp, 8
lea ecx, [ebp - 0x218]
call fcn.00409ff0
test eax, eax
jne 0x40d98e
push eax
mov eax, dword [ebp - 0x21c]
lea ecx, [ebp - 0x21c]
push 2
mov eax, dword [eax + 4]
add ecx, eax
call dword [sym.imp.MSVCP120.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
mov dword [ebp - 0x14], 0x5a8f00
mov ebx, dword [ebp - 0x14]
mov edi, dword [ebp - 0x14]
add edi, 0x14
cmp byte [ebx + 0x13], 0
je 0x40d9e3
mov esi, dword [ebx + 0xf]
lea eax, [esi + 1]
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
add esp, 4
mov ecx, eax
xor edx, edx
mov dword [ebp - 0x14], ecx
test esi, esi
je 0x40d9da
sub edi, ecx
mov eax, edx
add ecx, edx
and eax, 7
inc edx
mov al, byte [eax + ebx + 7]
xor al, byte [edi + ecx]
mov byte [ecx], al
mov ecx, dword [ebp - 0x14]
cmp edx, dword [ebx + 0xf]
jb 0x40d9c1
mov eax, dword [ebx + 0xf]
mov edi, ecx
mov byte [ecx + eax], 0
push 2
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
call fcn.0040da50
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret