Notification goes to ALL guest users when sharing a folder

Hi,

On Owncloud 10.0.0.10 stable (upgraded from 10.0.0.9 stable), using the Guest add-on, when a regular user shares a folder with a new guest (the guest does not yet have an established account) and then sends them a notification about the share, the notification is sent to the email addresses of ALL guest accounts.

Server OS is Ubuntu 16.04.06 LTS, MySQL version is 5.7.25, and Apache2 is 2.4.18. PHP is 7.2.16.

Below are the owncloud.log entries from the time that the user tried to notify the guest about the newly created share:

{“reqId”:“FQSYeTjaznmKM4zp7Smw”,“level”:3,“time”:“2019-04-18T20:45:19+00:00”,“remoteAddr”:“192.168.222.2”,“user”:“jsmith”,“app”:“PHP”,“method”:“GET”,“url”:"/index.php/core/ajax/share.php?fetch=getShareWith&search=jrogers&limit=200&itemType=folder",“message”:“Invalid argument supplied for foreach() at /var/www/owncloud/core/ajax/share.php#463”}

{“reqId”:“2hMcpH93VfW9shsQnr6t”,“level”:3,“time”:“2019-04-18T20:45:56+00:00”,“remoteAddr”:“192.168.222.2”,“user”:“jrogers”,“app”:“PHP”,“method”:“POST”,“url”:"/index.php/core/ajax/share.php",“message”:“Undefined offset: 0 at /var/www/owncloud/lib/private/Share/MailNotifications.php#142”}

{“reqId”:“2hMcpH93VfW9shsQnr6t”,“level”:3,“time”:“2019-04-18T20:45:56+00:00”,“remoteAddr”:“192.168.222.2”,“user”:“jsmith”,“app”:“PHP”,“method”:“POST”,“url”:"/index.php/core/ajax/share.php",“message”:“Undefined offset: 0 at /var/www/owncloud/lib/private/Share/MailNotifications.php#155”}

{“reqId”:“2hMcpH93VfW9shsQnr6t”,“level”:3,“time”:“2019-04-18T20:45:56+00:00”,“remoteAddr”:“192.168.222.2”,“user”:“jsmith”,“app”:“index”,“method”:“POST”,“url”:"/index.php/core/ajax/share.php",“message”:“Exception: {“Exception”:“Symfony\\Component\\Routing\\Exception\\InvalidParameterException”,“Message”:“Parameter \“fileId\” for route \“files.viewcontroller.showFile\” must match \”[^\/]++\” (\"\" given) to generate a corresponding URL.",“Code”:0,“Trace”:"#0 \/var\/www\/owncloud\/lib\/composer\/symfony\/routing\/Generator\/UrlGenerator.php(119): Symfony\\Component\\Routing\\Generator\\UrlGenerator->doGenerate(Array, Array, Array, Array, Array, ‘files.viewcontr…’, 1, Array, Array)\n#1 \/var\/www\/owncloud\/lib\/private\/Route\/Router.php(382): Symfony\\Component\\Routing\\Generator\\UrlGenerator->generate(‘files.viewcontr…’, Array, 1)\n#2 \/var\/www\/owncloud\/lib\/private\/URLGenerator.php(86): OC\\Route\\Router->generate(‘files.viewcontr…’, Array)\n#3 \/var\/www\/owncloud\/lib\/private\/URLGenerator.php(99): OC\\URLGenerator->linkToRoute(‘files.viewcontr…’, Array)\n#4 \/var\/www\/owncloud\/lib\/private\/Share\/MailNotifications.php(155): OC\\URLGenerator->linkToRouteAbsolute(‘files.viewcontr…’, Array)\n#5 \/var\/www\/owncloud\/core\/ajax\/share.php(136): OC\\Share\\MailNotifications->sendInternalShareMail(Array, ‘8221’, ‘folder’)\n#6 \/var\/www\/owncloud\/lib\/private\/Route\/Route.php(155): require_once(’\/var\/www\/ownclo…’)\n#7 \/var\/www\/owncloud\/lib\/private\/Route\/Router.php(342): OC\\Route\\Route->OC\\Route\\{closure}(NULL)\n#8 \/var\/www\/owncloud\/lib\/base.php(909): OC\\Route\\Router->match(’\/core\/ajax\/shar…’)\n#9 \/var\/www\/owncloud\/index.php(54): OC::handleRequest()\n#10 {main}",“File”:"\/var\/www\/owncloud\/lib\/composer\/symfony\/routing\/Generator\/UrlGenerator.php",“Line”:146}"}

{“reqId”:“dUIu1XzAsU5ashgsL3Pj”,“level”:3,“time”:“2019-04-18T20:47:18+00:00”,“remoteAddr”:“192.168.222.2”,“user”:“jsmith”,“app”:“no app in context”,“method”:“PUT”,“url”:"/index.php/apps/guests/users",“message”:"User backend OC\User\Database is returning home: /var/www/owncloud/data/eat@joes.com for user: eat@joes.com which differs from existing value: "}

Thanks for any help that can be provided.

Hey,

i’m not sure how much help a user support forum can offer for such issues. I think it is probably better to notify the ownCloud developers via a bug report about this issue: