jisa_poiur Posted December 18, 2023 Report Posted December 18, 2023 (edited) I use machinesAuth to avoid requesting the access code from the application again after the first login when, for example, the bot is restarted. But here's what I noticed, if the account is confirmed via mail - then after login a file with machine is created, but if the account is confirmed via application - then after login only cellid-***.txt is created and when logging in again it asks for the code from the application. I have looked everywhere, but did not find the answer to my question. I also noticed that the machineAuthToken event is triggered only when a code is requested from mail I use node-steam-user 5.0.4 const Account = new SteamUser({ dataDirectory: "./data", machineIdType: SteamUser.EMachineIDType.AccountNameGenerated, autoRelogin: true }); Account.logOn({ accountName: 'login', password: 'password' }) Edited December 18, 2023 by jisa_poiur Quote
Dr. McKay Posted December 19, 2023 Report Posted December 19, 2023 Machine auths are not issued for accounts that are using mobile 2FA. If you want to log on to such an account without providing a code, you'll need to use a refresh token. Quote
jisa_poiur Posted December 19, 2023 Author Report Posted December 19, 2023 (edited) 14 hours ago, Dr. McKay said: Machine auths are not issued for accounts that are using mobile 2FA. If you want to log on to such an account without providing a code, you'll need to use a refresh token. Thanks for the reply. I made the system via tokens, but when the user logs in via code from mail, it creates machineAuthToken.name.txt I tried passing the machineIdType field to the SteamUser instance: SteamUser.EMachineIDType.None, but the file is still created, is there any way to disable this? Edited December 19, 2023 by jisa_poiur Quote
Dr. McKay Posted December 19, 2023 Report Posted December 19, 2023 Machine auth tokens and machine IDs are two separate things. There isn't a direct way to prevent machineAuthToken files from being saved, but you could implement a custom storage engine if you wanted, and suppress saving them that way. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.