Didstopia / starbound-server

Provides a dedicated linux server for Starbound running inside a Docker container.
29 stars 12 forks source link

Does not work with SteamGuard #1

Open sgrigson opened 8 years ago

sgrigson commented 8 years ago

Normally when issuing a login request against the Steam API, if SteamGuard is enabled for the account, there is a pause allowing the user time to enter the verification code. This step in two-factor authentication is required in order to authorize a new computer (and copy down the cached auth to the server).

However, the script written attempts to apply other scripts after the login command, and does not pause for user input in the event that a steamguard code is required.

The workaround, of disabling SteamGuard, is a bad idea, and a security risk.

I'd suggest enabling SteamGuard on your account (you can always disable it later) and testing the setup/install process and applying a patch to detect for this eventuality.

Otherwise, I'm pretty excited by this project, and hope I can use it in the future.

Fank commented 7 years ago

@sgrigson if you are using gmail u could use https://hub.docker.com/r/fank/steamcmd-gmail/ My cronjob example:

docker run -t --rm -v ~/.gmail-credential.json:/credential.json -v /var/docker/starbound:/server fank/steamcmd-gmail +login USER PASS +force_install_dir /server +app_update 211820 validate +quit && docker restart starbound
Dids commented 7 years ago

Sorry, completely forgot about this.

As a more universal solution, I'll see about having the startup script wait for the auth token and notify the user that they need to provide it using a docker command.

I can probably come up with a solution that allows you to run docker exec starbound-server auth XXXXX, which will inject the code to the main script/steamcmd, allowing it to continue.

Naturally this will still be a tad cumbersome, but 2FA security is definitely worth it.

sanmadjack commented 4 years ago

Is this not going to be implemented then?

lowensodium commented 4 years ago

Is this not going to be implemented then?

I found a work around.

Set up this docker image as it requires with your steam name and password but also include "-I -t" when creating it, or check the button Console "Interactive & TYY" if you are using Portainer

Start the container and then attach to it's console using "docker attach containername" or use the attach button in portainer.

You should see it start up and when it gets to the authenticate part, it will stop and ask you to enter your steam guard code.

After that, it hasn't asked me for the code again.

edit: I changed this post because I found out that most of my steps were not required and corrected them

dschmidt commented 3 years ago

@lowensodium It's probably worth mentioning you need to persist /root/ (or just /root/.steam and possibly /root/Steam) to be reboot safe.

The scripts could/should probably be adjusted to be able to skip login - right now I still need to provide my password although the auth code is already persisted, so I would rather get rid of my password in my docker-compose file.

What do you think?