[Koha-bugs] [Bug 24719] C4::Context::set_remote_address() prevents file upload for non-Plack Koha

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Mar 6 08:35:15 CET 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24719

--- Comment #19 from Marcel de Rooy <m.de.rooy at rijksmuseum.nl> ---
Created attachment 100211
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=100211&action=edit
Bug 24719: Remove use of CGI object in C4::Context::set_remote_address()

This patch replaces the CGI "http" object method with its equivalent
class method, which doesn't require object instantiation and thus skips
global initialization and premature handling of the incoming HTTP request.

Test plan:
0. Disable Plack if it is enabled
1. Set koha_trusted_proxies in koha-conf.xml to 1.1.1.1
2. Clear Memcached
3. Try to upload MARCXML file to /cgi-bin/koha/tools/stage-marc-import.pl
4. Note that form below "Upload progress" never appears and errors show
in browser console
5. Apply the patch
6. Try to upload MARCXML file to /cgi-bin/koha/tools/stage-marc-import.pl
7. Note that form appears below "Upload progress"

Signed-off-by: Nick Clemens <nick at bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy at rijksmuseum.nl>
See comment18 on Bugzilla.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list