summaryrefslogtreecommitdiffstats
path: root/src/network/access/qhttpthreaddelegate.cpp
diff options
context:
space:
mode:
authorRichard Moore <rich@kde.org>2013-02-10 17:06:34 +0000
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-02-19 21:37:32 +0100
commit5ebc8d3663df5860f13ec9fe0bf4cce1cb37111b (patch)
tree3f953c8f37728cd6eaf001428fe9c6c54d160c9b /src/network/access/qhttpthreaddelegate.cpp
parent7898080ca78ceec15163976390979631fcbd178d (diff)
Add an encrypted() signal to QNetworkAccessManager and QNetworkReply.
Add an encrypted signal to QNAM and QNetworkReply to allow applications to perform additional checks on the certificate chain beyond those done as part of the standard SSL validation. This allows things like certificate change notification to be implemented for QNAM as they can be for QSSLSocket currently. Change-Id: I693e3e6fec8b7040379b7e7f1f819550e6b2617f Reviewed-by: Peter Hartmann <phartmann@rim.com>
Diffstat (limited to 'src/network/access/qhttpthreaddelegate.cpp')
-rw-r--r--src/network/access/qhttpthreaddelegate.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/network/access/qhttpthreaddelegate.cpp b/src/network/access/qhttpthreaddelegate.cpp
index 117265dbfb..a2cee48b22 100644
--- a/src/network/access/qhttpthreaddelegate.cpp
+++ b/src/network/access/qhttpthreaddelegate.cpp
@@ -315,6 +315,7 @@ void QHttpThreadDelegate::startRequest()
connect(httpReply,SIGNAL(readyRead()), this, SLOT(readyReadSlot()));
connect(httpReply,SIGNAL(dataReadProgress(qint64,qint64)), this, SLOT(dataReadProgressSlot(qint64,qint64)));
#ifndef QT_NO_SSL
+ connect(httpReply,SIGNAL(encrypted()), this, SLOT(encryptedSlot()));
connect(httpReply,SIGNAL(sslErrors(QList<QSslError>)), this, SLOT(sslErrorsSlot(QList<QSslError>)));
#endif
@@ -589,6 +590,14 @@ void QHttpThreadDelegate::cacheCredentialsSlot(const QHttpNetworkRequest &reques
#ifndef QT_NO_SSL
+void QHttpThreadDelegate::encryptedSlot()
+{
+ if (!httpReply)
+ return;
+
+ emit encrypted();
+}
+
void QHttpThreadDelegate::sslErrorsSlot(const QList<QSslError> &errors)
{
if (!httpReply)