Function at 0x480330
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4b2814
mov eax, dword fs:[0]
push eax
sub esp, 0x48
mov eax, dword [section..data]
xor eax, esp
mov dword [esp + 0x40], eax
push ebx
push esi
push edi
mov eax, dword [section..data]
xor eax, esp
push eax
lea eax, [esp + 0x58]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [esp + 0x14], ebx
push 0
push 0x4e4624
push 0x4e4640
push 0
push 0
call fcn.0047f8b0
push eax
call fcn.004a6d6e
mov edi, eax
add esp, 0x14
test edi, edi
je 0x4808c5
lea ecx, [ebx + 0x90]
push ecx
call dword [0x4b90bc]
mov byte [esp + 0x13], 0
test edi, edi
je 0x48062a
push edi
lea eax, [esp + 0x3c]
push eax
call fcn.00482df0
mov dword [esp + 0x60], 0
lea ecx, [esp + 0x38]
cmp dword [esp + 0x4c], 8
mov esi, 0xc
mov ebx, dword [esp + 0x48]
cmovae ecx, dword [esp + 0x38]
cmp ebx, esi
cmovb esi, ebx
test esi, esi
je 0x480405
mov edx, str.Capabilities
jmp 0x4803f0
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x48049e
add ecx, 2
add edx, 2
dec esi
jne 0x4803f0
xor eax, eax
test eax, eax
jne 0x480659
cmp ebx, 0xc
jb 0x480659
cmp ebx, 0xc
setne al
test eax, eax
jne 0x480659
sub esp, 0x18
mov ecx, esp
push 0x11
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], eax
push str.GrappaSupportInfo
mov word [ecx], ax
call fcn.0040b250
push edi
call fcn.00482e90
mov esi, eax
test esi, esi
jne 0x48050c
push 0x2d
push str.Cant_get_GrappaSupportInfo_from_Capabilities
lea ecx, [esp + 0x24]
mov dword [esp + 0x38], 7
mov dword [esp + 0x34], eax
mov word [esp + 0x24], ax
call fcn.0040b250
mov byte [esp + 0x60], 1
mov esi, dword [0x4e5bd8]
test esi, esi
jne 0x4804b7
push 0x44
call dword [0x4b93e8]
add esp, 4
test eax, eax
je 0x4804af
mov ecx, eax
call fcn.00466620
mov esi, eax
jmp 0x4804b1
movzx eax, word [ecx]
cmp ax, word [edx]
sbb eax, eax
and eax, 0xfffffffe
inc eax
jmp 0x480407
xor esi, esi
mov dword [0x4e5bd8], esi
sub esp, 0x18
mov byte [esp + 0x78], 2
mov ecx, esp
xor eax, eax
push 0xffffffffffffffff
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], 0
push eax
mov word [ecx], ax
lea eax, [esp + 0x3c]
push eax
call fcn.0040b790
push 1
mov ecx, esi
call fcn.00466ae0
mov byte [esp + 0x60], 0
cmp dword [esp + 0x30], 8
jb 0x4805ca
push dword [esp + 0x1c]
call dword [0x4b93e4]
add esp, 4
jmp 0x4805ca
push str.version
mov ecx, esi
call fcn.004046d0
test al, al
je 0x48054e
push 0
push 0x4e4914
push 0x4e4640
push 0
push str.version
mov ecx, esi
call fcn.004047c0
push eax
call fcn.004a6d6e
mov ebx, dword [esp + 0x28]
add esp, 0x14
mov eax, dword [eax + 8]
mov dword [ebx + 0x84], eax
jmp 0x480552
mov ebx, dword [esp + 0x14]
push str.deviceType
mov ecx, esi
call fcn.004046d0
test al, al
je 0x48058e
push 0
push 0x4e4914
push 0x4e4640
push 0
push str.deviceType
mov ecx, esi
call fcn.004047c0
push eax
call fcn.004a6d6e
add esp, 0x14
mov eax, dword [eax + 8]
mov dword [ebx + 0x88], eax
push str.protocolVersion
mov ecx, esi
call fcn.004046d0
test al, al
je 0x4805ca
push 0
push 0x4e4914
push 0x4e4640
push 0
push str.protocolVersion
mov ecx, esi
call fcn.004047c0
push eax
call fcn.004a6d6e
add esp, 0x14
mov eax, dword [eax + 8]
mov dword [ebx + 0x8c], eax
mov byte [esp + 0x13], 1
mov ebx, dword [esp + 0x14]
lea eax, [ebx + 0x90]
push eax
call dword [0x4b90c0]
cmp byte [esp + 0x13], 0
je 0x4808af
test edi, edi
je 0x4805f7
mov eax, dword [edi]
mov ecx, edi
push 1
call dword [eax]
mov dword [esp + 0x60], 0xffffffff
cmp dword [esp + 0x4c], 8
jb 0x480613
push dword [esp + 0x38]
call dword [0x4b93e4]
add esp, 4
xor eax, eax
mov dword [esp + 0x4c], 7
mov dword [esp + 0x48], 0
mov word [esp + 0x38], ax
push 0
push 0x4e4624
push 0x4e4640
push 0
push 0
mov ecx, ebx
call fcn.0047f8b0
push eax
call fcn.004a6d6e
mov edi, eax
add esp, 0x14
test edi, edi
je 0x4808c3
jmp 0x480395
push str.Session
mov ecx, edi
xor esi, esi
call fcn.004047c0
test eax, eax
je 0x480698
mov ecx, dword [eax + 4]
sub ecx, 2
je 0x48067e
dec ecx
jne 0x480698
push ecx
push 0x4e48f8
jmp 0x480685
push 0
push 0x4e4914
push 0x4e4640
push 0
push eax
call fcn.004a6d6e
add esp, 0x14
mov esi, dword [eax + 8]
push 0xc
push str.ReadyForSync
push dword [esp + 0x50]
push ecx
lea ecx, [esp + 0x48]
call fcn.00408690
test eax, eax
jne 0x480805
mov ebx, dword [esp + 0x14]
mov eax, dword [ebx + 0x7c]
cmp esi, eax
je 0x4806d6
push eax
push esi
push str.ReadyForSync_message_from_stale_session__d__current_session_is__d
push str.CATCService::ATCConnectionReadMessage
push 0x95
jmp 0x48083e
sub esp, 0x18
mov ecx, esp
push str.DeviceInfo
call fcn.0040b350
push edi
call fcn.00482e90
mov esi, eax
test esi, esi
jne 0x480742
sub esp, 0x18
mov ecx, esp
mov dword [esp + 0x30], esp
push str.Cant_get_DeviceInfo_from_ReadyForSync
call fcn.0040b350
mov byte [esp + 0x78], 3
mov eax, dword [0x4e5bd8]
test eax, eax
jne 0x480731
push 0x44
call dword [0x4b93e8]
add esp, 4
test eax, eax
je 0x48072a
mov ecx, eax
call fcn.00466620
jmp 0x48072c
xor eax, eax
mov dword [0x4e5bd8], eax
mov ecx, eax
mov byte [esp + 0x78], 0
call fcn.00466910
jmp 0x4805d3
push str.Grappa
mov ecx, esi
call fcn.004046d0
test al, al
je 0x4805d3
push 0
push 0x4e48e4
push 0x4e4640
push 0
push str.Grappa
mov ecx, esi
call fcn.004047c0
push eax
call fcn.004a6d6e
mov esi, eax
add esp, 0x14
test esi, esi
jne 0x4807bf
sub esp, 0x18
mov ecx, esp
mov dword [esp + 0x30], esp
push str.Grappa_key_could_not_be_found
call fcn.0040b350
mov byte [esp + 0x78], 4
call fcn.00466c50
mov ecx, eax
mov byte [esp + 0x78], 0
call fcn.00466910
mov eax, dword [edi]
mov ecx, edi
push 1
call dword [eax]
push ecx
mov ecx, ebx
call fcn.00482f40
mov edi, eax
jmp 0x4805d3
push 0x10
call dword [0x4b93e8]
add esp, 4
mov dword [esp + 0x18], eax
mov byte [esp + 0x60], 5
test eax, eax
je 0x4807f4
push dword [esi + 0xc]
mov ecx, eax
push dword [esi + 8]
call fcn.004209b0
mov byte [esp + 0x60], 0
mov dword [ebx + 0xa8], eax
jmp 0x4805d3
xor eax, eax
mov byte [esp + 0x60], al
mov dword [ebx + 0xa8], eax
jmp 0x4805d3
push 0xd
push str.AssetManifest
push dword [esp + 0x50]
push ecx
lea ecx, [esp + 0x48]
call fcn.00408690
test eax, eax
jne 0x480857
mov ebx, dword [esp + 0x14]
mov eax, dword [ebx + 0x7c]
cmp esi, eax
je 0x4805d3
push eax
push esi
push str.AssetManifest_message_from_stale_session__d__current_session_is__d
push str.CATCService::ATCConnectionReadMessage
push 0xb9
push str.ServiceATCService.cpp
push 3
call fcn.004438a0
add esp, 0x1c
mov byte [esp + 0x13], 1
jmp 0x4805d3
push 0xa
push str.SyncFailed
push dword [esp + 0x50]
push ecx
lea ecx, [esp + 0x48]
call fcn.00408690
test eax, eax
je 0x48088d
push 0xc
push str.SyncFinished
push dword [esp + 0x50]
push ecx
lea ecx, [esp + 0x48]
call fcn.00408690
test eax, eax
jne 0x4805cf
mov ebx, dword [esp + 0x14]
mov eax, dword [ebx + 0x7c]
cmp esi, eax
je 0x4805d3
push eax
push esi
push str.Sync_end_message_from_stale_session__d__current_session_is__d
push str.CATCService::ATCConnectionReadMessage
push 0xcb
jmp 0x48083e
cmp dword [esp + 0x4c], 8
jb 0x4808c3
push dword [esp + 0x38]
call dword [0x4b93e4]
add esp, 4
mov eax, edi
mov ecx, dword [esp + 0x58]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x40]
xor ecx, esp
call fcn.004a6303
mov esp, ebp
pop ebp
ret