protonscr

Client tries to write to other user's and root dir

steamclosed
ValveSoftware/steam-for-linux#9679 · opened 2023-06-19 by z0rti · updated 2023-06-19 · 1 comments · github
Zz0rti 2023-06-19 github

Steam-Version: 1686880776
Steam-Client: Build-Datum: Fr., 16. Juni 3:41 UTC -08:00
Steam: Webbuild-Datum: Fr., 16. Juni 3:10 UTC -08:00
Steam-API-Version: SteamClient020

Ubuntu 20.04.6 LTS

  • Opted into Steam client beta?: [Yes/No]
    No but yes.

Please describe your issue in as much detail as possible:

Trying to add a new SteamLibrary dir to Storage

stdout log:

Couldn't write /.steam_exec_test.sh: Permission Denied
src/tier1/fileio.cpp (3931) : Assertion Failed: statvfs64 failed for /run/user/1000/doc, errno 13

Execute: /home/zorti/Steam/ubuntu12_64/disk-free /run/user/1000/doc >/tmp/disk-free.eJdvsL
src/tier1/fileio.cpp (3962) : disk-free command failed

Couldn't write /run/user/1000/doc/.steam_exec_test.sh: Permission Denied

src/tier1/fileio.cpp (3931) : Assertion Failed: statvfs64 failed for /home/klaus/.cache/doc, errno 13
Execute: /home/zorti/Steam/ubuntu12_64/disk-free /home/klaus/.cache/doc >/tmp/disk-free.GjLK0L
src/tier1/fileio.cpp (3962) : disk-free command failed
Couldn't write /home/klaus/.cache/doc/.steam_exec_test.sh: Permission Denied

src/tier1/fileio.cpp (3885) : statvfs64 reports success but zero free space

src/tier1/fileio.cpp (3931) : Assertion Failed: statvfs64 failed for /home/five/.cache/doc, errno 13
Execute: /home/zorti/Steam/ubuntu12_64/disk-free /home/five/.cache/doc >/tmp/disk-free.t9nXTM
realpath errno 13
src/tier1/fileio.cpp (3962) : disk-free command failed

Couldn't write /home/five/.cache/doc/.steam_exec_test.sh: Permission Denied
Couldn't write /mnt/externalHDD/.steam_exec_test.sh: Permission Denied

It probably should not try to write to the main root dir, and other user's dirs and every mounted HDD's root dir?
It seems like it does scan every user that is currently logged in and has a gvfsd running
Maybe it should only scan dirs for the current user that is actually running steam
And for the root dir of every mounted disk: maybe scan only disks that are added manually? Or a dir in the home?

Steps for reproducing this issue:

While multiple users are logged in (start a new term, 'sudo -i -u user2')
Start steam client (as user1), Settings, Storage, PLUS (+)

Kkisak-valve maintainer 2023-06-19 github

Hello @z0rti, https://github.com/ValveSoftware/steam-for-linux/issues/8081#issuecomment-954352996 notes that Steam is looking at /proc/mounts to generate the list of potential partitions that could be used to add a secondary Steam library folder and this basic test is to check if your regular unprivileged user is allowed to write an executable file to it. Trying and failing to write to these partitions should be harmless.