owncloud / android

:phone: The ownCloud Android App
GNU General Public License v2.0
3.83k stars 3.05k forks source link

Lots of login failed in log after update to material version #1357

Closed jsalatiel closed 8 years ago

jsalatiel commented 8 years ago

Since the last update to the new material design version, my owncloud log is being flooded with

Error PHP Cannot modify header information - headers already sent by (output started at /var/www/owncloud/user-otp/user_otp/lib/otp.php:310) at /var/www/owncloud/lib/private/api.php#346 2015-12-14T13:46:02-03:00 Warning core Login failed: 'salas' Error PHP session_regenerate_id(): Cannot regenerate session id - headers already sent at /var/www/owncloud/lib/private/user.php#241 2015-12-14T13:46:02-03:00 The app appears to be working , but this flood is making very difficult be able to use fail2ban to block bruteforce attempts because connection from the new android app is generating a 'login failed' message.

Nothing was changed on the server (otp in use for a long time with no problem) and this log started appearing right after update to the material design, so i think something changed on the client;

ii owncloud 8.1.4-12.1
ii php5 5.6.14+dfsg-0+deb8u1 ii apache2 2.4.10-10+deb8u3

tobiasKaminsky commented 8 years ago

Do you mean the new owncloud-1.9 version? Or the beta version?

jsalatiel commented 8 years ago

Sorry , i forgot to say. owncloud 1.9.0 downloaded from play store

AndyScherzinger commented 8 years ago

@davivel @masensio looping you in here since it shouldn't be material design related, since material has been introduced with 1.8.0

jsalatiel commented 8 years ago

I don't update play store apps very often, so i cant say exactly in which version it started. I only got the material design version yesterday and it is already 1.9.

jsalatiel commented 8 years ago

I only noticed this problem because right after update the app in play store, i was unable to connect to the server and found out that fail2ban had banned my ip address because of several 'login failed'. So i manually unban my ip address and seconds later it was banned again.

davivel commented 8 years ago

@jsalatiel , would you consider to upgrade your server?

I have to search for the issue, but I'm sure I've read that error message before and was server-side related. Let me check...

davivel commented 8 years ago

@jsalatiel , do you know what version of the app was installed before you updated?

jsalatiel commented 8 years ago

Hi @davivel , i have scheduled the update to january 16. If it is a server related problem it will be fixed there :) i have no idea what version it was. Sorry :/

jsalatiel commented 8 years ago

btw, i see absolutely no errors when accessing through webdav from another clients;

davivel commented 8 years ago

No, I was wrong. I've read that log before, but in other issues of the Android app. Too many, indeed.

davivel commented 8 years ago

Do you use Nginx ?

jsalatiel commented 8 years ago

No, apache2 2.4.10-10+deb8u3

ii owncloud 8.1.4-12.1 ii php5 5.6.14+dfsg-0+deb8u1

jsalatiel commented 8 years ago

Upgraded server to 8.2.2-1.1and still same problem! {"reqId":"xxxx","remoteAddr":"xxx.xxx.xxx.xxx","app":"core","message":"Login failed: 'salas' (Remote IP: 'xxx.xxx.xxx.xxx')","level":2,"time":"2016-01-11T21:41:33-03:00"}

davivel commented 8 years ago

@jsalatiel , is this still a problem for you?

Thanks in advance.

jsalatiel commented 8 years ago

Hi, i was able to track down the problem. Apparently new versions of android app started to make GET for different paths in the server than those it did before.

For example: /cloud/capabilities/ /apps/files_sharing/api/v1/sharees(.) ( Why two e's ? sharee ? before it was just share! )

So OTP was not bypassing connections for these URLs. You can close this issue. Thanks and i am sorry for not reporting. A forgot =)

AndyScherzinger commented 8 years ago

sharee is the person/group you want to share something with :)

davivel commented 8 years ago

@jsalatiel , thank a lot, no problem at all :)