Page 1 of 1
[0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 4:46 pm
by Gerkiz
Hello,
Updating to 0.18.7 and trying to start a server headless results with:
Code: Select all
Only one of token or username and password can be set at once.
What i've tried:
1. Username, token and no password (as before the update)
Code: Select all
0.564 Error CommandLineMultiplayer.cpp:88: Only one of token or username and password can be set at once.
2. Token only - no username/password
Code: Select all
91.740 Error ServerMultiplayerManager.cpp:710: Matching server connection failed: Error when creating server game: Download failed (status code 401): auth error: Missing username.
Am I doing something wrong?
Log is uploaded.
/Gerkiz
Re: [0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 5:47 pm
by Morthan
Having the same issue here but managed to start the server (and join and play). When using a token it seems you need to ditch both "username" and "password" from the server-settings.json config! It's a bit weird but it works, seems to only require the token, not the username?
I have the following settings in the server-settings.json:
Code: Select all
"_comment_credentials": "Your factorio.com login credentials. Required for games with visibility public",
"username": "username",
"password": "",
"_comment_token": "Authentication token. May be used instead of 'password' above.",
"token": "some.token.info.here",
The game won't start with this info.
Removing the "comment_credentials", "username" and "password" resulted in a started server. I could also join and play like normal.
Code: Select all
"_comment_token": "Authentication token. May be used instead of 'password' above.",
"token": "some.token.info.here",
Noticed the API send me a serverHash, I'm guessing this is important?
Code: Select all
2.442 Hosting game at IP ADDR:({0.0.0.0:34197})
2.442 Info HttpSharedState.cpp:54: Downloading https://auth.factorio.com/generate-server-padlock-2?api_version=4
2.855 Info AuthServerConnector.cpp:66: Obtained serverPadlock for serverHash (this.is.important.right?) from the auth server.
Re: [0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 5:55 pm
by Loewchen
Morthan wrote: ↑Tue Feb 18, 2020 5:47 pm
Having the same issue here but managed to start the server (and join and play). When using a token it seems you need to ditch both "username" and "password" from the server-settings.json config! It's a bit weird but it works, seems to only require the token, not the username?
Then you do NOT have the issue, ofc you need to remove username and password if you have the token set, that is the whole point.
Re: [0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 6:08 pm
by Hanakocz
Well, starting server is one thing, but do you have the server listed within public servers?
Re: [0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 6:10 pm
by billbo99
0.18.8 fixes this
Re: [0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 6:18 pm
by Rseding91
billbo99 wrote: ↑Tue Feb 18, 2020 6:10 pm
0.18.8 fixes this
Yes.
Re: [0.18.7] Authenticating with token does not work: "auth error: Missing username"
Posted: Tue Feb 18, 2020 7:02 pm
by Morthan
Loewchen wrote: ↑Tue Feb 18, 2020 5:55 pm
Morthan wrote: ↑Tue Feb 18, 2020 5:47 pm
Having the same issue here but managed to start the server (and join and play). When using a token it seems you need to ditch both "username" and "password" from the server-settings.json config! It's a bit weird but it works, seems to only require the token, not the username?
Then you do NOT have the issue, ofc you need to remove username and password if you have the token set, that is the whole point.
Pardon me for thinking the token only replaced the password. Thought you still needed the username identifier.
Also forgot to adjust the starting part of the text. I actually had the issues and was looking at the forum to see if someone reported it already. Turned out they did and I wanted to add my stuff at it, but kept on experimenting. Found a "solution" so I adjusted the text partially.
Sorry for that!
Hanakocz wrote: ↑Tue Feb 18, 2020 6:08 pm
Well, starting server is one thing, but do you have the server listed within public servers?
I don't know. I'm currently joining on IP and give that out to my friends. It's handy if it shows in the serverlist but the IP part isn't that hard as the server logs show the external IP when starting.