Wrong files in shared links

Steps to reproduce

  1. Open shared-link with password
  2. check files contain in folder
  3. check file on NAS

Expected behaviour

Correct data in the folder should be displayed. (Folder name like “First example” is the same as the name of the pdf file “First example.pdf”).

Actual behaviour

It shows files that should be in another folder.
But the data is correctly located on the NAS

Server configuration

Ubuntu 14.04 LTS

Web server:
Apache 2.4.17

Database:
mysql 5.7.35

PHP version:
PHP 5.6.16

ownCloud version: (see ownCloud admin page)
l3iggs/owncloud latest version

Updated from an older ownCloud or fresh install:

Where did you install ownCloud from:
l3iggs/owncloud image docker container

The content of config/config.php:

<?php
$CONFIG = array (
  'instanceid' => 'deleted',
  'passwordsalt' => 'deleted',
  'secret' => 'deleted',
  'trusted_domains' =>
  array (
    0 => 'ip:port',
    1 => 'fqdn',
  ),
  'datadirectory' => '/usr/share/webapps/owncloud/data',
  'overwrite.cli.url' => 'https://ip:port',
  'dbtype' => 'mysql',
  'version' => 'deleted',
  'dbname' => 'deleted',
  'dbhost' => 'deleted',
  'dbtableprefix' => 'deleted',
  'dbuser' => 'deleted',
  'dbpassword' => 'deleted',
  'logtimezone' => 'UTC',
  'installed' => true,
  'loglevel' => 0,
  'apps_paths' =>
  array (
    0 =>
    array (
      'path' => '/usr/share/webapps/owncloud/apps',
      'url' => '/apps',
      'writable' => false,
    ),
    1 =>
    array (
      'path' => '/usr/share/webapps/owncloud/custom_apps',
      'url' => '/custom_apps',
      'writable' => true,
    ),
  ),
);

Are you using external storage, if yes which one: local/smb/sftp/…
NAS - SMB

he Virtual Host Part from httpd-ssl.conf like that

<VirtualHost _default_:443>

#   General setup for the virtual host
DocumentRoot "/srv/http"
ServerName www.example.com:443
ServerAdmin you@example.com
ErrorLog "/var/log/httpd/error_log"
TransferLog "/var/log/httpd/access_log"

And owncloud.conf like that

<IfModule mod_alias.c>
    Alias /${TARGET_SUBDIR} /usr/share/webapps/owncloud/
</IfModule>

<Directory /usr/share/webapps/owncloud/>
Header always add Strict-Transport-Security "max-age=15768000; includeSubDomains; preload"
    Options FollowSymlinks
    AllowOverride all
    Require all granted
    php_admin_value open_basedir "/srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/owncloud/:/etc/webapps/owncloud:/dev/urandom"
</Directory>

And a startServers.sh from the image

#!/usr/bin/env bash

if [ "$ENABLE_DAV" = true ] ; then
  cat >> /etc/httpd/conf/httpd.conf <<EOF
Alias /dav "/home/httpd/html/dav"

<Directory "/home/httpd/html/dav">
  DAV On
  AllowOverride None
  Options Indexes FollowSymLinks
  Require all granted
</Directory>
EOF

ownCloud log (data/owncloud.log)

Insert your ownCloud log here

