Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Request] [Tutorial] Import maFile from iDevices #350

Closed
Infinitay opened this issue May 28, 2017 · 37 comments
Closed

[Request] [Tutorial] Import maFile from iDevices #350

Infinitay opened this issue May 28, 2017 · 37 comments

Comments

@Infinitay
Copy link

Infinitay commented May 28, 2017

Requirements

  • Jailbroken iDevice (NOT ENTIRELY SURE, YOU MAY BE ABLE TO DO THIS WITHOUT JB)
  • File browser tweak on your iDevice (Filza recommended)
  • Notepad++ along with plugin called NppBplistPlugin, however currently it's labeled as Notepad++ bplist plugin within the plugin manager. We need this to view the downloaded contents of our downloaded file from .../Documents/Steamguard/.

Important locations & files

  • /var/mobile/Containers/Data/Application/F7CE8###-####-####-####-############/ is the Steam app folder
  • The root folder (listed above) contains a file named .com.apple.blablabla.plist which has our device_id
  • .../Documents/Steamguard contains the file(s) we need to create the .maFile

Tutorial

Gathering required files and information

  • Note, if you're using Filza, make sure to toggle "WebDAV Server" within the app's settings.
  1. On your iDevice, open Filza or any other tweak/app to browse your filesystem to the Steam app folder. Location is listed above, ignore the #, it's there for my privacy in case folders are unique.
  2. Either using the WebDAV server within Filza or other means, download the files under .../Documents/Steamguard. Do not rename them or anything to be safe. We will use this to create our .maFile manually as SDA currently does not support iDevice imports.
  3. Now we need to get our unique device id. Go back to the root Steam application folder and I'd recommend simply tapping to open the only .plist file there (see above for partial name). Next, tap Root to expand the menu and tap the i in the MCMMetadataUUID variable. Copy the value and send it to yourself. OR you can download that file as well and I'm sure using Notepad++ you can still retrieve the UUID.
  • It's important to get the UUID located within the .plist as our actual devices UUID is not equal the UUID within the .plist file. Better safe then sorry.

Creating our .maFile to import

  • If you haven't already, download Notepad++ and install the Notepad++ bplist plugin via the plugin manager.
  1. Open the downloaded Steamguard-YourSteamIDHere file using Notepad++. Scroll down to where you see <string>shared_secret</string>. From here I recommend labeling each variable and it's value. Do not save the file should you choose to modify the file. Click here to see an example on how I labeled my file. I highly doubt these 24 lines will change it's order. Keep in mind, the first 12 lines, as shown in the picture, represent the variables, followed by the next 12 lines whose values are assigned to the variables above.
  2. Create a new file called _STEAMID_.maFile, make sure to scroll up and select All files as the file type, and preferably through Notepad++ and not windows explorer/notepad. Save the file within the folder maFiles, if it's not there, make it.
  3. Using the .maFile's manifest listed below under the Manifiest Template headline and copy & paste the necessary values. Copy values from your downloaded Steamguard - SteamID and replace the REPLACEME text.
  • IF REPLACEME IS WITHIN QUOTATIONS, MAKE SURE TO KEEP THE QUOTES!

Importing our .maFile

  • By this step, you should have no longer have any REPLACEME occurrences within your newly created .maFile (located within .../SteamDeskAuth/maFiles)
  1. Open SDA. Click File -> Import Account -> From maFile
  • Don't enter anything into the text box as we never set any encryption, yet.
  1. Click "Select .maFile....." and browse to and select the newly created .maFile, located within /SDA/maFiles if you followed my instructions.

Encryption - Optional

  • Personally I haven't done this yet but I'm 99% sure it will work.
  1. Within the account list box, make sure to select the account you wish to encrypt.
  2. Click Setup Encryption and follow the steps, simple right?
  • If you regret this, after clicking setup encryption, just hit cancel

Final Remarks

Well, we're done! You should have and hopefully successfully the steam guard auth code from your iDevice to SDA. Make sure you double check to see if the code displayed on your iDevice corresponds with the code within the SDA application. I'm not sure if device_id matters when creating .maFile, but when using SDA to setup a new account, it generates a new and random value. For instance, when setting up the same steam account, twice, it's device_id value was assigned android:###blablabla###.

.maFile Template

