[Bug 40954] New: PLACK-ERROR: End of stream encountered while parsing preamble
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 Bug ID: 40954 Summary: PLACK-ERROR: End of stream encountered while parsing preamble Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: m.de.rooy@rijksmuseum.nl QA Contact: testopia@bugs.koha-community.org Found this in the plack-error.log on a 24.11 install: End of stream encountered while parsing preamble at /usr/share/perl5/HTTP/Entity/Parser/MultiPart.pm line 157. Grepping for HTTP::Entity::Parser::MultiPart did not give any results. Anyone have an idea? -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 --- Comment #1 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Joubu: the error comes from /usr/share/perl5/HTTP/MultiPartParser.pm: $finish && $on_error->(q/End of stream encountered while parsing preamble/); -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 --- Comment #2 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Marcel de Rooy from comment #1)
Joubu: the error comes from /usr/share/perl5/HTTP/MultiPartParser.pm: $finish && $on_error->(q/End of stream encountered while parsing preamble/);
HTTP::MultiPartParser This class provides a low-level API for processing MultiPart MIME data streams conforming to MultiPart types as defined in RFC 2616. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dcook@prosentient.com.au --- Comment #3 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Saw a few coming by again. Tracing them down to 'hacking stuff' like: 177.135.23.55 - - [29/Oct/2025:17:19:52 +0000] "POST /admin/categories.php/login.php?cPath=&action=new_product_preview HTTP/1.1" 500 21 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" "library.rijksmuseum.nl:443" "-" 177.135.23.55 - - [29/Oct/2025:17:19:52 +0000] "GET /includes/configure.php HTTP/1.1" 404 28935 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" "library.rijksmuseum.nl:443" "-" 177.135.23.55 - - [29/Oct/2025:17:19:53 +0000] "POST /admin/banner_manager.php/login.php?action=insert HTTP/1.1" 500 21 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" "library.rijksmuseum.nl:443" "-" 177.135.23.55 - - [29/Oct/2025:17:19:53 +0000] "POST /cgi-bin/admin/categories.php/login.php?cPath=&action=new_product_preview HTTP/1.1" 404 28935 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" "library.rijksmuseum.nl:443" "-" Not sure why the first and third url results in 500 21? But the fourth url in 404 28935, coming from errors/404.pl. How does an unexisting php trigger a 500 ? Also I am wondering if we should pass such Apache errors to Plack? It takes just a few hundred bytes to say Not found in about 50 ms with a trivial ErrorDocument but it takes 40K and 500ms to go to errors/404 or 500.pl in Plack. Shouldnt we reserve the Plack responses for Plack requests (so real perl ones)? -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 --- Comment #4 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- The above is from the nginx log. Plack.log just says: 177.135.23.55 - - [29/Oct/2025:18:19:52 +0100] "GET errors/500.pl HTTP/1.1" 500 21 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" 177.135.23.55 - - [29/Oct/2025:18:19:53 +0100] "GET errors/500.pl HTTP/1.1" 500 21 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" And Apache: myclone.rijkskoha.nl:80 177.135.23.55 - - [29/Oct/2025:18:19:52 +0100] "POST /admin/categories.php/login.php?cPath=&action=new_product_preview HTTP/1.0" 500 210 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 --- Comment #5 from David Cook <dcook@prosentient.com.au> --- (In reply to Marcel de Rooy from comment #3)
Also I am wondering if we should pass such Apache errors to Plack? It takes just a few hundred bytes to say Not found in about 50 ms with a trivial ErrorDocument but it takes 40K and 500ms to go to errors/404 or 500.pl in Plack. Shouldnt we reserve the Plack responses for Plack requests (so real perl ones)?
I do think about that sometimes. It also takes up valuable Starman process time in general. If you've got some bots sending lots of requests that generate 404s, it doesn't really make sense to hammer your Starman with requests for 404.pl. In the past, I've thought about generating static HTML files which could be served from the DocumentRoot, so that Starman isn't being touched and Apache can just do what it does best. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 --- Comment #6 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Opened bug 41154 for the ErrorDocument of Apache. This bug keeps focused on the preamble crash. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40954 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=41154 -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org