ValvePython / steam

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

Correct TOTP URI #313

Closed James-E-A closed 3 years ago

James-E-A commented 3 years ago

Steam requires a 5-digit code, but most TOTP software has 6 digits as the default when a length is not specified.

This commit will patch, when necessary, the value of Steam's endpoint's erroneous response.

rossengeorgiev commented 3 years ago

That uri is correct for accounts that have TOTP enabled. There is no need to modify any of the data returned from Steam. If you are looking to use 3rd-party 2FA apps like AndOTP or Aegis, then check out steamctl authenticator qrcode

James-E-A commented 3 years ago

That uri is correct… There is no need to modify any of the data returned from Steam.

The default value for an omitted digits parameter is widely recognized ([1][2][3][4]) to be 6; therefore Steam's API is outputting a slightly malformed URI.

I'm glad to see that other software may patch this mistake later on, though I still contend it'd be appropriate to fix it immediately upon receipt.

rossengeorgiev commented 3 years ago

The URI is correct, it was intended for classic TOTP, not Steam TOTP.