-
Bug
-
Resolution: Duplicate
-
P2: Important
-
None
-
6.9
-
None
-
Qt 6.9
macOS, Linux, and Windows
PySide/Qt for Python is also affected
Some servers and systems provided by third parties are not standards compliant and only accept headers like Authorization when capitalized in specific ways. Unfortunately this seems common for network controlled devices that often don't receive firmware updates to bring them into compliance.
In earlier versions of Qt this was a non-issue, we could use setRawHeader() to force a specific casing as necessary.
Now, when we use setRawHeader() the header name is converted into a HeaderName, which uses the HeaderName(QAnyStringView name) constructor and that forcefully normalizes the name using normalizedName(QAnyStringView name). This also affects using QHttpHeaders directly with the append, insert, etc. methods since they also use the HeaderName(QAnyStringView name) constructor.
For the most cases this seems very appropriate, but I also think there should be a way to bypass the normalization on demand. Perhaps via an attribute on QNetworkRequest or flag on QHttpHeaders that could be set.
I haven't been able to find any documentation or code that seems to enable this and it is blocking me from upgrading.
- duplicates
-
QTBUG-137203 Request to add an option for case sensitivity in QNetworkRequest::setRawHeader().
-
- Open
-