Function at 0x401000
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
cmp dword [0x49d708], 0
jne 0x40101e
call fcn.00422320
mov dword [0x49d708], 1
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0x80
je 0x401041
cmp dword [ebp - 0x10], 0xc0
je 0x401050
cmp dword [ebp - 0x10], 0x100
je 0x40105f
jmp 0x40106e
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x200], 0xa
jmp 0x401073
mov edx, dword [ebp + 8]
mov dword [edx + 0x200], 0xc
jmp 0x401073
mov eax, dword [ebp + 8]
mov dword [eax + 0x200], 0xe
jmp 0x401073
jmp 0x401762
mov ecx, dword [ebp + 8]
mov dword [ebp - 4], ecx
mov dword [ebp - 8], 0
jmp 0x40108b
mov edx, dword [ebp - 8]
add edx, 1
mov dword [ebp - 8], edx
mov eax, dword [ebp + 0x10]
sar eax, 5
cmp dword [ebp - 8], eax
jge 0x4010db
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
movzx eax, byte [edx + ecx*4]
shl eax, 0x18
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
movzx ecx, byte [edx + ecx*4 + 1]
shl ecx, 0x10
or eax, ecx
mov edx, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
movzx edx, byte [ecx + edx*4 + 2]
shl edx, 8
or eax, edx
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
movzx ecx, byte [edx + ecx*4 + 3]
or eax, ecx
mov edx, dword [ebp - 8]
mov ecx, dword [ebp - 4]
mov dword [ecx + edx*4], eax
jmp 0x401082
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x200]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0xa
je 0x401106
cmp dword [ebp - 0x14], 0xc
je 0x4011d8
cmp dword [ebp - 0x14], 0xe
je 0x4012ce
jmp 0x401433
mov dword [ebp - 8], 0
jmp 0x401121
mov ecx, dword [ebp - 8]
add ecx, 1
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 4]
add edx, 0x10
mov dword [ebp - 4], edx
cmp dword [ebp - 8], 0xa
jge 0x4011d3
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 8]
mov edx, dword [eax]
xor edx, dword [ecx*4 + 0x48e874]
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0xc]
shr ecx, 0x10
movzx eax, cl
movzx ecx, byte [eax + str.cw]
shl ecx, 0x18
xor edx, ecx
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0xc]
shr ecx, 8
movzx eax, cl
movzx ecx, byte [eax + str.cw]
shl ecx, 0x10
xor edx, ecx
mov eax, dword [ebp - 4]
movzx ecx, byte [eax + 0xc]
movzx eax, byte [ecx + str.cw]
shl eax, 8
xor edx, eax
mov ecx, dword [ebp - 4]
mov eax, dword [ecx + 0xc]
shr eax, 0x18
movzx ecx, al
movzx eax, byte [ecx + str.cw]
xor edx, eax
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x10], edx
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 4]
mov ecx, dword [edx + 4]
xor ecx, dword [eax + 0x10]
mov edx, dword [ebp - 4]
mov dword [edx + 0x14], ecx
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 4]
mov edx, dword [eax + 8]
xor edx, dword [ecx + 0x14]
mov eax, dword [ebp - 4]
mov dword [eax + 0x18], edx
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov eax, dword [ecx + 0xc]
xor eax, dword [edx + 0x18]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x1c], eax
jmp 0x40110f
jmp 0x401433
mov dword [ebp - 8], 0
jmp 0x4011f3
mov edx, dword [ebp - 8]
add edx, 1
mov dword [ebp - 8], edx
mov eax, dword [ebp - 4]
add eax, 0x18
mov dword [ebp - 4], eax
cmp dword [ebp - 8], 8
jge 0x4012c9
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 8]
mov eax, dword [ecx]
xor eax, dword [edx*4 + 0x48e874]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0x14]
shr edx, 0x10
movzx ecx, dl
movzx edx, byte [ecx + str.cw]
shl edx, 0x18
xor eax, edx
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0x14]
shr edx, 8
movzx ecx, dl
movzx edx, byte [ecx + str.cw]
shl edx, 0x10
xor eax, edx
mov ecx, dword [ebp - 4]
movzx edx, byte [ecx + 0x14]
movzx ecx, byte [edx + str.cw]
shl ecx, 8
xor eax, ecx
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x14]
shr ecx, 0x18
movzx edx, cl
movzx ecx, byte [edx + str.cw]
xor eax, ecx
mov edx, dword [ebp - 4]
mov dword [edx + 0x18], eax
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 4]
mov edx, dword [eax + 4]
xor edx, dword [ecx + 0x18]
mov eax, dword [ebp - 4]
mov dword [eax + 0x1c], edx
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov eax, dword [ecx + 8]
xor eax, dword [edx + 0x1c]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x20], eax
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 4]
mov ecx, dword [edx + 0xc]
xor ecx, dword [eax + 0x20]
mov edx, dword [ebp - 4]
mov dword [edx + 0x24], ecx
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 4]
mov edx, dword [eax + 0x10]
xor edx, dword [ecx + 0x24]
mov eax, dword [ebp - 4]
mov dword [eax + 0x28], edx
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov eax, dword [ecx + 0x14]
xor eax, dword [edx + 0x28]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x2c], eax
jmp 0x4011e1
jmp 0x401433
mov dword [ebp - 8], 0
jmp 0x4012e9
mov edx, dword [ebp - 8]
add edx, 1
mov dword [ebp - 8], edx
mov eax, dword [ebp - 4]
add eax, 0x20
mov dword [ebp - 4], eax
cmp dword [ebp - 8], 7
jge 0x401433
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 8]
mov eax, dword [ecx]
xor eax, dword [edx*4 + 0x48e874]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0x1c]
shr edx, 0x10
movzx ecx, dl
movzx edx, byte [ecx + str.cw]
shl edx, 0x18
xor eax, edx
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0x1c]
shr edx, 8
movzx ecx, dl
movzx edx, byte [ecx + str.cw]
shl edx, 0x10
xor eax, edx
mov ecx, dword [ebp - 4]
movzx edx, byte [ecx + 0x1c]
movzx ecx, byte [edx + str.cw]
shl ecx, 8
xor eax, ecx
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x1c]
shr ecx, 0x18
movzx edx, cl
movzx ecx, byte [edx + str.cw]
xor eax, ecx
mov edx, dword [ebp - 4]
mov dword [edx + 0x20], eax
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 4]
mov edx, dword [eax + 4]
xor edx, dword [ecx + 0x20]
mov eax, dword [ebp - 4]
mov dword [eax + 0x24], edx
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov eax, dword [ecx + 8]
xor eax, dword [edx + 0x24]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x28], eax
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 4]
mov ecx, dword [edx + 0xc]
xor ecx, dword [eax + 0x28]
mov edx, dword [ebp - 4]
mov dword [edx + 0x2c], ecx
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x2c]
shr ecx, 0x18
movzx edx, cl
movzx eax, byte [edx + str.cw]
shl eax, 0x18
mov ecx, dword [ebp - 4]
xor eax, dword [ecx + 0x10]
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x2c]
shr ecx, 0x10
movzx edx, cl
movzx ecx, byte [edx + str.cw]
shl ecx, 0x10
xor eax, ecx
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x2c]
shr ecx, 8
movzx edx, cl
movzx ecx, byte [edx + str.cw]
shl ecx, 8
xor eax, ecx
mov edx, dword [ebp - 4]
movzx ecx, byte [edx + 0x2c]
movzx edx, byte [ecx + str.cw]
xor eax, edx
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x30], eax
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 4]
mov ecx, dword [edx + 0x14]
xor ecx, dword [eax + 0x30]
mov edx, dword [ebp - 4]
mov dword [edx + 0x34], ecx
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 4]
mov edx, dword [eax + 0x18]
xor edx, dword [ecx + 0x34]
mov eax, dword [ebp - 4]
mov dword [eax + 0x38], edx
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov eax, dword [ecx + 0x1c]
xor eax, dword [edx + 0x38]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x3c], eax
jmp 0x4012d7
cmp dword [0x49d70c], 0
jne 0x4014d3
mov dword [ebp - 8], 0
jmp 0x401452
mov edx, dword [ebp - 8]
add edx, 1
mov dword [ebp - 8], edx
cmp dword [ebp - 8], 0x100
jge 0x4014c9
mov eax, dword [ebp - 8]
movzx ecx, byte [eax + str.cw]
mov edx, dword [ebp - 8]
mov eax, dword [ecx*4 + 0x48fbe8]
mov dword [edx*4 + 0x49df10], eax
mov ecx, dword [ebp - 8]
movzx edx, byte [ecx + str.cw]
mov eax, dword [ebp - 8]
mov ecx, dword [edx*4 + 0x48ffe8]
mov dword [eax*4 + 0x49db10], ecx
mov edx, dword [ebp - 8]
movzx eax, byte [edx + str.cw]
mov ecx, dword [ebp - 8]
mov edx, dword [eax*4 + 0x4903e8]
mov dword [ecx*4 + 0x49d710], edx
mov eax, dword [ebp - 8]
movzx ecx, byte [eax + str.cw]
mov edx, dword [ebp - 8]
mov eax, dword [ecx*4 + 0x4907e8]
mov dword [edx*4 + 0x49e310], eax
jmp 0x401449
mov dword [0x49d70c], 1
mov ecx, dword [ebp + 8]
add ecx, 0x100
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov dword [edx], ecx
mov edx, dword [ebp - 0xc]
add edx, 4
mov dword [ebp - 0xc], edx
mov eax, dword [ebp - 4]
add eax, 4
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov eax, dword [edx]
mov dword [ecx], eax
mov ecx, dword [ebp - 0xc]
add ecx, 4
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp - 4]
add edx, 4
mov dword [ebp - 4], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov dword [edx], ecx
mov edx, dword [ebp - 0xc]
add edx, 4
mov dword [ebp - 0xc], edx
mov eax, dword [ebp - 4]
add eax, 4
mov dword [ebp - 4], eax
mov dword [ebp - 8], 1
jmp 0x401561
mov ecx, dword [ebp - 8]
add ecx, 1
mov dword [ebp - 8], ecx
mov edx, dword [ebp + 8]
mov eax, dword [ebp - 8]
cmp eax, dword [edx + 0x200]
jge 0x4016e9
mov ecx, dword [ebp - 4]
sub ecx, 0x20
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x18
movzx ecx, al
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x10
movzx edx, al
mov eax, dword [ecx*4 + 0x49df10]
xor eax, dword [edx*4 + 0x49db10]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
shr edx, 8
movzx ecx, dl
xor eax, dword [ecx*4 + 0x49d710]
mov edx, dword [ebp - 4]
movzx ecx, byte [edx]
xor eax, dword [ecx*4 + 0x49e310]
mov edx, dword [ebp - 0xc]
mov dword [edx], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x18
movzx ecx, al
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x10
movzx edx, al
mov eax, dword [ecx*4 + 0x49df10]
xor eax, dword [edx*4 + 0x49db10]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
shr edx, 8
movzx ecx, dl
xor eax, dword [ecx*4 + 0x49d710]
mov edx, dword [ebp - 4]
movzx ecx, byte [edx]
xor eax, dword [ecx*4 + 0x49e310]
mov edx, dword [ebp - 0xc]
mov dword [edx], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x18
movzx ecx, al
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x10
movzx edx, al
mov eax, dword [ecx*4 + 0x49df10]
xor eax, dword [edx*4 + 0x49db10]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
shr edx, 8
movzx ecx, dl
xor eax, dword [ecx*4 + 0x49d710]
mov edx, dword [ebp - 4]
movzx ecx, byte [edx]
xor eax, dword [ecx*4 + 0x49e310]
mov edx, dword [ebp - 0xc]
mov dword [edx], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x18
movzx ecx, al
mov edx, dword [ebp - 4]
mov eax, dword [edx]
shr eax, 0x10
movzx edx, al
mov eax, dword [ecx*4 + 0x49df10]
xor eax, dword [edx*4 + 0x49db10]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
shr edx, 8
movzx ecx, dl
xor eax, dword [ecx*4 + 0x49d710]
mov edx, dword [ebp - 4]
movzx ecx, byte [edx]
xor eax, dword [ecx*4 + 0x49e310]
mov edx, dword [ebp - 0xc]
mov dword [edx], eax
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
jmp 0x401558
mov edx, dword [ebp - 4]
sub edx, 0x20
mov dword [ebp - 4], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov dword [edx], ecx
mov edx, dword [ebp - 0xc]
add edx, 4
mov dword [ebp - 0xc], edx
mov eax, dword [ebp - 4]
add eax, 4
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov eax, dword [edx]
mov dword [ecx], eax
mov ecx, dword [ebp - 0xc]
add ecx, 4
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp - 4]
add edx, 4
mov dword [ebp - 4], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [ebp - 0xc]
add eax, 4
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 4]
add ecx, 4
mov dword [ebp - 4], ecx
mov esp, ebp
pop ebp
ret