Function at 0x10012650
Capabilities:
Authenticate hmac
Encode data using xor
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
mov eax, 0x344
call fcn.10079f60
mov eax, dword [0x100ce750]
xor eax, esp
mov dword [esp + 0x340], eax
mov eax, dword [ebp + 8]
mov dword [esp + 0x48], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x5c], eax
mov eax, dword [ebp + 0x14]
push ebx
mov ebx, dword [ebp + 0x20]
mov dword [esp + 0x30], eax
mov eax, dword [ebp + 0x18]
mov dword [esp + 0x2c], eax
mov eax, dword [ebp + 0x24]
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], 0x28
mov dword [esp + 0xc], 8
mov byte [esp + 7], 1
push esi
mov esi, dword [ebp + 0x10]
mov dword [esp + 0x70], esi
push edi
mov edi, 0x40
cmp ebx, 0x100000
jb 0x100126d7
push str.data_plus_mac_plus_padding_size___1024__1024
push 0x1c0
push str.._ssl_s3_cbc.c
call fcn.10022bf0
add esp, 0xc
push dword [esp + 0x54]
call fcn.1002faa0
add esp, 4
cmp eax, 0x2a0
jg 0x10012781
je 0x1001275a
cmp eax, 4
je 0x10012725
cmp eax, 0x40
jne 0x1001278e
lea eax, [esp + 0xa0]
push eax
call fcn.10034010
mov dword [esp + 0x2c], 0x100131f0
mov eax, 0x14
mov dword [esp + 0x14], 0x10034060
jmp 0x1001282c
lea eax, [esp + 0xa0]
push eax
call fcn.10039fe0
mov edx, 0x30
mov dword [esp + 0x2c], 0x10013170
mov dword [esp + 0x14], 0x1003a020
mov eax, 0x10
mov dword [esp + 0x50], edx
mov byte [esp + 0x13], 0
jmp 0x10012831
lea eax, [esp + 0xa0]
push eax
call fcn.100359d0
mov dword [esp + 0x2c], 0x10013290
mov eax, 0x20
mov dword [esp + 0x14], 0x10035a30
jmp 0x1001282c
sub eax, 0x2a1
je 0x100127fd
dec eax
je 0x100127ec
dec eax
je 0x100127c8
push 0x100971c0
push 0x1fc
push str.._ssl_s3_cbc.c
call fcn.10022bf0
add esp, 0xc
test esi, esi
je 0x10012f5a
mov dword [esi], 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x340]
xor ecx, esp
call fcn.1007ba40
mov esp, ebp
pop ebp
ret
lea eax, [esp + 0xa0]
push eax
call fcn.10035690
mov dword [esp + 0x2c], 0x10013290
mov eax, 0x1c
mov dword [esp + 0x14], 0x10035a30
jmp 0x1001282c
lea eax, [esp + 0xa0]
push eax
call fcn.10037260
mov eax, edi
jmp 0x1001280f
lea eax, [esp + 0xa0]
push eax
call fcn.10036c30
mov eax, 0x30
mov dword [esp + 0x18], 0x10
mov edi, 0x80
mov dword [esp + 0x14], 0x10037310
mov dword [esp + 0x2c], 0x10013380
mov edx, 0x28
add esp, 4
mov dword [esp + 0x18], eax
cmp byte [ebp + 0x2c], 0
mov ecx, 0xd
mov dword [esp + 0x44], ecx
je 0x10012853
mov ecx, dword [ebp + 0x28]
add ecx, 0xb
add ecx, edx
mov dword [esp + 0x44], ecx
xor edx, edx
mov esi, ecx
cmp byte [ebp + 0x2c], dl
sete dl
sub esi, eax
mov eax, dword [esp + 0x14]
xor ecx, ecx
dec eax
add eax, esi
add esi, dword [ebp + 0x1c]
add eax, edi
lea edx, [edx*4 + 2]
add eax, ebx
mov dword [esp + 0x30], edx
xor edx, edx
xor ebx, ebx
div edi
xor edx, edx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x2c], eax
xor eax, eax
mov dword [esp + 0x3c], eax
mov eax, esi
div edi
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x40], edx
add eax, esi
xor edx, edx
div edi
cmp byte [ebp + 0x2c], cl
mov edx, dword [esp + 0x30]
setne cl
mov dword [esp + 0x8c], eax
mov eax, dword [esp + 0x2c]
add ecx, edx
cmp eax, ecx
jbe 0x100128d0
sub eax, edx
mov ebx, eax
mov dword [esp + 0x3c], eax
imul ebx, edi
mov dword [esp + 0x1c], ebx
cmp byte [ebp + 0x2c], 0
lea eax, [esi*8]
mov dword [esp + 0x20], eax
jne 0x100129b8
lea eax, [eax + edi*8]
push edi
mov dword [esp + 0x24], eax
lea eax, [esp + 0x1cc]
push 0
push eax
call fcn.10078750
mov esi, dword [ebp + 0x28]
add esp, 0xc
cmp esi, 0x80
jbe 0x10012921
push str.mac_secret_length___sizeof_hmac_pad_
push 0x264
push str.._ssl_s3_cbc.c
call fcn.10022bf0
add esp, 0xc
push esi
push dword [esp + 0x4c]
lea eax, [esp + 0x1d0]
push eax
call fcn.10078a50
add esp, 0xc
xor ecx, ecx
test edi, edi
je 0x1001299d
cmp edi, 0x20
jb 0x10012986
movdqa xmm1, xmmword [str.6666666666666666jjjjjjjjjjjjjjjjA]
mov eax, edi
and eax, 0x1f
mov edx, edi
sub edx, eax
lea eax, [esp + 0x1d8]
lea esp, [esp]
movdqu xmm0, xmmword [eax - 0x10]
add ecx, 0x20
lea eax, [eax + 0x20]
pxor xmm0, xmm1
movdqu xmmword [eax - 0x30], xmm0
movdqu xmm0, xmmword [eax - 0x20]
pxor xmm0, xmm1
movdqu xmmword [eax - 0x20], xmm0
cmp ecx, edx
jb 0x10012960
cmp ecx, edi
jae 0x1001299d
lea ebx, [ebx]
xor byte [esp + ecx + 0x1c8], 0x36
inc ecx
cmp ecx, edi
jb 0x10012990
mov esi, dword [esp + 0x10]
lea eax, [esp + 0x1c8]
push eax
lea eax, [esp + 0xa4]
push eax
call esi
add esp, 8
jmp 0x100129bc
mov esi, dword [esp + 0x10]
cmp byte [esp + 0xf], 0
je 0x10012a12
mov eax, dword [esp + 0x14]
add eax, 0xfffffffc
push eax
lea eax, [esp + 0x17c]
push 0
push eax
call fcn.10078750
mov ecx, dword [esp + 0x2c]
add esp, 0xc
mov edx, dword [esp + 0x14]
mov eax, ecx
shr eax, 0x18
mov byte [esp + edx + 0x174], al
mov eax, ecx
shr eax, 0x10
mov byte [esp + edx + 0x175], al
mov eax, ecx
shr eax, 8
mov byte [esp + edx + 0x176], al
mov byte [esp + edx + 0x177], cl
jmp 0x10012a5b
push dword [esp + 0x14]
lea eax, [esp + 0x17c]
push 0
push eax
call fcn.10078750
mov ecx, dword [esp + 0x2c]
add esp, 0xc
mov edx, dword [esp + 0x14]
mov eax, ecx
shr eax, 0x18
mov byte [esp + edx + 0x173], al
mov eax, ecx
shr eax, 0x10
mov byte [esp + edx + 0x172], al
mov eax, ecx
shr eax, 8
mov byte [esp + edx + 0x171], al
mov byte [esp + edx + 0x170], cl
test ebx, ebx
je 0x10012b85
cmp byte [ebp + 0x2c], 0
je 0x10012b07
mov esi, dword [esp + 0x44]
lea eax, [esp + 0xa0]
push dword [esp + 0x38]
sub esi, edi
push eax
mov dword [esp + 0x34], esi
call dword [esp + 0x18]
mov eax, dword [esp + 0x40]
add eax, edi
push esi
push eax
lea eax, [esp + 0x258]
push eax
call fcn.10078a50
mov eax, edi
sub eax, esi
push eax
push dword [esp + 0x4c]
lea eax, [esp + 0x264]
add eax, esi
push eax
call fcn.10078a50
lea eax, [esp + 0x268]
push eax
lea eax, [esp + 0xc4]
push eax
call dword [esp + 0x38]
xor edx, edx
mov eax, ebx
div edi
add esp, 0x28
dec eax
cmp eax, 1
jbe 0x10012b85
mov esi, dword [esp + 0x34]
lea ebx, [eax - 1]
sub esi, dword [esp + 0x2c]
add esi, edi
jmp 0x10012af0
lea eax, [esp + 0xa0]
push esi
push eax
call dword [esp + 0x18]
add esp, 8
add esi, edi
dec ebx
jne 0x10012af0
jmp 0x10012b85
mov ecx, dword [esp + 0x38]
mov eax, dword [ecx + 8]
movq xmm0, qword [ecx]
mov dword [esp + 0x250], eax
mov al, byte [ecx + 0xc]
mov byte [esp + 0x254], al
lea eax, [edi - 0xd]
push eax
push dword [esp + 0x38]
lea eax, [esp + 0x25d]
movq qword [esp + 0x250], xmm0
push eax
call fcn.10078a50
lea eax, [esp + 0x254]
push eax
lea eax, [esp + 0xb0]
push eax
call esi
xor edx, edx
mov eax, ebx
div edi
add esp, 0x14
cmp eax, 1
jbe 0x10012b85
mov esi, dword [esp + 0x34]
lea ebx, [eax - 1]
add esi, 0xfffffff3
add esi, edi
lea ecx, [ecx]
lea eax, [esp + 0xa0]
push esi
push eax
call dword [esp + 0x18]
add esp, 8
add esi, edi
dec ebx
jne 0x10012b70
push 0x40
lea eax, [esp + 0x18c]
push 0
push eax
call fcn.10078750
mov eax, dword [esp + 0x3c]
add esp, 0xc
mov edx, dword [esp + 0x3c]
add eax, edx
mov esi, dword [esp + 0x18]
mov dword [esp + 0x80], eax
cmp edx, eax
ja 0x10012e1b
mov eax, edx
xor eax, dword [esp + 0x70]
lea ecx, [eax - 1]
not eax
shr eax, 0x1f
shr ecx, 0x1f
and cl, al
mov eax, edx
xor eax, dword [esp + 0x8c]
neg cl
mov dword [esp + 0x50], ecx
xor ecx, ecx
mov dword [esp + 0x20], ecx
lea edx, [eax - 1]
not eax
shr edx, 0x1f
shr eax, 0x1f
and dl, al
neg dl
movsx eax, dl
mov dword [esp + 0x2c], edx
movd xmm0, eax
punpcklbw xmm0, xmm0
punpcklwd xmm0, xmm0
pshufd xmm0, xmm0, 0
movdqa xmmword [esp + 0x90], xmm0
test edi, edi
je 0x10012d3d
mov eax, dword [esp + 0x40]
not dl
lea esi, [eax + 1]
shr eax, 0x1f
mov dword [esp + 0x7c], eax
mov eax, dword [esp + 0x50]
or dl, al
movzx ebx, al
mov eax, edi
sub eax, dword [esp + 0x14]
shr esi, 0x1f
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x78], esi
sub eax, edi
mov esi, dword [esp + 0x40]
mov dword [esp + 0x84], ebx
neg esi
lea ebx, [esp + 0x178]
mov byte [esp + 0x27], dl
add eax, ebx
mov ebx, dword [esp + 0x1c]
mov dword [esp + 0x30], eax
jmp 0x10012c70
mov edx, dword [esp + 0x44]
mov byte [esp + 0xf], 0
cmp ebx, edx
jae 0x10012c83
mov eax, dword [esp + 0x38]
jmp 0x10012c92
mov eax, dword [ebp + 0x20]
add eax, edx
cmp ebx, eax
jae 0x10012c99
mov eax, dword [esp + 0x34]
sub eax, edx
mov al, byte [eax + ebx]
mov byte [esp + 0xf], al
mov eax, dword [esp + 0x7c]
mov edx, ecx
inc ebx
shr edx, 0x1f
mov dword [esp + 0x1c], ebx
mov ecx, esi
shr ecx, 0x1f
lea ebx, [esi - 1]
xor cl, al
shr ebx, 0x1f
xor al, dl
or cl, al
mov eax, dword [esp + 0x78]
xor bl, al
xor cl, dl
dec cl
xor al, dl
or bl, al
movzx ecx, cl
and ecx, dword [esp + 0x84]
xor bl, dl
dec bl
mov al, cl
and bl, byte [esp + 0x50]
not al
and al, byte [esp + 0xf]
and cl, 0x80
or al, cl
not bl
mov ecx, dword [esp + 0x20]
and bl, al
and bl, byte [esp + 0x27]
cmp ecx, dword [esp + 0x88]
jb 0x10012d15
mov eax, dword [esp + 0x2c]
movzx ecx, al
mov eax, dword [esp + 0x30]
mov dl, cl
not dl
and bl, dl
mov al, byte [eax]
and al, cl
mov ecx, dword [esp + 0x20]
or bl, al
inc dword [esp + 0x30]
lea eax, [esp + 0x2c8]
add eax, dword [esp + 0x40]
inc ecx
mov dword [esp + 0x20], ecx
mov byte [eax + esi], bl
inc esi
mov ebx, dword [esp + 0x1c]
cmp ecx, edi
jb 0x10012c70
mov esi, dword [esp + 0x18]
lea eax, [esp + 0x2c8]
push eax
lea eax, [esp + 0xa4]
push eax
call dword [esp + 0x18]
lea eax, [esp + 0x2d0]
push eax
lea eax, [esp + 0xac]
push eax
call dword [esp + 0x38]
add esp, 0x10
xor eax, eax
test esi, esi
je 0x10012e05
cmp esi, 0x20
jb 0x10012ddd
movdqa xmm2, xmmword [esp + 0x90]
mov ecx, esi
and ecx, 0x1f
mov edx, esi
sub edx, ecx
lea esp, [esp]
movdqu xmm0, xmmword [esp + eax + 0x188]
movdqu xmm1, xmmword [esp + eax + 0x2c8]
pand xmm1, xmm2
por xmm1, xmm0
movdqu xmmword [esp + eax + 0x188], xmm1
movdqu xmm1, xmmword [esp + eax + 0x2d8]
movdqu xmm0, xmmword [esp + eax + 0x198]
pand xmm1, xmm2
por xmm1, xmm0
movdqu xmmword [esp + eax + 0x198], xmm1
add eax, 0x20
cmp eax, edx
jb 0x10012d90
cmp eax, esi
jae 0x10012e05
mov edx, dword [esp + 0x2c]
jmp 0x10012df0
mov cl, byte [esp + eax + 0x2c8]
and cl, dl
or byte [esp + eax + 0x188], cl
inc eax
cmp eax, esi
jb 0x10012df0
mov edx, dword [esp + 0x3c]
inc edx
mov dword [esp + 0x3c], edx
cmp edx, dword [esp + 0x80]
jbe 0x10012bb6
lea eax, [esp + 0x58]
push eax
call fcn.100319d0
push 0
push dword [esp + 0x5c]
lea eax, [esp + 0x64]
push eax
call fcn.10031790
add esp, 0x10
cmp byte [ebp + 0x2c], 0
je 0x10012e94
mov ebx, dword [esp + 0x4c]
lea eax, [esp + 0x1c8]
push ebx
push 0x5c
push eax
call fcn.10078750
push dword [ebp + 0x28]
lea eax, [esp + 0x68]
push dword [esp + 0x58]
push eax
call fcn.10031840
push ebx
lea eax, [esp + 0x1e4]
push eax
lea eax, [esp + 0x78]
push eax
call fcn.10031840
push esi
lea eax, [esp + 0x1b0]
push eax
lea eax, [esp + 0x84]
push eax
call fcn.10031840
add esp, 0x30
jmp 0x10012f26
xor ecx, ecx
test edi, edi
je 0x10012efd
cmp edi, 0x20
jb 0x10012ee6
movdqa xmm1, xmmword [0x10097200]
mov eax, edi
and eax, 0x1f
mov edx, edi
sub edx, eax
lea eax, [esp + 0x1d8]
jmp 0x10012ec0
movdqu xmm0, xmmword [eax - 0x10]
add ecx, 0x20
lea eax, [eax + 0x20]
pxor xmm0, xmm1
movdqu xmmword [eax - 0x30], xmm0
movdqu xmm0, xmmword [eax - 0x20]
pxor xmm0, xmm1
movdqu xmmword [eax - 0x20], xmm0
cmp ecx, edx
jb 0x10012ec0
cmp ecx, edi
jae 0x10012efd
lea ebx, [ebx]
xor byte [esp + ecx + 0x1c8], 0x6a
inc ecx
cmp ecx, edi
jb 0x10012ef0
push edi
lea eax, [esp + 0x1cc]
push eax
lea eax, [esp + 0x60]
push eax
call fcn.10031840
push esi
lea eax, [esp + 0x198]
push eax
lea eax, [esp + 0x6c]
push eax
call fcn.10031840
add esp, 0x18
lea eax, [esp + 0x6c]
push eax
push dword [esp + 0x6c]
lea eax, [esp + 0x60]
push eax
call fcn.100316f0
mov ecx, dword [esp + 0x80]
add esp, 0xc
test ecx, ecx
je 0x10012f4d
mov eax, dword [esp + 0x6c]
mov dword [ecx], eax
lea eax, [esp + 0x58]
push eax
call fcn.10031850
add esp, 4
mov ecx, dword [esp + 0x34c]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1007ba40
mov esp, ebp
pop ebp
ret