Function at 0x406690
Capabilities:
Hash data using sha1
Hash data using sha256

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x338
mov eax, dword [0x447280]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
movzx eax, word [esi]
mov edi, ecx
mov ebx, edx
cmp byte [edi + 0x3b], 2
mov dword [ebp - 0x334], eax
jne 0x406812
mov eax, dword [esi]
movzx ecx, byte [eax + ebx]
movzx eax, byte [eax + ebx + 1]
add dword [esi], 2
shl cx, 8
or cx, ax
mov eax, dword [0x44c5c4]
movzx ecx, cx
mov dword [ebp - 0x328], ecx
mov dword [ebp - 0x330], eax
push ecx
test eax, eax
je 0x4066fe
call eax
mov ecx, dword [0x44c5c4]
mov dword [ebp - 0x330], ecx
jmp 0x406703
call fcn.0041bec0
mov edx, eax
add esp, 4
mov dword [edi + 0x2e8], edx
test edx, edx
je 0x406855
mov eax, dword [ebp - 0x328]
push eax
mov dword [edi + 0x2e4], eax
mov eax, dword [esi]
add eax, ebx
push eax
push edx
call fcn.00422490
mov eax, dword [ebp - 0x328]
add dword [esi], eax
mov eax, dword [esi]
add esp, 0xc
movzx ecx, byte [eax + ebx]
movzx eax, byte [eax + ebx + 1]
add dword [esi], 2
shl cx, 8
or cx, ax
mov eax, dword [ebp - 0x330]
movzx ecx, cx
mov dword [ebp - 0x328], ecx
push ecx
test eax, eax
je 0x406773
call eax
mov ecx, eax
mov eax, dword [0x44c5c4]
mov dword [ebp - 0x330], eax
jmp 0x40677a
call fcn.0041bec0
mov ecx, eax
add esp, 4
mov dword [edi + 0x2f0], ecx
test ecx, ecx
je 0x406855
mov eax, dword [ebp - 0x328]
push eax
mov dword [edi + 0x2ec], eax
mov eax, dword [esi]
add eax, ebx
push eax
push ecx
call fcn.00422490
mov eax, dword [ebp - 0x328]
add dword [esi], eax
mov eax, dword [esi]
add esp, 0xc
movzx ecx, byte [eax + ebx]
movzx eax, byte [eax + ebx + 1]
add dword [esi], 2
shl cx, 8
or cx, ax
mov eax, dword [ebp - 0x330]
movzx ecx, cx
mov dword [ebp - 0x328], ecx
push ecx
test eax, eax
je 0x4067db
call eax
jmp 0x4067e0
call fcn.0041bec0
mov ecx, eax
add esp, 4
mov dword [edi + 0x2f8], ecx
test ecx, ecx
je 0x406855
mov eax, dword [ebp - 0x328]
push eax
mov dword [edi + 0x2f4], eax
mov eax, dword [esi]
add eax, ebx
push eax
push ecx
call fcn.00422490
mov eax, dword [ebp - 0x328]
add esp, 0xc
add dword [esi], eax
mov al, byte [edi + 0x3c]
mov byte [ebp - 0x32a], al
mov ax, word [esi]
sub ax, word [ebp - 0x334]
mov ecx, 0x264
movzx eax, ax
mov byte [ebp - 0x329], 2
mov dword [ebp - 0x334], eax
cmp ax, cx
jbe 0x40686b
mov eax, 0xffffff1c
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041b6fe
mov esp, ebp
pop ebp
ret
mov eax, 0xffffff35
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041b6fe
mov esp, ebp
pop ebp
ret
movzx ecx, ax
mov eax, dword [esi]
sub eax, ecx
push ecx
add eax, ebx
push eax
lea eax, [ebp - 0x2b4]
push eax
call fcn.00422490
mov al, byte [edi + 8]
add esp, 0xc
cmp al, 3
jne 0x406891
cmp byte [edi + 9], al
jae 0x40689b
cmp al, 0xfe
jne 0x4068b7
cmp byte [edi + 9], 0xfd
ja 0x4068b7
mov ecx, dword [esi]
mov al, byte [ecx + ebx]
mov byte [ebp - 0x329], al
lea eax, [ecx + 1]
mov dword [esi], eax
mov cl, byte [eax + ebx]
inc eax
mov byte [ebp - 0x32a], cl
mov dword [esi], eax
mov eax, dword [esi]
add ebx, 2
movzx ecx, byte [eax + ebx - 2]
movzx eax, byte [eax + ebx - 1]
shl cx, 8
or cx, ax
mov eax, dword [esi]
movzx ecx, cx
add ebx, eax
add eax, 2
add eax, ecx
mov dword [ebp - 0x328], ecx
mov dword [esi], eax
mov edx, dword [edi + 0x374]
push 0x20
lea ecx, [ebp - 0x314]
mov dword [ebp - 0x308], 0x67452301
mov dword [ebp - 0x304], 0xefcdab89
mov dword [ebp - 0x300], 0x98badcfe
mov dword [ebp - 0x2fc], 0x10325476
mov dword [ebp - 0x314], 0
mov dword [ebp - 0x310], 0
mov dword [ebp - 0x30c], 0
call fcn.00409dd0
mov edx, dword [edi + 0x374]
add esp, 4
add edx, 0x20
push 0x20
lea ecx, [ebp - 0x314]
call fcn.00409dd0
mov eax, dword [ebp - 0x334]
movzx esi, ax
add esp, 4
lea edx, [ebp - 0x2b4]
push esi
lea ecx, [ebp - 0x314]
call fcn.00409dd0
add esp, 4
lea edx, [ebp - 0x2c]
lea ecx, [ebp - 0x314]
call fcn.00409e50
mov edx, dword [edi + 0x374]
push 0x20
lea ecx, [ebp - 0x31c]
mov dword [ebp - 0x310], 0x67452301
mov dword [ebp - 0x30c], 0xefcdab89
mov dword [ebp - 0x308], 0x98badcfe
mov dword [ebp - 0x304], 0x10325476
mov dword [ebp - 0x300], 0xc3d2e1f0
mov dword [ebp - 0x31c], 0
mov dword [ebp - 0x318], 0
mov dword [ebp - 0x314], 0
call fcn.00414870
mov edx, dword [edi + 0x374]
add esp, 4
add edx, 0x20
push 0x20
lea ecx, [ebp - 0x31c]
call fcn.00414870
add esp, 4
lea edx, [ebp - 0x2b4]
push esi
lea ecx, [ebp - 0x31c]
call fcn.00414870
add esp, 4
lea edx, [ebp - 0x1c]
lea ecx, [ebp - 0x31c]
call fcn.00414920
mov edx, dword [edi + 0x374]
mov dword [ebp - 0x318], 0x6a09e667
mov dword [ebp - 0x314], 0xbb67ae85
mov dword [ebp - 0x310], 0x3c6ef372
mov dword [ebp - 0x30c], 0xa54ff53a
mov dword [ebp - 0x308], 0x510e527f
mov dword [ebp - 0x304], 0x9b05688c
mov dword [ebp - 0x300], 0x1f83d9ab
mov dword [ebp - 0x2fc], 0x5be0cd19
mov dword [ebp - 0x324], 0
mov dword [ebp - 0x320], 0
mov dword [ebp - 0x31c], 0
push 0x20
lea ecx, [ebp - 0x324]
call fcn.00413250
mov edx, dword [edi + 0x374]
add esp, 4
add edx, 0x20
push 0x20
lea ecx, [ebp - 0x324]
call fcn.00413250
add esp, 4
lea edx, [ebp - 0x2b4]
push esi
lea ecx, [ebp - 0x324]
call fcn.00413250
add esp, 4
lea edx, [ebp - 0x4c]
lea ecx, [ebp - 0x324]
call fcn.00413300
cmp byte [ebp - 0x32a], 1
jne 0x406c6b
cmp byte [edi + 0x3d8], 0
jne 0x406b10
mov eax, 0xffffff28
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041b6fe
mov esp, ebp
pop ebp
ret
push dword [edi + 0x3d4]
mov edx, dword [ebp - 0x328]
push 1
lea eax, [ebp - 0x328]
push eax
push ebx
mov ecx, ebx
mov dword [ebp - 0x328], edx
call fcn.00412790
mov esi, eax
add esp, 0x10
test esi, esi
js 0x406b57
mov edx, dword [ebp - 0x328]
lea eax, [ebp - 0x330]
push 1
push eax
mov ecx, ebx
call fcn.00412720
add esp, 8
mov esi, eax
mov al, byte [edi + 8]
cmp al, 3
jne 0x406b63
cmp byte [edi + 9], al
jae 0x406b75
cmp al, 0xfe
jne 0x406c29
cmp byte [edi + 9], 0xfd
ja 0x406c29
mov bl, byte [ebp - 0x329]
mov eax, 0x58
lea edx, [ebp - 0x1c]
lea ecx, [eax - 0x44]
cmp bl, 2
jne 0x406b8d
jmp 0x406b9f
cmp bl, 4
jne 0x406b9f
lea edx, [ebp - 0x4c]
mov eax, 0x19e
mov ecx, 0x20
push eax
push ecx
lea ecx, [ebp - 0x254]
call fcn.0040b8b0
add esp, 8
cmp eax, esi
jne 0x406c13
mov edx, dword [ebp - 0x330]
mov ecx, 0x200
cmp eax, ecx
cmovb ecx, eax
lea esi, [ebp - 0x254]
sub ecx, 4
jb 0x406be1
mov edi, edi
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x406be6
add edx, 4
add esi, 4
sub ecx, 4
jae 0x406bd0
cmp ecx, 0xfffffffc
je 0x406c51
mov al, byte [edx]
cmp al, byte [esi]
jne 0x406c13
cmp ecx, 0xfffffffd
je 0x406c51
mov al, byte [edx + 1]
cmp al, byte [esi + 1]
jne 0x406c13
cmp ecx, 0xfffffffe
je 0x406c51
mov al, byte [edx + 2]
cmp al, byte [esi + 2]
jne 0x406c13
cmp ecx, 0xffffffff
je 0x406c51
mov al, byte [edx + 3]
cmp al, byte [esi + 3]
je 0x406c51
mov eax, 0xffffff1a
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041b6fe
mov esp, ebp
pop ebp
ret
cmp esi, 0x24
jne 0x406c13
mov ecx, dword [ebp - 0x330]
lea edx, [ebp - 0x2c]
mov esi, 0x20
lea esp, [esp]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x406c13
add ecx, 4
add edx, 4
sub esi, 4
jae 0x406c40
mov byte [edi + 0x34c], 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0041b6fe
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
mov eax, 0xffffff7b
pop ebx
call fcn.0041b6fe
mov esp, ebp
pop ebp
ret