flathub / com.valvesoftware.Steam

https://flathub.org/apps/details/com.valvesoftware.Steam
338 stars 69 forks source link

Games wont launch with --unshare-network #1304

Open ghost opened 4 months ago

ghost commented 4 months ago

I'm facing an issue where launching steam with network perms disabled (either with Flatseal or through --unshare=network), opens steam just fine, but when trying to launch a game, some games don't open (listed a few which I've tried).

If i enable the network perm, but disable my internet connection (through lets say NetworkManager) , steam again opens just fine, AND i am also able to open the game.

I would like to restrict network access to steam when actually playing games, but still allow the background system to access the internet. AFAIK steam offline mode, doesn't quite restrict the network access to the actual games , but correct me if i am wrong.

Games I've tried that does not open at all Tell me why (Straight up fails) tell-me-why.log.txt

Crysis 3 remastered (Retries to launch, but fails over and over again): crysis3.log.txt

Last of us Remastered I dont have a trace for this as I uninstalled the game (just wanted to test fsr 3 FG at that time) , but I got a popup stating that Steam SDK was not found and it closed after that.

Counter Strike 2 (flashes Valve Logo but immediately closes after that; this may be used to reproduce the issue as this is a free to play game) cs2.txt

Games I've tried that does open Star wars Jedi Fallen Order (the drm free executable) Dusk Batman Arkham Knight

Distribution Arch Linux

flatpak --version Flatpak 1.15.8

flatpak --gl-drivers default host

Does this issue reproduce with native Steam Have not tested

ghost commented 4 months ago

Update 1: Alright, ive tried 2 more now:

Deponia The Complete journey Spec Ops The Line

Both of which apparently had a linux native version which got installed OOTB, and which opens and runs fine, even when steam is launched with --unshare=network.

The problem seems to occur only when i specifically download the windows versions of these games (by enabling the proton compatibility in the settings)...I pretty much get the same error as the ones mentioned in the logs...that being:

[S_API FAIL] SteamAPI_Init() failed; create pipe failed.pid 2410 != 2409, skipping destruction (fork without exec?)

If this is getting too boring to read All i wanna know is, how is steam launched normally (but with internet switched off through NetworkManager) able to run these games fine, but when launched with --unshare=network (which I would think does the same thing but just for this flatpak app) , gives these SteamAPI_Init errors all the time (well except for DRM free games) ?