• Skip to content
  • Skip to link menu
KDE 4.6 API Reference
  • KDE API Reference
  • kdelibs
  • KDE Home
  • Contact Us
 

KDECore

ksslcertificatemanager.h

Go to the documentation of this file.
00001 /* This file is part of the KDE project
00002  *
00003  * Copyright (C) 2007, 2008, 2010 Andreas Hartmetz <ahartmetz@gmail.com>
00004  *
00005  * This library is free software; you can redistribute it and/or
00006  * modify it under the terms of the GNU Library General Public
00007  * License as published by the Free Software Foundation; either
00008  * version 2 of the License, or (at your option) any later version.
00009  *
00010  * This library is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013  * Library General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU Library General Public License
00016  * along with this library; see the file COPYING.LIB.  If not, write to
00017  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00018  * Boston, MA 02110-1301, USA.
00019  */
00020 
00021 #ifndef _INCLUDE_KSSLCERTIFICATEMANAGER_H
00022 #define _INCLUDE_KSSLCERTIFICATEMANAGER_H
00023 
00024 #include "ktcpsocket.h"
00025 
00026 #include <QtNetwork/QSslCertificate>
00027 #include <QtNetwork/QSslError>
00028 #include <QtCore/QString>
00029 #include <QtCore/QStringList>
00030 #include <QtCore/QDate>
00031 
00032 class QSslCertificate;
00033 class KSslCertificateRulePrivate;
00034 class KSslCertificateManagerPrivate;
00035 
00036 //### document this... :/
00037 class KDECORE_EXPORT KSslCertificateRule
00038 {
00039 public:
00040     KSslCertificateRule(const QSslCertificate &cert = QSslCertificate(),
00041                         const QString &hostName = QString());
00042     KSslCertificateRule(const KSslCertificateRule &other);
00043     ~KSslCertificateRule();
00044     KSslCertificateRule &operator=(const KSslCertificateRule &other);
00045 
00046     QSslCertificate certificate() const;
00047     QString hostName() const;
00048     void setExpiryDateTime(const QDateTime &dateTime);
00049     QDateTime expiryDateTime() const;
00050     void setRejected(bool rejected);
00051     bool isRejected() const;
00052     bool isErrorIgnored(KSslError::Error error) const;
00053     void setIgnoredErrors(const QList<KSslError::Error> &errors);
00054     void setIgnoredErrors(const QList<KSslError> &errors);
00055     QList<KSslError::Error> ignoredErrors() const;
00056     QList<KSslError::Error> filterErrors(const QList<KSslError::Error> &errors) const;
00057     QList<KSslError> filterErrors(const QList<KSslError> &errors) const;
00058 private:
00059     KSslCertificateRulePrivate *const d;
00060 };
00061 
00062 
00063 //### document this too... :/
00064 class KDECORE_EXPORT KSslCertificateManager
00065 {
00066 public:
00067     static KSslCertificateManager *self();
00068     void setRule(const KSslCertificateRule &rule);
00069     void clearRule(const KSslCertificateRule &rule);
00070     void clearRule(const QSslCertificate &cert, const QString &hostName);
00071     KSslCertificateRule rule(const QSslCertificate &cert, const QString &hostName) const;
00072 
00073     // do not use, it does nothing!
00074 #ifndef KDE_NO_DEPRECATED
00075     KDE_DEPRECATED void setRootCertificates(const QList<QSslCertificate> &rootCertificates)
00076         { Q_UNUSED(rootCertificates) }
00077 #endif
00078     // use caCertificates() instead
00079 #ifndef KDE_NO_DEPRECATED
00080     KDE_DEPRECATED QList<QSslCertificate> rootCertificates() const
00081         { return caCertificates(); }
00082 #endif
00083 
00084     QList<QSslCertificate> caCertificates() const;
00085 
00086     static QList<KSslError> nonIgnorableErrors(const QList<KSslError> &);
00087     static QList<KSslError::Error> nonIgnorableErrors(const QList<KSslError::Error> &);
00088 
00089 private:
00090     friend class KSslCertificateManagerContainer;
00091     friend class KSslCertificateManagerPrivate;
00092     KSslCertificateManager();
00093     ~KSslCertificateManager();
00094 
00095     KSslCertificateManagerPrivate *const d;
00096 };
00097 
00098 
00099 #endif

KDECore

Skip menu "KDECore"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.7.3
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal