Function at 0x547980
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
sub esp, 0x74
mov edx, dword [ebp + 0x14]
push ebx
push esi
push edi
mov esi, ecx
mov ecx, dword [ebp + 0x18]
push ecx
mov ecx, dword [edx]
push ecx
lea edx, [eax + 0x414]
push edx
add eax, 0x20c
xor edi, edi
push eax
push str.PATCH__s_HTTP_1.1_r_nHost:__s_r_nTus_Resumable:_1.0.0_r_nUpload_Offset:__u_r_nContent_Length:__u_r_nContent_Type:_application_offsetoctet_stream_r_n_r_n
lea eax, [esp + 0x88]
mov dword [esp + 0x5c], edi
mov dword [esp + 0x88], edi
mov dword [esp + 0x8c], edi
mov dword [esp + 0x90], edi
call fcn.00552e70
mov ecx, dword [esp + 0x88]
add esp, 0x14
cmp ecx, edi
jne 0x5479e4
mov ecx, 0x6bc0ce
mov eax, ecx
lea ebx, [eax + 1]
lea esp, [esp]
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x5479f0
push 0xea60
push ecx
push esi
lea ecx, [esp + 0x50]
push ecx
mov ecx, dword [ebp + 0xc]
sub eax, ebx
call fcn.0054d6a0
mov eax, dword [esp + 0x44]
cmp eax, edi
je 0x547a34
mov edx, dword [esp + 0x74]
mov esi, dword [ebp + 8]
push edx
mov dword [esi], eax
call fcn.0069c8fa
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
lea eax, [esp + 0x58]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x547a55
xor ebx, ebx
mov dword [esp + 0x60], ebx
mov dword [esp + 0x64], edi
jmp 0x547a67
mov eax, dword [esp + 0x58]
mov ecx, dword [esp + 0x5c]
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], ecx
mov ebx, eax
mov edx, dword [ebp + 0x14]
mov eax, dword [ebp + 0x18]
mov edi, dword [edx]
push 0x8000
mov dword [esp + 0x48], eax
call fcn.0069c0de
add esp, 4
cmp dword [ebp + 0x18], 0
mov dword [esp + 0x40], eax
jbe 0x547ba2
mov edi, edi
mov edx, dword [esi]
mov eax, dword [edx]
mov ecx, esi
call eax
test al, al
jne 0x547c8e
mov ecx, ebx
shr ecx, 0xa
push ecx
mov edx, edi
shr edx, 0xa
push edx
push str.Upload_Progress:__u_Kb_of__u_Kb
push 0
call fcn.004b1130
mov eax, dword [esi]
mov ecx, edi
test ecx, ecx
mov dword [esp + 0x68], ecx
fild dword [esp + 0x68]
jge 0x547ace
fadd qword [0x7235b8]
test ebx, ebx
mov dword [esp + 0x68], ebx
fild dword [esp + 0x68]
jge 0x547ae0
fadd qword [0x7235b8]
fdivp st(1)
mov edx, dword [eax + 0x24]
add esp, 8
mov ecx, esi
fstp qword [esp]
call edx
mov ebx, dword [esp + 0x44]
cmp ebx, 0x8000
jb 0x547b00
mov ebx, 0x8000
xor eax, eax
push eax
push eax
push eax
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
push edi
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push 1
lea edx, [esp + 0x6c]
push edx
xor ecx, ecx
push ecx
xor eax, eax
push eax
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x547b35
mov dword [esp + 0x5c], eax
jmp 0x547b41
mov edx, dword [esp + 0x6c]
mov eax, dword [esp + 0x68]
mov dword [esp + 0x5c], edx
cmp eax, edi
jne 0x547cbc
mov ecx, dword [esp + 0x40]
mov edx, dword [ebp + 0x10]
push 0
lea eax, [esp + 0x54]
push eax
mov eax, dword [edx]
push ebx
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [esp + 0x50], ebx
mov ecx, dword [esp + 0x40]
jne 0x547cc5
push 0xea60
push ecx
mov ecx, dword [ebp + 0xc]
push esi
lea edx, [esp + 0x60]
push edx
mov eax, ebx
call fcn.0054d6a0
mov eax, dword [esp + 0x54]
test eax, eax
jne 0x547cef
add edi, ebx
sub dword [esp + 0x44], ebx
mov ebx, dword [esp + 0x60]
jne 0x547a90
mov edx, ebx
shr edx, 0xa
push edx
mov eax, edi
shr eax, 0xa
push eax
push str.Upload_Progress:__u_Kb_of__u_Kb
push 0
call fcn.004b1130
test edi, edi
mov edx, dword [esi]
mov dword [esp + 0x68], edi
fild dword [esp + 0x68]
jge 0x547bce
fadd qword [0x7235b8]
test ebx, ebx
mov dword [esp + 0x68], ebx
fild dword [esp + 0x68]
jge 0x547be0
fadd qword [0x7235b8]
fdivp st(1)
mov eax, dword [edx + 0x24]
add esp, 8
mov ecx, esi
fstp qword [esp]
call eax
mov ecx, dword [esp + 0x40]
push ecx
call fcn.0069c8fa
mov ebx, dword [ebp + 0xc]
add esp, 4
xor eax, eax
push ebx
push esi
lea edx, [esp + 0x5c]
mov dword [esp + 0x54], eax
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], eax
push edx
mov edi, 0xea60
lea eax, [esp + 0x74]
mov byte [esp + 0x4b], 0
call fcn.00499e50
mov eax, dword [esp + 0x54]
test eax, eax
jne 0x547d72
mov eax, dword [esp + 0x68]
test eax, eax
jne 0x547c44
mov eax, 0x6bc0ce
lea edx, [esp + 0x48]
push edx
push str.HTTP__d._d__d__s
push eax
call fcn.0069e906
add esp, 0xc
cmp eax, 1
je 0x547cf6
mov eax, dword [esp + 0x68]
mov esi, dword [ebp + 8]
push eax
mov dword [esi], 2
call fcn.0069c8fa
mov ecx, dword [esp + 0x78]
add esp, 4
push ecx
call fcn.0069c8fa
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov esi, dword [ebp + 8]
mov dword [esi], 1
mov eax, dword [esp + 0x40]
push eax
call fcn.0069c8fa
add esp, 4
mov ecx, dword [esp + 0x74]
push ecx
call fcn.0069c8fa
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov edx, dword [esp + 0x40]
jmp 0x547db2
mov esi, dword [ebp + 8]
push ecx
mov dword [esi], 2
call fcn.0069c8fa
mov edx, dword [esp + 0x78]
add esp, 4
push edx
call fcn.0069c8fa
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov esi, dword [ebp + 8]
mov dword [esi], eax
jmp 0x547c97
mov edx, dword [esp + 0x48]
add edx, 0xffffff38
cmp edx, 0x63
ja 0x547dae
push ebx
push esi
lea eax, [esp + 0x4c]
push eax
lea eax, [esp + 0x74]
call fcn.00499e50
mov eax, dword [esp + 0x44]
test eax, eax
jne 0x547d72
mov eax, dword [esp + 0x68]
test eax, eax
je 0x547d80
cmp byte [eax], 0
je 0x547d80
cmp byte [esp + 0x3f], 0
jne 0x547d55
lea ecx, [esp + 0x4c]
push ecx
call fcn.00547010
test al, al
je 0x547d55
mov eax, dword [esp + 0x4c]
mov ecx, dword [ebp + 0x14]
cmp dword [ecx], eax
mov byte [esp + 0x3f], 1
je 0x547d55
mov dword [ecx], eax
push ebx
push esi
lea edx, [esp + 0x4c]
push edx
mov edi, 0xea60
lea eax, [esp + 0x74]
call fcn.00499e50
mov eax, dword [esp + 0x44]
test eax, eax
je 0x547d21
mov esi, dword [ebp + 8]
mov dword [esi], eax
mov eax, dword [esp + 0x68]
jmp 0x547c9b
push eax
call fcn.0069c8fa
mov edx, dword [esp + 0x4c]
mov esi, dword [ebp + 8]
add edx, 0xffffff38
add esp, 4
cmp edx, 0x63
ja 0x547da3
mov dword [esi], 0
jmp 0x547dc4
mov dword [esi], 2
jmp 0x547ca4
mov edx, dword [esp + 0x68]
mov esi, dword [ebp + 8]
push edx
mov dword [esi], 2
call fcn.0069c8fa
add esp, 4
mov eax, dword [esp + 0x74]
push eax
call fcn.0069c8fa
add esp, 4
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14