diff --git a/src/com/fsck/k9/preferences/Settings.java b/src/com/fsck/k9/preferences/Settings.java index b4dd8ef41..22ed1cb1f 100644 --- a/src/com/fsck/k9/preferences/Settings.java +++ b/src/com/fsck/k9/preferences/Settings.java @@ -35,7 +35,7 @@ public class Settings { * * @see SettingsExporter */ - public static final int VERSION = 32; + public static final int VERSION = 33; public static Map validate(int version, Map> settings, diff --git a/src/com/fsck/k9/preferences/SettingsExporter.java b/src/com/fsck/k9/preferences/SettingsExporter.java index b09ef359d..64a9fbd6c 100644 --- a/src/com/fsck/k9/preferences/SettingsExporter.java +++ b/src/com/fsck/k9/preferences/SettingsExporter.java @@ -61,6 +61,7 @@ public class SettingsExporter { public static final String CONNECTION_SECURITY_ELEMENT = "connection-security"; public static final String AUTHENTICATION_TYPE_ELEMENT = "authentication-type"; public static final String USERNAME_ELEMENT = "username"; + public static final String CLIENT_CERTIFICATE_ALIAS_ELEMENT = "client-cert-alias"; public static final String PASSWORD_ELEMENT = "password"; public static final String EXTRA_ELEMENT = "extra"; public static final String IDENTITIES_ELEMENT = "identities"; @@ -232,6 +233,7 @@ public class SettingsExporter { writeElement(serializer, CONNECTION_SECURITY_ELEMENT, incoming.connectionSecurity.name()); writeElement(serializer, AUTHENTICATION_TYPE_ELEMENT, incoming.authenticationType.name()); writeElement(serializer, USERNAME_ELEMENT, incoming.username); + writeElement(serializer, CLIENT_CERTIFICATE_ALIAS_ELEMENT, incoming.clientCertificateAlias); // XXX For now we don't export the password //writeElement(serializer, PASSWORD_ELEMENT, incoming.password); @@ -259,6 +261,7 @@ public class SettingsExporter { writeElement(serializer, CONNECTION_SECURITY_ELEMENT, outgoing.connectionSecurity.name()); writeElement(serializer, AUTHENTICATION_TYPE_ELEMENT, outgoing.authenticationType.name()); writeElement(serializer, USERNAME_ELEMENT, outgoing.username); + writeElement(serializer, CLIENT_CERTIFICATE_ALIAS_ELEMENT, outgoing.clientCertificateAlias); // XXX For now we don't export the password //writeElement(serializer, PASSWORD_ELEMENT, outgoing.password); diff --git a/src/com/fsck/k9/preferences/SettingsImporter.java b/src/com/fsck/k9/preferences/SettingsImporter.java index b54ae1728..9cacb13b6 100644 --- a/src/com/fsck/k9/preferences/SettingsImporter.java +++ b/src/com/fsck/k9/preferences/SettingsImporter.java @@ -976,6 +976,8 @@ public class SettingsImporter { server.authenticationType = AuthType.valueOf(text); } else if (SettingsExporter.USERNAME_ELEMENT.equals(element)) { server.username = getText(xpp); + } else if (SettingsExporter.CLIENT_CERTIFICATE_ALIAS_ELEMENT.equals(element)) { + server.clientCertificateAlias = getText(xpp); } else if (SettingsExporter.PASSWORD_ELEMENT.equals(element)) { server.password = getText(xpp); } else if (SettingsExporter.EXTRA_ELEMENT.equals(element)) {