"reqId":"e9QleU77evfFGkVmx574","remoteAddr":"xxx.xxx.xxx.xxx","app":"core","message":"Exception: {\"Exception\":\"Doctrine\\\\DBAL\\\\DBALException\",\"Message\":\"Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [1862] Your password has expired. To log in you must change it using a client that supports expired passwords.\",\"Code\":0,\"Trace\":\"#0 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/doctrine\\\/dbal\\\/lib\\\/Doctrine\\\/DBAL\\\/Connection.php(429): OC\\\\DB\\\\Connection->connect()\\n#1 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/doctrine\\\/dbal\\\/lib\\\/Doctrine\\\/DBAL\\\/Connection.php(389): Doctrine\\\\DBAL\\\\Connection->getDatabasePlatformVersion()\\n#2 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/doctrine\\\/dbal\\\/lib\\\/Doctrine\\\/DBAL\\\/Connection.php(328): Doctrine\\\\DBAL\\\\Connection->detectDatabasePlatform()\\n#3 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/doctrine\\\/dbal\\\/lib\\\/Doctrine\\\/DBAL\\\/Connection.php(621): Doctrine\\\\DBAL\\\\Connection->getDatabasePlatform()\\n#4 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/db\\\/connection.php(135): Doctrine\\\\DBAL\\\\Connection->setTransactionIsolation(2)\\n#5 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/doctrine\\\/dbal\\\/lib\\\/Doctrine\\\/DBAL\\\/DriverManager.php(172): OC\\\\DB\\\\Connection->__construct(Array, Object(Doctrine\\\\DBAL\\\\Driver\\\\PDOMySql\\\\Driver), Object(Doctrine\\\\DBAL\\\\Configuration), Object(Doctrine\\\\Common\\\\EventManager))\\n#6 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/db\\\/connectionfactory.php(118): Doctrine\\\\DBAL\\\\DriverManager::getConnection(Array, Object(Doctrine\\\\DBAL\\\\Configuration), Object(Doctrine\\\\Common\\\\EventManager))\\n#7 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/server.php(327): OC\\\\DB\\\\ConnectionFactory->getConnection('mysql', Array)\\n#8 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/pimple\\\/pimple\\\/src\\\/Pimple\\\/Container.php(112): OC\\\\Server->OC\\\\{closure}(Object(OC\\\\Server))\\n#9 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/appframework\\\/utility\\\/simplecontainer.php(104): Pimple\\\\Container->offsetGet('DatabaseConnect...')\\n#10 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/server.php(762): OC\\\\AppFramework\\\\Utility\\\\SimpleContainer->query('DatabaseConnect...')\\n#11 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/db.php(42): OC\\\\Server->getDatabaseConnection()\\n#12 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/server.php(235): OC_DB::getConnection()\\n#13 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/3rdparty\\\/pimple\\\/pimple\\\/src\\\/Pimple\\\/Container.php(112): OC\\\\Server->OC\\\\{closure}(Object(OC\\\\Server))\\n#14 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/appframework\\\/utility\\\/simplecontainer.php(104): Pimple\\\\Container->offsetGet('AppConfig')\\n#15 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/server.php(701): OC\\\\AppFramework\\\\Utility\\\\SimpleContainer->query('AppConfig')\\n#16 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/util.php(410): OC\\\\Server->getAppConfig()\\n#17 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/util.php(343): OC_Util::loadVersion()\\n#18 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/defaults.php(52): OC_Util::getVersion()\\n#19 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/template.php(81): OC_Defaults->__construct()\\n#20 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/template.php(328): OC_Template->__construct('', 'exception', 'error', false)\\n#21 \\\/usr\\\/share\\\/webapps\\\/owncloud\\\/index.php(55): OC_Template::printExceptionErrorPage(Object(Doctrine\\\\DBAL\\\\DBALException))\\n#22 {main}\",\"File\":\"\\\/usr\\\/share\\\/webapps\\\/owncloud\\\/lib\\\/private\\\/db\\\/connection.php\",\"Line\":52}","level":3,"time":"2021-09-14T17:42:22+00:00","method":"GET","url":"\/index.php\/s\/AZ0Eeyp1QkXDyBC"}

Stepforward,

I am afraid I cannot understand what you are talking about. Maybe you could provide more details and/or screenshots to understand what you are looking for.

You tagged your posting as 9.1.x, I guess this was a mistake?

Edit: I just read you are using an outdated 3rd party docker with Ubuntu 14.04 (!). I’m pretty sure this is full of security nightmares and I guess the ownCloud version is brutally old as well.

I don’t think anybody here can give support for a 9.x version, I strongly recommend to create a fresh docker using the official ownCloud image and migrate your data from the old to the new instance.

See the docs:

https://doc.owncloud.com/server/next/admin_manual/installation/docker/

https://doc.owncloud.com/server/next/admin_manual/maintenance/migrating.html

Thank you for your answer! So, we have folders which have the name of people. As an example Max Tree. In this folder there are files (pdf) which belong to Max Tree. From these files shared links were created which were password protected. When Max clicks on the link and enters the password, files from another person are displayed. On the mounted NAS, where the data is located, everything is fine and looks correct.

And you are absolutely right, it is also in the works to build a completely new infrastructure. But we have encountered this problem and it makes no sense to me how this can occur.

And sorry for my mistake, my tagged version is wrong of course. It is a “l3iggs/owncloud latest” Docker version.

I just reviewed l3iggs/owncloud. Don’t use this image. It comes with a farly outdated ownCloud 9.1.3 and the repository had not been updated after 2016. Go with the official image instead.

I’m pretty sure your issue is fixed in a recent version and I don’t think anybody here can give support for a 9.x version.

Thank you very much for your information. But how can that issue happen? Makes no sense to me…

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.