OGC API: Feature Creation Request Fails When Location Header is in Lowercase #61729
Open
1 of 2 tasks
Labels
Bug
Either a bug report, or a bug fix. Let's hope for the latter!
What is the bug or the crash?
Hello!
I'm using the OGC API to facilitate communication between a REST API service and QGIS standalone.
During the feature creation process, QGIS sends a request to create a feature, and the service responds with a 204 No Content status along with a Location header containing the URL of the created feature.
However, this response undergoes additional processing by a server middleware, which conforms to HTTP/2 specifications by converting all response headers to lowercase, as stated in RFC 7540 Section 8.1.2.
After this conversion, QGIS displays an error message, indicating that the feature was not created.
Issue in Source Code:
if ( headerKeyValue.first == QByteArray( "Location" ) )
This logic expects the Location header to be camel case, meaning it does not properly handle headers in lowercase, as required by HTTP/2.
Requested Fix:
To ensure compatibility with HTTP/2, please modify the response header handling so that case is ignored when checking for the Location header.
Steps to reproduce the issue
Versions
3.34.14
Supported QGIS version
New profile
Additional context
No response
The text was updated successfully, but these errors were encountered: