Function at 0x300064d0
Capabilities:
Allocate or change rwx memory
Check for software breakpoints
Execute shellcode via indirect call

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xc
push ebx
push esi
push edi
mov edi, ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [0x3026f264], 0
mov edx, eax
mov dword [esp + 0x10], edx
je 0x300069ec
mov esi, dword [edi]
mov eax, dword [esi]
cmp eax, 0x80000004
jne 0x30006827
mov ebx, dword [0x302727e8]
test ebx, ebx
je 0x3000651e
cmp dword [ebx], edx
je 0x30006535
mov ebx, dword [ebx + 0x88]
test ebx, ebx
jne 0x30006510
push edx
push str.CAPEExceptionFilter:_Cant_find_breakpoints_for_thread__d_n
call fcn.30009b00
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 4]
xor esi, esi
mov eax, dword [eax + 0x14]
mov edx, eax
nop
mov eax, 1
mov ecx, esi
shl eax, cl
test edx, eax
jne 0x30006553
inc esi
cmp esi, 4
jb 0x30006540
mov edx, dword [esp + 0x10]
mov dword [esp + 0x14], esi
cmp esi, 4
jne 0x3000657d
mov eax, dword [0x30272898]
test eax, eax
je 0x30006bc0
push edi
call eax
add esp, 4
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [0x302727ec]
test eax, eax
je 0x30006598
push eax
push str.CAPEExceptionFilter:_Anomaly_detected:_Trap_index_set_on_non_single_step:__d_n
call fcn.30009b00
mov edx, dword [esp + 0x18]
add esp, 8
cmp dword [0x30272208], 0
jne 0x300065be
cmp dword [0x30271144], 0
jne 0x300065be
mov eax, dword [edi]
push edx
push dword [eax + 0xc]
push esi
push str.CAPEExceptionFilter:_breakpoint__d_hit_by_instruction_at_0x_p__thread__d__n
call fcn.30009b00
add esp, 0x10
mov eax, esi
lea esi, [ebx + 8]
shl eax, 5
add esi, eax
jne 0x300065e5
push dword [esp + 0x10]
push str.CAPEExceptionFilter:_Cant_get_BreakpointInfo_for_thread__d_n
call fcn.30009b00
add esp, 8
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x30006647
mov eax, dword [edi + 4]
mov ecx, dword [esi + 0xc]
mov edx, dword [eax + 4]
cmp ecx, edx
je 0x3000660c
push ecx
push edx
push str.CAPEExceptionFilter:_Anomaly_detected__bp0_address__0x_x__different_to_BreakpointInfo__0x_x___n
call fcn.30009b00
mov eax, dword [edi + 4]
add esp, 0xc
movzx edx, word [eax + 0x1a]
mov eax, dword [esi + 0x10]
and edx, 3
cmp eax, edx
je 0x300067a4
cmp eax, 3
jne 0x3000663b
cmp edx, 1
jne 0x3000663b
mov ecx, dword [esi + 0xc]
call fcn.3004d370
test eax, eax
jne 0x3000675b
mov eax, dword [esi + 0x10]
push eax
push edx
push str.CAPEExceptionFilter:_Anomaly_detected__bp0_type__0x_x__different_to_BreakpointInfo__0x_x___n
jmp 0x30006794
cmp eax, 1
jne 0x300066a8
mov edx, dword [edi + 4]
mov eax, dword [esi + 0xc]
mov ecx, dword [edx + 8]
cmp eax, ecx
je 0x3000666b
push eax
push ecx
push str.CAPEExceptionFilter:_Anomaly_detected__bp1_address__0x_x__different_to_BreakpointInfo__0x_x___n
call fcn.30009b00
mov edx, dword [edi + 4]
add esp, 0xc
mov edx, dword [edx + 0x18]
mov eax, dword [esi + 0x10]
shr edx, 0x14
and edx, 3
cmp eax, edx
je 0x300067a4
cmp eax, 3
jne 0x3000669c
cmp edx, 1
jne 0x3000669c
mov ecx, dword [esi + 0xc]
call fcn.3004d370
test eax, eax
jne 0x3000675b
mov eax, dword [esi + 0x10]
push eax
push edx
push str.CAPEExceptionFilter:_Anomaly_detected__bp1_type__0x_x__different_to_BreakpointInfo__0x_x___n
jmp 0x30006794
cmp eax, 2
jne 0x3000670d
mov eax, dword [edi + 4]
mov ecx, dword [esi + 0xc]
mov edx, dword [eax + 0xc]
cmp ecx, edx
je 0x300066cc
push ecx
push edx
push str.CAPEExceptionFilter:_Anomaly_detected__bp2_address__0x_x__different_to_BreakpointInfo__0x_x___n
call fcn.30009b00
mov eax, dword [edi + 4]
add esp, 0xc
movzx edx, byte [eax + 0x1b]
mov eax, dword [esi + 0x10]
and edx, 3
cmp eax, edx
je 0x300067a4
cmp eax, 3
jne 0x30006701
cmp edx, 1
jne 0x30006701
mov ecx, dword [esi + 0xc]
call fcn.3004d370
test eax, eax
je 0x300066fe
push dword [esi + 4]
push str.CAPEExceptionFilter:_Reinstated_BP_READWRITE_on_stack_breakpoint__d__WoW64_workaround__n
jmp 0x30006763
mov eax, dword [esi + 0x10]
push eax
push edx
push str.CAPEExceptionFilter:_Anomaly_detected__bp2_type__0x_x__different_to_BreakpointInfo__0x_x___n
jmp 0x30006794
cmp eax, 3
jne 0x300067a4
mov edx, dword [edi + 4]
mov eax, dword [esi + 0xc]
mov ecx, dword [edx + 0x10]
cmp eax, ecx
je 0x30006735
push eax
push ecx
push str.CAPEExceptionFilter:_Anomaly_detected__bp3_address__0x_x__different_to_BreakpointInfo__0x_x___n
call fcn.30009b00
mov edx, dword [edi + 4]
add esp, 0xc
mov edx, dword [edx + 0x18]
mov eax, dword [esi + 0x10]
shr edx, 0x1c
and edx, 3
cmp eax, edx
je 0x300067a4
cmp eax, 3
jne 0x3000678d
cmp edx, 1
jne 0x3000678d
mov ecx, dword [esi + 0xc]
call fcn.3004d370
test eax, eax
je 0x3000678a
push dword [esi + 4]
push str.CAPEExceptionFilter:_Reinstated_BP_READWRITE_on_breakpoint__d__WoW64_workaround__n
call fcn.30009b00
mov edx, dword [esi + 4]
add esp, 4
mov ecx, dword [edi + 4]
push dword [esi + 0x18]
push dword [esi + 0x14]
push dword [esi + 0x10]
push dword [esi + 0xc]
push dword [esi + 8]
call fcn.30007450
add esp, 0x18
jmp 0x300067a4
mov eax, dword [esi + 0x10]
push eax
push edx
push str.CAPEExceptionFilter:_Anomaly_detected__bp3_type__0x_x__different_to_BreakpointInfo__0x_x___n
call fcn.30009b00
mov edx, dword [edi + 4]
add esp, 0xc
call fcn.30006fc0
mov eax, dword [esi + 0x14]
test eax, eax
je 0x300067be
add eax, 0xffffffff
mov dword [esi + 0x14], eax
jne 0x300067be
mov edx, dword [esi + 4]
mov ecx, dword [edi + 4]
call fcn.300072f0
mov eax, dword [esi + 0x18]
test eax, eax
jne 0x300067df
push dword [esp + 0x10]
push str.CAPEExceptionFilter:_Cant_find_callback__passing_exception__thread__d__n
call fcn.30009b00
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [esi + 0x1c], 0
jne 0x30006aac
push edi
push esi
mov dword [esi + 0x1c], 1
call eax
mov dword [esi + 0x1c], 0
add esp, 8
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x30006812
or dword [ecx + 0xc0], 0x10000
mov ecx, dword [edi + 4]
push ecx
mov edx, ebx
call fcn.300077a0
add esp, 4
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, reloc.WS2_32.dll_closesocket
jne 0x300069ec
mov esi, dword [esi + 0xc]
cmp byte [esi], 0xcc
jne 0x300069ec
mov ecx, dword [0x30244584]
mov eax, ecx
test eax, eax
je 0x30006896
lea ebx, [ebx]
cmp dword [eax + 4], esi
je 0x3000685d
mov eax, dword [eax]
test eax, eax
jne 0x30006850
jmp 0x30006896
add eax, 0xc
je 0x30006896
test esi, esi
je 0x30006896
cmp byte [esi], 0xcc
jne 0x30006896
jmp 0x30006870
cmp dword [ecx + 4], esi
je 0x3000687d
mov ecx, dword [ecx]
test ecx, ecx
jne 0x30006870
jmp 0x30006888
lea ebx, [ecx + 0xc]
test ebx, ebx
jne 0x30006961
push esi
push str.SoftwareBreakpointHandler:_Unable_to_retrieve_instruction_byte_for_0x_p
call fcn.30009b00
add esp, 8
mov eax, dword [edi]
mov ecx, dword [eax + 0xc]
mov eax, dword [0x30244568]
test eax, eax
je 0x300068b3
cmp dword [eax + 4], ecx
je 0x300069a7
mov eax, dword [eax]
test eax, eax
jne 0x300068a4
mov ecx, dword [edi]
mov ecx, dword [ecx + 0xc]
call fcn.30003230
mov eax, dword [edi]
mov eax, dword [eax + 0xc]
cmp byte [eax], 0xcc
je 0x300068d6
mov ecx, edi
call fcn.3001aa80
test eax, eax
jne 0x30006aac
mov ecx, dword [edi]
mov edx, dword [ecx + 0xc]
mov esi, dword [0x3026c324]
cmp edx, esi
jb 0x30006916
mov eax, dword [0x3026c32c]
add eax, esi
cmp edx, eax
jae 0x30006916
cmp dword [0x3026d6f4], 0
je 0x30006901
cmp dword [ecx], 0x80000001
je 0x30006916
sub edx, esi
push edx
push dword [ecx + 0x18]
push dword [ecx]
push str.CAPEExceptionFilter:_Exception_0x_x_accessing_0x_x_caught_at_RVA_0x_x_in_capemon__expected_in_memory_scans___passing_to_next_handler._n
call fcn.30009b00
add esp, 0x10
cmp dword [0x30272208], 0
je 0x30006bc0
mov ecx, dword [edi]
lea edx, [esp + 0x14]
mov ecx, dword [ecx + 0xc]
call fcn.3004b210
mov ecx, dword [edi]
mov edx, dword [ecx + 0x10]
test eax, eax
je 0x30006b10
test edx, edx
jne 0x30006ab6
push dword [ecx + 4]
push dword [esp + 0x14]
push dword [esp + 0x1c]
push eax
push dword [ecx + 0xc]
push dword [ecx]
push str._nException_0x_x_at_0x_p_in__s__RVA_0x_x__thread__d___flags_0x_x_n
jmp 0x30006b6e
lea eax, [esp + 0x14]
push eax
push 0x40
push 1
push esi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x30006980
push esi
push str.SoftwareBreakpointHandler:_Unable_to_change_memory_protection_at_0x_p
jmp 0x3000688e
mov al, byte [ebx]
mov byte [esi], al
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x18]
push 1
push esi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov ecx, edi
call fcn.3001aa80
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
add eax, 0xc
je 0x300068b3
mov eax, dword [edi + 4]
mov ecx, dword [eax + 0xb0]
call fcn.300095f0
push eax
push 0x301e6ac8
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x300068b3
mov ecx, dword [edi + 4]
mov dword [ecx + 0xb8], eax
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [edi]
mov eax, dword [ecx]
cmp eax, 0xc0000096
je 0x30006a02
cmp eax, 0xc000001d
jne 0x300068d8
mov esi, dword [edi + 4]
mov edx, dword [esi + 0xb8]
movzx eax, byte [edx]
cmp al, 0xf
jne 0x30006a26
movzx eax, byte [edx + 1]
cmp al, 1
jne 0x30006a26
movzx eax, byte [edx + 2]
cmp al, 0xf9
jne 0x30006a26
xor eax, eax
jmp 0x30006a2b
sbb eax, eax
or eax, 1
test eax, eax
jne 0x300068d8
cmp dword [0x3026f26c], eax
je 0x30006a87
mov esi, dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea eax, [esp + 0x14]
push eax
push 0x40
push 3
push edx
call esi
mov eax, dword [edi + 4]
mov ecx, dword [eax + 0xb8]
mov ax, word [0x301e6fec]
mov word [ecx], ax
mov al, byte [0x301e6fee]
mov byte [ecx + 2], al
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x18]
mov eax, dword [edi + 4]
push 3
push dword [eax + 0xb8]
call esi
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
rdtsc
mov dword [esi + 0xb0], eax
mov eax, dword [edi + 4]
mov dword [eax + 0xa8], edx
mov esi, dword [edi + 4]
mov ecx, dword [esi + 0xb8]
call fcn.30029510
add dword [esi + 0xb8], eax
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp edx, 1
jne 0x30006ae1
push dword [ecx + 0x14]
push dword [ecx + 4]
push dword [esp + 0x18]
push dword [esp + 0x20]
push eax
push dword [ecx + 0xc]
push dword [ecx]
push str._nException_0x_x_at_0x_p_in__s__RVA_0x_x__thread__d___flags_0x_x__exception_information_0x_p_n
call fcn.30009fa0
add esp, 0x20
jmp 0x30006b76
cmp edx, 2
jne 0x30006b76
push dword [ecx + 0x18]
push dword [ecx + 0x14]
push dword [ecx + 4]
push dword [esp + 0x1c]
push dword [esp + 0x24]
push eax
push dword [ecx + 0xc]
push dword [ecx]
push str._nException_0x_x_at_0x_p_in__s__RVA_0x_x__thread__d___flags_0x_x__exception_information_0__0x_p__exception_information_1__0x_p_n
call fcn.30009fa0
add esp, 0x24
jmp 0x30006b76
test edx, edx
jne 0x30006b2f
push dword [ecx + 4]
push dword [esp + 0x14]
push dword [ecx + 0xc]
push dword [ecx]
push str._nException_0x_x_at_0x_p__thread__d__flags_0x_x_n
call fcn.30009fa0
add esp, 0x14
jmp 0x30006b76
cmp edx, 1
jne 0x30006b52
push dword [ecx + 0x14]
push dword [ecx + 4]
push dword [esp + 0x18]
push dword [ecx + 0xc]
push dword [ecx]
push str._nException_0x_x_at_0x_p__thread__d__flags_0x_x__exception_information_0x_p_n
call fcn.30009fa0
add esp, 0x18
jmp 0x30006b76
cmp edx, 2
jne 0x30006b76
push dword [ecx + 0x18]
push dword [ecx + 0x14]
push dword [ecx + 4]
push dword [esp + 0x1c]
push dword [ecx + 0xc]
push dword [ecx]
push str._nException_0x_x_at_0x_p__thread__d__flags_0x_x__exception_information_0__0x_p__exception_information_1__0x_p_n
call fcn.30009fa0
add esp, 0x1c
mov eax, dword [edi + 4]
push dword [eax + 0xb4]
push dword [eax + 0xc4]
push dword [eax + 0x9c]
push dword [eax + 0xa0]
push dword [eax + 0xa8]
push dword [eax + 0xac]
push dword [eax + 0xa4]
push dword [eax + 0xb0]
push str.EAX_0x_x_EBX_0x_x_ECX_0x_x_EDX_0x_x_ESI_0x_x_EDI_0x_x_ESP_0x_x_EBP_0x_x_n
call fcn.30009fa0
mov ecx, dword [edi]
add esp, 0x24
mov ecx, dword [ecx + 0xc]
call fcn.300166b0
cmp dword [0x30271b20], 0
je 0x30006bd1
mov ecx, dword [edi + 4]
call fcn.30006f70
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret