Function at 0x40d790
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x43f6d5
mov eax, dword fs:[0]
push eax
sub esp, 0x124
mov eax, dword [0x450040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ecx]
mov esi, dword [ecx + 4]
mov ecx, 0x10027
mov dword [ebp - 0x6c], eax
imul eax, esi, 0x5dc
mov byte [ebp - 0x45], 0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x78], 0
mov dword [ebp - 0x74], 0
cmp eax, ecx
cmovb eax, ecx
push eax
mov dword [ebp - 0x5c], eax
call fcn.0042184b
mov edi, eax
lea eax, [ebp - 0x130]
push 0x50
push 0
push eax
mov dword [ebp - 0x50], edi
call fcn.0041e750
add esp, 0x10
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x4c], 0
test edi, edi
jne 0x40d828
push 1
call fcn.004238d4
lea edx, [esi + esi*4]
mov esi, edi
shl edx, 4
mov dword [ebp - 0x60], edx
mov edi, dword [ebp - 0x5c]
push 0
lea eax, [ebp - 0x68]
mov dword [ebp - 0x68], edx
push eax
lea eax, [ebp - 0x130]
push eax
push 0
push 0
lea eax, [ebp - 0x70]
push eax
push edi
push esi
push dword [ebp - 0x6c]
call dword [sym.imp.WinDivert.dll_WinDivertRecvEx]
mov edx, dword [ebp - 0x60]
add esp, 0x24
test eax, eax
je 0x40d836
push 0
push 0
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x54]
push eax
lea eax, [ebp - 0x4c]
push eax
push 0
push 0
lea eax, [ebp - 0x45]
push eax
push 0
lea eax, [ebp - 0x44]
push eax
push edi
push esi
call dword [sym.imp.WinDivert.dll_WinDivertHelperParsePacket]
mov ecx, dword [ebp - 0x44]
add esp, 0x34
mov edx, dword [ebp - 0x60]
test ecx, ecx
je 0x40d836
mov al, byte [ebp - 0x45]
cmp al, 0x11
jne 0x40d9cf
mov eax, dword [ebp - 0x54]
mov edi, dword [sym.imp.WS2_32.dll_ntohs]
movzx eax, word [eax]
push eax
call edi
mov eax, dword [ebp - 0x54]
movzx eax, word [eax + 2]
push eax
call edi
test dword [ebp - 0x128], 0x20000
je 0x40d93a
mov eax, dword [ebp - 0x54]
push 0x35
movzx edi, word [eax + 2]
call dword [sym.imp.WS2_32.dll_htons]
cmp di, ax
jne 0x40d91b
mov eax, dword [ebp - 0x54]
mov edx, dword [ebp - 0x44]
mov word [ebp - 0xa8], di
movzx ecx, word [eax]
mov eax, dword [edx + 0xc]
mov dword [ebp - 0x9c], eax
lea eax, [ebp - 0x9c]
mov word [ebp - 0x98], cx
mov esi, dword [edx + 0x10]
push eax
call fcn.0040ddc0
mov ecx, dword [ebp - 0xa8]
mov dword [eax], esi
mov esi, dword [ebp - 0x50]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x44]
mov eax, dword [0x4524c4]
push 0x35
mov dword [ecx + 0x10], eax
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [ebp - 0x54]
mov word [ecx + 2], ax
jmp 0x40dcf8
mov eax, dword [ebp - 0x44]
mov eax, dword [eax + 0xc]
cmp eax, dword [0x4524c4]
jne 0x40dcf8
push 0x35
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [ebp - 0x54]
cmp word [ecx], ax
jne 0x40dcf8
mov eax, dword [ebp - 0x44]
movzx edi, word [ecx + 2]
mov esi, dword [eax + 0x10]
lea eax, [ebp - 0x84]
push eax
lea eax, [ebp - 0xc0]
mov dword [ebp - 0x84], esi
push eax
mov word [ebp - 0x80], di
call fcn.004132a0
mov eax, dword [ebp - 0xb8]
mov edx, dword [0x452574]
cmp byte [eax + 0xd], 0
jne 0x40d9a6
cmp esi, dword [eax + 0x10]
jb 0x40d9a6
jne 0x40d9a8
cmp di, word [eax + 0x14]
jae 0x40d9a8
mov eax, edx
cmp eax, edx
je 0x40dcf5
lea eax, [ebp - 0x84]
push eax
call fcn.0040ddc0
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, dword [ebp - 0x44]
mov dword [eax + 0xc], ecx
mov eax, dword [ebp - 0x54]
jmp 0x40dcf2
cmp al, 6
jne 0x40dcf8
test dword [ebp - 0x128], 0x20000
je 0x40dbec
push dword [ecx + 0x10]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
mov edx, eax
mov dword [ebp - 0x30], 0
mov ecx, edx
mov dword [ebp - 0x2c], 0
xorps xmm0, xmm0
movups xmmword [ebp - 0x40], xmm0
lea esi, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40da10
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x40]
call fcn.004031a0
mov dword [ebp - 4], 0
xorps xmm0, xmm0
movups xmmword [ebp - 0x28], xmm0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
mov byte [ebp - 4], 1
lea esi, [ebp - 0x40]
cmp dword [ebp - 0x2c], 0xf
mov edx, 0x811c9dc5
mov edi, dword [ebp - 0x30]
cmova esi, dword [ebp - 0x40]
xor ecx, ecx
test edi, edi
je 0x40da71
movzx eax, byte [ecx + esi]
inc ecx
xor eax, edx
imul edx, eax, 0x1000193
cmp ecx, edi
jb 0x40da60
push edx
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0xe0]
push eax
call fcn.0040aa80
mov eax, dword [eax + 4]
test eax, eax
je 0x40da95
cmp eax, dword [0x4525a8]
jne 0x40db6e
mov eax, dword [ebp - 0x4c]
lea edx, [ebp - 0x28]
lea ecx, [ebp - 0x40]
movzx eax, word [eax + 2]
push eax
call fcn.00406050
add esp, 4
test al, al
je 0x40db66
mov esi, dword [ebp - 0x4c]
mov edx, dword [ebp - 0x44]
movzx ecx, word [esi]
mov eax, dword [edx + 0xc]
mov dword [ebp - 0xa4], eax
mov word [ebp - 0xa0], cx
movzx eax, word [esi + 2]
mov esi, dword [edx + 0x10]
mov word [ebp - 0xb0], ax
lea eax, [ebp - 0xa4]
push eax
call fcn.0040ddc0
mov ecx, dword [ebp - 0xb0]
mov edx, dword [ebp - 0x28]
mov edi, dword [ebp - 0x18]
mov dword [eax], esi
mov esi, dword [ebp - 0x14]
cmp esi, 0xf
mov dword [eax + 4], ecx
lea eax, [ebp - 0x28]
seta cl
cmova eax, edx
mov byte [ebp - 0x55], cl
cmp edi, 4
jne 0x40db31
cmp dword [eax], 0x70747468
jne 0x40db31
mov ecx, dword [ebp - 0x44]
mov eax, dword [0x4524bc]
mov dword [ecx + 0x10], eax
mov ecx, dword [ebp - 0x4c]
mov ax, word [0x4524b4]
mov word [ecx + 2], ax
mov cl, byte [ebp - 0x55]
test cl, cl
lea eax, [ebp - 0x28]
cmovne eax, edx
cmp edi, 5
jne 0x40db74
cmp dword [eax], 0x70747468
jne 0x40db74
cmp byte [eax + 4], 0x73
jne 0x40db74
mov ecx, dword [ebp - 0x44]
mov eax, dword [0x4524c8]
mov dword [ecx + 0x10], eax
mov ecx, dword [ebp - 0x4c]
mov ax, word [0x4524b8]
mov word [ecx + 2], ax
jmp 0x40db74
lea ecx, [ebp - 0x40]
call fcn.00405900
mov esi, dword [ebp - 0x14]
mov edx, dword [ebp - 0x28]
mov byte [ebp - 4], 0
cmp esi, 0xf
jbe 0x40dba8
lea ecx, [esi + 1]
mov eax, edx
cmp ecx, 0x1000
jb 0x40db9e
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40dd42
push ecx
push edx
call fcn.0041cdc8
add esp, 8
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x2c]
cmp ecx, 0xf
jbe 0x40dcf5
mov edx, dword [ebp - 0x40]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40dbdd
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40dd42
push ecx
push edx
call fcn.0041cdc8
add esp, 8
jmp 0x40dcf5
mov edi, dword [ebp - 0x4c]
mov ax, word [edi]
cmp ax, word [0x4524b4]
jne 0x40dd37
mov eax, dword [ecx + 0x10]
movzx edx, word [edi + 2]
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x8c], eax
lea eax, [ebp - 0x8c]
push eax
lea eax, [ebp - 0xcc]
mov dword [ebp - 0x64], edx
push eax
mov word [ebp - 0x88], dx
call fcn.004132a0
mov eax, dword [ebp - 0xc4]
mov esi, dword [0x452574]
cmp byte [eax + 0xd], 0
jne 0x40dc51
mov edx, dword [eax + 0x10]
cmp dword [ebp - 0x7c], edx
jb 0x40dc51
jne 0x40dc53
mov ecx, dword [ebp - 0x64]
cmp cx, word [eax + 0x14]
jae 0x40dc53
mov eax, esi
cmp eax, esi
je 0x40dc7d
lea eax, [ebp - 0x8c]
push eax
call fcn.0040ddc0
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, dword [ebp - 0x44]
mov dword [eax + 0xc], ecx
mov eax, dword [ebp - 0x4c]
mov word [eax], dx
mov edi, dword [ebp - 0x4c]
mov esi, dword [0x452574]
mov ecx, dword [ebp - 0x44]
mov ax, word [edi]
cmp ax, word [0x4524b8]
jne 0x40dcf5
movzx eax, word [edi + 2]
mov edi, dword [ecx + 0x10]
mov dword [ebp - 0x64], eax
mov word [ebp - 0x90], ax
lea eax, [ebp - 0x94]
push eax
lea eax, [ebp - 0xd8]
mov dword [ebp - 0x94], edi
push eax
call fcn.004132a0
mov eax, dword [ebp - 0xd0]
cmp byte [eax + 0xd], 0
jne 0x40dcd2
cmp edi, dword [eax + 0x10]
jb 0x40dcd2
jne 0x40dcd4
mov ecx, dword [ebp - 0x64]
cmp cx, word [eax + 0x14]
jae 0x40dcd4
mov eax, esi
cmp eax, esi
je 0x40dcf5
lea eax, [ebp - 0x94]
push eax
call fcn.0040ddc0
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, dword [ebp - 0x44]
mov dword [eax + 0xc], ecx
mov eax, dword [ebp - 0x4c]
mov word [eax], dx
mov esi, dword [ebp - 0x50]
push 0
push 0
lea eax, [ebp - 0x130]
push eax
push dword [ebp - 0x5c]
push esi
call dword [sym.imp.WinDivert.dll_WinDivertHelperCalcChecksums]
push 0
push dword [ebp - 0x68]
lea eax, [ebp - 0x130]
push eax
push 0
push 0
push 0
push dword [ebp - 0x70]
push esi
push dword [ebp - 0x6c]
call dword [sym.imp.WinDivert.dll_WinDivertSendEx]
mov edx, dword [ebp - 0x60]
add esp, 0x38
jmp 0x40d833
mov esi, dword [0x452574]
jmp 0x40dc80
call fcn.004217fa
int3