geel9 / SteamAuth

A C# library that provides vital Steam Mobile Authenticator functionality
MIT License
279 stars 105 forks source link

What about accounts that already had an authenticator linked before using this library? #12

Closed ChernayaKoshka closed 8 years ago

ChernayaKoshka commented 8 years ago

Out of curiosity, how would we save the file? It can never reach the step where the file is saved, for obvious reasons. Is this because Steam will only ever save the linked file once after linking mobile? Is the only available solution to unlink and relink using this library in order to capture the data?

shravan2x commented 8 years ago

If you try to add an authenticator to an account that already has one, the AddAuthenticator() method will return GeneralFailure as the server returns the status as 29.

The only solution would be to unlink and relink if you have to use this library. You could always manually extract the details from your phone to avoid the 7 day trade block.

ChernayaKoshka commented 8 years ago

Do you have a link on how to extract this data from a phone?

shravan2x commented 8 years ago

Never used it myself, but here you go : http://forums.backpack.tf/index.php?/topic/45995-guide-how-to-get-your-shared-secret-from-ios-device-steam-mobile/

pipe01 commented 8 years ago

If you wanna extract from an android phone, I'm developing a fork of SteamDesktopAuthenticator which allows you to extract it, although it's still in development, and if anyone could help me, it would be greatly appreciated.

shravan2x commented 8 years ago

Not sure if this is the place to discuss this, but I may be able to help. What do you need?

pipe01 commented 8 years ago

Well, it can already extract a SteamGuardAccount object from the device, the issue is on the rest of the logic that is needed to implement that to the rest of the program. Also, the object that it extracts is missing the Session value, as it isn't contained on the json file. So that's where I'm stuck at the moment

pipe01 commented 8 years ago

I guess I should somehow generate it by making the user login.

shravan2x commented 8 years ago

I'm thoroughly familiar with the SteamAuth library with the exception of crypto, so AMA.

Alright, answering your question, session is not something that you should be concerned with extracting. A new session is created every time a user logs in. In your code, just leave session empty. It will be filled in when the user calls DoLogin in UserLogin.cs.

DeviceID is another thing that you will not be able to find in the stored secrets. Now there are 2 ways to handle this issue. 1. Get the Mobile app's deviceID, which you would need fiddler for. 2. Generate a random deviceID each time. The latter should be automatically done after my recent pull request. The fact is that the deviceID is currently not checked by Steam servers. This may change in the future, so my recommendation lies with obtaining it.

pipe01 commented 8 years ago

Oh, OK. I think I got it, thanks! I'm gonna test it when I get on my computer.

shravan2x commented 8 years ago

Let me know when you decide on a license. I would like to write a GUI based app for your library. Additionally, I plan to make the following changes :

pipe01 commented 8 years ago

You mean my ADB.net?

shravan2x commented 8 years ago

I mean specifically a tool that enables users to extract their Steam secrets with ease. If this requires your ADB.net library, then I will need your license for that as well.

pipe01 commented 8 years ago

Well, I can make a slim and adapted version of my library, or just use the class that is already in use on my fork, as the shared secret is already obtained by the class. About ios, I have never in my life touched it and I have no idea on how the system even works.

shravan2x commented 8 years ago

I could create the new project right now and allow you write access if you'd like, so you can be a part of what it becomes.

iOS will not be that easy. It will require a root and SSH access if I'm not mistaken. I'm not very familiar with it as well, but I've been around it a couple of times.

pipe01 commented 8 years ago

That's fine by me! I can start developing either a few hours later or tomorrow.

shravan2x commented 8 years ago

Could I have your Steam so we can continue our discussion there without spamming this thread? Feel free to email it to me on the id on my profile.

Jessecar96 commented 8 years ago

Fixed with #17