12 Commits

Author SHA1 Message Date
Alessandro Pasotti
53a14e2402 Server: better formatting when logging request params 2019-02-15 12:10:24 +01:00
Alessandro Pasotti
2641b3fe20 Allow REQUEST_BODY in tests even if QGISDEBUG is off 2019-01-22 12:14:42 +01:00
Alessandro Pasotti
691176b39b Fix POST requests for QGIS server
Followup https://github.com/qgis/QGIS/pull/8830 that fixed
a regression with rewritten urls in the server, unfortunately
my original solution introduced a side-effect on the POST
request, with the new approach I'm introducing a new method
to retrieve the URL as seen by the web server: by default
this is the same URL seen by QGIS server, but in case
a rewrite module made some changes, the original URL will
be used as a base URL if not overridden by a config setting.

This PR comes with an extended set of tests that should
cover both (rewritten and unrewritten) cases for GET and
POST and for WFS/WFS/WCS and WMTS.
2019-01-21 19:15:49 +01:00
Alessandro Pasotti
4d609ff46f
Merge pull request #8830 from elpaso/bugfix-server-fcgi-rewritten-uri
[server] Use REQUEST_URI as default URL for FCGI requests
2019-01-11 15:58:26 +01:00
Alessandro Pasotti
70466320a8 Typo (old one) 2019-01-10 11:18:03 +01:00
Alessandro Pasotti
cd763bccf2 Update override comment with a full explanation of what it does
Also checks for original url emptiness before returning it.
2019-01-10 10:58:27 +01:00
Nyall Dawson
43df43fb32 Fix build 2019-01-10 10:25:08 +10:00
Blottiere Paul
fcc3996ddf Remove unnecessary #include in server 2019-01-10 07:50:02 +10:00
Alessandro Pasotti
bb9ec39fa6 [server] Fix URL rewrite from fcgi servers
The URL exposed in the XML documents generated
by the server was wrong because instead of
using the original URL (from REQUEST_URI)
the rewritten query string (from QUERY_STRING)
was applied to the internal mUrl variable.

This patch also adds some tests for the
FCGI request, that handle most common
scenarios with bot rewritten and not
rewritten URLs.

QgsFcgiServerRequest is now exposed to
Python mainly for testability purposes.
2019-01-09 18:46:32 +01:00
Denis Rouzaud
3dc3d9d1b2 unite QgsMessageLog::Level and QgsMessageBar::MessageLevel in Qgis::MessageLevel
make enum items lower case
remove unused QgsMessageLog::None and All
2018-02-06 08:56:40 -04:00
Nyall Dawson
92af1dacaf Replace default constructors/destructors with = default 2017-10-01 06:52:14 +10:00
Alessandro Pasotti
76d8650358 [server] Moved QgsFcgiServerRequest into its own header and cpp file 2017-04-29 12:12:49 +02:00