You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We've encountered php processes (using php-fpm) that are running indefinitely due to an infinite loop in AssemblyStream.php's stream_read(). We were able to identify this by starting an upload, corrupting a chunk after it started the assembly (this is to bypass the checksum matching) and inspecting PHP processes with strace -s 1024 -p <pid>.
It does appear to be an edge case, but we have multiple processes stuck in this loop in our production environment.
Steps to reproduce
(these are the steps I used to replicate it)
Start an upload via the web interface
Once the upload is complete and starts assembling, truncate one of the chunks to 0 bytes
Watch the upload never complete because it is stuck in a read loop.
Expected behaviour
If stream_read() encounters an invalid chunk, throw an exception and exit the loop.
Actual behaviour
stream_read() continually attempts to read the invalid chunk and enters an infinite loop.
Server configuration
Operating system: RHEL7
Web server: Apache 2.4.6
Database: MariaDB 10.0.28
PHP version: PHP-FPm 7.0.30
ownCloud version: 10.0.3
Updated from an older ownCloud or fresh install: Updated
Where did you install ownCloud from: TAR on the ownCloud website
Signing status (ownCloud 9.0 and above):Integrity checker has been disabled. Integrity cannot be verified.
Login as admin user into your ownCloud and access
http://example.com/index.php/settings/integrity/failed
paste the results into https://gist.github.com/ and puth the link here.
Possibly related issues are #10819 ([master] createUser infinite loop error), #4365 (Infinite Loop on share Upload), #5462 (Memory Limit Exhausted / Infinite Loop), #29708 (Case sensitive usernames when logging in with an app password via webdav), and #33485 (Configured share_folder is removed from filecache when storage is unavailable).
We've encountered php processes (using php-fpm) that are running indefinitely due to an infinite loop in AssemblyStream.php's
stream_read()
. We were able to identify this by starting an upload, corrupting a chunk after it started the assembly (this is to bypass the checksum matching) and inspecting PHP processes withstrace -s 1024 -p <pid>
.It does appear to be an edge case, but we have multiple processes stuck in this loop in our production environment.
Steps to reproduce
(these are the steps I used to replicate it)
Expected behaviour
If stream_read() encounters an invalid chunk, throw an exception and exit the loop.
Actual behaviour
stream_read() continually attempts to read the invalid chunk and enters an infinite loop.
Server configuration
Operating system: RHEL7
Web server: Apache 2.4.6
Database: MariaDB 10.0.28
PHP version: PHP-FPm 7.0.30
ownCloud version: 10.0.3
Updated from an older ownCloud or fresh install: Updated
Where did you install ownCloud from: TAR on the ownCloud website
Signing status (ownCloud 9.0 and above):
Integrity checker has been disabled. Integrity cannot be verified.
The content of config/config.php:
List of activated apps:
Are you using external storage, if yes which one: No
Are you using encryption: No
Are you using an external user-backend, if yes which one: No
The text was updated successfully, but these errors were encountered: