ValvePython / steam

☁️ Python package for interacting with Steam
http://steam.readthedocs.io
MIT License
1.06k stars 129 forks source link

Document './mysecrets.json' #363

Closed luckydonald closed 2 years ago

luckydonald commented 2 years ago

So the docs about steam authenticator/guard are about a sa.secrets or mysecrets.json file. But it is missing a example of actual (fake) values.

luckydonald commented 2 years ago

Am trying to get the auth codes from my iPhone in there (and what I found looks promising) as I don't really wanna log out there, but have no clue what format that secrets dict needs to be.

Gobot1234 commented 2 years ago

It should be a dictionary with optionally shared_secret (for logging in) and identity_secret (less likely to be useful as it's for generating trading confirmation codes) keys which values should be base 64 strings.

luckydonald commented 2 years ago

So it needs the shared_secret? How does that look like? I have 40 chars of 0-9, A-F and a steamID64 (76561198044975919) as far as I can see, hoping that's enough.

luckydonald commented 2 years ago

I figured from the android code it's at least

{
 "some_steam_id": {"steamid": "some_steam_id"},
 ...
}

But I don't know the format of that steam id (or it's type, if it's string)

luckydonald commented 2 years ago

Currently either it's a dead end or the format is wrong.

image
rossengeorgiev commented 2 years ago

Format is what Steam returns, you only need this:

{
    "account_name": "accountname",
    "shared_secret": "base64 secret",
    "status": 1,
    "token_gid": "token gid",
}

Or you can simply use steamctl authenticator add --from-secret <BASE64 SHARED SECRET> <accountname>

luckydonald commented 2 years ago

Closed? Is this documented in the docs now?

r1bnc commented 2 years ago

I dont think so? https://steam.readthedocs.io/en/stable/api/steam.guard.html

luckydonald commented 2 years ago

So it's still undocumented, I don't think that's good.