Function at 0x4120c0
Capabilities:
Encrypt or decrypt via wincrypt
Read file on windows
Write file on windows

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49d5d4
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x100
mov eax, dword [0x4dc100]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x6c], eax
mov edi, dword [ebx + 8]
lea edx, [eax + 0x18]
mov dword [ebp - 0x68], 0
mov dword [eax + 0x10], 0xa
mov eax, accept
mov ecx, dword [edx + 0x10]
sub eax, ecx
mov esi, dword [edi + 0x10]
mov dword [ebp - 0x78], edi
cmp eax, esi
jb 0x412b0b
cmp dword [edx + 0x14], 0xf
jbe 0x41213a
mov edx, dword [edx]
cmp dword [edi + 0x14], 0xf
mov eax, edi
jbe 0x412144
mov eax, dword [edi]
push esi
push eax
push ecx
push edx
push ecx
push dword [ebp - 0x78]
lea ecx, [ebp - 0xc4]
call fcn.0040a900
mov dword [ebp - 4], 0
lea ecx, [ebp - 0xc4]
mov esi, dword [ebp - 0xb0]
mov eax, esi
mov edx, dword [ebp - 0xb4]
sub eax, edx
cmp eax, 1
jb 0x4121a1
cmp esi, 0xf
lea eax, [edx + 1]
mov dword [ebp - 0xb4], eax
cmova ecx, dword [ebp - 0xc4]
mov al, byte [0x4d1398]
mov byte [edx + ecx], al
lea eax, [ebp - 0xc4]
mov byte [edx + ecx + 1], 0
jmp 0x4121b2
push 1
push 0x4d1398
push dword [ebp - 0x78]
push 1
call fcn.004094f0
mov dword [ebp - 0x44], 0
xorps xmm0, xmm0
movups xmmword [ebp - 0x54], xmm0
mov dword [ebp - 0x40], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x54], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0x44], xmm0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0xf
mov byte [eax], 0
mov eax, 0x60
mov dword [ebp - 0x64], eax
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0xb0]
cmp ecx, 0xf
jbe 0x41222f
mov edx, dword [ebp - 0xc4]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412225
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b10
push ecx
push edx
call fcn.00474928
add esp, 8
push edi
push 8
push 0x4d186c
lea edx, [ebp - 0x54]
mov dword [ebp - 0xb4], 0
lea ecx, [ebp - 0xf4]
mov dword [ebp - 0xb0], 0xf
mov byte [ebp - 0xc4], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x1c], 0
call fcn.00415330
add esp, 0xc
cmp dword [eax + 0x14], 0xf
jbe 0x412279
mov eax, dword [eax]
push 0
push 0x80
push 3
push 0
push 1
push 1
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ecx, dword [ebp - 0xe0]
mov esi, eax
mov dword [ebp - 0x74], esi
cmp ecx, 0xf
jbe 0x4122ce
mov edx, dword [ebp - 0xf4]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4122c4
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b15
push ecx
push edx
call fcn.00474928
add esp, 8
push edi
push 8
push 0x4d1878
lea edx, [ebp - 0x54]
mov dword [ebp - 0xe4], 0
lea ecx, [ebp - 0x10c]
mov dword [ebp - 0xe0], 0xf
mov byte [ebp - 0xf4], 0
call fcn.00415330
add esp, 0xc
cmp dword [eax + 0x14], 0xf
jbe 0x41230a
mov eax, dword [eax]
push 0
push 0x80
push 3
push 0
push 1
push 1
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ecx, dword [ebp - 0xf8]
mov dword [ebp - 0x70], eax
cmp ecx, 0xf
jbe 0x412360
mov edx, dword [ebp - 0x10c]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412353
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b1a
push ecx
push edx
call fcn.00474928
mov eax, dword [ebp - 0x70]
add esp, 8
mov dword [ebp - 0xfc], 0
mov dword [ebp - 0xf8], 0xf
mov byte [ebp - 0x10c], 0
cmp esi, 0xffffffff
je 0x412abb
cmp eax, 0xffffffff
je 0x412abb
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
lea eax, [ebp - 0x18]
push 0
push eax
push 4
lea eax, [ebp - 0x38]
mov dword [ebp - 0x18], 0
push eax
push esi
call edi
cmp eax, 1
jne 0x4129ad
cmp dword [ebp - 0x38], 0x186a0
jae 0x4123ca
push 0
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x4123d2
mov ecx, dword [ebp - 0x6c]
call fcn.00411d70
mov eax, dword [ebp - 0x6c]
push 0
cmp dword [eax + 4], 0
lea eax, [ebp - 0x18]
push eax
push 4
lea eax, [ebp - 0x1c]
push eax
push esi
je 0x41240c
call edi
cmp eax, 1
jne 0x412416
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x1c]
push eax
mov eax, dword [ebp - 0x6c]
push 0
push 1
push dword [eax + 0xc]
push dword [eax + 8]
call dword [sym.imp.ADVAPI32.dll_CryptDecrypt]
jmp 0x412416
call edi
test eax, eax
je 0x412abb
cmp dword [ebp - 0x1c], 0
mov dword [ebp - 0x7c], 0
jbe 0x4129ad
mov ecx, dword [ebp - 0x6c]
lea eax, [ebp - 0x18]
push 0
push eax
xor eax, eax
mov dword [ebp - 0x5c], 0
cmp dword [ecx + 4], eax
sete al
lea eax, [eax*2 + 2]
push eax
lea eax, [ebp - 0x5c]
push eax
push esi
call edi
test eax, eax
je 0x4129ad
mov esi, dword [ebp - 0x5c]
xorps xmm0, xmm0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
movups xmmword [ebp - 0x34], xmm0
cmp esi, 0x7fffffff
ja 0x412b0b
cmp esi, 0xf
ja 0x41249f
push esi
lea eax, [ebp - 0x34]
mov dword [ebp - 0x24], esi
push 0
push eax
mov dword [ebp - 0x20], 0xf
call fcn.00476480
mov byte [ebp + esi - 0x34], 0
jmp 0x41252b
mov edi, esi
or edi, 0xf
cmp edi, 0x7fffffff
jbe 0x4124bb
mov ecx, accept
mov edi, accept
add ecx, 0x23
jmp 0x4124df
cmp edi, 0x16
mov eax, 0x16
cmovb edi, eax
lea eax, [edi + 1]
test eax, eax
je 0x412506
cmp eax, 0x1000
jb 0x4124fd
lea ecx, [eax + 0x23]
cmp ecx, eax
jbe 0x412b1f
push ecx
call fcn.004748f3
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x412b29
lea eax, [ecx + 0x23]
and eax, 0xffffffe0
mov dword [eax - 4], ecx
jmp 0x412506
push eax
call fcn.004748f3
add esp, 4
push esi
push 0
push eax
mov dword [ebp - 0x68], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x20], edi
call fcn.00476480
mov eax, dword [ebp - 0x68]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
mov byte [esi + eax], 0
mov esi, dword [ebp - 0x5c]
add esp, 0xc
push 0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x18]
cmp dword [ebp - 0x20], 0xf
lea eax, [ebp - 0x34]
push ecx
cmova eax, dword [ebp - 0x34]
push esi
mov esi, dword [ebp - 0x74]
push eax
push esi
call edi
test eax, eax
je 0x412a1a
push 0
lea eax, [ebp - 0x18]
mov dword [ebp - 0x3c], 0
push eax
push 4
lea eax, [ebp - 0x3c]
mov dword [ebp - 0x58], 0
push eax
push esi
call edi
test eax, eax
je 0x412975
push 0
lea eax, [ebp - 0x18]
push eax
push 4
lea eax, [ebp - 0x58]
push eax
push esi
call edi
test eax, eax
je 0x412975
cmp dword [ebp - 0x20], 0xf
lea esi, [ebp - 0x34]
mov eax, dword [ebp - 0x24]
cmova esi, dword [ebp - 0x34]
cmp eax, 1
jb 0x412712
lea edi, [esi + eax]
mov eax, edi
sub eax, esi
push eax
push 0x5c
push esi
call fcn.00477040
add esp, 0xc
test eax, eax
je 0x412712
movzx ecx, byte [eax]
cmp cl, 0x5c
jne 0x4125cd
xor ecx, ecx
jmp 0x4125d2
sbb ecx, ecx
or ecx, 1
test ecx, ecx
je 0x4125f0
inc eax
mov ecx, edi
sub ecx, eax
push ecx
push 0x5c
push eax
call fcn.00477040
add esp, 0xc
test eax, eax
jne 0x4125c1
jmp 0x412712
sub eax, esi
cmp eax, 0xffffffff
je 0x412712
lea eax, [ebp - 0x34]
push eax
push 4
push 0x4d1884
lea edx, [ebp - 0x54]
lea ecx, [ebp - 0xdc]
call fcn.00415330
add esp, 0xc
mov edx, eax
mov byte [ebp - 4], 4
mov esi, dword [ebp - 0x64]
or esi, 1
cmp dword [edx + 0x14], 0xf
mov dword [ebp - 0x68], esi
jbe 0x41262e
mov edx, dword [edx]
mov ecx, edx
mov dword [ebp - 0x9c], 0
xorps xmm0, xmm0
mov dword [ebp - 0x98], 0
movups xmmword [ebp - 0xac], xmm0
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x412651
sub ecx, edi
push ecx
push edx
lea ecx, [ebp - 0xac]
call fcn.00409650
mov dword [ebp - 4], 5
lea ecx, [ebp - 0xac]
or esi, 2
cmp dword [ebp - 0x98], 0xf
push 2
cmova ecx, dword [ebp - 0xac]
mov dword [ebp - 0x64], esi
mov dword [ebp - 0x68], esi
mov esi, dword [ebp - 0x9c]
mov edx, esi
push 0x4d189c
push ecx
call fcn.004091f0
mov ecx, eax
mov dword [ebp - 0x84], 0
add esp, 0xc
mov dword [ebp - 0x80], 0
cmp esi, ecx
lea eax, [ebp - 0xac]
xorps xmm0, xmm0
cmovb ecx, esi
cmp dword [ebp - 0x98], 0xf
push ecx
cmova eax, dword [ebp - 0xac]
lea ecx, [ebp - 0x94]
push eax
movups xmmword [ebp - 0x94], xmm0
call fcn.00409650
mov eax, dword [ebp - 0x64]
or eax, 0x600
or eax, 4
mov dword [ebp - 4], 6
mov dword [ebp - 0x64], eax
mov dword [ebp - 0x68], eax
lea eax, [ebp - 0x94]
push eax
call fcn.00413d80
mov byte [ebp - 0x5d], 1
test eax, eax
je 0x412716
mov byte [ebp - 0x5d], 0
mov dword [ebp - 4], 5
mov eax, dword [ebp - 0x64]
test al, 4
je 0x41277c
mov ecx, dword [ebp - 0x80]
and eax, 0xfffffffb
mov dword [ebp - 0x64], eax
cmp ecx, 0xf
jbe 0x412764
mov edx, dword [ebp - 0x94]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412757
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b10
push ecx
push edx
call fcn.00474928
mov eax, dword [ebp - 0x64]
add esp, 8
mov dword [ebp - 0x84], 0
mov dword [ebp - 0x80], 0xf
mov byte [ebp - 0x94], 0
mov dword [ebp - 4], 4
test al, 2
je 0x4127e5
mov ecx, dword [ebp - 0x98]
and eax, 0xfffffffd
mov dword [ebp - 0x64], eax
cmp ecx, 0xf
jbe 0x4127ca
mov edx, dword [ebp - 0xac]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4127bd
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b10
push ecx
push edx
call fcn.00474928
mov eax, dword [ebp - 0x64]
add esp, 8
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0xf
mov byte [ebp - 0xac], 0
mov dword [ebp - 4], 3
test al, 1
je 0x412830
mov ecx, dword [ebp - 0xc8]
and eax, 0xfffffffe
mov dword [ebp - 0x64], eax
cmp ecx, 0xf
jbe 0x412830
mov edx, dword [ebp - 0xdc]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412826
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b10
push ecx
push edx
call fcn.00474928
add esp, 8
cmp byte [ebp - 0x5d], 0
jne 0x412923
lea eax, [ebp - 0x34]
push eax
push 4
push 0x4d1884
lea edx, [ebp - 0x54]
lea ecx, [ebp - 0x94]
call fcn.00415330
add esp, 0xc
cmp dword [eax + 0x14], 0xf
jbe 0x41285e
mov eax, dword [eax]
push 0
push 0x80
push 2
push 0
push 1
push 2
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ecx, dword [ebp - 0x80]
mov esi, eax
cmp ecx, 0xf
jbe 0x4128ad
mov edx, dword [ebp - 0x94]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4128a3
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b10
push ecx
push edx
call fcn.00474928
add esp, 8
mov dword [ebp - 0x84], 0
mov dword [ebp - 0x80], 0xf
mov byte [ebp - 0x94], 0
cmp esi, 0xffffffff
je 0x412923
push 0
push 0
push dword [ebp - 0x3c]
push dword [ebp - 0x70]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push dword [ebp - 0x58]
call fcn.00474936
add esp, 4
mov edi, eax
lea eax, [ebp - 0x18]
push 0
push eax
push dword [ebp - 0x58]
push edi
push dword [ebp - 0x70]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x412923
push 0
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x58]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x412923
push edi
call fcn.004748ee
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x20]
cmp ecx, 0xf
jbe 0x41295b
mov edx, dword [ebp - 0x34]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412951
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b29
push ecx
push edx
call fcn.00474928
add esp, 8
mov eax, dword [ebp - 0x7c]
mov esi, dword [ebp - 0x74]
inc eax
mov dword [ebp - 0x7c], eax
cmp eax, dword [ebp - 0x1c]
jae 0x4129ad
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
jmp 0x412427
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x20]
cmp ecx, 0xf
jbe 0x4129ad
mov edx, dword [ebp - 0x34]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4129a3
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b29
push ecx
push edx
call fcn.00474928
add esp, 8
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x70]
call esi
mov esi, dword [ebp - 0x78]
lea edx, [ebp - 0x54]
push esi
push 8
push 0x4d186c
lea ecx, [ebp - 0xdc]
call fcn.00415330
add esp, 0xc
cmp dword [eax + 0x14], 0xf
jbe 0x4129df
mov eax, dword [eax]
push eax
call fcn.0047ddcd
mov ecx, dword [ebp - 0xc8]
add esp, 4
cmp ecx, 0xf
jbe 0x412a5b
mov edx, dword [ebp - 0xdc]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412a51
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b24
jmp 0x412a51
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x20]
cmp ecx, 0xf
jbe 0x4129ad
mov edx, dword [ebp - 0x34]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4129a3
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b29
jmp 0x4129a3
push ecx
push edx
call fcn.00474928
add esp, 8
push esi
push 8
push 0x4d1878
lea edx, [ebp - 0x54]
lea ecx, [ebp - 0xdc]
call fcn.00415330
add esp, 0xc
cmp dword [eax + 0x14], 0xf
jbe 0x412a7c
mov eax, dword [eax]
push eax
call fcn.0047ddcd
mov ecx, dword [ebp - 0xc8]
add esp, 4
cmp ecx, 0xf
jbe 0x412abb
mov edx, dword [ebp - 0xdc]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412ab1
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b2e
push ecx
push edx
call fcn.00474928
add esp, 8
mov ecx, dword [ebp - 0x40]
cmp ecx, 0xf
jbe 0x412aeb
mov edx, dword [ebp - 0x54]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x412ae1
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x412b33
push ecx
push edx
call fcn.00474928
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004748e0
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 4
call fcn.004015c0
call fcn.0047ce51
call fcn.0047ce51
call fcn.0047ce51
call fcn.00401520
call fcn.0047ce51
call fcn.0047ce51
call fcn.0047ce51
call fcn.0047ce51
int3