Function at 0x51df56a5
Capabilities:
Encrypt data using rc4 ksa
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x88
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x9c]
mov dword [esp + 0x64], 0
cmp di, 0x400
mov dword [esp + 0x6c], 0
mov esi, edi
je 0x51e30c12
cmp di, 0x800
je 0x51e30c1a
cmp esi, dword [0x51e84be0]
jne 0x51e30ca7
mov eax, dword [0x51e874f0]
test eax, eax
jne 0x51e30c27
mov esi, 1
mov edx, dword [esp + 0xa0]
mov eax, dword [esp + 0xa8]
mov ecx, 0x51e895a0
and edx, 0xbfffffff
test ecx, ecx
mov ecx, dword [esp + 0xb0]
je 0x51df5733
mov ebx, dword [0x51e895bc]
test ebx, ebx
jne 0x51df5733
cmp eax, 0xffffffff
jle 0x51e313e5
cmp ecx, 0xffffffff
jle 0x51e3224f
cmp eax, 0xffffffff
jle 0x51e32259
push esi
push ecx
mov ecx, dword [esp + 0xb4]
push ecx
push eax
mov eax, dword [esp + 0xb4]
mov ecx, 0x51e895a0
push eax
call fcn.51df576f
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret 0x18
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
jmp 0x51e30c20
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultLCID]
mov esi, eax
jmp 0x51df56de
mov eax, dword [0x51e874ec]
test eax, eax
je 0x51e30c6c
mov eax, dword [esp + 0xb0]
mov ecx, dword [esp + 0xac]
mov edx, dword [esp + 0xa8]
push eax
mov eax, dword [esp + 0xa8]
push ecx
mov ecx, dword [esp + 0xa8]
push edx
push eax
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_CompareStringW]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret 0x18
mov edx, dword [esp + 0xb0]
mov eax, dword [esp + 0xac]
mov ecx, dword [esp + 0xa8]
push edx
mov edx, dword [esp + 0xa8]
push eax
push ecx
push edx
mov edx, dword [esp + 0xb0]
mov ecx, edi
call fcn.51e75351
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret 0x18
mov edx, dword [0x51eb981c]
mov ecx, 0xd
xor eax, eax
mov edi, 0x51e895a0
rep stosd dword es:[edi], eax
mov eax, dword [edx]
mov ecx, dword [edx + 0x1c]
test eax, eax
mov dword [0x51e895a0], esi
mov ebx, 1
jbe 0x51e30ce3
cmp dword [ecx], esi
je 0x51e30cdd
dec eax
add ecx, 4
test eax, eax
ja 0x51e30ccf
jmp 0x51e30ce3
mov dword [0x51e895b8], ebx
mov ecx, dword [edx + 0x10]
mov eax, dword [edx + 0x2c]
test ecx, ecx
jbe 0x51e30cf9
cmp dword [eax], esi
je 0x51e30d1a
dec ecx
add eax, 0xc
test ecx, ecx
ja 0x51e30ced
mov eax, dword [0x51e895bc]
test eax, eax
je 0x51e30d65
mov eax, dword [edx + 4]
mov ecx, dword [edx + 0x20]
test eax, eax
jbe 0x51e30d65
cmp dword [ecx], esi
je 0x51e30d5f
dec eax
add ecx, 4
test eax, eax
ja 0x51e30d0c
jmp 0x51e30d65
mov cx, word [eax + 8]
mov dword [0x51e895bc], ebx
test cx, cx
mov dword [0x51e895c4], eax
jbe 0x51e30d3e
mov edi, dword [eax + 4]
mov ebp, dword [edx + 0x30]
lea edi, [ebp + edi*2]
mov dword [0x51e895c8], edi
cmp word [eax + 0xa], 0
jbe 0x51e30d02
mov eax, dword [eax + 4]
and ecx, 0xffff
lea ecx, [eax + ecx*4]
mov eax, dword [edx + 0x30]
lea ecx, [eax + ecx*2]
mov dword [0x51e895cc], ecx
jmp 0x51e30d02
mov dword [0x51e895c0], ebx
mov eax, dword [0x51eb8bf8]
xor ebp, ebp
test eax, eax
jle 0x51e30da1
mov edi, 0x51eb85b8
xor edx, edx
mov dl, byte [edi]
mov eax, dword [edx*4 + section..bootdat]
push eax
call fcn.51e77526
mov edx, dword [edi + 4]
mov eax, dword [0x51eb8bf8]
xor ecx, ecx
inc ebp
mov cl, byte [edi]
add edi, 8
cmp ebp, eax
mov dword [ecx*4 + section..bootdat], edx
jl 0x51e30d75
mov eax, esi
xor edx, edx
and eax, 0x3ff
mov dword [0x51eb8bf8], edx
cmp eax, 0x1f
mov dword [0x51e84be0], esi
mov dword [esp + 0x54], esi
mov dword [esp + 0x70], edx
mov dword [esp + 0x74], edx
mov dword [esp + 0x68], edx
mov dword [esp + 0x60], edx
jne 0x51e30dea
mov ecx, esi
shr ecx, 0x10
and cl, 0xf
cmp cl, 0xf
jne 0x51e30dea
and esi, 0xfff0ffff
mov dword [esp + 0x60], ebx
mov dword [esp + 0x54], esi
xor ecx, ecx
mov eax, 0x51e371c0
cmp dword [eax], esi
je 0x51e30e05
add eax, 0xc
inc ecx
cmp eax, 0x51e37328
jl 0x51e30df1
jmp 0x51e30f59
lea ecx, [ecx + ecx*2]
mov eax, 0xaaaaaaab
shl ecx, 2
mul dword [ecx + 0x51e371c4]
mov ebp, dword [ecx + 0x51e371c8]
xor eax, eax
shr edx, 1
cmp ebp, eax
mov dword [esp + 0x7c], ebp
lea edx, [edx + edx*2]
mov dword [0x51eb8bf8], eax
mov dword [esp + 0x58], eax
lea edi, [edx*2 + 0x51e37328]
jle 0x51e30f57
xor eax, eax
mov al, byte [edi + 1]
and eax, 0xff
mov eax, dword [eax*4 + section..bootdat]
cmp byte [eax], 0xa
jne 0x51e30e7c
xor edx, edx
xor ecx, ecx
mov dl, byte [edi]
mov cl, byte [edi + 3]
mov byte [eax + edx*4 + 4], cl
mov cl, byte [edi + 2]
mov byte [eax + edx*4 + 5], cl
mov cl, byte [edi + 4]
mov byte [eax + edx*4 + 6], cl
mov cl, byte [edi + 5]
mov byte [eax + edx*4 + 7], cl
jmp 0x51e30f43
push 2
push 0x404
call fcn.51e774f5
mov esi, eax
test esi, esi
je 0x51e3141a
mov ax, word [edi]
mov ecx, dword [0x51eb8bf8]
shr ax, 8
mov byte [ecx*8 + 0x51eb85b8], al
and eax, 0xff
inc ecx
mov byte [esi], 0xa
mov edx, dword [eax*4 + section..bootdat]
mov dword [0x51eb8bf8], ecx
mov dword [ecx*8 + 0x51eb85b4], edx
xor ebx, ebx
lea ebp, [esi + 5]
mov cx, word [edi]
lea edx, [esp + 0x20]
and ecx, 0xff00
or ecx, ebx
call fcn.51df5aac
mov al, byte [esp + 0x21]
inc ebx
mov byte [ebp - 1], al
mov cl, byte [esp + 0x20]
mov byte [ebp], cl
mov dl, byte [esp + 0x22]
mov byte [ebp + 1], dl
mov al, byte [esp + 0x23]
mov byte [ebp + 2], al
add ebp, 4
cmp bx, 0x100
jb 0x51e30ec8
mov dl, byte [edi + 2]
xor eax, eax
mov al, byte [edi]
xor ecx, ecx
mov cl, byte [edi + 3]
mov ebp, dword [esp + 0x7c]
mov byte [esi + eax*4 + 4], cl
mov cl, byte [edi + 4]
mov byte [esi + eax*4 + 5], dl
mov dl, byte [edi + 5]
mov byte [esi + eax*4 + 6], cl
mov byte [esi + eax*4 + 7], dl
xor eax, eax
mov ebx, 1
mov al, byte [edi + 1]
and eax, 0xff
mov dword [eax*4 + section..bootdat], esi
mov esi, dword [esp + 0x54]
mov eax, dword [esp + 0x58]
add edi, 6
inc eax
cmp eax, ebp
mov dword [esp + 0x58], eax
jl 0x51e30e3f
xor edx, edx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x3c], ebx
xor ecx, ecx
mov eax, 0x51e32268
cmp dword [eax], esi
je 0x51e30fa0
add eax, 0xc
inc ecx
cmp eax, 0x51e322bc
jl 0x51e30f68
cmp dword [esp + 0x60], edx
je 0x51e313ca
mov ecx, dword [0x51eb9004]
mov edx, dword [section..bootdat]
mov al, 0x31
mov byte [ecx + 0xc9], al
mov byte [edx + 0x129], al
jmp 0x51e313ca
lea ecx, [ecx + ecx*2]
shl ecx, 2
mov dword [esp + 0x7c], ecx
mov ebp, dword [ecx + 0x51e3226c]
cmp ebp, edx
je 0x51e3141a
cmp esi, 0x412
jne 0x51e30fff
mov edx, 0x51eb044c
mov dword [esp + 0x70], 0x51eb044c
test edx, edx
mov dword [esp + 0x74], 0x51eb04e4
mov dword [esp + 0x68], 0x51eb0c48
je 0x51e3141a
mov eax, 0x51eb04e4
test eax, eax
je 0x51e3141a
mov edx, 0x51eb0c48
test edx, edx
je 0x51e3141a
xor ebx, ebx
cmp word [ecx + 0x51e32270], bx
jbe 0x51e312a4
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x70]
add ecx, 4
mov dword [esp + 0x38], ebp
lea edi, [eax + 4]
mov dword [esp + 0x24], ecx
mov dword [esp + 0x58], edi
mov ax, word [ebp]
test ax, ax
je 0x51e31287
xor edx, edx
mov dl, ah
and edx, 0xff
mov ecx, dword [edx*4 + section..bootdat]
cmp byte [ecx], 0xa
jne 0x51e31116
cmp dword [esp + 0x54], 0x412
je 0x51e3109a
xor eax, eax
mov al, byte [ebp]
mov esi, eax
mov eax, 0x81020409
imul ebx
add edx, ebx
sar edx, 7
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, ebx
add dl, 0x80
mov byte [ecx + esi*4 + 4], dl
lea ecx, [ecx + esi*4]
cdq
mov esi, 0xfe
idiv esi
add dl, 2
mov byte [ecx + 5], dl
mov byte [ecx + 6], 2
mov byte [ecx + 7], 2
jmp 0x51e31287
cmp dword [esp + 0x40], 0x26
jge 0x51e310be
mov eax, dword [esp + 0x24]
xor edx, edx
mov dx, word [eax]
cmp ebx, edx
jl 0x51e310be
mov edx, dword [esp + 0x40]
inc edx
add eax, 4
mov dword [esp + 0x40], edx
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x24]
xor edx, edx
mov dl, byte [ebp]
mov esi, edx
mov dl, byte [eax - 2]
mov eax, dword [esp + 0x3c]
cmp eax, 0x1d9
mov byte [ecx + esi*4 + 4], dl
jge 0x51e310f4
xor eax, eax
mov ax, word [edi]
cmp ebx, eax
jl 0x51e310f4
mov edx, dword [esp + 0x3c]
inc edx
add edi, 4
mov dword [esp + 0x3c], edx
mov dword [esp + 0x58], edi
mov dl, byte [edi - 2]
mov al, byte [edi - 4]
lea ecx, [ecx + esi*4]
mov byte [ecx + 5], dl
mov dl, 0x7f
imul dl
add al, bl
shl al, 1
add al, 0x41
mov byte [ecx + 6], al
mov byte [ecx + 7], 2
jmp 0x51e31287
push 2
push 0x404
call fcn.51e774f5
mov ebp, eax
test ebp, ebp
je 0x51e3141a
mov eax, dword [esp + 0x38]
mov ecx, dword [0x51eb8bf8]
mov byte [ebp], 0xa
lea edi, [ebp + 5]
mov ax, word [eax]
shr ax, 8
mov byte [ecx*8 + 0x51eb85b8], al
and eax, 0xff
inc ecx
xor esi, esi
mov edx, dword [eax*4 + section..bootdat]
mov dword [0x51eb8bf8], ecx
mov dword [ecx*8 + 0x51eb85b4], edx
mov eax, dword [esp + 0x38]
lea edx, [esp + 0x20]
mov cx, word [eax]
and ecx, 0xff00
or ecx, esi
call fcn.51df5aac
mov cl, byte [esp + 0x21]
inc esi
mov byte [edi - 1], cl
mov dl, byte [esp + 0x20]
mov byte [edi], dl
mov al, byte [esp + 0x22]
mov byte [edi + 1], al
mov cl, byte [esp + 0x23]
mov byte [edi + 2], cl
add edi, 4
cmp si, 0x100
jb 0x51e31167
cmp dword [esp + 0x54], 0x412
je 0x51e311ec
mov eax, 0x81020409
mov esi, dword [esp + 0x38]
imul ebx
add edx, ebx
xor ecx, ecx
mov cl, byte [esi]
mov edi, 0xfe
sar edx, 7
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, ebx
add dl, 0x80
mov byte [ebp + ecx*4 + 4], dl
cdq
idiv edi
add dl, 2
mov byte [ebp + ecx*4 + 5], dl
mov byte [ebp + ecx*4 + 6], 2
jmp 0x51e3126d
mov eax, dword [esp + 0x40]
cmp eax, 0x26
jge 0x51e31212
mov edx, dword [esp + 0x24]
xor ecx, ecx
mov cx, word [edx]
cmp ebx, ecx
jl 0x51e31212
mov ecx, eax
mov eax, edx
inc ecx
add eax, 4
mov dword [esp + 0x40], ecx
mov dword [esp + 0x24], eax
mov esi, dword [esp + 0x38]
mov ecx, dword [esp + 0x24]
xor eax, eax
mov al, byte [esi]
mov dl, byte [ecx - 2]
mov edi, eax
mov eax, dword [esp + 0x3c]
cmp eax, 0x1d9
mov byte [ebp + edi*4 + 4], dl
jge 0x51e31251
mov eax, dword [esp + 0x58]
xor ecx, ecx
mov cx, word [eax]
cmp ebx, ecx
jl 0x51e31255
mov edx, dword [esp + 0x3c]
inc edx
add eax, 4
mov dword [esp + 0x3c], edx
mov dword [esp + 0x58], eax
jmp 0x51e31255
mov eax, dword [esp + 0x58]
mov dl, byte [eax - 2]
mov al, byte [eax - 4]
mov cl, 0x7f
mov byte [ebp + edi*4 + 5], dl
imul cl
add al, bl
shl al, 1
add al, 0x41
mov byte [ebp + edi*4 + 6], al
xor edx, edx
mov edi, dword [esp + 0x58]
mov dl, byte [esi + 1]
and edx, 0xff
mov dword [edx*4 + section..bootdat], ebp
mov ebp, dword [esp + 0x38]
mov ecx, dword [esp + 0x7c]
xor eax, eax
inc ebx
add ebp, 2
mov ax, word [ecx + 0x51e32270]
mov dword [esp + 0x38], ebp
cmp ebx, eax
jl 0x51e31028
cmp dword [esp + 0x54], 0x412
jne 0x51e313ca
mov esi, dword [esp + 0x68]
mov dword [esp + 0x58], 0
xor edx, edx
mov dl, byte [esi + 1]
and edx, 0xff
mov eax, dword [edx*4 + section..bootdat]
cmp byte [eax], 0xa
jne 0x51e312fa
mov dl, byte [esi + 2]
xor ecx, ecx
mov cl, byte [esi]
mov byte [eax + ecx*4 + 4], dl
mov dl, byte [esi + 3]
mov byte [eax + ecx*4 + 5], dl
mov dl, byte [esi + 4]
mov byte [eax + ecx*4 + 6], dl
mov dl, byte [esi + 5]
mov byte [eax + ecx*4 + 7], dl
jmp 0x51e313b3
push 2
push 0x404
call fcn.51e774f5
mov ebp, eax
test ebp, ebp
je 0x51e3141a
mov ax, word [esi]
mov ecx, dword [0x51eb8bf8]
shr ax, 8
mov byte [ecx*8 + 0x51eb85b8], al
and eax, 0xff
inc ecx
mov byte [ebp], 0xa
mov eax, dword [eax*4 + section..bootdat]
mov dword [0x51eb8bf8], ecx
mov dword [ecx*8 + 0x51eb85b4], eax
xor ebx, ebx
lea edi, [ebp + 5]
mov cx, word [esi]
lea edx, [esp + 0x20]
and ecx, 0xff00
or ecx, ebx
call fcn.51df5aac
mov cl, byte [esp + 0x21]
inc ebx
mov byte [edi - 1], cl
mov dl, byte [esp + 0x20]
mov byte [edi], dl
mov al, byte [esp + 0x22]
mov byte [edi + 1], al
mov cl, byte [esp + 0x23]
mov byte [edi + 2], cl
add edi, 4
cmp bx, 0x100
jb 0x51e31347
mov dl, byte [esi + 2]
mov cl, byte [esi + 3]
xor eax, eax
mov al, byte [esi]
mov byte [ebp + eax*4 + 4], dl
mov dl, byte [esi + 4]
mov byte [ebp + eax*4 + 5], cl
mov cl, byte [esi + 5]
mov byte [ebp + eax*4 + 6], dl
xor edx, edx
mov dl, byte [esi + 1]
mov byte [ebp + eax*4 + 7], cl
and edx, 0xff
mov dword [edx*4 + section..bootdat], ebp
mov eax, dword [esp + 0x58]
add esi, 6
inc eax
cmp eax, 0x609
mov dword [esp + 0x58], eax
jl 0x51e312be
mov edi, dword [esp + 0x9c]
mov dword [0x51e874f0], 0
mov esi, 4
jmp 0x51df56fc
cmp ecx, 0xffffffff
jg 0x51df573c
cmp edx, 1
ja 0x51df5733
test edi, 0xfff00000
je 0x51e31490
push 0x57
call dword [sym.imp.KERNEL32.dll_SetLastError]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x88
ret 0x18
mov eax, dword [0x51e874ec]
mov ecx, dword [esp + 0xac]
mov edx, dword [esp + 0xa8]
mov dword [0x51e874f0], 1
test eax, eax
mov eax, dword [esp + 0xb0]
push eax
mov eax, dword [esp + 0xa8]
push ecx
push edx
push eax
je 0x51e31470
mov ecx, dword [esp + 0xb0]
mov edx, dword [esp + 0xac]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_CompareStringW]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret 0x18
mov edx, dword [esp + 0xb0]
mov ecx, dword [esp + 0xac]
call fcn.51e75351
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret 0x18
mov edi, dword [esp + 0xa4]
mov ebp, dword [esp + 0xac]
xor ecx, ecx
mov dword [esp + 0x14], edi
cmp edi, ecx
mov dword [esp + 0x18], ebp
je 0x51e31403
cmp ebp, ecx
je 0x51e31403
mov ax, word [edi]
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
mov ax, word [edi + 2]
add edi, 2
add ebp, 2
cmp ax, word [ebp]
jne 0x51e31574
cmp ax, cx
je 0x51e31574
add edi, 2
add ebp, 2
jmp 0x51e314b8
mov ax, word [edi]
mov dword [esp + 0x18], ebp
cmp ax, word [ebp]
mov dword [esp + 0x14], edi
je 0x51e3223d
neg edx
sbb edx, edx
mov si, word [edi]
and edx, 0xe8000000
xor eax, eax
dec edx
mov dword [esp + 0x5c], ecx
mov ebx, edx
mov edx, dword [0x51e895b8]
cmp edx, ecx
mov dword [esp + 0x28], ecx
setne al
inc eax
mov dword [esp + 0x74], ecx
or al, 4
cmp si, cx
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x40], ecx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x70], ecx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x90], ecx
mov dword [esp + 0x60], ebx
mov dword [esp + 0x24], eax
je 0x51e3207c
jmp 0x51e315e7
mov ebx, dword [esp + 0x60]
cmp word [ebp], 0
je 0x51e3207c
lea edx, [esp + 0x44]
mov ecx, esi
call fcn.51df5aac
mov ecx, dword [0x51e895a0]
and ecx, 0x3ff
cmp ecx, 0x12
jne 0x51e31649
mov al, byte [esp + 0x45]
cmp al, 3
jne 0x51e31629
mov al, byte [esp + 0x44]
test al, al
je 0x51e31649
cmp al, 1
je 0x51e31649
mov byte [esp + 0x45], 0x94
jmp 0x51e31649
cmp al, 0xe
jb 0x51e31649
cmp si, 0xe000
jb 0x51e3163b
cmp si, 0xf8ff
jbe 0x51e31649
cmp al, 0x80
jae 0x51e31643
add al, 0x72
jmp 0x51e31645
add al, 0x8e
mov byte [esp + 0x45], al
mov si, word [ebp]
lea edx, [esp + 0x48]
mov ecx, esi
call fcn.51df5aac
mov edx, dword [0x51e895a0]
and edx, 0x3ff
cmp edx, 0x12
jne 0x51e316a4
mov al, byte [esp + 0x49]
cmp al, 3
jne 0x51e31684
mov al, byte [esp + 0x48]
test al, al
je 0x51e316a4
cmp al, 1
je 0x51e316a4
mov byte [esp + 0x49], 0x94
jmp 0x51e316a4
cmp al, 0xe
jb 0x51e316a4
cmp si, 0xe000
jb 0x51e31696
cmp si, 0xf8ff
jbe 0x51e316a4
cmp al, 0x80
jae 0x51e3169e
add al, 0x72
jmp 0x51e316a0
add al, 0x8e
mov byte [esp + 0x49], al
mov ecx, dword [esp + 0x44]
mov esi, dword [esp + 0x48]
and ecx, ebx
and esi, ebx
cmp ecx, esi
mov dword [esp + 0x88], ecx
mov dword [esp + 0x80], esi
je 0x51e3202e
mov al, byte [esp + 0x89]
cmp cx, si
mov byte [esp + 0x13], al
mov dword [esp + 0x30], ecx
mov dword [esp + 0x34], esi
jne 0x51e316e6
cmp al, 3
jne 0x51e31ebc
xor ecx, ecx
test al, al
mov dword [esp + 0x58], ecx
jne 0x51e31700
add edi, 2
mov ecx, 1
mov dword [esp + 0x14], edi
mov dword [esp + 0x58], ecx
mov al, byte [esp + 0x81]
test al, al
je 0x51e32069
test ecx, ecx
jne 0x51e32070
mov edx, dword [esp + 0x89]
and edx, 0xff
lea eax, [edx - 1]
cmp eax, 5
ja case.0x51e31730.4
jmp dword [eax*4 + 0x51e75470]
mov eax, dword [esp + 0x28]
test eax, eax
je 0x51e31746
test byte [esp + 0x24], 2
je 0x51e31762
mov eax, dword [esp + 0x24]
mov dword [esp + 0x28], 3
and al, 0xfe
mov dword [esp + 0x24], eax
jmp 0x51e31762
mov eax, dword [esp + 0x5c]
test eax, eax
je 0x51e31777
add edi, 2
mov ecx, 1
mov dword [esp + 0x14], edi
mov dword [esp + 0x58], ecx
jmp 0x51e31a73
cmp byte [esp + 0x81], 6
je case.0x51e31730.4
mov eax, dword [esp + 0x40]
test eax, eax
je 0x51e317ae
mov ecx, 1
add edi, 2
mov dword [esp + 0x40], 3
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x14], edi
mov dword [esp + 0x58], ecx
jmp 0x51e31a73
mov ecx, 1
add edi, 2
mov dword [esp + 0x2c], 3
mov dword [esp + 0x14], edi
mov dword [esp + 0x58], ecx
jmp 0x51e31a73
mov ecx, dword [0x51eb981c]
mov eax, dword [esp + 0x88]
and eax, 0xff
mov dword [esp + 0x68], edi
mov edx, dword [ecx + 0x28]
lea edi, [esp + 0x78]
mov cx, word [edx + eax*4]
mov dword [esp + 0x14], edi
lea eax, [edx + eax*4]
mov word [esp + 0x78], cx
mov ecx, 1
mov dword [esp + 0x64], 2
mov dx, word [eax + 2]
mov dword [esp + 0x58], ecx
mov word [esp + 0x7a], dx
jmp 0x51e31a73
mov bl, byte [esp + 0x8b]
mov al, byte [esp + 0x88]
and bl, 0x3f
cmp al, 1
mov dword [esp + 0x1c], 0
mov ecx, 0xffff0000
ja 0x51e31969
mov eax, dword [esp + 0xa4]
add edi, 0xfffffffe
cmp edi, eax
jb 0x51e31990
mov eax, dword [esp + 0x14]
mov ebp, 2
lea edi, [eax - 2]
mov si, word [edi]
lea edx, [esp + 0x4c]
mov ecx, esi
call fcn.51df5aac
mov ecx, dword [0x51e895a0]
and ecx, 0x3ff
cmp ecx, 0x12
jne 0x51e318b5
mov al, byte [esp + 0x4d]
cmp al, 3
jne 0x51e31895
mov al, byte [esp + 0x4c]
test al, al
je 0x51e318b5
cmp al, 1
je 0x51e318b5
mov byte [esp + 0x4d], 0x94
jmp 0x51e318b5
cmp al, 0xe
jb 0x51e318b5
cmp si, 0xe000
jb 0x51e318a7
cmp si, 0xf8ff
jbe 0x51e318b5
cmp al, 0x80
jae 0x51e318af
add al, 0x72
jmp 0x51e318b1
add al, 0x8e
mov byte [esp + 0x4d], al
mov ecx, dword [esp + 0x4c]
mov esi, dword [esp + 0x60]
and ecx, esi
mov dword [esp + 0x20], ecx
mov al, byte [esp + 0x21]
cmp al, 3
jae 0x51e318da
cmp al, 2
mov ecx, 0xffff0000
je 0x51e31990
jmp 0x51e318ed
jne 0x51e31963
mov al, byte [esp + 0x20]
cmp al, 1
ja 0x51e3190d
mov ecx, 0xffff0000
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0xa4]
add ebp, 2
sub edi, 2
sub edx, ebp
cmp edx, eax
jae 0x51e3185b
jmp 0x51e31990
movzx ax, al
or ah, 0x22
mov word [esp + 0x20], ax
mov al, byte [esp + 0x23]
and al, 0x3f
mov cl, al
and cl, 0xc6
mov byte [esp + 0x1c], cl
mov cl, al
and cl, 0xe4
mov byte [esp + 0x1e], cl
mov cl, byte [esp + 0x88]
test cl, cl
mov ecx, dword [esp + 0x20]
jne 0x51e31951
and al, 0xc5
mov dword [esp + 0x30], ecx
mov byte [esp + 0x1d], 4
mov byte [esp + 0x1f], al
jmp 0x51e3199a
mov eax, ecx
mov byte [esp + 0x1d], 5
and eax, 0xff87
mov dword [esp + 0x30], eax
jmp 0x51e31989
mov dword [esp + 0x30], ecx
jmp 0x51e31990
movzx ax, al
or ah, 0x22
mov byte [esp + 0x1d], 3
mov dword [esp + 0x30], eax
mov al, bl
and al, 0xc6
mov byte [esp + 0x1c], al
mov al, bl
and al, 0xe4
mov byte [esp + 0x1e], al
and bl, 0xc5
mov byte [esp + 0x1f], bl
cmp byte [esp + 0x88], 1
ja 0x51e319bb
cmp ecx, 0xffff0000
jne 0x51e319bb
mov dword [esp + 0x30], 0xffff
mov dword [esp + 0x88], ecx
mov dword [esp + 0x1c], 0
jmp 0x51e319e2
mov eax, dword [esp + 0x88]
mov ecx, dword [esp + 0x30]
and eax, 0xffff0000
and ecx, 0xffff
or eax, ecx
mov dword [esp + 0x88], eax
mov byte [esp + 0x8b], 2
cmp byte [esp + 0x81], 3
je 0x51e31a58
mov al, byte [esp + 0x90]
test al, al
jne 0x51e31a07
mov al, byte [esp + 0x1c]
test al, al
je 0x51e31a07
mov byte [esp + 0x90], 3
mov al, byte [esp + 0x91]
test al, al
jne 0x51e31a22
mov al, byte [esp + 0x1d]
test al, al
je 0x51e31a22
mov byte [esp + 0x91], 3
mov al, byte [esp + 0x92]
test al, al
jne 0x51e31a3d
mov al, byte [esp + 0x1e]
test al, al
je 0x51e31a3d
mov byte [esp + 0x92], 3
mov al, byte [esp + 0x93]
test al, al
jne 0x51e31a58
mov al, byte [esp + 0x1f]
test al, al
je 0x51e31a58
mov byte [esp + 0x93], 3
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x80]
mov ecx, 1
jmp 0x51e31a73
mov ecx, 1
mov edx, dword [esp + 0x81]
and edx, 0xff
lea eax, [edx - 1]
cmp eax, 5
ja case.0x51e31a8c.4
jmp dword [eax*4 + 0x51e75488]
mov eax, dword [esp + 0x28]
test eax, eax
je 0x51e31aa6
test byte [esp + 0x24], 2
je 0x51e32069
mov eax, dword [esp + 0x24]
mov dword [esp + 0x28], ecx
and al, 0xfe
mov dword [esp + 0x24], eax
jmp 0x51e32069
mov eax, dword [esp + 0x5c]
test eax, eax
jne 0x51e32069
mov al, byte [esp + 0x13]
cmp al, 6
mov eax, dword [esp + 0x2c]
je 0x51e31aeb
test eax, eax
je 0x51e31ae2
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x5c], ecx
jmp 0x51e32069
mov dword [esp + 0x40], ecx
jmp 0x51e32069
test eax, eax
je 0x51e31afc
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x5c], ecx
jmp 0x51e32062
mov eax, dword [esp + 0x40]
test eax, eax
je 0x51e31b15
mov dword [esp + 0x40], 3
mov dword [esp + 0x5c], ecx
jmp 0x51e32062
mov al, byte [esp + 0x88]
mov bl, byte [esp + 0x80]
cmp al, bl
mov dword [esp + 0x5c], ecx
sbb eax, eax
and al, 0xfe
add eax, 3
mov dword [esp + 0x2c], eax
jmp 0x51e32062
mov edx, dword [0x51eb981c]
mov ecx, dword [esp + 0x80]
and ecx, 0xff
mov dword [esp + 0x70], ebp
mov eax, dword [edx + 0x28]
lea ebp, [esp + 0x7c]
mov dx, word [eax + ecx*4 + 2]
mov dword [esp + 0x18], ebp
lea eax, [eax + ecx*4]
mov word [esp + 0x7e], dx
mov dword [esp + 0x6c], 2
mov cx, word [eax]
mov word [esp + 0x7c], cx
jmp 0x51e32070
mov bl, byte [esp + 0x83]
mov al, byte [esp + 0x80]
and bl, 0x3f
cmp al, 1
mov dword [esp + 0x20], 0
mov ecx, 0xffff0000
ja 0x51e31d15
mov edx, dword [esp + 0xac]
lea eax, [ebp - 2]
cmp eax, edx
jb 0x51e31d3e
mov ecx, dword [esp + 0x18]
mov ebp, 2
lea edi, [ecx - 2]
mov si, word [edi]
lea edx, [esp + 0x50]
mov ecx, esi
call fcn.51df5aac
mov edx, dword [0x51e895a0]
and edx, 0x3ff
cmp edx, 0x12
jne 0x51e31c1b
mov al, byte [esp + 0x51]
cmp al, 3
jne 0x51e31bfb
mov al, byte [esp + 0x50]
test al, al
je 0x51e31c1b
cmp al, 1
je 0x51e31c1b
mov byte [esp + 0x51], 0x94
jmp 0x51e31c1b
cmp al, 0xe
jb 0x51e31c1b
cmp si, 0xe000
jb 0x51e31c0d
cmp si, 0xf8ff
jbe 0x51e31c1b
cmp al, 0x80
jae 0x51e31c15
add al, 0x72
jmp 0x51e31c17
add al, 0x8e
mov byte [esp + 0x51], al
mov ecx, dword [esp + 0x50]
mov esi, dword [esp + 0x60]
and ecx, esi
mov dword [esp + 0x54], ecx
mov al, byte [esp + 0x55]
cmp al, 3
jae 0x51e31c3c
cmp al, 2
mov ecx, 0xffff0000
je 0x51e31c6a
jmp 0x51e31c4f
jne 0x51e31cf8
mov al, byte [esp + 0x54]
cmp al, 1
ja 0x51e31c86
mov ecx, 0xffff0000
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0xac]
add ebp, 2
sub edi, 2
sub eax, ebp
cmp eax, edx
jae 0x51e31bc1
mov al, byte [esp + 0x23]
mov dl, byte [esp + 0x20]
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x80]
jmp 0x51e31d46
xor cx, cx
mov cl, al
mov al, byte [esp + 0x57]
or ch, 0x22
and al, 0x3f
mov word [esp + 0x54], cx
mov cl, al
and cl, 0xe4
mov dl, al
mov byte [esp + 0x22], cl
mov cl, byte [esp + 0x80]
and dl, 0xc6
test cl, cl
mov ecx, dword [esp + 0x54]
jne 0x51e31cd2
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x80]
mov dword [esp + 0x34], ecx
mov byte [esp + 0x21], 4
and al, 0xc5
jmp 0x51e31d50
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x80]
mov eax, ecx
and eax, 0xff87
and bl, 0xc5
mov dword [esp + 0x34], eax
mov byte [esp + 0x21], 5
mov al, bl
jmp 0x51e31d46
mov al, byte [esp + 0x23]
mov dl, byte [esp + 0x20]
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x80]
mov dword [esp + 0x34], ecx
jmp 0x51e31d46
movzx ax, byte [esp + 0x80]
or ah, 0x22
mov dl, bl
mov dword [esp + 0x34], eax
mov al, bl
and dl, 0xc6
and al, 0xe4
and bl, 0xc5
mov byte [esp + 0x22], al
mov byte [esp + 0x21], 3
mov al, bl
jmp 0x51e31d46
mov al, byte [esp + 0x23]
mov dl, byte [esp + 0x20]
cmp byte [esp + 0x80], 1
ja 0x51e31d79
cmp ecx, 0xffff0000
jne 0x51e31d79
mov dword [esp + 0x20], 0
mov al, byte [esp + 0x23]
mov dl, byte [esp + 0x20]
mov dword [esp + 0x34], 0xffff
mov dword [esp + 0x80], ecx
jmp 0x51e31d9a
mov ecx, dword [esp + 0x34]
and esi, 0xffff0000
and ecx, 0xffff
or esi, ecx
mov dword [esp + 0x80], esi
mov byte [esp + 0x83], 2
mov cl, byte [esp + 0x13]
cmp cl, 3
mov cl, byte [esp + 0x90]
je 0x51e31e14
test cl, cl
jne 0x51e31dba
test dl, dl
je 0x51e31dba
mov byte [esp + 0x90], 1
mov cl, byte [esp + 0x91]
test cl, cl
jne 0x51e31dd5
mov cl, byte [esp + 0x21]
test cl, cl
je 0x51e31dd5
mov byte [esp + 0x91], 1
mov cl, byte [esp + 0x92]
test cl, cl
jne 0x51e31df0
mov cl, byte [esp + 0x22]
test cl, cl
je 0x51e31df0
mov byte [esp + 0x92], 1
mov cl, byte [esp + 0x93]
test cl, cl
jne case.0x51e31a8c.4
test al, al
je case.0x51e31a8c.4
mov byte [esp + 0x93], 1
jmp case.0x51e31a8c.4
test cl, cl
jne 0x51e31e2f
mov cl, byte [esp + 0x1c]
cmp cl, dl
je 0x51e31e2f
sbb cl, cl
and cl, 0xfe
add cl, 3
mov byte [esp + 0x90], cl
mov cl, byte [esp + 0x91]
test cl, cl
jne 0x51e31e55
mov cl, byte [esp + 0x1d]
mov dl, byte [esp + 0x21]
cmp cl, dl
je 0x51e31e55
sbb cl, cl
and cl, 0xfe
add cl, 3
mov byte [esp + 0x91], cl
mov cl, byte [esp + 0x92]
test cl, cl
jne 0x51e31e7b
mov cl, byte [esp + 0x1e]
mov dl, byte [esp + 0x22]
cmp cl, dl
je 0x51e31e7b
sbb cl, cl
and cl, 0xfe
add cl, 3
mov byte [esp + 0x92], cl
mov cl, byte [esp + 0x93]
test cl, cl
jne case.0x51e31a8c.4
mov cl, byte [esp + 0x1f]
cmp cl, al
je case.0x51e31a8c.4
mov bl, cl
cmp bl, al
sbb al, al
and al, 0xfe
add al, 3
mov byte [esp + 0x93], al
mov eax, dword [esp + 0x58]
test eax, eax
jne 0x51e32070
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x34]
cmp cx, ax
jne 0x51e320e6
test byte [esp + 0x24], 3
je 0x51e31ff4
mov al, byte [esp + 0x8a]
mov cl, byte [esp + 0x82]
cmp al, cl
mov byte [esp + 0x13], al
mov bl, cl
je 0x51e31ff4
mov si, word [edi + 2]
test si, si
je 0x51e31f61
lea edx, [esp + 0x38]
mov ecx, esi
call fcn.51df5aac
mov edx, dword [0x51e895a0]
mov al, byte [esp + 0x39]
and edx, 0x3ff
cmp edx, 0x12
jne 0x51e31f30
cmp al, 3
je 0x51e31f50
cmp al, 0xe
jb 0x51e31f30
cmp si, 0xe000
jb 0x51e31f22
cmp si, 0xf8ff
jbe 0x51e31f30
cmp al, 0x80
jae 0x51e31f2a
add al, 0x72
jmp 0x51e31f2c
add al, 0x8e
mov byte [esp + 0x39], al
cmp al, 1
jne 0x51e31f61
mov al, byte [esp + 0x3a]
mov cl, byte [esp + 0x13]
mov si, word [edi + 4]
add edi, 2
add cl, al
test si, si
mov byte [esp + 0x13], cl
je 0x51e31f61
jmp 0x51e31eec
mov al, byte [esp + 0x38]
test al, al
je 0x51e31f61
cmp al, 1
je 0x51e31f61
mov byte [esp + 0x39], 0x94
mov si, word [ebp + 2]
test si, si
je 0x51e31fd7
lea edx, [esp + 0x3c]
mov ecx, esi
call fcn.51df5aac
mov ecx, dword [0x51e895a0]
mov al, byte [esp + 0x3d]
and ecx, 0x3ff
cmp ecx, 0x12
jne 0x51e31fae
cmp al, 3
je 0x51e31fc6
cmp al, 0xe
jb 0x51e31fae
cmp si, 0xe000
jb 0x51e31fa0
cmp si, 0xf8ff
jbe 0x51e31fae
cmp al, 0x80
jae 0x51e31fa8
add al, 0x72
jmp 0x51e31faa
add al, 0x8e
mov byte [esp + 0x3d], al
cmp al, 1
jne 0x51e31fd7
mov cl, byte [esp + 0x3e]
mov si, word [ebp + 4]
add ebp, 2
add bl, cl
test si, si
je 0x51e31fd7
jmp 0x51e31f6a
mov al, byte [esp + 0x3c]
test al, al
je 0x51e31fd7
cmp al, 1
je 0x51e31fd7
mov byte [esp + 0x3d], 0x94
mov al, byte [esp + 0x13]
cmp al, bl
je 0x51e31ff4
sbb eax, eax
and al, 0xfe
add eax, 3
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x24]
and al, 0xfe
mov dword [esp + 0x24], eax
test byte [esp + 0x24], 4
je 0x51e3202e
mov cl, byte [esp + 0x83]
mov al, byte [esp + 0x8b]
mov dl, cl
xor dl, al
test dl, 0x3f
je 0x51e3202e
and cl, 0x3f
and al, 0x3f
cmp al, cl
sbb eax, eax
and al, 0xfe
add eax, 3
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x24]
and al, 0xfb
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x68]
xor ecx, ecx
cmp eax, ecx
je 0x51e32049
mov edx, dword [esp + 0x64]
dec edx
mov dword [esp + 0x64], edx
jne 0x51e32049
mov edi, eax
mov dword [esp + 0x68], ecx
mov eax, dword [esp + 0x70]
cmp eax, ecx
je 0x51e32062
mov edx, dword [esp + 0x6c]
dec edx
mov dword [esp + 0x6c], edx
jne 0x51e32062
mov ebp, eax
mov dword [esp + 0x70], ecx
add edi, 2
mov dword [esp + 0x14], edi
add ebp, 2
mov dword [esp + 0x18], ebp
mov si, word [edi]
test si, si
jne 0x51e315e3
cmp word [edi], 0
jne 0x51e32124
cmp word [ebp], 0
jne 0x51e32122
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x51df5762
mov eax, dword [esp + 0x74]
test eax, eax
jne 0x51df5762
mov eax, dword [esp + 0x90]
test eax, eax
je 0x51e32225
mov cl, al
test cl, cl
jne 0x51e32213
mov al, byte [esp + 0x91]
test al, al
je 0x51e320fa
mov eax, dword [esp + 0x91]
pop edi
pop esi
pop ebp
and eax, 0xff
pop ebx
add esp, 0x88
ret 0x18
sbb eax, eax
pop edi
and al, 0xfe
pop esi
pop ebp
add eax, 3
pop ebx
add esp, 0x88
ret 0x18
mov al, byte [esp + 0x92]
test al, al
je 0x51e32201
mov eax, dword [esp + 0x92]
pop edi
pop esi
pop ebp
and eax, 0xff
pop ebx
add esp, 0x88
ret 0x18
mov edi, ebp
mov si, word [ebp]
neg si
sbb esi, esi
and esi, 0xfffffffe
add esi, 3
cmp word [edi], 0
je 0x51e3216d
mov ebx, dword [esp + 0x28]
mov cx, word [edi]
lea edx, [esp + 0x88]
call fcn.51df5aac
mov eax, dword [esp + 0x89]
and eax, 0xff
sub eax, 0
je 0x51e32164
dec eax
jne 0x51e321aa
test ebx, ebx
je 0x51e321aa
add edi, 2
cmp word [edi], 0
jne 0x51e3213d
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x51df5762
mov eax, dword [esp + 0x74]
test eax, eax
jne 0x51df5762
mov eax, dword [esp + 0x90]
test eax, eax
je 0x51e32225
test al, al
je 0x51e321b9
pop edi
pop esi
pop ebp
and eax, 0xff
pop ebx
add esp, 0x88
ret 0x18
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret 0x18
mov al, byte [esp + 0x91]
test al, al
je 0x51e321dd
mov eax, dword [esp + 0x91]
pop edi
pop esi
pop ebp
and eax, 0xff
pop ebx
add esp, 0x88
ret 0x18
mov al, byte [esp + 0x92]
test al, al
je 0x51e32201
mov eax, dword [esp + 0x92]
pop edi
pop esi
pop ebp
and eax, 0xff
pop ebx
add esp, 0x88
ret 0x18
mov al, byte [esp + 0x93]
test al, al
je 0x51e32225
mov eax, dword [esp + 0x93]
pop edi
pop esi
pop ebp
and eax, 0xff
pop ebx
add esp, 0x88
ret 0x18
mov eax, dword [esp + 0x2c]
test eax, eax
jne 0x51df5762
mov eax, dword [esp + 0x40]
test eax, eax
jne 0x51df5762
pop edi
pop esi
pop ebp
mov eax, 2
pop ebx
add esp, 0x88
ret 0x18
mov ecx, 0xfffffffe
jmp 0x51df573c
mov eax, 0xfffffffe
jmp 0x51df5745