Function at 0x10041f220
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x30
mov eax, dword [rcx]
mov rbx, rcx
mov rdi, rdx
test eax, eax
jne 0x10041f56b
xor esi, esi
cmp dword [rcx + 0x60], 2
je 0x10041f310
movsxd rax, dword [rbx + 0x40]
test eax, eax
js 0x10041f2f8
cmp eax, dword [rbx + 0x5c]
jge 0x10041f2f8
lea rax, [rax + rax*2]
lea rdx, [rbx + rax*8]
mov eax, dword [rdx + 0xa8]
cmp eax, 1
je 0x10041f2c0
cmp eax, 2
je 0x10041f400
test eax, eax
jne 0x10041f2d1
cmp dword [rbx + 0x60], 2
je 0x10041f2b1
mov dword [rbx + 0x60], 0
mov rcx, qword [rbx + 0x88]
call fcn.1004ae120
mov qword [rbx + 0x88], 0
mov dword [rbx + 0x98], 0xffffffff
mov qword [rbx + 0xa0], 0xffffffffffffffff
mov esi, 0x2000001
jmp 0x10041f2e8
mov rcx, qword [rdx + 0xb0]
mov rdx, rdi
call fcn.1004214a0
mov esi, eax
cmp dword [rbx + 0x60], 2
jne 0x10041f370
test esi, esi
jne 0x10041f2e8
add dword [0x1005054ac], 1
xor esi, esi
mov eax, esi
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
mov esi, 0x200001c
mov eax, esi
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
mov rcx, qword [rcx + 0x88]
xor edx, edx
call fcn.1004b0800
mov esi, eax
test eax, eax
je 0x10041f3b0
lea rcx, str.keydb_get_keyblock:_failed_to_rewind_iobuf_for_cache_n
call sub.msys_gpg_error_0.dll_gpgrt_log_error
mov dword [rbx + 0x60], 0
mov rcx, qword [rbx + 0x88]
call fcn.1004ae120
mov qword [rbx + 0x88], 0
mov dword [rbx + 0x98], 0xffffffff
mov qword [rbx + 0xa0], 0xffffffffffffffff
jmp 0x10041f243
mov dword [rbx + 0x60], 0
mov rcx, qword [rbx + 0x88]
call fcn.1004ae120
mov qword [rbx + 0x88], 0
mov dword [rbx + 0x98], 0xffffffff
mov qword [rbx + 0xa0], 0xffffffffffffffff
jmp 0x10041f2db
mov edx, dword [rbx + 0x90]
mov rcx, qword [rbx + 0x88]
mov r9, rdi
mov r8d, dword [rbx + 0x94]
call fcn.10041eef0
mov esi, eax
test eax, eax
jne 0x10041f4f0
mov rax, qword [0x1004f7480]
test byte [rax + 9], 0x10
je 0x10041f2e8
lea rdx, [0x1004d5960]
lea rcx, str._s_leave__cached_mode_
call sub.msys_gpg_error_0.dll_gpgrt_log_clock
jmp 0x10041f2e8
mov rcx, qword [rdx + 0xb0]
lea rax, [rsp + 0x28]
lea r9, [rsp + 0x24]
lea r8, [rsp + 0x20]
mov rdx, rax
call fcn.10049a5e0
mov esi, eax
test eax, eax
je 0x10041f470
cmp dword [rbx + 0x60], 2
je 0x10041f2e8
mov dword [rbx + 0x60], 0
mov rcx, qword [rbx + 0x88]
call fcn.1004ae120
mov qword [rbx + 0x88], 0
mov dword [rbx + 0x98], 0xffffffff
mov qword [rbx + 0xa0], 0xffffffffffffffff
jmp 0x10041f2e8
mov rcx, qword [rsp + 0x28]
mov r8d, dword [rsp + 0x24]
mov r9, rdi
mov edx, dword [rsp + 0x20]
call fcn.10041eef0
mov rcx, qword [rsp + 0x28]
mov esi, eax
test eax, eax
jne 0x10041f530
cmp dword [rbx + 0x60], 1
je 0x10041f540
call fcn.1004ae120
cmp dword [rbx + 0x60], 2
je 0x10041f2df
mov dword [rbx + 0x60], 0
mov rcx, qword [rbx + 0x88]
call fcn.1004ae120
mov qword [rbx + 0x88], 0
mov dword [rbx + 0x98], 0xffffffff
mov qword [rbx + 0xa0], 0xffffffffffffffff
jmp 0x10041f2df
mov dword [rbx + 0x60], 0
mov rcx, qword [rbx + 0x88]
call fcn.1004ae120
mov qword [rbx + 0x88], 0
mov dword [rbx + 0x98], 0xffffffff
mov qword [rbx + 0xa0], 0xffffffffffffffff
jmp 0x10041f3d6
call fcn.1004ae120
jmp 0x10041f424
movd xmm0, dword [rsp + 0x20]
movd xmm1, dword [rsp + 0x24]
mov dword [rbx + 0x60], 2
mov qword [rbx + 0x88], rcx
punpckldq xmm0, xmm1
movq qword [rbx + 0x90], xmm0
jmp 0x10041f2df
lea r9, str.internal_keydb_get_keyblock
mov r8d, 0x521
lea rdx, str.keydb.c
lea rcx, str._hd__use_keyboxd
call sub.msys_gpg_error_0.dll__gpgrt_log_assert
nop
nop dword [rax]