{"shared_secret":"REPLACEME","serial_number":"REPLACEME","revocation_code":"REPLACEME","uri":"REPLACEME","server_time":REPLACEME,"account_name":"REPLACEME","token_gid":"REPLACEME","identity_secret":"REPLACEME","secret_1":"REPLACEME","status":1,"device_id":"iphone:REPLACEME","fully_enrolled":true,"Session":{"SessionID":"","SteamLogin":"","SteamLoginSecure":"","WebCookie":"","OAuthToken":"","SteamID":REPLACEME}}

manifest.json Template - Not needed

{"encrypted":false,"first_run":false,"entries":[{"encryption_iv":null,"encryption_salt":null,"filename":"REPLACEME.maFile","steamid":REPLACEME},{"encryption_iv":null,"encryption_salt":null,"filename":"REPLACEME.maFile","steamid":REPLACEME}],"periodic_checking":false,"periodic_checking_interval":5,"periodic_checking_checkall":false,"auto_confirm_market_transactions":false,"auto_confirm_trades":false}

  • Ignore, only here for reference or for someone who doesn't have the file.
  • If you don't have the file, create it just as you created .maFile, but instead name the file manifest.json.
  • If you want to add more accounts, after the element within entries, added a comma followed by {"encryption_iv":null,"encryption_salt":null,"filename":"REPLACEME.maFile","steamid":REPLACEME}
  • However, it's easier to just import the .maFile
@Infinitay
Copy link
Author

Infinitay commented May 28, 2017

Hopefully I helped some of us iDevice users. If anyone could implement this into SDA that'd be wonderful. Unfortunately I only know Java, and even then I'm just a beginner student otherwise I'd love to develop a tool that automatically creates the .maFile after connecting your jailbroke iDevice. Of course, if it's even possible with Java :p

ignore below, hoping this helps with people finding this tutorial
iphone, ipod, ipad, idevice, import from iphone, sda, steam authenticator, how to import

@Chasnechok
Copy link

Thank you man!!! U're the best!

@zyoi
Copy link

zyoi commented Jun 19, 2019

  • /var/mobile/Containers/Data/Application/F7CE8###-####-####-####-############/ is the Steam app folder

On my iPad 4 folder starts with 9F23EB8D.

@melvyn2
Copy link

melvyn2 commented Aug 18, 2019

Hey, I'm trying to put a file back into steam mobile. Do you have a template of what it looks like in the original form? Thanks

@Infinitay
Copy link
Author

On my iPad 4 folder starts with 9F23EB8D

Guess I didn’t realize at the time I posted this that the folder name may change. Now a days I think tools/apps will show the app name as the folder name so you can know what’s what.

——

Unfortunately I don’t, I haven’t touched anything ever since I made this post, and I no longer have a jailbroken device. You weren’t supposed to move the file out, just view its contents. Have you tried re-installing the app? Also I was looking over my post and there is a photo of what the plist file looked like I believe, as well as a template for the mafile

@melvyn2
Copy link

melvyn2 commented Aug 18, 2019

What I mean is that I have an maFile created outside of Steam mobile, that I want to insert back in. Also, the template is incomplete (there is a </dict> at the top, indicating there was one above).

@Arslan30
Copy link

Hi!
Sorry for pinging this thread a year later but this is closet to problem i'm facing...I have multiple accounts set on my SDA on PC and i want to import MaFiles to steam authenticator on my Jb iphone...Can someone please provide a solution towards it @Infinitay looking at you brother

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

@Arslan30 I have a code stub that converts json based maFiles to the ios format. I'll send it over tomorrow and try to help with installing the files.

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

