usbmuxd icon indicating copy to clipboard operation
usbmuxd copied to clipboard

USBMUX fails to send TCP ACK when bombarded with data

Open ecnepsnai opened this issue 7 years ago • 2 comments

Almost certainly related to #19 I have observed an issue where USBMUXd will fail to send back TCP ACKs when bombarded with data from the iOS device faster than the server application can read from it.

We're able to reproduce this issue 100% of the time when sending 100MB of data, broken down into 4KB chunks. The iOS device will write as fast as it can, up until its output buffer fills up. Examining the code I see two potential issues:

https://github.com/libimobiledevice/usbmuxd/blob/master/src/device.c#L328

If the ib_size is 0, shouldn't we be sending an ACK here?

https://github.com/libimobiledevice/usbmuxd/blob/master/src/device.c#L672

Shouldn't the ACK be the sequence + 1?

ecnepsnai avatar Aug 24 '16 05:08 ecnepsnai

Still an issue?

Blefish avatar May 03 '18 11:05 Blefish

Not sure if the two mentioned things in the code are really a problem, but there is definitely a problem with ACKs going on as mentioned in #19. Fix is being tested :)

nikias avatar May 07 '18 00:05 nikias