Function at 0x402af0
Capabilities:
Delete file
Get common file path
Get file size
Read file via mapping

Disassembly:
push 0xffffffffffffffff
push 0x528ee0
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push ebp
push esi
push edi
mov eax, dword [0x572608]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
call fcn.00402930
call fcn.0040bd24
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x402b36
push 0x80004005
call fcn.00401b90
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea esi, [eax + 0x10]
mov dword [esp + 0x18], esi
mov dword [esp + 0x28], 0
call fcn.0040bd24
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x402b68
push 0x80004005
call fcn.00401b90
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
mov byte [esp + 0x28], 1
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
sub eax, 0x12c
or eax, ecx
jge 0x402ba3
push 0x12c
lea ecx, [esp + 0x1c]
call fcn.00401ae0
mov esi, dword [esp + 0x18]
push esi
push 0x12c
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push esi
lea ecx, [esp + 0x18]
push str._sMyCert.cer
push ecx
call fcn.00403070
mov ebx, dword [esp + 0x20]
add esp, 0xc
push 0
push 0
push 3
push 0
push 1
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x402c4e
push 0x10
push str.information
push str.Certificate_not_found._Check_that_the_path_indicated_is_correct.
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
lea eax, [ebx - 0x10]
mov byte [esp + 0x28], 0
lea edx, [eax + 0xc]
or ecx, edi
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x402c14
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add esi, 0xfffffff0
mov dword [esp + 0x28], 0xffffffff
lea ecx, [esi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402c38
mov ecx, dword [esi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push esi
call edx
xor eax, eax
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
push 0
push 0
push 0
push 2
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov ebp, eax
test ebp, ebp
jne 0x402c9d
push 0x10
push str.information
push str.Error_in_CreateFileMapping.
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
test edi, edi
je 0x402c83
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebx - 0x10]
mov byte [esp + 0x28], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x402c08
push 0
push 0
push 0
push 4
push ebp
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov esi, eax
test esi, esi
jne 0x402d2c
push 0x10
push str.information
push str.Error_in_MapViewOfFile
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
push esi
mov eax, esi
push 0
mov esi, ebp
mov ebx, edi
call fcn.004028e0
mov byte [esp + 0x30], 0
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
add esp, 8
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402cfb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x28], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402c38
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x402c38
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push eax
push esi
push 0x10001
call dword [sym.imp.CRYPT32.dll_CertCreateCertificateContext]
mov ebx, eax
test ebx, ebx
jne 0x402d61
push 0x10
push str.information
push str.Error_in_CertCreateCertificateContext
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
push ebx
jmp 0x402cc6
push str.Root
push 0x24000
push 0
push 0
push 0xa
call dword [sym.imp.CRYPT32.dll_CertOpenStore]
mov dword [esp + 0x1c], eax
test eax, eax
jne 0x402dbd
push 0x10
push str.information
push str.Error_in_CertOpenStore
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
mov ecx, dword [esp + 0x1c]
push ebx
push ecx
mov eax, esi
mov esi, ebp
mov ebx, edi
call fcn.004028e0
add esp, 8
lea ecx, [esp + 0x14]
call fcn.004017c0
lea ecx, [esp + 0x18]
call fcn.004017c0
jmp 0x402c38
push 0
push 1
push ebx
push eax
call dword [sym.imp.CRYPT32.dll_CertAddCertificateContextToStore]
test eax, eax
jne 0x402dee
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x80092005
jne 0x402e24
mov edx, dword [esp + 0x1c]
push ebx
mov eax, esi
push edx
mov esi, ebp
mov ebx, edi
call fcn.004028e0
add esp, 8
mov ecx, dword [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0x14]
call fcn.004017c0
lea ecx, [esp + 0x18]
call fcn.004017c0
mov eax, 1
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret
push 0x10
push str.information
push str.Error_in_CertAddCertificateContextToStore
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
mov eax, dword [esp + 0x1c]
push ebx
push eax
jmp 0x402d98