From 81585da939b043d38137c40ea8a5de3171fb7fe0 Mon Sep 17 00:00:00 2001 From: Jonathan Barrow Date: Sat, 24 Sep 2022 08:41:02 -0400 Subject: [PATCH] Made getUserBasic spec issue more clear --- src/database.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/database.js b/src/database.js index 20186bb..1f00cbf 100644 --- a/src/database.js +++ b/src/database.js @@ -54,6 +54,8 @@ async function doesUserExist(username) { async function getUserBasic(token) { verifyConnected(); + // Wii U sends Basic auth as `username password`, where the password may not have spaces + // This is not to spec, but that is the consoles fault not ours const [username, password] = Buffer.from(token, 'base64').toString().split(' '); const user = await getUserByUsername(username);