Skip to content

Commit 58b0592

Browse files
Merge pull request #1032 from nextcloud/nc12auth
HOTFIX: Ignore oauth for now and use always basic auth
2 parents 9bc5d1b + d17af1d commit 58b0592

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/main/java/com/owncloud/android/operations/DetectAuthenticationMethodOperation.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,8 @@ protected RemoteOperationResult run(OwnCloudClient client) {
9898
// analyze response
9999
if (result.getHttpCode() == HttpStatus.SC_UNAUTHORIZED) {
100100
String authRequest = ((result.getAuthenticateHeader()).trim()).toLowerCase();
101-
if (authRequest.startsWith("basic")) {
101+
if (authRequest.startsWith("basic") || authRequest.startsWith("bearer")) {
102102
authMethod = AuthenticationMethod.BASIC_HTTP_AUTH;
103-
104-
} else if (authRequest.startsWith("bearer")) {
105-
authMethod = AuthenticationMethod.BEARER_TOKEN;
106103
}
107104
// else - fall back to UNKNOWN
108105

0 commit comments

Comments
 (0)