owncloud / ocis

:atom_symbol: ownCloud Infinite Scale Stack
https://doc.owncloud.com/ocis/next/
Apache License 2.0
1.38k stars 181 forks source link

Preview request in public links are broken #8602

Closed kulmann closed 7 months ago

kulmann commented 7 months ago

Describe the bug

Thumbnail service in public links (i.e. preview requests via /dav/public-files) lead to http 500.

Steps to reproduce

  1. Create a project space
  2. Upload some images
  3. Create a public link to the space itself or a single file public link to one of the images
  4. Public link must be password protected
  5. Open the public link in a private tab and try to open one of the images

Expected behavior

Image renders successfully

Actual behavior

Preview app shows error state

Setup

I built the single binary from HEAD (009f1e508efe56f31b6c203567931c507f387d04) of stable-5.0 and run it locally.

Screenshot 2024-03-07 at 13 14 30
fschade commented 7 months ago

i can confrim 😢 list item previews are working here but as soon as i open the file.... broken

2024-03-07T13:35:10+01:00 ERR failed to list storage spaces error="rpc error: code = PermissionDenied desc = gateway: error calling ListReceivedShares: rpc error: code = PermissionDenied desc = auth: core access token is invalid" filters=[{"Term":{"Path":"/public/XrXJuqIhEfGHjcx/ag_perso_v.jpg"},"type":5},{"Term":{"SpaceType":"+mountpoint"},"type":4}] pkg=rgrpc service=ocm status={"code":15,"message":"error listing spaces","trace":"f8d454267e76c3d959dbe0479b192f23"} traceid=f8d454267e76c3d959dbe0479b192f23
saw-jan commented 7 months ago

Is this a flaky one? because I couldn't reproduce with current stable-5.0 (commit: a18d54afeb) Started just with:

PROXY_ENABLE_BASIC_AUTH=true \
./ocis/bin/ocis server

versions:

ownCloud Web UI 8.0.0-rc.6 
Infinite Scale 5.0.0-rc.5+a18d54afeb Community 
kulmann commented 7 months ago

Is this a flaky one? because I couldn't reproduce with current stable-5.0 (commit: a18d54afeb) Started just with:

PROXY_ENABLE_BASIC_AUTH=true \
./ocis/bin/ocis server

versions:

ownCloud Web UI 8.0.0-rc.6 
Infinite Scale 5.0.0-rc.5+a18d54afeb Community 

Not flaky. 100% reproducible for me. But it only happens for password protected public links, maybe yours didn't have a password?

saw-jan commented 7 months ago

The link was password-protected because I used the default ocis config. Maybe I missed something? I just built the latest stable-5.0 and ran ocis with PROXY_ENABLE_BASIC_AUTH=true ./ocis/bin/ocis server

saw-jan commented 7 months ago

Still the same versions but now it reproduces after couple of retries:

ownCloud Web UI 8.0.0-rc.6
Infinite Scale 5.0.0-rc.5+a18d54afeb Community