Function at 0x5a9150
Capabilities:
Encode data using xor
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x80
mov edx, dword [ebp + 0x14]
pxor xmm0, xmm0
movdqa xmmword [esp + 0x30], xmm0
mov dword [esp + 0x40], 0
movdqa xmmword [esp + 0x50], xmm0
mov dword [esp + 0x60], 0
mov eax, dword [edx + 4]
test eax, eax
jle 0x5a9192
mov esi, dword [edx]
mov ecx, dword [esi]
test cl, 1
jne 0x5a91a3
push 0x391
push str.external_boringssl_src_crypto_fipsmodule_bn_exponentiation.c
push 0x68
jmp 0x5a94bc
cmp dword [edx + 0xc], 0
je 0x5a91ba
push 0x395
push str.external_boringssl_src_crypto_fipsmodule_bn_exponentiation.c
push 0x6d
jmp 0x5a94bc
mov dword [esp + 0x2c], ecx
mov ecx, dword [ebp + 0xc]
cmp dword [ecx + 0xc], 0
jne 0x5a94b0
mov edx, dword [ecx]
mov dword [esp + 0x1c], edx
mov ecx, dword [ecx + 4]
cmp ecx, eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], ecx
cmovb eax, ecx
test eax, eax
mov dword [esp + 0x18], esi
je 0x5a9226
xor edi, edi
xor ecx, ecx
nop dword [eax]
mov edx, dword [esp + 0x1c]
mov esi, dword [edx + ecx*4]
mov edx, dword [esp + 0x18]
mov ebx, dword [edx + ecx*4]
mov edx, esi
sub edx, ebx
xor ebx, esi
xor edx, esi
or edx, ebx
xor edx, esi
mov esi, edx
sar esi, 0x1f
not edx
shr edx, 0x1f
or edx, esi
test ebx, ebx
mov esi, dword [esp + 0x18]
cmovne edi, edx
inc ecx
cmp eax, ecx
jne 0x5a91f0
jmp 0x5a9228
xor edi, edi
mov dword [esp + 0x28], edi
mov ecx, dword [esp + 0x10]
mov edi, ecx
mov edx, dword [esp + 0x14]
sub edi, edx
jae 0x5a924d
mov edi, edx
sub edi, ecx
xor eax, eax
cmp edi, 8
jae 0x5a928d
mov ebx, dword [ebp + 0x14]
jmp 0x5a93a0
jbe 0x5a92b0
xor ecx, ecx
mov eax, edx
cmp edi, 8
mov ebx, dword [ebp + 0x14]
mov esi, dword [esp + 0x1c]
jb 0x5a9483
mov dword [esp + 0xc], edi
lea ecx, [edi - 8]
mov eax, ecx
shr eax, 3
inc eax
mov edi, eax
and edi, 3
cmp ecx, 0x18
jae 0x5a93c1
pxor xmm0, xmm0
xor edx, edx
pxor xmm1, xmm1
jmp 0x5a942b
lea eax, [edi - 8]
mov edx, eax
shr edx, 3
inc edx
mov ebx, edx
and ebx, 3
mov dword [esp + 0x1c], ebx
cmp eax, 0x18
jae 0x5a92bc
pxor xmm0, xmm0
xor eax, eax
pxor xmm1, xmm1
jmp 0x5a9326
mov ebx, dword [ebp + 0x14]
mov eax, dword [esp + 0x28]
jmp 0x5a94ac
and edx, 0xfffffffc
lea ebx, [esi + ecx*4]
add ebx, 0x70
pxor xmm0, xmm0
xor eax, eax
pxor xmm1, xmm1
movdqu xmm2, xmmword [ebx + eax*4 - 0x70]
por xmm2, xmm0
movdqu xmm0, xmmword [ebx + eax*4 - 0x60]
por xmm0, xmm1
movdqu xmm1, xmmword [ebx + eax*4 - 0x50]
movdqu xmm3, xmmword [ebx + eax*4 - 0x40]
movdqu xmm4, xmmword [ebx + eax*4 - 0x30]
por xmm4, xmm1
por xmm4, xmm2
movdqu xmm2, xmmword [ebx + eax*4 - 0x20]
por xmm2, xmm3
por xmm2, xmm0
movdqu xmm0, xmmword [ebx + eax*4 - 0x10]
por xmm0, xmm4
movdqu xmm1, xmmword [ebx + eax*4]
por xmm1, xmm2
add eax, 0x20
add edx, 0xfffffffc
jne 0x5a92cf
mov edx, edi
and edx, 0xfffffff8
mov ebx, dword [esp + 0x1c]
test ebx, ebx
mov esi, dword [esp + 0x18]
je 0x5a936a
add eax, dword [esp + 0x10]
lea eax, [esi + eax*4]
add eax, 0x10
shl ebx, 5
xor ecx, ecx
nop word cs:[eax + eax]
movdqu xmm2, xmmword [eax + ecx - 0x10]
por xmm0, xmm2
movdqu xmm2, xmmword [eax + ecx]
por xmm1, xmm2
add ecx, 0x20
cmp ebx, ecx
jne 0x5a9350
por xmm0, xmm1
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movd eax, xmm0
cmp edi, edx
mov ebx, dword [ebp + 0x14]
jne 0x5a9391
mov edx, dword [esp + 0x14]
jmp 0x5a93a8
mov ecx, dword [esp + 0x10]
add ecx, edx
mov edx, dword [esp + 0x14]
nop dword [eax + eax]
or eax, dword [esi + ecx*4]
inc ecx
cmp edx, ecx
jne 0x5a93a0
mov ecx, eax
not ecx
dec eax
and eax, ecx
sar eax, 0x1f
not eax
mov edi, dword [esp + 0x28]
or edi, eax
mov eax, edi
jmp 0x5a94ac
and eax, 0xfffffffc
lea ecx, [esi + edx*4]
add ecx, 0x70
pxor xmm0, xmm0
xor edx, edx
pxor xmm1, xmm1
movdqu xmm2, xmmword [ecx + edx*4 - 0x70]
por xmm2, xmm0
movdqu xmm0, xmmword [ecx + edx*4 - 0x60]
por xmm0, xmm1
movdqu xmm1, xmmword [ecx + edx*4 - 0x50]
movdqu xmm3, xmmword [ecx + edx*4 - 0x40]
movdqu xmm4, xmmword [ecx + edx*4 - 0x30]
por xmm4, xmm1
por xmm4, xmm2
movdqu xmm2, xmmword [ecx + edx*4 - 0x20]
por xmm2, xmm3
por xmm2, xmm0
movdqu xmm0, xmmword [ecx + edx*4 - 0x10]
por xmm0, xmm4
movdqu xmm1, xmmword [ecx + edx*4]
por xmm1, xmm2
add edx, 0x20
add eax, 0xfffffffc
jne 0x5a93d4
mov eax, dword [esp + 0xc]
and eax, 0xfffffff8
test edi, edi
je 0x5a945f
add edx, dword [esp + 0x14]
lea ecx, [esi + edx*4]
add ecx, 0x10
shl edi, 5
xor edx, edx
movdqu xmm2, xmmword [ecx + edx - 0x10]
por xmm0, xmm2
movdqu xmm2, xmmword [ecx + edx]
por xmm1, xmm2
add edx, 0x20
cmp edi, edx
jne 0x5a9445
por xmm0, xmm1
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movd ecx, xmm0
cmp dword [esp + 0xc], eax
je 0x5a9498
add eax, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
nop word [eax + eax]
or ecx, dword [esi + eax*4]
inc eax
cmp edx, eax
jne 0x5a9490
xor edx, edx
xor eax, eax
test ecx, ecx
cmove edx, dword [esp + 0x28]
setne al
or eax, edx
mov edx, dword [esp + 0x14]
test eax, eax
js 0x5a94d4
push 0x399
push str.external_boringssl_src_crypto_fipsmodule_bn_exponentiation.c
push 0x6b
push 0
push 3
call sym.adb.exe_ERR_put_error
add esp, 0x14
xor ebx, ebx
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, dword [ebp + 0x10]
mov esi, dword [ebp + 8]
mov edi, dword [eax + 4]
test edi, edi
je 0x5a989b
mov eax, dword [ebp + 0x1c]
xor ecx, ecx
test eax, eax
jne 0x5a9504
push dword [ebp + 0x18]
push ebx
call sym.adb.exe_BN_MONT_CTX_new_consttime
add esp, 8
mov ecx, eax
test eax, eax
je 0x5a98fb
mov dword [esp + 0x20], ecx
mov dword [esp + 0x2c], eax
mov edx, dword [eax + 0x18]
mov ecx, 6
cmp edi, 0x1d
jg 0x5a9538
mov ecx, 5
cmp edi, 9
jg 0x5a9538
mov ecx, 4
cmp edi, 2
jg 0x5a9538
xor eax, eax
test edi, edi
setg al
lea ecx, [eax + eax]
inc ecx
mov dword [esp + 0x1c], edi
mov esi, 1
shl esi, cl
mov edi, edx
mov dword [esp + 0x14], ecx
shl edi, cl
mov dword [esp + 0x10], edx
lea ebx, [edx + edx]
cmp ebx, esi
cmovle ebx, esi
add ebx, edi
lea eax, [ebx*4 + 0x40]
shl ebx, 2
push eax
call sym.adb.exe_OPENSSL_malloc
add esp, 4
test eax, eax
mov dword [esp + 0x4c], ebx
je 0x5a98e6
mov dword [esp + 0x28], eax
and eax, 0xffffffc0
add eax, 0x40
test ebx, ebx
mov dword [esp + 0xc], eax
je 0x5a959a
push ebx
push 0
push eax
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
mov eax, dword [esp + 0x18]
add esp, 0xc
lea eax, [eax + edi*4]
mov dword [esp + 0x30], eax
mov ecx, dword [esp + 0x10]
lea eax, [eax + ecx*4]
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], 0
mov dword [esp + 0x34], 0
mov dword [esp + 0x58], ecx
mov dword [esp + 0x38], ecx
mov dword [esp + 0x5c], 0
mov dword [esp + 0x3c], 0
mov dword [esp + 0x60], 2
mov dword [esp + 0x40], 2
lea eax, [esp + 0x30]
mov edi, dword [ebp + 0x18]
push edi
mov edi, dword [esp + 0x30]
push edi
push eax
call fcn.005a9c00
add esp, 0xc
xor ebx, ebx
test eax, eax
je 0x5a9bb5
lea eax, [esp + 0x50]
push dword [ebp + 0x18]
push edi
push edi
push dword [ebp + 0xc]
push eax
call sym.adb.exe_BN_mod_mul_montgomery
add esp, 0x14
test eax, eax
je 0x5a9bb5
lea ecx, [esp + 0x30]
mov edx, dword [esp + 0x10]
push 0
mov edi, dword [esp + 0x10]
push edi
call fcn.005a9c90
add esp, 8
lea ecx, [esp + 0x50]
mov edx, dword [esp + 0x10]
push 1
push edi
call fcn.005a9c90
add esp, 8
cmp dword [esp + 0x14], 2
jb 0x5a9916
push dword [ebp + 0x18]
push dword [esp + 0x30]
lea eax, [esp + 0x58]
push eax
push eax
lea edi, [esp + 0x40]
push edi
call sym.adb.exe_BN_mod_mul_montgomery
add esp, 0x14
test eax, eax
je 0x5a9bb5
mov ecx, edi
mov edi, dword [esp + 0x10]
mov edx, edi
push 2
push dword [esp + 0x10]
call fcn.005a9c90
add esp, 8
lea eax, [edi*4]
cmp esi, 5
mov ecx, 4
cmovae ecx, esi
mov dword [esp + 0x18], ecx
lea ecx, [edi*4 + 0x70]
mov dword [esp + 0x70], ecx
mov esi, 3
mov dword [esp + 0x78], eax
jmp 0x5a96dd
push 0x135
push str.external_boringssl_src_crypto_fipsmodule_bn_bn.c
push 0x6d
push 0
push 3
call sym.adb.exe_ERR_put_error
add esp, 0x14
inc esi
cmp esi, dword [esp + 0x18]
je 0x5a9916
push dword [ebp + 0x18]
push dword [esp + 0x30]
lea ecx, [esp + 0x38]
push ecx
lea eax, [esp + 0x5c]
push eax
push ecx
call sym.adb.exe_BN_mod_mul_montgomery
add esp, 0x14
test eax, eax
je 0x5a9bb5
cmp dword [esp + 0x3c], 0
jne 0x5a96ba
mov edi, dword [esp + 0x34]
mov edx, edi
mov ecx, dword [esp + 0x10]
sub edx, ecx
jbe 0x5a9855
mov eax, dword [esp + 0x30]
mov dword [esp + 0x24], eax
xor eax, eax
cmp edx, 8
jb 0x5a982e
mov dword [esp + 0x48], edx
lea eax, [edx - 8]
mov ecx, eax
shr ecx, 3
inc ecx
mov edx, ecx
and edx, 3
mov dword [esp + 0x74], edx
cmp eax, 0x18
mov dword [esp + 0x44], esi
jae 0x5a9756
pxor xmm0, xmm0
xor edx, edx
pxor xmm1, xmm1
jmp 0x5a97c4
and ecx, 0xfffffffc
mov eax, dword [esp + 0x70]
mov edx, dword [esp + 0x24]
add eax, edx
pxor xmm0, xmm0
xor edx, edx
pxor xmm1, xmm1
movdqu xmm2, xmmword [eax + edx*4 - 0x70]
por xmm2, xmm0
movdqu xmm0, xmmword [eax + edx*4 - 0x60]
por xmm0, xmm1
movdqu xmm1, xmmword [eax + edx*4 - 0x50]
movdqu xmm3, xmmword [eax + edx*4 - 0x40]
movdqu xmm4, xmmword [eax + edx*4 - 0x30]
por xmm4, xmm1
por xmm4, xmm2
movdqu xmm2, xmmword [eax + edx*4 - 0x20]
por xmm2, xmm3
por xmm2, xmm0
movdqu xmm0, xmmword [eax + edx*4 - 0x10]
por xmm0, xmm4
movdqu xmm1, xmmword [eax + edx*4]
por xmm1, xmm2
add edx, 0x20
add ecx, 0xfffffffc
jne 0x5a976d
mov ecx, dword [esp + 0x48]
and ecx, 0xfffffff8
mov esi, dword [esp + 0x74]
test esi, esi
je 0x5a9800
add edx, dword [esp + 0x10]
mov eax, dword [esp + 0x24]
lea eax, [eax + edx*4]
add eax, 0x10
shl esi, 5
xor edx, edx
movdqu xmm2, xmmword [eax + edx - 0x10]
por xmm0, xmm2
movdqu xmm2, xmmword [eax + edx]
por xmm1, xmm2
add edx, 0x20
cmp esi, edx
jne 0x5a97e6
por xmm0, xmm1
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movd eax, xmm0
cmp dword [esp + 0x48], ecx
jne 0x5a9826
mov esi, dword [esp + 0x44]
jmp 0x5a983a
add ecx, dword [esp + 0x10]
mov esi, dword [esp + 0x44]
mov edx, dword [esp + 0x24]
or eax, dword [edx + ecx*4]
inc ecx
cmp edi, ecx
jne 0x5a9832
mov ecx, dword [esp + 0x10]
mov edi, ecx
test eax, eax
je 0x5a9855
push 0x13c
push str.external_boringssl_src_crypto_fipsmodule_bn_bn.c
push 0x66
jmp 0x5a96c6
mov eax, esi
imul eax, ecx
mov ecx, dword [esp + 0xc]
lea ecx, [ecx + eax*4]
mov eax, dword [esp + 0x78]
test eax, eax
je 0x5a987d
push eax
push 0
push ecx
mov dword [esp + 0x30], ecx
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
mov ecx, dword [esp + 0x30]
add esp, 0xc
shl edi, 2
test edi, edi
je 0x5a96d2
push edi
push dword [esp + 0x34]
push ecx
call sub.api_ms_win_crt_private_l1_1_0.dll_memcpy
add esp, 0xc
jmp 0x5a96d2
mov ecx, dword [esp + 0x2c]
xor ecx, 1
cmp edx, 2
jl 0x5a9a5d
mov ebx, 1
cmp edx, 9
jb 0x5a9a51
lea esi, [edx - 1]
movd xmm0, ecx
lea ecx, [edx - 9]
mov edx, ecx
shr edx, 3
inc edx
mov eax, edx
and eax, 3
cmp ecx, 0x18
jae 0x5a9991
pxor xmm1, xmm1
xor edi, edi
mov ecx, dword [esp + 0x18]
jmp 0x5a99f6
xor ebx, ebx
mov dword [esp + 0x28], 0
xor esi, esi
mov eax, dword [esp + 0x20]
jmp 0x5a9bbd
xor ebx, ebx
xor eax, eax
mov dword [esp + 0x28], 0
mov dword [esp + 0x4c], 0
xor esi, esi
jmp 0x5a9bbd
mov ecx, dword [esp + 0x1c]
shl ecx, 5
lea edi, [ecx - 1]
mov eax, edi
cdq
idiv dword [esp + 0x14]
xor ebx, ebx
test edx, edx
js 0x5a9aac
add ecx, 0xfffffffe
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x24], edx
lea ecx, [edx + 1]
xor eax, eax
jmp 0x5a994b
or eax, edx
dec edi
dec ecx
test ecx, ecx
jle 0x5a9984
mov edx, eax
add edx, eax
mov eax, 0
test edi, edi
js 0x5a9943
mov esi, edi
shr esi, 5
mov eax, 0
mov dword [esp + 0x18], edi
mov edi, dword [ebp + 0x10]
cmp esi, dword [edi + 4]
mov edi, dword [esp + 0x18]
jae 0x5a9943
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
mov esi, dword [eax + esi*4]
xor eax, eax
bt esi, edi
setb al
jmp 0x5a9943
mov edi, dword [esp + 0x1c]
sub edi, dword [esp + 0x24]
jmp 0x5a9aae
and edx, 0xfffffffc
pxor xmm1, xmm1
xor edi, edi
mov ecx, dword [esp + 0x18]
movdqu xmm2, xmmword [ecx + edi*4 + 4]
por xmm2, xmm0
movdqu xmm0, xmmword [ecx + edi*4 + 0x14]
por xmm0, xmm1
movdqu xmm1, xmmword [ecx + edi*4 + 0x24]
movdqu xmm3, xmmword [ecx + edi*4 + 0x34]
movdqu xmm4, xmmword [ecx + edi*4 + 0x44]
por xmm4, xmm1
por xmm4, xmm2
movdqu xmm2, xmmword [ecx + edi*4 + 0x54]
por xmm2, xmm3
por xmm2, xmm0
movdqu xmm0, xmmword [ecx + edi*4 + 0x64]
por xmm0, xmm4
movdqu xmm1, xmmword [ecx + edi*4 + 0x74]
por xmm1, xmm2
add edi, 0x20
add edx, 0xfffffffc
jne 0x5a999e
mov ebx, esi
and ebx, 0xfffffff8
test eax, eax
je 0x5a9a24
mov edx, ecx
lea ecx, [edi*4]
or ecx, 4
movdqu xmm2, xmmword [edx + ecx]
por xmm0, xmm2
movdqu xmm2, xmmword [edx + ecx + 0x10]
por xmm1, xmm2
add edi, 8
dec eax
jne 0x5a9a01
por xmm0, xmm1
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movd ecx, xmm0
cmp esi, ebx
mov edx, dword [esp + 0x14]
jne 0x5a9a4b
mov esi, dword [ebp + 8]
jmp 0x5a9a5d
or ebx, 1
mov esi, dword [ebp + 8]
mov eax, dword [esp + 0x18]
or ecx, dword [eax + ebx*4]
inc ebx
cmp edx, ebx
jne 0x5a9a55
test ecx, ecx
je 0x5a9a94
push 1
push esi
call fcn.0059f5c0
add esp, 8
test eax, eax
je 0x5a94c8
mov dword [esi + 0xc], 0
mov eax, dword [esi]
mov dword [eax], 1
mov dword [esi + 4], 1
mov ebx, 1
jmp 0x5a94ca
mov dword [esi + 0xc], 0
mov dword [esi + 4], 0
mov ebx, 1
jmp 0x5a94ca
xor eax, eax
lea ecx, [esp + 0x30]
mov edx, dword [esp + 0x10]
push dword [esp + 0x14]
push eax
push dword [esp + 0x14]
call fcn.005a9e40
add esp, 0xc
test eax, eax
je 0x5a9bb5
test edi, edi
js 0x5a9b97
mov dword [esp + 0x18], edi
sub edi, dword [esp + 0x14]
mov dword [esp + 0x24], edi
xor ebx, ebx
xor edi, edi
xor esi, esi
jmp 0x5a9afa
mov esi, dword [esp + 0x1c]
or esi, eax
dec edi
mov eax, dword [esp + 0x14]
add eax, edi
je 0x5a9b52
push dword [ebp + 0x18]
push dword [esp + 0x30]
lea eax, [esp + 0x38]
push eax
push eax
push eax
call sym.adb.exe_BN_mod_mul_montgomery
add esp, 0x14
test eax, eax
je 0x5a9bb5
mov eax, dword [esp + 0x18]
lea ecx, [eax + edi]
mov eax, esi
add eax, esi
mov dword [esp + 0x1c], 0
test ecx, ecx
js 0x5a9aeb
mov edx, ecx
shr edx, 5
mov esi, dword [ebp + 0x10]
cmp edx, dword [esi + 4]
jae 0x5a9aeb
mov esi, dword [ebp + 0x10]
mov esi, dword [esi]
mov esi, dword [esi + edx*4]
xor edx, edx
bt esi, ecx
setb dl
mov dword [esp + 0x1c], edx
jmp 0x5a9aeb
lea edi, [esp + 0x50]
mov ecx, edi
mov edx, dword [esp + 0x10]
push dword [esp + 0x14]
push esi
push dword [esp + 0x14]
call fcn.005a9e40
add esp, 0xc
xor ebx, ebx
test eax, eax
je 0x5a9bb5
push dword [ebp + 0x18]
push dword [esp + 0x30]
push edi
lea eax, [esp + 0x3c]
push eax
push eax
call sym.adb.exe_BN_mod_mul_montgomery
add esp, 0x14
mov edi, dword [esp + 0x24]
test eax, eax
jne 0x5a9acf
jmp 0x5a9bb5
push dword [ebp + 0x18]
push dword [esp + 0x30]
lea eax, [esp + 0x38]
push eax
push dword [ebp + 8]
call sym.adb.exe_BN_from_montgomery
add esp, 0x10
xor ebx, ebx
test eax, eax
setne bl
mov eax, dword [esp + 0x20]
mov esi, dword [esp + 0xc]
push eax
call sym.adb.exe_BN_MONT_CTX_free
add esp, 4
test esi, esi
mov eax, dword [esp + 0x28]
je 0x5a9be3
test eax, eax
jne 0x5a9be3
push dword [esp + 0x4c]
push esi
call sym.adb.exe_OPENSSL_cleanse
mov eax, dword [esp + 0x30]
add esp, 8
push eax
call sym.adb.exe_OPENSSL_free
add esp, 4
jmp 0x5a94ca