Authentication error for one user - help to debug

Hi,
My Mail-in-a-Box Instance has problems with one specific user account. The User cannot login via Exchange Client (“Username/Password wrong”) and CalDAV/CardDAV client. But this user is able to connect to the Services Owncloud, RoundCube and IMAP with his credentials. Other users don’t have any impact.

I tried to change his password, but same behaviour as before. Does anyone can tell me how to debug this?

Thanks in advance,
redflag237

You mention ownCloud, which version are you running? Latest is nextcloud and has an updated z-push (the exchange client).

1 Like

You’re right, it is NextCloud and Z-Push. Status Page shows “✓
Mail-in-a-Box is up to date. You are running version v0.23a.”

Can you run this while the user tries to log in:

(cd /var/log && tail -f mail.log z-push/z-push-error.log z-push/z-push.log)

Okay found the Error. NextCloud rejects the authentication on CardDav and CalDav.

==> z-push/z-push.log <==
11/07/2017 16:07:52 [22531] [ERROR] [user@domain.de] BackendCardDAV->Logon(): User ‘user@domain.de’ failed to authenticate on ‘https://127.0.0.1:443/carddav/addressbooks/user@domain.de/’:
11/07/2017 16:07:52 [22531] [FATAL] [user@domain.de] Exception: (AuthenticationRequiredException) - Access denied. Username or password incorrect

And this is what NextCloud tells me:
Exception: {“Message”:“HTTP/1.1 401 No ‘Authorization: Basic’ header found. Either the client didn’t send one, or the server is mis-configured”,“Exception”:“Sabre\DAV\Exception\NotAuthenticated”,“Code”:0,“Trace”:"#0 [internal function]: Sabre\DAV\Auth\Plugin->beforeMethod(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))\n#1 /usr/local/lib/owncloud/3rdparty/sabre/event/lib/EventEmitterTrait.php(105): call_user_func_array(Array, Array)\n#2 /usr/local/lib/owncloud/3rdparty/sabre/dav/lib/DAV/Server.php(446): Sabre\Event\EventEmitter->emit(‘beforeMethod’, Array)\n#3 /usr/local/lib/owncloud/3rdparty/sabre/dav/lib/DAV/Server.php(248): Sabre\DAV\Server->invokeMethod(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))\n#4 /usr/local/lib/owncloud/apps/dav/appinfo/v1/caldav.php(88): Sabre\DAV\Server->exec()\n#5 /usr/local/lib/owncloud/remote.php(165): require_once(’/usr/local/lib/…’)\n#6 {main}",“File”:"/usr/local/lib/owncloud/3rdparty/sabre/dav/lib/DAV/Auth/Plugin.php",“Line”:188,“User”:false}

Can anyone help me with this?

Does this user have a special client? Very weird though.

On the master branch we have updated to NextCloud 12 and a newer version of z-push. Maybe we’ll get lucky and that fixes it? Otherwise you might need to check with the NextCloud people.

No special Client, they are using Android (6.0 / 7.0) Exchange Client. CardDAV and CalDAV Apps are on Android, too. I will ask the NextCloud Poeple if they have an idea. Thanks so far :slight_smile:

1 Like