https://gist.github.com/melvyn2/aaf514254f87d7f44b8140537cce6c87 is a python script that will convert your maFiles to the iOS format. You'll need to have a working python3 installation, with pip. The script requires bpylist, which you can install by running pip3 install bpylist.
Start by downloading the script, then copying your target maFile to the same folder as the script (you don't need to copy manifest.json).
Run the script with python3 convert.py your_steamid_here.maFile, replacing your_steamid_here with your steamid, or whatever the maFile is named.
The script will create a file named Steamguard-your_steamid_here.plist, which is the file that you can put in the documents folder of steam on your phone. Simply follow the instructions given before, but place the file into the Documents folder instead of copying it out.

@Arslan30
Copy link

@melvyn2 can you confirm that i have to install Microsoft VS build tools ~5GB to install bpylist?

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

You shouldn't have to, the package is pure python. Try installing bpylist2 instead?

@Arslan30
Copy link

You shouldn't have to, the package is pure python. Try installing bpylist2 instead?

C:\Program Files\Python37\Lib\site-packages\bpylist2-3.0.2.dist-info this is path for my bpylist2 script...i copied file here and Ran the command...command didn't gave any error but there's no output file as u specified

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

hmm. When you ran the command, it didn't print anything to the cmd window?

@Arslan30
Copy link

Arslan30 commented Jul 20, 2020

hmm. When you ran the command, it didn't print anything to the cmd window?

nothing
image

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

I've updated the script with some debug prints. Download it again, and tell me how it goes.

@Arslan30
Copy link

This is what I'm encountering when installing bpylist
image
and i'm still not getting any response from bpylist 2, same results...and i have tried without having a mafile in folder and still not response

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

bpylist2 works fine for me, so I don't think that's the issue; don't worry about installing 'normal' bpylist. After having downloaded the updated script, does running it still give no output?

@Arslan30
Copy link

bpylist2 works fine for me, so I don't think that's the issue; don't worry about installing 'normal' bpylist. After having downloaded the updated script, does running it still give no output?

yeah exactly i uninstalled and installed the script but same result...I even tried it without copying mafile in directory and it still runs the same way it was running before

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

Can you try running it with no arguments at all?

@Arslan30
Copy link

Can you try running it with no arguments at all?

image
I'm sorry but i don't understand which arguments you're referring to as i'm running everything as you're guiding me to

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

I meant the command arguments; the things after python3 convert.py. Without the arguments, the command would simply be python3 convert.py.

@Arslan30
Copy link

Arslan30 commented Jul 20, 2020

I meant the command arguments; the things after python3 convert.py. Without the arguments, the command would simply be python3 convert.py.

still the same response....isn't there a debug argument or log argument with it so you can understand why am i facing this issue?
image

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

isn't there a debug argument or log argument

Yeah, try running it with python3 -v convert.py. This is a really weird error, because the program should crash without any arguments. This look like a base python error more than a script error.

@Arslan30
Copy link

Where should be convert.py located because i can't find such a script anywhere in my entire python directory/subdirectories....
image
Are these all the files??
Also i ran python -v convert.py and it's showing the same behaviour
image

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

Ohhhh, that probably explains all the problems. You should create a folder on your desktop, or in downloads, and put the maFile and convert.py in that folder. cd to that folder, then run python3 convert.py 76561198301342675.maFile

@Arslan30
Copy link

but i don't have a convert.py file in any location? can you give me a raw code so i can save one?

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

https://gist.github.com/melvyn2/aaf514254f87d7f44b8140537cce6c87 is the link to convert.py. Go there and click 'Download as ZIP' and unzip it. That should give you convert.py

@Arslan30
Copy link

OK.I have a folder named ma in D drive and inside are my mafile and convert.py....I opened an elevated CMD and cd there and ran the command python3 convert.py myMafilename and still nothing

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

can you send a screenshot of the console output and folder?

@Arslan30
Copy link

can you send a screenshot of the console output and folder?

nvm i don't know why but i got my required file by doing python instead of python3....sorry to waste so much of your time....i have python 3.7 and python3 should have worked but i don't know much about python
Thanks alot for all your assistance

@melvyn2
Copy link

melvyn2 commented Jul 20, 2020

No problem!

@Infinitay
Copy link
Author

Closing because there's no need for this to be open as it's not an issue.

@hellotinh03
Copy link

As of the Steam Mobile App update on Oct 13 2022, this method doesn't work anymore. The authentication system got a rework.
Only thing I can find in the Documents folder is a log file named 'current.txt'.

@melvyn2
Copy link

melvyn2 commented Nov 17, 2022

Same problem, I had to recreate my mobile authenticator and I haven't been able to extract the needed keys yet either.

@hellotinh03
Copy link

A workaround is to use AppStore++ to downgrade the app to v2.0.20 (last update before 3.0, aka the rework). The app still works fine, for now at least.

@shinji257
Copy link

shinji257 commented Dec 6, 2023

Really old issue report but I wanted to note that I was able to convert the SteamGuard file I pulled (using an old Steam android app) to a layout that SDA expects for import using the maFile template. The only thing not really defined was the device_id. I just put android:X on that spot and SDA took it just fine.

@hellotinh03
Copy link

(using an old Steam android app)
#780

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants