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

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x5c
mov ebp, dword [esp + 0x70]
test ebp, ebp
je 0x493541
mov dword [esp], 0
call sub.msvcrt.dll_time
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x78]
shl eax, 2
mov dword [esp + 0x34], eax
cmp eax, 0x100000
ja 0x4933f0
mov edx, dword [esp + 0x34]
shl edx, 3
mov dword [esp + 0x3c], edx
mov ecx, dword [ebp + 0xc]
mov dword [esp + 0x20], ecx
mov edi, dword [ecx]
mov eax, dword [edi + 0x48]
mov dword [esp + 0x28], eax
mov eax, dword [ecx + 0x54]
cmp eax, 3
je 0x49314c
cmp eax, 5
je 0x4933a8
test eax, eax
jne 0x49326c
mov eax, dword [ebp + 0x134]
test eax, eax
jne 0x49341c
cmp byte [ebp + 0x138], 0
jne 0x49314c
mov eax, dword [ebp + 0x120]
sub eax, dword [ebp + 0x118]
cmp eax, dword [esp + 0x34]
jae 0x49347f
mov ecx, dword [esp + 0x34]
sub ecx, eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], edi
call sym.curl.exe_libssh2_channel_window_read_ex
cmp eax, dword [esp + 0x34]
jb 0x4934b5
mov esi, dword [esp + 0x1c]
test esi, esi
je 0x49314c
lea ecx, [ebp + 0x10]
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x38], edi
jmp 0x4930f0
mov dword [eax + 0xc], esi
mov edx, dword [esp + 0x24]
mov dword [eax + 0x14], edx
mov dword [eax + 0x10], 0
lea eax, [eax + 0x1c]
mov dword [esp + 0x4c], eax
lea edx, [edi + 0x15]
mov dword [esp + 4], edx
lea ecx, [esp + 0x4c]
mov dword [esp], ecx
call fcn.004a00f4
mov eax, dword [esp + 0x4c]
mov byte [eax], 5
inc eax
mov dword [esp + 0x4c], eax
mov edx, dword [esp + 0x20]
mov eax, dword [edx + 4]
lea edx, [eax + 1]
mov ecx, dword [esp + 0x20]
mov dword [ecx + 4], edx
mov dword [ebx + 0x18], eax
mov dword [esp + 4], eax
lea eax, [esp + 0x4c]
mov dword [esp], eax
call fcn.004a00f4
mov eax, dword [ebp + 0x110]
mov dword [esp + 8], eax
mov edx, dword [esp + 0x2c]
mov dword [esp + 4], edx
lea ecx, [esp + 0x4c]
mov dword [esp], ecx
call fcn.004a0120
mov edx, dword [ebp + 0x120]
mov ecx, dword [ebp + 0x124]
lea eax, [esp + 0x4c]
call fcn.004915d8
xor edx, edx
add dword [ebp + 0x120], esi
adc dword [ebp + 0x124], edx
mov dword [esp + 4], esi
lea eax, [esp + 0x4c]
mov dword [esp], eax
call fcn.004a00f4
mov dword [esp + 4], ebx
lea ebx, [ebp + 0x14c]
mov dword [esp], ebx
call fcn.004a04f8
sub dword [esp + 0x1c], esi
je 0x493410
mov esi, dword [esp + 0x1c]
cmp esi, 0x7d0
jbe 0x493101
mov esi, 0x7d0
mov edi, dword [ebp + 0x110]
lea edx, [edi + 0x19]
mov dword [esp + 0x24], edx
mov ecx, dword [esp + 0x28]
mov dword [esp + 4], ecx
lea eax, [edi + 0x39]
mov dword [esp], eax
call dword [ecx + 4]
mov ebx, eax
test eax, eax
jne 0x493028
mov dword [esp + 8], str.malloc_fail_for_FXP_WRITE
mov dword [esp + 4], 0xfffffffa
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call fcn.0049ffcc
jmp 0x493235
lea ebx, [ebp + 0x14c]
mov edx, dword [esp + 0x20]
mov dword [edx + 0x54], 0
mov dword [esp], ebx
call fcn.004a0520
mov esi, eax
test eax, eax
je 0x4931b7
nop
mov eax, dword [esi + 0x14]
test eax, eax
je 0x4931a9
mov dword [esp + 0xc], eax
mov eax, dword [esi + 0x10]
lea eax, [esi + eax + 0x1c]
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], edi
call fcn.0049825c
test eax, eax
js 0x493400
mov edx, dword [esi + 0x14]
sub edx, eax
mov dword [esi + 0x14], edx
add dword [esi + 0x10], eax
test edx, edx
jne 0x4931b7
mov dword [esp], esi
call fcn.004a0528
mov esi, eax
test eax, eax
jne 0x49316c
mov eax, dword [esp + 0x20]
mov dword [eax + 0x54], 0
mov dword [esp], ebx
call fcn.004a0520
mov ebx, eax
test eax, eax
je 0x49326c
mov edi, dword [eax + 0x14]
test edi, edi
jne 0x49326c
mov ecx, dword [ebx + 0x18]
lea edx, [esp + 0x4c]
mov dword [esp + 4], edx
lea eax, [esp + 0x48]
mov dword [esp], eax
mov edx, 0x5e1976
mov eax, dword [esp + 0x20]
call fcn.00491d9c
test eax, eax
js 0x4934e8
mov edx, dword [esp + 0x48]
mov al, byte [edx]
cmp al, 0x65
je 0x49334c
cmp al, 0x67
je 0x493278
mov dword [esp + 8], str.SFTP_Protocol_badness:_unrecognised_read_request_response
mov dword [esp + 4], 0xffffffe1
mov edx, dword [esp + 0x28]
mov dword [esp], edx
call fcn.0049ffcc
cmp eax, 0xffffffdb
jne 0x493261
mov edx, dword [ebp + 0xc]
mov edx, dword [edx]
mov edx, dword [edx + 0x48]
mov esi, dword [edx + 0x50]
test esi, esi
je 0x493261
mov eax, dword [esp + 0x30]
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.004906d8
test eax, eax
je 0x492f80
add esp, 0x5c
pop ebx
pop esi
pop edi
pop ebp
ret
xor eax, eax
add esp, 0x5c
pop ebx
pop esi
pop edi
pop ebp
ret
add edx, 5
mov dword [esp], edx
call fcn.004a0068
mov edx, eax
mov ecx, dword [esp + 0x4c]
lea eax, [ecx - 9]
cmp edx, eax
ja 0x4934f8
mov esi, dword [ebx + 0xc]
cmp edx, esi
ja 0x493520
je 0x4932b1
sub esi, edx
xor edi, edi
sub dword [ebp + 0x120], esi
sbb dword [ebp + 0x124], edi
cmp dword [esp + 0x78], edx
jae 0x4933dc
sub edx, dword [esp + 0x78]
mov dword [ebp + 0x134], edx
mov eax, dword [esp + 0x48]
mov dword [ebp + 0x12c], eax
mov dword [ebp + 0x130], ecx
mov edx, dword [esp + 0x78]
lea esi, [eax + 9]
mov edi, dword [esp + 0x74]
mov ecx, edx
rep movsb byte es:[edi], byte [esi]
xor edi, edi
add dword [ebp + 0x118], edx
adc dword [ebp + 0x11c], edi
mov ecx, dword [ebp + 0x130]
test ecx, ecx
je 0x493464
mov dword [esp], ebx
mov dword [esp + 0x18], edx
call fcn.004a0528
mov esi, eax
mov dword [esp], ebx
call fcn.004a0538
mov eax, dword [esp + 0x28]
mov dword [esp + 4], eax
mov dword [esp], ebx
call dword [eax + 0xc]
mov edx, dword [esp + 0x18]
test edx, edx
jne 0x493519
test esi, esi
je 0x49326c
mov ebx, dword [esi + 0x14]
test ebx, ebx
jne 0x49326c
mov ebx, esi
jmp 0x4931df
mov dword [esp], ebx
call fcn.004a0538
mov ecx, dword [esp + 0x28]
mov dword [esp + 4], ecx
mov dword [esp], ebx
call dword [ecx + 0xc]
mov eax, ebp
call fcn.00491afc
mov eax, dword [esp + 0x48]
add eax, 5
mov dword [esp], eax
call fcn.004a0068
mov ebx, eax
mov eax, dword [esp + 0x28]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x48]
mov dword [esp], eax
mov edx, dword [esp + 0x28]
call dword [edx + 0xc]
cmp ebx, 1
jne 0x4933b4
mov byte [ebp + 0x138], 1
xor eax, eax
add esp, 0x5c
pop ebx
pop esi
pop edi
pop ebp
ret
lea ebx, [ebp + 0x14c]
jmp 0x4931b7
mov ecx, dword [esp + 0x20]
mov dword [ecx + 0x24], ebx
mov dword [esp + 8], str.SFTP_READ_error
mov dword [esp + 4], 0xffffffe1
mov eax, dword [esp + 0x28]
mov dword [esp], eax
call fcn.0049ffcc
jmp 0x493235
mov dword [ebp + 0x130], 0
mov eax, dword [esp + 0x48]
jmp 0x4932d9
mov dword [esp + 0x34], 0x100000
jmp 0x492f75
mov ecx, dword [esp + 0x20]
mov dword [ecx + 0x54], 3
jmp 0x493235
mov edi, dword [esp + 0x38]
jmp 0x493152
mov ebx, dword [esp + 0x78]
cmp ebx, eax
ja 0x49348c
mov esi, dword [ebp + 0x130]
sub esi, eax
add esi, dword [ebp + 0x12c]
mov edi, dword [esp + 0x74]
mov ecx, ebx
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 0x134]
sub ecx, ebx
mov dword [ebp + 0x134], ecx
xor edx, edx
add dword [ebp + 0x118], ebx
adc dword [ebp + 0x11c], edx
test ecx, ecx
je 0x493490
mov eax, ebx
jmp 0x493235
mov ecx, dword [esp + 0x28]
mov dword [esp + 4], ecx
mov dword [esp], eax
mov dword [esp + 0x18], edx
call dword [ecx + 0xc]
mov edx, dword [esp + 0x18]
jmp 0x493300
mov dword [esp + 0x1c], 0
jmp 0x492fe8
mov ebx, eax
jmp 0x493424
mov edx, dword [esp + 0x28]
mov dword [esp + 4], edx
mov eax, dword [ebp + 0x12c]
mov dword [esp], eax
call dword [edx + 0xc]
mov dword [ebp + 0x12c], 0
mov eax, ebx
jmp 0x493235
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov eax, dword [esp + 0x3c]
mov dword [esp + 4], eax
mov edx, dword [esp + 0x20]
mov eax, dword [edx]
mov dword [esp], eax
call fcn.00497a94
test eax, eax
je 0x49300a
jmp 0x493235
mov edx, dword [esp + 0x20]
mov dword [edx + 0x54], 5
jmp 0x493235
mov dword [esp + 8], str.SFTP_Protocol_badness
mov dword [esp + 4], 0xffffffe1
mov edx, dword [esp + 0x28]
mov dword [esp], edx
call fcn.0049ffcc
jmp 0x493235
mov eax, edx
jmp 0x493235
mov dword [esp + 8], str.FXP_READ_response_too_big
mov dword [esp + 4], 0xffffffe1
mov ecx, dword [esp + 0x28]
mov dword [esp], ecx
call fcn.0049ffcc
jmp 0x493235
mov eax, 0xffffffd9
jmp 0x493261