17 #ifndef QGSAUTHCONFIG_H 18 #define QGSAUTHCONFIG_H 24 #include <QSslCertificate> 83 bool isValid(
bool validateid =
false )
const;
89 const QString configString()
const;
94 void loadConfigString(
const QString& configstr );
124 int removeConfig(
const QString &key );
143 bool hasConfig(
const QString &key )
const;
156 static bool uriToResource(
const QString &accessurl,
QString *resource,
bool withpath =
false );
167 static const QString mConfigSep;
168 static const QString mConfigKeySep;
169 static const QString mConfigListSep;
171 static const int mConfigVersion;
177 #ifndef QT_NO_OPENSSL 205 const QString &keyPass = QString::null,
214 const QString &bundlepass = QString::null );
220 bool isValid()
const;
233 void setClientKey(
const QSslKey &certkey );
346 const QString configString()
const;
358 QSsl::SslProtocol mSslProtocol;
361 QSslSocket::PeerVerifyMode mSslPeerVerifyMode;
362 int mSslPeerVerifyDepth;
369 #endif // QGSAUTHCONFIG_H void setUri(const QString &uri)
QgsStringMap configMap() const
Get extended configuration, mapped to key/value pairs of QStrings.
Storage set for constructed SSL certificate, key, associated with an authentication config...
void setId(const QString &id)
Set auth config ID.
int sslPeerVerifyDepth() const
Number or SSL client's peer to verify in connections.
void setCaChain(const QList< QSslCertificate > &cachain)
Set chain of Certificate Authorities for client certificate.
bool operator==(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)
bool operator!=(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)
int qtVersion() const
Qt version when the configuration was made (SSL protocols may differ)
const QSslKey clientCertKey() const
Private key object.
Configuration container for SSL server connection exceptions or overrides.
~QgsAuthConfigSslServer()
void setClientCert(const QSslCertificate &cert)
Set client certificate object.
const QSslCertificate clientCert() const
Client certificate object.
QSsl::SslProtocol sslProtocol() const
SSL server protocol to use in connections.
QSslSocket::PeerVerifyMode sslPeerVerifyMode() const
SSL client's peer verify mode to use in connections.
void setSslPeerVerifyMode(QSslSocket::PeerVerifyMode mode)
Set SSL client's peer verify mode to use in connections.
Storage set for PKI bundle: SSL certificate, key, optional CA cert chain.
QHash< QString, QgsAuthMethodConfig > QgsAuthMethodConfigsMap
void setVersion(int version)
Set version of the configuration (used for future upgrading)
const QSslKey clientKey() const
Private key object.
void setMethod(const QString &method)
Configuration storage class for authentication method configurations.
const QString name() const
Get name of configuration.
const QString sslHostPort() const
Server host:port string.
void setClientCertKey(const QSslKey &certkey)
Set private key object.
const QList< QSslError::SslError > sslIgnoredErrorEnums() const
SSL server errors (as enum list) to ignore in connections.
void setConfig(const QgsAuthMethodConfig &config)
Set authentication method configuration.
void setSslHostPort(const QString &hostport)
Set server host:port string.
int version() const
Get version of the configuration.
const QSslCertificate clientCert() const
Client certificate object.
void setSslProtocol(QSsl::SslProtocol protocol)
Set SSL server protocol to use in connections.
const QSslCertificate sslCertificate() const
Server certificate object.
void setSslIgnoredErrorEnums(const QList< QSslError::SslError > &errors)
Set SSL server errors (as enum list) to ignore in connections.
void setVersion(int version)
Set version of the configuration.
void setQtVersion(int version)
Set Qt version when the configuration was made (SSL protocols may differ)
const QList< QSslCertificate > caChain() const
Chain of Certificate Authorities for client certificate.
QString method() const
Textual key of the associated authentication method.
const QString uri() const
A URI to auto-select a config when connecting to a resource.
void setSslPeerVerifyDepth(int depth)
Set number or SSL client's peer to verify in connections.
void clearConfigMap()
Clear all configs.
int version() const
Version of the configuration (used for future upgrading)
void setName(const QString &name)
Set name of configuration.
void setSslCertificate(const QSslCertificate &cert)
Set server certificate object.
void setConfigMap(const QgsStringMap &map)
Set extended configuration map.
bool isNull(const QVariant &v)
const QString id() const
Get 'authcfg' 7-character alphanumeric ID of the config.
const QgsAuthMethodConfig config() const
Authentication method configuration.