From e021363e510a8cc0229e5eb5cb39e9a84ed3bf07 Mon Sep 17 00:00:00 2001 From: mutec Date: Mon, 15 Nov 2021 21:37:01 +0100 Subject: [PATCH] encode user id in `OwnCloudClient.getFilesDavUri(String)` usernames containing spaces cause serious issues up to denying logins and syncs - making the whole app unusable while the same id works using the web gui. Signed-off-by: mutec --- .../java/com/owncloud/android/lib/common/OwnCloudClient.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/owncloud/android/lib/common/OwnCloudClient.java b/src/main/java/com/owncloud/android/lib/common/OwnCloudClient.java index e87366e44..611c865fd 100644 --- a/src/main/java/com/owncloud/android/lib/common/OwnCloudClient.java +++ b/src/main/java/com/owncloud/android/lib/common/OwnCloudClient.java @@ -297,7 +297,7 @@ public void setDefaultTimeouts(int defaultDataTimeout, int defaultConnectionTime } public String getFilesDavUri(String path) { - return getDavUri() + "/files/" + userId + "/" + WebdavUtils.encodePath(path); + return getDavUri() + "/files/" + getUserId() + "/" + WebdavUtils.encodePath(path); } public Uri getFilesDavUri() {