Nextcloud version (eg, 10.0.2): 12.0.0
Operating system and version (eg, Ubuntu 16.04): Centos 7.3
Apache or nginx version (eg, Apache 2.4.25): Apache 2.4.25
PHP version (eg, 5.6): Php 7.0
Is this the first time you’ve seen this error?: Yes
Can you reliably replicate it? (If so, please outline steps): Try to login with Android or Windows app
The issue you are facing:
Have Nextcloud on a VPS. Can login through browser. Cannot login through Android or Windows applications. “Wrong username or password”. Tried creating App passwords.
Apps say “Secure connection established”
I had the same setup with Owncloud and it worked fine. Not sure why Nextcloud isn’t allowing me to login.
The output of your Nextcloud log in Admin > Logging:
https://pastebin.com/2Kada1Sc
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
https://pastebin.com/KUcfn2eC
The output of your Apache/nginx/system log in /var/log/____
:
[16/Jun/2017:04:29:02 +0000] “PROPFIND /remote.php/webdav/ HTTP/1.1” 401 414 “-” “Mozilla/5.0 (Windows) mirall/2.3.1 (build 8) (Nextcloud)”
1 Like
Can you edit your topic to provide the requested logs please?
updated. and now I will type at least 10 characters to get around the reply limit.
Here is some dumpio logs that I found useful:
https://pastebin.com/NvC5BgUz
So it’s sending an Authorization Basic… but then the server returns 401…then some XML: “No ‘Authorization: Basic’ header found. Either the client didn’t send one, or the server is misconfigured, No ‘Authorization: Bearer’ header found. Either the client didn’t send one, or the server is mis-configured”
Not sure what this means or how to fix it…
Spent a day on this…
I was able to solve this problem with this somewhat hard to find gem: https://central.owncloud.org/t/no-basic-authentication-headers-were-found-message/819
I was unaware Nextcloud prefers mod_php and not fastcgi
in case link goes down…
Solution
There is no “all in one” solution but you can try to add this to your Apache vhost configuration:
SetEnvIf Authorization “(.*)” HTTP_AUTHORIZATION=$1
before the line “ProxyPassMatch”.
For mod_fastcgi a possible solution is to add this to the Apache config:
FastCgiConfig -pass-header Authorization
2 Likes