Commit b9041499 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Merge branch 'release/20.04'

parents 0bafefdc 18817bea
......@@ -31,7 +31,7 @@ include(ECMAddAppIcon)
include(ECMQtDeclareLoggingCategory)
# Do NOT add quote
set(KDEPIM_DEV_VERSION beta1)
set(KDEPIM_DEV_VERSION rc)
# add an extra space
if(DEFINED KDEPIM_DEV_VERSION)
......@@ -46,7 +46,7 @@ set(KPIMTEXTEDIT_LIB_VERSION "5.14.40")
set(KDEPIM_LIB_VERSION "${PIM_VERSION}")
set(KDEPIM_LIB_SOVERSION "5")
set(LIBKSIEVE_LIB_VERSION "5.14.40")
set(LIBKSIEVE_LIB_VERSION "5.14.41")
set(PIMCOMMON_LIB_VERSION "5.14.40")
set(KIMAP_LIB_VERSION "5.14.40")
......
......@@ -113,7 +113,7 @@ void ImportImapSettingsAkonadiCheckJobTest::shouldImportSieveSettings_data()
settings.sieveImapAccountSettings.setServerName(QStringLiteral("bla.foo.com"));
settings.sieveImapAccountSettings.setPort(143);
settings.sieveImapAccountSettings.setPassword(QStringLiteral("password_imap"));
settings.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
settings.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
settings.sieveSettings.userName = QStringLiteral("foo@foo.com");
settings.sieveSettings.serverName = QStringLiteral("bla.foo.com");
......@@ -127,7 +127,7 @@ void ImportImapSettingsAkonadiCheckJobTest::shouldImportSieveSettings_data()
settings2.sieveImapAccountSettings.setServerName(QStringLiteral("bla.foo.com"));
settings2.sieveImapAccountSettings.setPort(143);
settings2.sieveImapAccountSettings.setPassword(QStringLiteral("password_imap"));
settings2.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
settings2.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
settings2.sieveSettings.userName = QStringLiteral("b");
settings2.sieveSettings.serverName = QStringLiteral("bla.foo.com"); //TODO
settings2.sieveSettings.password = QStringLiteral("password_custom_sieve_imap");
......@@ -154,7 +154,7 @@ void ImportImapSettingsAkonadiCheckJobTest::shouldImportSieveSettings_data()
settings4.sieveImapAccountSettings.setServerName(QStringLiteral("bla.foo.com"));
settings4.sieveImapAccountSettings.setPort(143);
settings4.sieveImapAccountSettings.setAuthenticationType(static_cast<KSieveUi::SieveImapAccountSettings::AuthenticationMode>(3));
settings4.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
settings4.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
settings4.sieveImapAccountSettings.setPassword(QStringLiteral("password_imap"));
settings4.sieveSettings.userName = QStringLiteral("b");
settings4.sieveSettings.password = QStringLiteral("password_custom_sieve_imap");
......@@ -168,7 +168,7 @@ void ImportImapSettingsAkonadiCheckJobTest::shouldImportSieveSettings_data()
settings5.sieveImapAccountSettings.setServerName(QStringLiteral("bla.foo.com"));
settings5.sieveImapAccountSettings.setPort(143);
settings5.sieveImapAccountSettings.setAuthenticationType(static_cast<KSieveUi::SieveImapAccountSettings::AuthenticationMode>(3));
settings5.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SslV3_1);
settings5.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SSLorTLS);
settings5.sieveImapAccountSettings.setPassword(QStringLiteral("password_imap"));
settings5.sieveSettings.userName = QStringLiteral("b");
settings5.sieveSettings.serverName = QStringLiteral("bla.foo.com"); //TODO
......
......@@ -124,7 +124,7 @@ void ImportImapSettingsThunderbirdCheckJobTest::shouldImportSieveSettings_data()
SieveEditorUtil::SieveServerConfig settings;
settings.sieveImapAccountSettings.setUserName(QStringLiteral("bla@kde.org"));
settings.sieveImapAccountSettings.setServerName(QStringLiteral("sever.foo.org"));
settings.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SslV3_1);
settings.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SSLorTLS);
settings.sieveImapAccountSettings.setAuthenticationType(KSieveUi::SieveImapAccountSettings::Plain);
settings.sieveImapAccountSettings.setPort(993);
settings.sieveSettings.userName = QStringLiteral("bla@kde.org");
......@@ -138,7 +138,7 @@ void ImportImapSettingsThunderbirdCheckJobTest::shouldImportSieveSettings_data()
SieveEditorUtil::SieveServerConfig settings;
settings.sieveImapAccountSettings.setUserName(QStringLiteral("bla@kde.org"));
settings.sieveImapAccountSettings.setServerName(QStringLiteral("sever.foo.org"));
settings.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
settings.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
settings.sieveImapAccountSettings.setAuthenticationType(KSieveUi::SieveImapAccountSettings::GSSAPI);
settings.sieveImapAccountSettings.setPort(993);
settings.sieveSettings.userName = QStringLiteral("bla@kde.org");
......
......@@ -89,14 +89,14 @@ bool ImportImapSettingsAkonadiCheckJob::importSettings(const QString &directory,
static_cast<int>(KSieveUi::SieveImapAccountSettings::Plain))));
const QString encryption = networkGroup.readEntry(QStringLiteral("Safety"));
if (encryption == QLatin1String("SSL")) {
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SslV3_1);
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SSLorTLS);
} else if (encryption == QLatin1String("STARTTLS")) {
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
} else if (encryption == QLatin1String("None")) {
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::Unencrypted);
} else if (encryption.isEmpty()) { //Default value
if (isKolabSettings) {
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
} else {
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::Unencrypted);
}
......
......@@ -214,11 +214,11 @@ void ImportImapSettingsThunderbirdCheckJob::encryption(SieveEditorUtil::SieveSer
break;
case 2:
//STARTTLS
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::TlsV1);
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::STARTTLS);
break;
case 3:
//SSL/TLS
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SslV3_1);
config.sieveImapAccountSettings.setEncryptionMode(KSieveUi::SieveImapAccountSettings::EncryptionMode::SSLorTLS);
break;
default:
qCDebug(SIEVEEDITOR_LOG) << "Unknown encryption mode " << socketType;
......
......@@ -89,8 +89,8 @@ ServerSieveSettings::ServerSieveSettings(QWidget *parent)
ui->testProgress->hide();
ui->safeImapGroup->setId(ui->noRadio, KSieveUi::SieveImapAccountSettings::Unencrypted);
ui->safeImapGroup->setId(ui->sslRadio, KSieveUi::SieveImapAccountSettings::AnySslVersion);
ui->safeImapGroup->setId(ui->tlsRadio, KSieveUi::SieveImapAccountSettings::TlsV1);
ui->safeImapGroup->setId(ui->sslRadio, KSieveUi::SieveImapAccountSettings::SSLorTLS);
ui->safeImapGroup->setId(ui->tlsRadio, KSieveUi::SieveImapAccountSettings::STARTTLS);
connect(ui->testButton, &QPushButton::pressed, this, &ServerSieveSettings::slotTest);
......@@ -352,10 +352,10 @@ void ServerSieveSettings::slotEncryptionRadioChanged()
{
switch (ui->safeImapGroup->checkedId()) {
case KSieveUi::SieveImapAccountSettings::Unencrypted:
case KSieveUi::SieveImapAccountSettings::TlsV1:
case KSieveUi::SieveImapAccountSettings::STARTTLS:
ui->imapPort->setValue(143);
break;
case KSieveUi::SieveImapAccountSettings::AnySslVersion:
case KSieveUi::SieveImapAccountSettings::SSLorTLS:
ui->imapPort->setValue(993);
break;
default:
......@@ -382,11 +382,11 @@ void ServerSieveSettings::slotSafetyChanged()
qCDebug(SIEVEEDITOR_LOG) << "safeImapGroup: unencrypted";
protocols = mServerTest->normalProtocols();
break;
case KSieveUi::SieveImapAccountSettings::AnySslVersion:
case KSieveUi::SieveImapAccountSettings::SSLorTLS:
protocols = mServerTest->secureProtocols();
qCDebug(SIEVEEDITOR_LOG) << "safeImapGroup: SSL";
break;
case KSieveUi::SieveImapAccountSettings::TlsV1:
case KSieveUi::SieveImapAccountSettings::STARTTLS:
protocols = mServerTest->tlsProtocols();
qCDebug(SIEVEEDITOR_LOG) << "safeImapGroup: starttls";
break;
......
......@@ -122,7 +122,7 @@ QVector<SieveEditorUtil::SieveServerConfig> SieveEditorUtil::readServerSieveConf
sieve.sieveImapAccountSettings.setAuthenticationType(
static_cast<KSieveUi::SieveImapAccountSettings::AuthenticationMode>(group.readEntry(QStringLiteral("ImapAuthentication"), static_cast<int>(KSieveUi::SieveImapAccountSettings::Plain))));
sieve.sieveImapAccountSettings.setEncryptionMode(
static_cast<KSieveUi::SieveImapAccountSettings::EncryptionMode>(group.readEntry(QStringLiteral("ImapEncrypt"), static_cast<int>(KSieveUi::SieveImapAccountSettings::TlsV1))));
static_cast<KSieveUi::SieveImapAccountSettings::EncryptionMode>(group.readEntry(QStringLiteral("ImapEncrypt"), static_cast<int>(KSieveUi::SieveImapAccountSettings::SSLorTLS))));
if (!sieve.sieveImapAccountSettings.userName().isEmpty()
&& !sieve.sieveImapAccountSettings.serverName().isEmpty()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment