nextcloud / server

☁️ Nextcloud server, a safe home for all your data
https://nextcloud.com
GNU Affero General Public License v3.0
27.54k stars 4.08k forks source link

Photos preview not working for external shared links (not logged in) #21615

Closed linucksrox closed 4 years ago

linucksrox commented 4 years ago

UPDATE: This issue occurs when deselecting "Allow users on this server to send shares to other servers" under the Federated Cloud Sharing section in the Admin settings. If you enable this option previews work as expected, although I believe this is a bug and should not be related to photo previews.

Steps to reproduce

  1. Share an external link to a folder with photos in it. Click on a photo to verify preview is working perfectly (it is).
  2. Log out and access the shared link
  3. Attempt to preview an image

Expected behaviour

After maybe a few seconds the image should load and display the preview, allowing you to browse the image gallery

Actual behaviour

A black screen with a spinning circle comes up, but the image never actually loads.

Server configuration

Operating system: Ubuntu 16.04

Web server: Apache behind Nginx reverse proxy

Database: MariaDB 10.4

PHP version: 7.4

Nextcloud version: (see Nextcloud admin page) 19.0

Updated from an older Nextcloud/ownCloud or fresh install: Updated from older instance

Where did you install Nextcloud from: Originally downloaded tarball and unzipped, then performed several upgrades over time

Login as admin user into your Nextcloud and access 
http://example.com/index.php/settings/integrity/failed 
paste the results here.

No errors have been found.

List of activated apps:

App list ``` Enabled: - accessibility: 1.5.0 - activity: 2.12.0 - admin_audit: 1.9.0 - bookmarks: 3.2.2 - bruteforcesettings: 1.6.0 - calendar: 2.0.3 - carnet: 0.22.1 - cloud_federation_api: 1.2.0 - comments: 1.9.0 - contactsinteraction: 1.0.0 - dav: 1.15.0 - deck: 1.0.4 - drawio: 0.9.6 - federatedfilesharing: 1.9.0 - files: 1.14.0 - files_downloadactivity: 1.8.0 - files_external: 1.10.0 - files_rightclick: 0.16.0 - files_sharing: 1.11.0 - files_trashbin: 1.9.0 - files_versions: 1.12.0 - files_videoplayer: 1.8.0 - firstrunwizard: 2.8.0 - groupfolders: 6.0.6 - guests: 1.4.6 - impersonate: 1.6.1 - logreader: 2.4.0 - lookup_server_connector: 1.7.0 - music: 0.14.1 - nextcloud_announcements: 1.8.0 - notes: 3.5.1 - notifications: 2.7.0 - oauth2: 1.7.0 - password_policy: 1.9.1 - photos: 1.1.0 - privacy: 1.3.0 - provisioning_api: 1.9.0 - serverinfo: 1.9.0 - settings: 1.1.0 - sharebymail: 1.9.0 - support: 1.2.1 - survey_client: 1.7.0 - systemtags: 1.9.0 - tasks: 0.13.1 - theming: 1.10.0 - twofactor_backupcodes: 1.8.0 - twofactor_totp: 4.1.3 - updatenotification: 1.9.0 - viewer: 1.3.0 - workflowengine: 2.1.0 Disabled: - encryption - federation - files_pdfviewer - recommendations - text - user_ldap ```

Nextcloud configuration:

Config report ``` { "system": { "instanceid": "***REMOVED SENSITIVE VALUE***", "passwordsalt": "***REMOVED SENSITIVE VALUE***", "secret": "***REMOVED SENSITIVE VALUE***", "trusted_domains": [ "localhost", "***REMOVED SENSITIVE VALUE***", "***REMOVED SENSITIVE VALUE***" ], "trusted_proxies": "***REMOVED SENSITIVE VALUE***", "htaccess.RewriteBase": "\/", "datadirectory": "***REMOVED SENSITIVE VALUE***", "dbtype": "mysql", "version": "19.0.0.12", "dbname": "***REMOVED SENSITIVE VALUE***", "dbhost": "***REMOVED SENSITIVE VALUE***", "dbport": "", "dbtableprefix": "oc_", "dbuser": "***REMOVED SENSITIVE VALUE***", "dbpassword": "***REMOVED SENSITIVE VALUE***", "mail_from_address": "***REMOVED SENSITIVE VALUE***", "mail_smtpmode": "smtp", "mail_domain": "***REMOVED SENSITIVE VALUE***", "mail_smtpdebug": false, "mail_smtptimeout": 10, "mail_smtpsecure": "ssl", "mail_smtpauthtype": "LOGIN", "mail_smtphost": "***REMOVED SENSITIVE VALUE***", "mail_smtpport": "465", "mail_smtpauth": 1, "mail_smtpname": "***REMOVED SENSITIVE VALUE***", "mail_smtppassword": "***REMOVED SENSITIVE VALUE***", "logtimezone": "UTC", "installed": true, "memcache.local": "\\OC\\Memcache\\APCu", "memcache.locking": "\\OC\\Memcache\\Redis", "filelocking.enabled": "true", "redis": { "host": "***REMOVED SENSITIVE VALUE***", "port": 0, "timeout": 0 }, "loglevel": 0, "share_folder": "\/Shared With You", "theme": "", "updater.release.channel": "stable", "maintenance": false, "trashbin_retention_obligation": "auto, 30", "mysql.utf8mb4": true, "app_install_overwrite": [ "files_downloadactivity", "drawio", "files_reader" ], "data-fingerprint": "143496c987f897f304213d5411758e77", "has_rebuilt_cache": true }, "apps": { "accessibility": { "enabled": "yes", "installed_version": "1.5.0", "types": "" }, "activity": { "enable_email": "no", "enabled": "yes", "installed_version": "2.12.0", "notify_email_calendar": "0", "notify_email_calendar_event": "0", "notify_email_calendar_todo": "0", "notify_email_comments": "1", "notify_email_favorite": "0", "notify_email_file_changed": "0", "notify_email_file_created": "0", "notify_email_file_deleted": "0", "notify_email_file_downloaded": "0", "notify_email_file_restored": "0", "notify_email_public_links": "0", "notify_email_remote_share": "1", "notify_email_shared": "1", "notify_email_systemtags": "0", "notify_setting_batchtime": "0", "notify_setting_self": "0", "notify_setting_selfemail": "0", "notify_stream_calendar": "1", "notify_stream_calendar_event": "1", "notify_stream_calendar_todo": "1", "notify_stream_comments": "1", "notify_stream_favorite": "1", "notify_stream_file_changed": "1", "notify_stream_file_created": "1", "notify_stream_file_deleted": "1", "notify_stream_file_downloaded": "1", "notify_stream_file_favorite": "0", "notify_stream_file_restored": "1", "notify_stream_public_links": "1", "notify_stream_remote_share": "1", "notify_stream_shared": "1", "notify_stream_systemtags": "1", "types": "filesystem" }, "admin_audit": { "enabled": "yes", "installed_version": "1.9.0", "types": "logging" }, "admin_notifications": { "enabled": "no", "installed_version": "1.0.0", "types": "logging" }, "backgroundjob": { "lastjob": "44269" }, "bookmarks": { "enabled": "yes", "installed_version": "3.2.2", "types": "" }, "bruteForce": { "whitelist_1": "192.168.1.0\/24" }, "bruteforcesettings": { "enabled": "yes", "installed_version": "1.6.0", "types": "" }, "calendar": { "enabled": "yes", "installed_version": "2.0.3", "types": "" }, "carnet": { "enabled": "yes", "installed_version": "0.22.1", "types": "filesystem" }, "checksum": { "enabled": "no", "installed_version": "0.4.4", "types": "filesystem" }, "cloud_federation_api": { "enabled": "yes", "installed_version": "1.2.0", "types": "filesystem" }, "comments": { "enabled": "yes", "installed_version": "1.9.0", "types": "logging" }, "contactsinteraction": { "enabled": "yes", "installed_version": "1.0.0", "types": "dav" }, "core": { "OC_Channel": "beta", "backgroundjobs_mode": "cron", "enterpriseLogoChecked": "yes", "incoming_server2server_share_enabled": "no", "installed.bundles": "[\"CoreBundle\"]", "installedat": "1440537434.527", "lastcron": "1593359106", "lastupdateResult": "[]", "lastupdatedat": "1593273607", "moveavatarsdone": "yes", "oc.integritycheck.checker": "[]", "outgoing_server2server_share_enabled": "no", "previewsCleanedUp": "1", "public_documents": "documents\/public.php", "public_files": "files_sharing\/public.php", "public_gallery": "gallery\/public.php", "public_webdav": "dav\/appinfo\/v1\/publicwebdav.php", "remote_caldav": "dav\/appinfo\/v1\/caldav.php", "remote_calendar": "dav\/appinfo\/v1\/caldav.php", "remote_carddav": "dav\/appinfo\/v1\/carddav.php", "remote_contacts": "dav\/appinfo\/v1\/carddav.php", "remote_dav": "dav\/appinfo\/v2\/remote.php", "remote_files": "dav\/appinfo\/v1\/webdav.php", "remote_webdav": "dav\/appinfo\/v1\/webdav.php", "repairlegacystoragesdone": "yes", "scss.variables": "129515193f32b824c7f61857a80237ae", "shareapi_allow_group_sharing": "yes", "shareapi_allow_links": "yes", "shareapi_allow_mail_notification": "yes", "shareapi_allow_public_notification": "yes", "shareapi_allow_public_upload": "yes", "shareapi_allow_resharing": "no", "shareapi_default_expire_date": "yes", "shareapi_default_permission_candelete": "no", "shareapi_default_permission_canupdate": "no", "shareapi_default_permissions": "21", "shareapi_enforce_expire_date": "no", "shareapi_expire_after_n_days": "7", "theming.variables": "82f18be2cdf596be9c38854e052b5e25", "umgmt_send_email": "true", "umgmt_show_backend": "false", "umgmt_show_email": "false", "umgmt_show_last_login": "true", "umgmt_show_storage_location": "true", "updater.secret.created": "1539264791", "vendor": "nextcloud" }, "dav": { "buildCalendarReminderIndex": "yes", "buildCalendarSearchIndex": "yes", "chunks_migrated": "1", "enabled": "yes", "installed_version": "1.15.0", "regeneratedBirthdayCalendarsForYearFix": "yes", "types": "filesystem" }, "deck": { "enabled": "yes", "installed_version": "1.0.4", "types": "dav" }, "direct_menu": { "enabled": "no", "installed_version": "0.10.2", "ocsid": "169148", "types": "" }, "documents": { "converter": "local", "enabled": "no", "installed_version": "0.12.0", "ocsid": "168711", "types": "" }, "documentserver_community": { "enabled": "no", "installed_version": "0.1.5", "types": "filesystem" }, "drawio": { "DrawioLang": "auto", "DrawioOffline": "yes", "DrawioTheme": "kennedy", "DrawioUrl": "https:\/\/www.draw.io", "DrawioXml": "yes", "enabled": "yes", "installed_version": "0.9.6", "types": "filesystem" }, "drop_account": { "enabled": "no", "installed_version": "0.2.1", "types": "" }, "edaly": { "documents": "save_path" }, "federatedfilesharing": { "enabled": "yes", "installed_version": "1.9.0", "types": "" }, "federation": { "enabled": "no", "installed_version": "1.2.0", "types": "authentication" }, "files": { "cronjob_scan_files": "500", "default_quota": "5 GB", "enabled": "yes", "installed_version": "1.14.0", "types": "filesystem" }, "files_accesscontrol": { "enabled": "no", "installed_version": "1.4.0", "types": "filesystem" }, "files_automatedtagging": { "enabled": "no", "installed_version": "1.4.0", "types": "filesystem" }, "files_downloadactivity": { "enabled": "yes", "installed_version": "1.8.0", "types": "filesystem" }, "files_external": { "allow_user_mounting": "no", "enabled": "yes", "installed_version": "1.10.0", "types": "filesystem", "user_mounting_backends": "" }, "files_locking": { "enabled": "no", "installed_version": "", "types": "filesystem" }, "files_markdown": { "enabled": "no", "installed_version": "2.2.0", "types": "" }, "files_mv": { "enabled": "no", "installed_version": "0.8.2", "ocsid": "150271", "types": "filesystem" }, "files_pdfviewer": { "enabled": "no", "installed_version": "1.2.1", "types": "" }, "files_reader": { "enabled": "no", "installed_version": "1.2.3", "types": "filesystem" }, "files_retention": { "enabled": "no", "installed_version": "1.5.1", "types": "filesystem" }, "files_rightclick": { "enabled": "yes", "installed_version": "0.16.0", "types": "" }, "files_sharing": { "enabled": "yes", "incoming_server2server_share_enabled": "no", "installed_version": "1.11.0", "lookupServerUploadEnabled": "no", "outgoing_server2server_share_enabled": "no", "types": "filesystem" }, "files_texteditor": { "enabled": "no", "installed_version": "2.8.0", "types": "" }, "files_trackdownloads": { "enabled": "no", "installed_version": "1.3.0", "types": "filesystem" }, "files_trashbin": { "enabled": "yes", "installed_version": "1.9.0", "types": "filesystem,dav" }, "files_versions": { "enabled": "yes", "installed_version": "1.12.0", "types": "filesystem,dav" }, "files_videoplayer": { "enabled": "yes", "installed_version": "1.8.0", "types": "" }, "files_videoviewer": { "enabled": "no", "installed_version": "0.1.3", "ocsid": "166054", "types": "" }, "firstrunwizard": { "enabled": "yes", "installed_version": "2.8.0", "types": "logging" }, "gallery": { "enabled": "no", "installed_version": "18.4.0", "types": "" }, "groupfolders": { "enabled": "yes", "installed_version": "6.0.6", "types": "filesystem,dav" }, "guests": { "allow_external_storage": "false", "enabled": "yes", "hide_users": "true", "installed_version": "1.4.6", "types": "authentication", "usewhitelist": "true", "whitelist": "files_trashbin,files_versions,files_sharing,files_texteditor,text,activity,photos,notifications" }, "heidiannette": { "documents": "save_path" }, "impersonate": { "enabled": "yes", "installed_version": "1.6.1", "types": "" }, "issuetemplate": { "enabled": "no", "installed_version": "0.3.0", "types": "" }, "keeweb": { "enabled": "no", "installed_version": "0.5.0", "types": "" }, "logreader": { "enabled": "yes", "installed_version": "2.4.0", "levels": "00111", "live": "1", "relativedates": "1", "types": "" }, "lookup_server_connector": { "enabled": "yes", "installed_version": "1.7.0", "types": "authentication" }, "lsd": { "enabled": "no", "installed_version": "1.0.0", "types": "authentication,sessions" }, "music": { "enabled": "yes", "installed_version": "0.14.1", "ocsid": "164319", "types": "filesystem" }, "nextant": { "configured": "1", "enabled": "no", "index_bookmarks_last": "1531733098", "index_bookmarks_needed": "0", "index_files_last": "1531733098", "index_files_needed": "0", "index_locked": "0", "installed_version": "1.0.10", "solr_core": "nextant", "solr_timeout": "30", "solr_url": "http:\/\/127.0.0.1:8983\/solr\/", "types": "filesystem" }, "nextcloud_announcements": { "enabled": "yes", "installed_version": "1.8.0", "pub_date": "Thu, 24 Oct 2019 00:00:00 +0200", "types": "logging" }, "notes": { "enabled": "yes", "installed_version": "3.5.1", "types": "" }, "notifications": { "enabled": "yes", "installed_version": "2.7.0", "types": "logging" }, "oauth2": { "enabled": "yes", "installed_version": "1.7.0", "types": "authentication" }, "onlyoffice": { "DocumentServerUrl": "https:\/\/cloud.dalydays.com\/apps\/documentserver_community\/", "defFormats": "{\"docx\":true,\"pptx\":true,\"xlsx\":true,\"odp\":true,\"ods\":true,\"odt\":true,\"doc\":true,\"ppt\":true,\"xls\":true}", "editFormats": "{\"csv\":true,\"docx\":true,\"pptx\":true,\"txt\":true,\"xlsx\":true,\"odp\":true,\"ods\":true,\"odt\":true,\"rtf\":true}", "enabled": "no", "installed_version": "4.1.4", "sameTab": "true", "types": "filesystem" }, "ownbackup": { "enabled": "no", "installed_version": "17.5.0", "ocsid": "170674", "types": "" }, "ownnote": { "enabled": "no", "installed_version": "1.08", "ocsid": "168512", "types": "" }, "password_policy": { "enabled": "yes", "enforceHaveIBeenPwned": "1", "enforceNumericCharacters": "1", "enforceUpperLowerCase": "1", "installed_version": "1.9.1", "minLength": "8", "types": "authentication" }, "passwords": { "enabled": "no", "installed_version": "2019.3.0", "service\/words": "wo4snakes", "types": "" }, "photos": { "enabled": "yes", "installed_version": "1.1.0", "types": "" }, "privacy": { "enabled": "yes", "installed_version": "1.3.0", "readableLocation": "us", "types": "" }, "provisioning_api": { "enabled": "yes", "installed_version": "1.9.0", "types": "prevent_group_restriction" }, "quota_warning": { "alert_email": "yes", "enabled": "no", "info_email": "yes", "installed_version": "1.3.0", "types": "filesystem", "warning_email": "yes", "warning_percentage": "90" }, "radio": { "enabled": "no", "installed_version": "0.6.4", "types": "" }, "recommendations": { "enabled": "no", "installed_version": "0.4.0", "types": "" }, "serverinfo": { "enabled": "yes", "installed_version": "1.9.0", "types": "" }, "settings": { "enabled": "yes", "installed_version": "1.1.0", "types": "" }, "sharebymail": { "enabled": "yes", "installed_version": "1.9.0", "sendpasswordmail": "yes", "types": "filesystem" }, "sharerenamer": { "enabled": "no", "installed_version": "2.1.0", "types": "" }, "spreed": { "enabled": "no", "installed_version": "4.0.0", "stun_servers": "***REMOVED SENSITIVE VALUE***", "types": "prevent_group_restriction" }, "storagecharts2": { "enabled": "no", "installed_version": "2.6.1", "ocsid": "165528", "types": "" }, "support": { "SwitchUpdaterServerHasRun": "yes", "enabled": "yes", "installed_version": "1.2.1", "types": "session" }, "survey_client": { "apps": "yes", "database": "yes", "enabled": "yes", "encryption": "yes", "files_sharing": "yes", "installed_version": "1.7.0", "last_report": "{\"id\":\"ocehvdbbozi8\",\"items\":[[\"server\",\"version\",\"18.0.3.0\"],[\"server\",\"code\",\"other\"],[\"server\",\"enable_avatars\",\"yes\"],[\"server\",\"enable_previews\",\"yes\"],[\"server\",\"memcache.local\",\"\\\\OC\\\\Memcache\\\\APCu\"],[\"server\",\"memcache.distributed\",\"none\"],[\"server\",\"asset-pipeline.enabled\",\"no\"],[\"server\",\"filelocking.enabled\",\"yes\"],[\"server\",\"memcache.locking\",\"\\\\OC\\\\Memcache\\\\Redis\"],[\"server\",\"debug\",\"no\"],[\"server\",\"cron\",\"cron\"],[\"php\",\"version\",\"7.2.30\"],[\"php\",\"memory_limit\",-1],[\"php\",\"max_execution_time\",0],[\"php\",\"upload_max_filesize\",2097152],[\"database\",\"type\",\"mysql\"],[\"database\",\"version\",\"10.3.22\"],[\"database\",\"size\",120578048],[\"apps\",\"accessibility\",\"1.4.0\"],[\"apps\",\"activity\",\"2.11.0\"],[\"apps\",\"admin_audit\",\"1.8.0\"],[\"apps\",\"admin_notifications\",\"disabled\"],[\"apps\",\"bookmarks\",\"2.3.4\"],[\"apps\",\"bruteforcesettings\",\"1.6.0\"],[\"apps\",\"calendar\",\"2.0.3\"],[\"apps\",\"carnet\",\"0.20.0\"],[\"apps\",\"checksum\",\"0.4.4\"],[\"apps\",\"cloud_federation_api\",\"1.1.0\"],[\"apps\",\"comments\",\"1.8.0\"],[\"apps\",\"dav\",\"1.14.0\"],[\"apps\",\"deck\",\"0.8.2\"],[\"apps\",\"direct_menu\",\"disabled\"],[\"apps\",\"documents\",\"disabled\"],[\"apps\",\"documentserver_community\",\"0.1.5\"],[\"apps\",\"drawio\",\"0.9.5\"],[\"apps\",\"drop_account\",\"disabled\"],[\"apps\",\"federatedfilesharing\",\"1.8.0\"],[\"apps\",\"federation\",\"disabled\"],[\"apps\",\"files\",\"1.13.1\"],[\"apps\",\"files_accesscontrol\",\"disabled\"],[\"apps\",\"files_automatedtagging\",\"disabled\"],[\"apps\",\"files_downloadactivity\",\"1.7.0\"],[\"apps\",\"files_external\",\"1.9.0\"],[\"apps\",\"files_locking\",\"disabled\"],[\"apps\",\"files_markdown\",\"2.2.0\"],[\"apps\",\"files_mv\",\"disabled\"],[\"apps\",\"files_pdfviewer\",\"disabled\"],[\"apps\",\"files_reader\",\"disabled\"],[\"apps\",\"files_retention\",\"disabled\"],[\"apps\",\"files_rightclick\",\"0.15.2\"],[\"apps\",\"files_sharing\",\"1.10.1\"],[\"apps\",\"files_texteditor\",\"disabled\"],[\"apps\",\"files_trackdownloads\",\"disabled\"],[\"apps\",\"files_trashbin\",\"1.8.0\"],[\"apps\",\"files_versions\",\"1.11.0\"],[\"apps\",\"files_videoplayer\",\"1.7.0\"],[\"apps\",\"files_videoviewer\",\"disabled\"],[\"apps\",\"firstrunwizard\",\"2.7.0\"],[\"apps\",\"gallery\",\"disabled\"],[\"apps\",\"groupfolders\",\"6.0.6\"],[\"apps\",\"impersonate\",\"1.5.0\"],[\"apps\",\"issuetemplate\",\"disabled\"],[\"apps\",\"keeweb\",\"disabled\"],[\"apps\",\"logreader\",\"2.3.0\"],[\"apps\",\"lookup_server_connector\",\"1.6.0\"],[\"apps\",\"lsd\",\"disabled\"],[\"apps\",\"music\",\"0.14.0\"],[\"apps\",\"nextant\",\"disabled\"],[\"apps\",\"nextcloud_announcements\",\"1.7.0\"],[\"apps\",\"notes\",\"3.2.0\"],[\"apps\",\"notifications\",\"2.6.0\"],[\"apps\",\"oauth2\",\"1.6.0\"],[\"apps\",\"onlyoffice\",\"4.1.4\"],[\"apps\",\"ownbackup\",\"disabled\"],[\"apps\",\"ownnote\",\"disabled\"],[\"apps\",\"password_policy\",\"1.8.0\"],[\"apps\",\"passwords\",\"disabled\"],[\"apps\",\"photos\",\"1.0.0\"],[\"apps\",\"privacy\",\"1.2.0\"],[\"apps\",\"provisioning_api\",\"1.8.0\"],[\"apps\",\"quota_warning\",\"disabled\"],[\"apps\",\"radio\",\"disabled\"],[\"apps\",\"recommendations\",\"disabled\"],[\"apps\",\"serverinfo\",\"1.8.0\"],[\"apps\",\"settings\",\"1.0.0\"],[\"apps\",\"sharebymail\",\"1.8.0\"],[\"apps\",\"sharerenamer\",\"disabled\"],[\"apps\",\"spreed\",\"disabled\"],[\"apps\",\"storagecharts2\",\"disabled\"],[\"apps\",\"support\",\"1.1.0\"],[\"apps\",\"survey_client\",\"1.6.0\"],[\"apps\",\"systemtags\",\"1.8.0\"],[\"apps\",\"tasks\",\"0.12.2\"],[\"apps\",\"templateeditor\",\"disabled\"],[\"apps\",\"text\",\"disabled\"],[\"apps\",\"theming\",\"1.9.0\"],[\"apps\",\"twofactor_backupcodes\",\"1.7.0\"],[\"apps\",\"twofactor_totp\",\"4.1.3\"],[\"apps\",\"updatenotification\",\"1.8.0\"],[\"apps\",\"updater\",\"disabled\"],[\"apps\",\"viewer\",\"1.2.0\"],[\"apps\",\"workflowengine\",\"2.0.0\"],[\"stats\",\"num_files\",310614],[\"stats\",\"num_users\",8],[\"stats\",\"num_storages\",89],[\"stats\",\"num_storages_local\",3],[\"stats\",\"num_storages_home\",8],[\"stats\",\"num_storages_other\",78],[\"stats\",\"num_comments\",1],[\"stats\",\"num_comment_markers\",3],[\"stats\",\"num_systemtags\",6],[\"stats\",\"num_systemtags_mappings\",0],[\"files_sharing\",\"num_shares\",40],[\"files_sharing\",\"num_shares_user\",35],[\"files_sharing\",\"num_shares_groups\",0],[\"files_sharing\",\"num_shares_link\",2],[\"files_sharing\",\"num_shares_link_no_password\",2],[\"files_sharing\",\"num_fed_shares_sent\",0],[\"files_sharing\",\"num_fed_shares_received\",0],[\"files_sharing\",\"permissions_0_1\",\"13\"],[\"files_sharing\",\"permissions_3_1\",\"2\"],[\"files_sharing\",\"permissions_4_1\",\"3\"],[\"files_sharing\",\"permissions_0_3\",\"10\"],[\"files_sharing\",\"permissions_0_5\",\"1\"],[\"files_sharing\",\"permissions_0_15\",\"2\"],[\"files_sharing\",\"permissions_0_17\",\"4\"],[\"files_sharing\",\"permissions_0_19\",\"3\"],[\"files_sharing\",\"permissions_0_23\",\"1\"],[\"files_sharing\",\"permissions_0_31\",\"1\"],[\"encryption\",\"enabled\",\"no\"],[\"encryption\",\"default_module\",\"no\"]]}", "last_sent": "1588754706", "php": "yes", "server": "yes", "stats": "yes", "types": "" }, "systemtags": { "enabled": "yes", "installed_version": "1.9.0", "types": "logging" }, "tasks": { "enabled": "yes", "installed_version": "0.13.1", "types": "" }, "templateeditor": { "enabled": "no", "installed_version": "0.2", "types": "" }, "text": { "enabled": "no", "installed_version": "2.0.0", "types": "dav" }, "theming": { "backgroundMime": "image\/jpeg", "cachebuster": "54", "color": "#D20014", "enabled": "yes", "installed_version": "1.10.0", "slogan": "***REMOVED SENSITIVE VALUE***", "types": "logging", "url": "***REMOVED SENSITIVE VALUE***" }, "twofactor_backupcodes": { "enabled": "yes", "installed_version": "1.8.0", "types": "" }, "twofactor_totp": { "enabled": "yes", "installed_version": "4.1.3", "types": "" }, "updatenotification": { "bookmarks": "3.2.0", "bruteforcesettings": "1.6.0", "calendar": "2.0.3", "carnet": "0.22.0", "checksum": "0.4.4", "core": "18.0.5.1", "deck": "1.0.3", "direct_menu": "0.10.1", "drawio": "0.9.6", "enabled": "yes", "files_accesscontrol": "1.2.5", "files_markdown": "2.2.0", "files_mv": "0.8.2", "files_retention": "1.4.2", "files_rightclick": "0.15.1", "groupfolders": "6.0.6", "impersonate": "1.6.1", "installed_version": "1.9.0", "issuetemplate": "0.3.0", "nextant": "1.0.10", "notes": "3.5.0", "sharerenamer": "1.5.0", "spreed": "3.2.5", "tasks": "0.13.1", "theming": "1.4.5", "twofactor_totp": "4.1.3", "types": "", "update_check_errors": "0" }, "updater": { "enabled": "no", "installed_version": "0.6", "types": "" }, "viewer": { "enabled": "yes", "installed_version": "1.3.0", "types": "" }, "workflowengine": { "enabled": "yes", "installed_version": "2.1.0", "types": "filesystem" } } } ```

Are you using external storage, if yes which one: local/smb/sftp/... Yes, but not for the purposes of this example.

Are you using encryption: yes/no No

Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/... No

Client configuration

Browser: Firefox 77.0.1 64-bit

Operating system: MX Linux 19.1

Logs

No new log entries appear when reproducing this issue.

Web server error log

Web server error log ``` No apache errors logged ```

Browser log

Browser log ``` JQMIGRATE: Migrate is installed, version 1.4.1 jquery-migrate.min.js:2:551 This page uses the non standard property “zoom”. Consider using calc() in the relevant property values, or using “transform” along with “transform-origin: 0 0”. addStylesClient.js:220:17 jQuery is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 2 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 3 globals.js:61:15 Handlebars is deprecated: please ship your own, this will be removed in Nextcloud 20 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 2 globals.js:61:15 jQuery is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 2 globals.js:61:15 Handlebars is deprecated: please ship your own, this will be removed in Nextcloud 20 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 2 globals.js:61:15 OCA.Viewer initialized Viewer.js:41:10 jQuery is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 2 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 3 globals.js:61:15 session heartbeat polling started session-heartbeat.js:97:9 jQuery is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 48 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 15 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 7 globals.js:61:15 jQuery is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 40 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 3 globals.js:61:15 TypeError: OCA.Files.App is undefined client.js:125:13 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 123 globals.js:61:15 jQuery is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 3 globals.js:61:15 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 6 globals.js:61:15 Opening the viewer with a single string parameter is deprecated. Please use a destructuring object instead OCA.Viewer.open({ path: '/0E7680AB-D61A-4979-B707-B7711E039D47.jpeg' }) Viewer.js:97:11 $ is deprecated: The global jQuery is deprecated. It will be updated to v2.4 in Nextcloud 20 and v3.x in Nextcloud 21. In later versions of Nextcloud it might be removed completely. Please ship your own. 2 globals.js:61:15 Opening viewer for file /0E7680AB-D61A-4979-B707-B7711E039D47.jpeg Viewer.vue:223 Error: "Request failed with status code 401" exports createError.js:16 exports settle.js:17 onreadystatechange xhr.js:61 Viewer.vue:395 r Viewer.vue:395 l ncvuecomponents.js:320 _invoke ncvuecomponents.js:320 e ncvuecomponents.js:320 re viewer.js:352 s viewer.js:352 ```
dgedgedge commented 4 years ago

Same issue with 18.0.6 server. see also : https://help.nextcloud.com/t/view-photos-by-shared-link/82012/7

Server configuration detail

Operating system: Linux 4.19.0-8-amd64 #1 SMP Debian 4.19.98-1 (2020-01-26) x86_64

Webserver: Apache (apache2handler)

Database: mysql 10.3.22

PHP version: 7.3.14-1~deb10u1

Modules loaded: Core, date, libxml, openssl, pcre, zlib, filter, hash, Reflection, SPL, session, sodium, standard, apache2handler, mysqlnd, PDO, xml, apcu, bz2, calendar, ctype, curl, dom, mbstring, fileinfo, ftp, gd, gettext, iconv, igbinary, imagick, intl, json, exif, msgpack, mysqli, pdo_mysql, apc, posix, readline, redis, shmop, SimpleXML, sockets, sysvmsg, sysvsem, sysvshm, tokenizer, wddx, xmlreader, xmlwriter, xsl, zip, Phar, memcached, Zend OPcache

Nextcloud version: 18.0.6 - 18.0.6.0

Updated from an older Nextcloud/ownCloud or fresh install:

Where did you install Nextcloud from: tgz on debian.

Signing status Array ( )
List of activated apps Enabled: - accessibility: 1.4.0 - activity: 2.11.0 - admin_audit: 1.8.0 - analytics: 2.3.1 - audioplayer: 2.10.1 - audioplayer_editor: 0.2.2 - bruteforcesettings: 1.6.0 - calendar: 2.0.3 - carnet: 0.22.1 - checksum: 0.4.4 - cloud_federation_api: 1.1.0 - comments: 1.8.0 - contacts: 3.3.0 - cookbook: 0.7.6 - dav: 1.14.0 - deck: 1.0.4 - documentserver_community: 0.1.7 - federatedfilesharing: 1.8.0 - federation: 1.8.0 - files: 1.13.1 - files_external: 1.9.0 - files_markdown: 2.3.0 - files_mindmap: 0.0.22 - files_pdfviewer: 1.7.0 - files_rightclick: 0.15.2 - files_sharing: 1.10.1 - files_trashbin: 1.8.0 - files_versions: 1.11.0 - files_videoplayer: 1.7.0 - firstrunwizard: 2.7.0 - geoblocker: 0.3.1 - groupfolders: 6.0.6 - keeweb: 0.6.2 - logreader: 2.3.0 - lookup_server_connector: 1.6.0 - maps: 0.1.6 - music: 0.14.1 - nextcloud_announcements: 1.7.0 - notes: 3.5.1 - notifications: 2.6.0 - oauth2: 1.6.0 - onlyoffice: 4.3.0 - password_policy: 1.8.0 - photos: 1.0.0 - privacy: 1.2.0 - provisioning_api: 1.8.0 - recommendations: 0.6.0 - serverinfo: 1.8.0 - settings: 1.0.0 - sharebymail: 1.8.0 - spreed: 8.0.9 - support: 1.1.1 - survey_client: 1.6.0 - systemtags: 1.8.0 - tasks: 0.13.1 - text: 2.0.0 - theming: 1.9.0 - twofactor_backupcodes: 1.7.0 - updatenotification: 1.8.0 - user_usage_report: 1.2.0 - viewer: 1.2.0 - workflowengine: 2.0.0 Disabled: - encryption - user_ldap
Configuration (config/config.php) { "instanceid": "***REMOVED SENSITIVE VALUE***", "passwordsalt": "***REMOVED SENSITIVE VALUE***", "secret": "***REMOVED SENSITIVE VALUE***", "trusted_domains": [ xxxxxx ], "datadirectory": "***REMOVED SENSITIVE VALUE***", "overwrite.cli.url": "xxxxxx", "dbtype": "mysql", "version": "18.0.6.0", "dbname": "***REMOVED SENSITIVE VALUE***", "dbhost": "***REMOVED SENSITIVE VALUE***", "dbport": "", "dbtableprefix": "oc_", "dbuser": "***REMOVED SENSITIVE VALUE***", "dbpassword": "***REMOVED SENSITIVE VALUE***", "loglevel": 2, "logtimezone": "Europe\/Paris", "logfile": "\/var\/log\/nextcloud.log", "installed": true, "memcache.local": "\\OC\\Memcache\\APCu", "mail_from_address": "***REMOVED SENSITIVE VALUE***", "mail_smtpmode": "smtp", "mail_domain": "***REMOVED SENSITIVE VALUE***", "mail_smtphost": "***REMOVED SENSITIVE VALUE***", "maintenance": false, "theme": "", "updater.release.channel": "stable", "mail_smtpauth": 1, "mail_sendmailmode": "smtp", "mail_smtpauthtype": "LOGIN", "mail_smtpname": "***REMOVED SENSITIVE VALUE***", "mail_smtppassword": "***REMOVED SENSITIVE VALUE***", "mysql.utf8mb4": true, "trashbin_retention_obligation": "auto, 100", "has_rebuilt_cache": true }

