Browse Source

ignore whitespaces in password

tobiaskaminsky 7 years ago
parent
commit
128f3c97c8

+ 1 - 1
src/main/java/com/owncloud/android/ui/dialog/SetupEncryptionDialogFragment.java

@@ -180,7 +180,7 @@ public class SetupEncryptionDialogFragment extends DialogFragment {
                                 try {
                                     String privateKey = task.get();
                                     String decryptedPrivateKey = EncryptionUtils.decryptPrivateKey(privateKey,
-                                            passwordField.getText().toString());
+                                            passwordField.getText().toString().replaceAll("\\s", ""));
 
                                     arbitraryDataProvider.storeOrUpdateKeyValue(account.name,
                                             EncryptionUtils.PRIVATE_KEY, decryptedPrivateKey);