Function at 0x426478
Capabilities:
Inspect section memory permissions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
mov esi, dword [ebp + 8]
mov al, byte [esi]
inc esi
dec dword [ebp + 0xc]
mov ebx, ecx
mov byte [ebp - 1], al
mov dword [ebp + 8], esi
cmp al, 5
jb 0x42649c
xor al, al
jmp 0x426cde
push edi
movzx edi, al
mov eax, edi
sub eax, 3
je 0x426cbc
dec eax
je 0x426a5f
mov eax, dword [ebp + 0xc]
push 0
add eax, esi
push eax
lea edx, [ebp - 0x1c]
mov ecx, esi
call fcn.004021cf
cmp eax, esi
jb 0x426a4c
mov edx, dword [ebp + 0xc]
lea ecx, [esi + edx]
cmp eax, ecx
ja 0x426a4c
cmp byte [ebp - 1], 2
je 0x4264e8
cmp eax, ecx
jne 0x426a4c
cmp byte [ebp - 0x14], 5
jne 0x426a50
mov ecx, edi
sub ecx, 0
je 0x42654c
dec ecx
je 0x426529
dec ecx
jne 0x426a50
mov ecx, dword [ebx + 0xc4]
test byte [ecx + 0x41], 2
jne 0x426a3f
sub esi, eax
add esi, edx
push esi
push eax
lea eax, [ebp - 0x1c]
push eax
mov ecx, ebx
call fcn.004257c8
jmp 0x426a3f
mov eax, dword [ebx + 0xc4]
mov al, byte [eax + 0x41]
and al, 6
cmp al, 4
jne 0x426a3f
lea eax, [ebp - 0x1c]
push eax
mov ecx, ebx
call fcn.00423585
jmp 0x426a3f
push 0
push 0x466450
lea ecx, [ebp - 0x1c]
call fcn.00401c3f
mov edi, eax
test edi, edi
je 0x426589
lea esi, [ebx + 0xc0]
mov eax, dword [esi]
movzx eax, word [eax + 0x24]
cmp edi, eax
je 0x426589
push 0
mov ecx, ebx
call fcn.00425080
mov eax, dword [esi]
push 1
mov ecx, ebx
mov word [eax + 0x24], di
call fcn.00425080
push 0xffffffffffffffff
push 0x4635cc
lea ecx, [ebp - 0x1c]
call fcn.00401c3f
test eax, eax
jl 0x4265ad
mov esi, dword [ebx + 0xc0]
mov cl, byte [esi + 0x4d]
xor cl, al
and cl, 1
xor byte [esi + 0x4d], cl
and dword [ebp + 8], 0
lea eax, [ebp + 8]
push eax
push str.ipv4
lea ecx, [ebp - 0x1c]
call fcn.00401c03
mov esi, eax
mov edi, 0x42284d
test esi, esi
je 0x4266ab
cmp dword [ebp + 8], 4
jne 0x4266ab
lea ecx, [ebp - 0x30]
call fcn.0042c9c1
push dword [ebp + 8]
lea ecx, [ebp - 0x30]
push esi
call fcn.0042caa9
lea ecx, [ebp - 0x30]
call fcn.0040253f
test al, al
je 0x4266ab
lea ecx, [ebp - 0x30]
call fcn.00405ccd
test al, al
jne 0x4266ab
test dword [0x486524], 0x40000000
je 0x42662b
lea eax, [ebp - 0x30]
push eax
push str.Extension:_ipv4:__a_
call fcn.0045c3cd
pop ecx
pop ecx
mov eax, dword [ebx + 0xc0]
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [eax + 0x14]
call fcn.0042ccf1
test eax, eax
je 0x4266ab
lea ecx, [ebp - 0x30]
call fcn.00405ccd
test al, al
jne 0x4266ab
mov eax, dword [ebx + 0xc0]
mov cx, word [eax + 0x24]
push 1
mov word [ebp - 0x20], cx
push edi
lea ecx, [ebp - 0x30]
push ecx
mov ecx, dword [ebx + 0xc4]
push 0
push eax
call fcn.00406c6a
mov esi, eax
lea eax, [ebp - 0x30]
push eax
lea ecx, [esi + 0x14]
call fcn.0042ccf1
test eax, eax
je 0x42668c
mov ecx, 0xa53
call fcn.004026bd
cmp esi, dword [ebx + 0xc0]
je 0x426698
or byte [esi + 0x4a], 8
test byte [ebx + 0xd4], 0x80
je 0x4266ab
mov al, byte [esi + 0x4d]
and al, 0xef
or al, 1
mov byte [esi + 0x4d], al
lea eax, [ebp + 8]
push eax
push str.ipv6
lea ecx, [ebp - 0x1c]
call fcn.00401c03
mov esi, eax
test esi, esi
je 0x4267a0
cmp dword [ebp + 8], 0x10
jne 0x4267a0
lea ecx, [ebp - 0x30]
call fcn.0042c9c1
push dword [ebp + 8]
lea ecx, [ebp - 0x30]
push esi
call fcn.0042caa9
lea ecx, [ebp - 0x30]
call fcn.0040253f
test al, al
jne 0x4267a0
lea ecx, [ebp - 0x30]
call fcn.00405ccd
test al, al
jne 0x4267a0
test dword [0x486524], 0x40000000
je 0x426720
lea eax, [ebp - 0x30]
push eax
push str.Extension:_ipv6:__a_
call fcn.0045c3cd
pop ecx
pop ecx
mov eax, dword [ebx + 0xc0]
lea ecx, [ebp - 0x30]
push ecx
lea ecx, [eax + 0x14]
call fcn.0042ccf1
test eax, eax
je 0x4267a0
lea ecx, [ebp - 0x30]
call fcn.00405ccd
test al, al
jne 0x4267a0
mov eax, dword [ebx + 0xc0]
mov cx, word [eax + 0x24]
push 1
mov word [ebp - 0x20], cx
push edi
lea ecx, [ebp - 0x30]
push ecx
mov ecx, dword [ebx + 0xc4]
push 0
push eax
call fcn.00406c6a
mov esi, eax
lea eax, [ebp - 0x30]
push eax
lea ecx, [esi + 0x14]
call fcn.0042ccf1
test eax, eax
je 0x426781
mov ecx, 0xa6c
call fcn.004026bd
cmp esi, dword [ebx + 0xc0]
je 0x42678d
or byte [esi + 0x4a], 8
test byte [ebx + 0xd4], 0x80
je 0x4267a0
mov al, byte [esi + 0x4d]
and al, 0xef
or al, 1
mov byte [esi + 0x4d], al
push 0xffffffffffffffff
push 0xffffffffffffffff
push str.metadata_size
lea ecx, [ebp - 0x1c]
call fcn.00401c5d
xor edi, edi
cmp edx, edi
jl 0x4267d5
jg 0x4267bd
cmp eax, edi
jbe 0x4267d5
mov ecx, dword [ebx + 0xc4]
push edx
push eax
call fcn.004044ad
test al, al
je 0x4267d5
or byte [ebx + 0xd6], 0x10
lea eax, [ebp + 8]
push eax
push str.yourip
lea ecx, [ebp - 0x1c]
call fcn.00401c03
mov esi, eax
cmp esi, edi
je 0x42681c
cmp dword [ebp + 8], 0x10
je 0x4267f8
cmp dword [ebp + 8], 4
jne 0x42681c
lea ecx, [ebp - 0x30]
call fcn.0042c9c1
push dword [ebp + 8]
lea ecx, [ebp - 0x30]
push esi
call fcn.0042caa9
mov ecx, dword [ebx + 0xc4]
push edi
lea eax, [ebp - 0x30]
push eax
call fcn.00408b54
push edi
push edi
mov esi, 0x4635fc
push esi
lea ecx, [ebp - 0x1c]
call fcn.004018ba
mov dword [ebp - 8], eax
cmp eax, edi
je 0x426981
mov eax, dword [ebx + 0x15c]
cmp word [eax], 0x5b
jne 0x42686a
cmp word [eax + 2], 0x46
jne 0x42686a
cmp word [eax + 4], 0x41
jne 0x42686a
cmp word [eax + 6], 0x4b
jne 0x42686a
cmp word [eax + 8], 0x45
jne 0x42686a
cmp word [eax + 0xa], 0x5d
je 0x426981
lea eax, [ebp + 0xc]
push eax
push esi
lea ecx, [ebp - 0x1c]
call fcn.00401c03
cmp dword [ebp + 0xc], 8
mov esi, eax
jb 0x426973
push 8
push 0x4663c4
push esi
call sub.MSVCRT.dll_strncmp
add esp, 0xc
test eax, eax
jne 0x426973
cmp dword [ebp + 0xc], 0xc
jb 0x4268d2
cmp byte [esi + 8], 0x20
jne 0x4268d2
cmp byte [esi + 9], 0x31
jne 0x4268d2
cmp byte [esi + 0xa], 0x2e
jne 0x4268d2
movzx eax, byte [esi + 0xb]
sub eax, 0x30
cmp eax, 5
jg 0x4268d2
movzx eax, byte [esi + 0xc]
push eax
call sub.MSVCRT.dll_isdigit
pop ecx
test eax, eax
je 0x426981
push 0x20
push dword [ebp - 8]
call sub.MSVCRT.dll_wcschr
mov edi, 0x462d8c
pop ecx
mov dword [ebp - 0xc], eax
mov eax, edi
pop ecx
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
test dx, dx
jne 0x4268eb
sub eax, ecx
sar eax, 1
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 8]
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
test dx, dx
jne 0x426902
mov esi, dword [ebp - 0xc]
sub eax, ecx
mov ecx, esi
sub ecx, dword [ebp - 8]
sar eax, 1
sar ecx, 1
neg esi
sbb esi, esi
and esi, ecx
sub eax, esi
add eax, dword [ebp - 0x10]
lea ecx, [eax + eax + 2]
call fcn.00434e42
mov ecx, eax
sub ecx, edi
movzx edx, word [edi]
mov word [edi + ecx], dx
inc edi
inc edi
test dx, dx
jne 0x426932
cmp dword [ebp - 0xc], 0
je 0x426964
mov ecx, dword [ebp - 8]
lea esi, [ecx + esi*2]
mov ecx, dword [ebp - 0x10]
add ecx, ecx
sub ecx, esi
lea edx, [ecx + eax]
movzx ecx, word [esi]
mov word [esi + edx], cx
inc esi
inc esi
test cx, cx
jne 0x426956
mov edx, eax
lea ecx, [ebx + 0x15c]
call fcn.0042d25e
jmp 0x426981
mov edx, dword [ebp - 8]
lea ecx, [ebx + 0x15c]
call fcn.0042d1d5
movzx eax, byte [ebx + 0xf6]
push eax
push str.reqq
lea ecx, [ebp - 0x1c]
call fcn.00401c3f
mov ecx, 0xff
cmp eax, ecx
jle 0x4269a1
mov eax, ecx
cmp eax, 1
jge 0x4269a9
xor eax, eax
inc eax
push 0x4663b8
lea ecx, [ebp - 0x1c]
mov byte [ebx + 0xf6], al
call fcn.00401bd3
mov esi, eax
xor edi, edi
cmp esi, edi
je 0x426a3f
push edi
push str.ut_pex
mov ecx, esi
call fcn.00401c3f
cmp eax, edi
jl 0x4269db
mov byte [ebx + 0x158], al
push edi
push str.ut_metadata
mov ecx, esi
call fcn.00401c3f
cmp eax, edi
jl 0x4269f2
mov byte [ebx + 0x159], al
push edi
push str.ut_holepunch
mov ecx, esi
call fcn.00401c3f
cmp eax, edi
jl 0x426a1d
mov ecx, dword [ebx + 0xc0]
mov byte [ebx + 0x15b], al
setne al
shl al, 4
xor al, byte [ecx + 0x4e]
and al, 0x10
xor byte [ecx + 0x4e], al
push edi
push str.upload_only
mov ecx, esi
call fcn.00401c3f
cmp eax, edi
jl 0x426a3f
mov byte [ebx + 0x15a], al
test al, al
je 0x426a3f
mov ecx, ebx
call fcn.0042266a
lea ecx, [ebp - 0x1c]
call fcn.00401ed9
jmp 0x426cdb
test eax, eax
je 0x426a58
lea ecx, [ebp - 0x1c]
call fcn.00401ed9
xor al, al
jmp 0x426cdd
cmp dword [ebp + 0xc], 1
jb 0x426a58
lea ecx, [ebp - 0x30]
call fcn.0042c9c1
mov al, byte [esi + 1]
test al, al
jne 0x426abd
cmp dword [ebp + 0xc], 8
jb 0x426a58
movzx eax, word [esi + 6]
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
movzx eax, ax
push eax
push dword [esi + 2]
call dword [sym.imp.WS2_32.dll_ntohl]
push eax
lea ecx, [ebp - 0x42]
call fcn.0042c9fc
mov esi, eax
mov eax, dword [ebp + 8]
mov al, byte [eax]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
cmp al, 2
jne 0x426b08
cmp dword [ebp + 0xc], 0xc
jne 0x426a58
mov ecx, dword [ebp + 8]
mov esi, dword [ecx + 8]
jmp 0x426b0b
cmp al, 1
jne 0x426a58
cmp dword [ebp + 0xc], 0x14
jb 0x426a58
movzx eax, word [esi + 0x12]
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
movzx eax, ax
push eax
add esi, 2
push esi
lea ecx, [ebp - 0x54]
call fcn.0042ca31
mov esi, eax
mov eax, dword [ebp + 8]
mov al, byte [eax]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
cmp al, 2
jne 0x426b08
cmp dword [ebp + 0xc], 0x18
jne 0x426a58
mov ecx, dword [ebp + 8]
mov esi, dword [ecx + 0x14]
jmp 0x426b0b
mov esi, dword [ebp + 0xc]
movzx eax, al
xor edi, edi
sub eax, edi
je 0x426c37
dec eax
je 0x426b8e
dec eax
jne 0x426a58
test dword [0x486524], 0x20000000
je 0x426b3d
push esi
push str.Got_Holepunch_failure__u_
push ebx
call fcn.004229e8
add esp, 0xc
cmp esi, 1
je 0x426b47
cmp esi, 2
jne 0x426b59
mov ecx, dword [ebx + 0x18c]
cmp ecx, edi
je 0x426b59
lea edx, [ebp - 0x30]
call fcn.00418a67
mov eax, dword [ebx + 0xc4]
add eax, 0x78
mov ecx, dword [eax]
lea edx, [ebp - 0x30]
call fcn.00418912
cmp eax, edi
je 0x426cdb
cmp esi, 1
je 0x426b82
cmp esi, 2
jne 0x426c21
mov eax, dword [eax + 0x18]
and dword [eax + 0x4f], 0xfffffff0
jmp 0x426c21
test dword [0x486524], 0x20000000
je 0x426bac
lea eax, [ebp - 0x30]
push eax
push str.Got_Holepunch_Connect__A_
push ebx
call fcn.004229e8
add esp, 0xc
lea ecx, [ebp - 0x30]
call fcn.00405ccd
test al, al
jne 0x426cdb
mov ecx, dword [ebx + 0xc4]
push 1
push 0x42284d
lea eax, [ebp - 0x30]
push eax
push edi
push edi
call fcn.00406c6a
mov esi, eax
lea eax, [ebp - 0x30]
push eax
lea ecx, [esi + 0x14]
call fcn.0042ccf1
test eax, eax
je 0x426bf0
mov ecx, 0x9f0
call fcn.004026bd
or byte [esi + 0x4a], 8
and byte [esi + 0x3b], 0xf0
or byte [esi + 0x4e], 4
mov dword [esi + 0x37], edi
mov eax, dword [ebx + 0xc4]
add eax, 0x78
mov ecx, dword [eax]
lea edx, [ebp - 0x30]
call fcn.00418912
cmp eax, edi
je 0x426cdb
mov eax, dword [eax + 0x18]
or byte [eax + 0x4e], 8
mov eax, dword [ebx + 0xc4]
mov ecx, dword [eax + 0x78]
lea edx, [ebp - 0x30]
call fcn.00418a67
jmp 0x426cdb
test dword [0x486524], 0x20000000
je 0x426c55
lea eax, [ebp - 0x30]
push eax
push str.Got_Holepunch_Rendezvous__A_
push ebx
call fcn.004229e8
add esp, 0xc
mov ecx, dword [ebx + 0xc4]
lea eax, [ebp - 0x30]
push eax
call fcn.004041b9
mov ecx, eax
cmp ecx, edi
jne 0x426c79
push 1
lea eax, [ebp - 0x30]
push eax
mov ecx, ebx
call fcn.00423a77
jmp 0x426cdb
cmp ecx, dword [ebx + 0xc0]
jne 0x426c85
push 4
jmp 0x426c6c
call fcn.004221da
mov esi, eax
cmp esi, edi
jne 0x426c94
push 2
jmp 0x426c6c
test byte [ecx + 0x4e], 0x10
jne 0x426c9e
push 3
jmp 0x426c6c
lea eax, [ebx + 0x160]
push eax
mov ecx, esi
call fcn.00423a45
add esi, 0x160
push esi
mov ecx, ebx
call fcn.00423a45
jmp 0x426cdb
cmp byte [esi], 0
mov eax, dword [ebx + 0xc0]
setne cl
shl cl, 6
xor cl, byte [eax + 0x4d]
and cl, 0x40
xor byte [eax + 0x4d], cl
mov ecx, ebx
call fcn.0042607d
mov al, 1
pop edi
pop esi
pop ebx
leave
ret 8