Details
-
Bug
-
Resolution: Fixed
-
P3: Somewhat important
-
5.15.0
-
None
-
-
5
-
42732d73d (dev)
-
Foundation Sprint 109, Foundation Sprint 110, Foundation Sprint 111, Foundation Sprint 112
Description
The signal callbackDataReceived is never emitted in QOAuthHttpServerReplyHandler. This is normally not used because callbackReceived is a better signal to use. But in some cases, like GitLab oauth2 provider, the callback URL is malformatted (use a '#' instead of '?' for the query parameters).
This should be easy to fix with the following trivial patch. (not tested)
--- a/src/oauth/qoauthhttpserverreplyhandler.cpp +++ b/src/oauth/qoauthhttpserverreplyhandler.cpp @@ -114,6 +114,7 @@ void QOAuthHttpServerReplyHandlerPrivate::_q_answerClient(QTcpSocket *socket, co if (!url.path().startsWith(QLatin1String("/") + path)) { qCWarning(lcReplyHandler, "Invalid request: %s", qPrintable(url.toString())); } else { + Q_EMIT q->callbackDataReceived(url.toEncoded()); QVariantMap receivedData; const QUrlQuery query(url.query()); const auto items = query.queryItems();
Attachments
For Gerrit Dashboard: QTBUG-85377 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
568359,2 | Emit callbackDataReceived signal | dev | qt/qtnetworkauth | Status: MERGED | +2 | +1 |