External storages: yes

External storage configuration No mounts configured

Encryption: no

User-backends:

OC\User\Database

linucksrox commented 4 years ago

I found what I think is the root cause, although I'm not exactly sure how to fix it. I was able to reproduce it on a fresh docker install of NC19 after restoring a copy of my current database.

In the admin settings, under Administration - Sharing, then under Federated Cloud Sharing by default the first option is checked "Allow users on this server to send shares to other servers" and photo preview works for guests. If you uncheck this option, that causes photo preview to break. For now I'm going to enable this option so I have a working previewer.

I hope this helps anyone else who runs into this problem until it gets fixed.

linucksrox commented 4 years ago

This still happens on the latest update 19.0.1, and the workaround still applies.

dgedgedge commented 4 years ago

I found what I think is the root cause, although I'm not exactly sure how to fix it. I was able to reproduce it on a fresh docker install of NC19 after restoring a copy of my current database.

In the admin settings, under Administration - Sharing, then under Federated Cloud Sharing by default the first option is checked "Allow users on this server to send shares to other servers" and photo preview works for guests. If you uncheck this option, that causes photo preview to break. For now I'm going to enable this option so I have a working previewer.

I hope this helps anyone else who runs into this problem until it gets fixed.

Note : Applying your workaround to my 18.0.6 server did solve the issue.

skjnldsv commented 4 years ago

Yep, you need to enable federated sharing. More info https://github.com/nextcloud/server/issues/19700