Function at 0x405320
Capabilities:
Hash data using djb2

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x1c
mov eax, 0xffffffff
cmp dword [esp + 0x30], 0
je 0x405483
mov esi, dword [esp + 0x34]
test esi, esi
je 0x405483
cmp dword [esp + 0x38], 0
je 0x405483
push esi
call fcn.0040ceb0
add esp, 4
test eax, eax
je 0x40538a
mov ecx, 0x1505
xor edi, edi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx edx, byte [esi + edi]
test edx, edx
je 0x405391
mov ebx, ecx
shl ebx, 5
add ebx, ecx
add ebx, edx
inc edi
mov ecx, ebx
cmp eax, edi
jne 0x405370
jmp 0x405393
mov ebx, 0x1505
jmp 0x405393
mov ebx, ecx
mov dword [esp], eax
mov ecx, dword [esp + 0x30]
mov ebp, dword [ecx + 0x20]
lea edi, [ebp - 1]
mov eax, ebp
sub eax, 1
mov dword [esp + 4], eax
jae 0x4053ff
mov eax, 0xffffffff
mov edx, dword [ecx + 0x18]
cmp edx, dword [ecx + 0x1c]
mov ebp, dword [esp + 0x38]
jae 0x40546f
mov esi, dword [ecx + 0xc]
mov edi, ecx
mov edx, dword [ecx + 0x18]
mov ecx, dword [esp + 0x34]
mov dword [esi + edx*4], ecx
mov ecx, dword [edi + 4]
mov edx, dword [edi + 0x18]
mov dword [ecx + eax*4], edx
mov ecx, dword [edi + 0x10]
mov dword [ecx + edx*4], ebp
mov ecx, dword [edi + 0x14]
mov edx, dword [edi + 0x18]
mov dword [ecx + edx*4], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi + 0x18]
mov dword [eax + ecx*4], ebx
inc dword [edi + 0x18]
mov eax, dword [edi]
mov dword [ebp], eax
xor eax, eax
jmp 0x405483
and edi, ebx
mov eax, dword [ecx + 4]
mov dword [esp + 0xc], eax
mov esi, edi
not esi
inc edi
jmp 0x405415
dec esi
inc edi
dec ebp
je 0x4053ab
mov eax, dword [esp + 4]
or eax, esi
add eax, edi
mov edx, dword [esp + 0xc]
mov edx, dword [edx + eax*4]
cmp edx, 0xffffffff
je 0x4053b0
mov eax, dword [ecx + 8]
cmp dword [eax + edx*4], ebx
jne 0x405410
mov eax, dword [ecx + 0xc]
mov eax, dword [eax + edx*4]
mov dword [esp + 8], eax
push eax
call fcn.0040ceb0
mov ecx, dword [esp + 0x34]
add esp, 4
cmp eax, dword [esp]
jne 0x405410
push dword [esp]
push dword [esp + 0xc]
push dword [esp + 0x3c]
call fcn.0040ced0
mov ecx, dword [esp + 0x3c]
add esp, 0xc
test eax, eax
jne 0x405410
mov eax, 0xffffffff
jmp 0x405483
call fcn.00406150
mov ecx, eax
mov eax, 0xffffffff
test ecx, ecx
mov ecx, dword [esp + 0x34]
je 0x40548b
add esp, 0x1c
pop esi
pop edi
pop ebx
pop ebp
ret
push ecx
call fcn.0040ceb0
add esp, 4
mov dword [esp + 0x10], eax
mov ecx, dword [esp + 0x30]
mov edx, dword [ecx + 0x20]
lea eax, [edx - 1]
mov esi, edx
sub esi, 1
mov dword [esp], esi
jae 0x4054b6
mov eax, 0xffffffff
jmp 0x4053c0
and eax, ebx
mov esi, dword [ecx + 4]
mov dword [esp + 8], esi
mov esi, eax
not esi
mov dword [esp + 0x14], eax
lea edi, [eax + 1]
xor eax, eax
jmp 0x4054de
mov eax, dword [esp + 4]
inc eax
dec esi
inc edi
mov edx, dword [esp + 0xc]
dec edx
je 0x405548
mov dword [esp + 4], eax
mov dword [esp + 0xc], edx
mov ebp, dword [esp]
or ebp, esi
lea eax, [edi + ebp]
mov edx, dword [esp + 8]
mov edx, dword [edx + eax*4]
cmp edx, 0xffffffff
je 0x40554d
mov eax, dword [ecx + 8]
cmp dword [eax + edx*4], ebx
jne 0x4054d0
mov eax, dword [ecx + 0xc]
mov eax, dword [eax + edx*4]
mov dword [esp + 0x18], eax
push eax
call fcn.0040ceb0
mov ecx, dword [esp + 0x34]
add esp, 4
cmp eax, dword [esp + 0x10]
jne 0x4054d0
push dword [esp + 0x10]
push dword [esp + 0x1c]
push dword [esp + 0x3c]
call fcn.0040ced0
mov ecx, dword [esp + 0x3c]
add esp, 0xc
test eax, eax
jne 0x4054d0
mov eax, dword [esp + 4]
add eax, dword [esp + 0x14]
add eax, ebp
inc eax
jmp 0x40554d
mov eax, 0xffffffff
mov ebp, dword [esp + 0x38]
jmp 0x4053c0