-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
[4.0.0] Authentication error 400 #2494
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
Comments
Can confirm, same error 400 every start since 4.0.0 on Windows 10. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Yes, it fails to get the access token. Error: 400. Since 4.0.0 on Windows 11 x86-64. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
I hope its just spotube and not spoti related. My friend used unofficial app and spoti deleted all of his playlists and other data... |
I just checked by redownloading Spotify and logging in, all my information is here with no sign of any tweaks, flags, or deletions. It's unlikely Spotify would do something like that for spotube specifically because spotube doesn't use Spotify requests to get songs but rather uses YouTube and just uses your playlist data to generate playlists and recommendations from Spotify instead, which isn't against their terms |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
That's what about more than half of us did, so I'm not sure what you're trying to get at. EDIT: Please STOP moderating issues you have no permission to moderate. You seem to be very technically unaware, and are beginning to mark issues as "duplicate" which have no relation to this current issue at all by basing their "duplicate nature" just off of a few similar words. |
JUST by opening the app from clean install i get a bunch of errors. take the log please. don't put me as spam. log spotube 4.0.1 android 10.txt
|
|
I have tried your troubleshooting 3 times. Also uninstalled and reinstalled the app 3 times. |
i'm on arch linux. login does seem to work with latest logs: |
Please anyone having the login issue after v4.0.1 continue the discussion in: #2525 |
Damn... it works |
This is issue is ready to be closed fixed in 4.0.1 |
That's from old version |
Closing this as we've finally resolved the login issue |
I'm leaving this Node.js typescript implementation to generate TOTP for the endpoint. In Dart we used , import { TOTP } from "totp-generator";
async function main() {
const secretSauce = "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567";
const base32FromBytes = (e: Uint8Array) => {
let t = 0;
let n = 0;
let r = "";
for (let i = 0; i < e.length; i++) {
n = n << 8 | e[i];
t += 8;
while (t >= 5) {
r += secretSauce[n >>> t - 5 & 31];
t -= 5;
}
}
if (t > 0) {
r += secretSauce[n << 5 - t & 31];
}
return r;
}
function cleanBuffer(e: string): Uint8Array<ArrayBuffer> {
e = e.replace(/ /g, "");
const t = new ArrayBuffer(e.length / 2);
const n = new Uint8Array(t);
for (let r = 0; r < e.length; r += 2) {
n[r / 2] = parseInt(e.substring(r, r + 2), 16);
}
return n;
};
const secretCipherBytes = [12, 56, 76, 33, 88, 44, 88, 33, 78, 78, 11, 66, 22, 22, 55, 69, 54].map((e, t) => e ^ t % 33 + 9)
const secretBytes = new Uint8Array((cleanBuffer(Buffer.from(secretCipherBytes.join(""), "utf8").toString("hex")).buffer));
const secret = base32FromBytes(secretBytes);
const res = await fetch("https://open.spotify.com/server-time").then((e) => e.json())
const timestamp = res["serverTime"];
const totp = TOTP.generate(secret, {
algorithm: "SHA-1",
digits: 6,
period: 30,
timestamp: timestamp * 1000,
});
const currentTimestamp = Math.floor(Date.now() / 1000);
console.log("secretCipherBytes:", secretCipherBytes);
console.log("secretBytes:", secretBytes);
console.log("secret:", secret);
console.log(`https://open.spotify.com/get_access_token?reason=transport&productType=web_player&totp=${totp.otp}&totpVer=5&ts=${currentTimestamp}`);
}
main(); |
i cant even get to the log on page, when i click log in a blank white page and the app crashes
|
Do you know of a project that has implemented fully functional node.js code or is working on it? The ones I've seen are Dart and Python, but I need to update a node.js implementation. |
I don't think it was a good idea for you to have posted this here. Because this code here is a bit borderline, and Spotify now has the right to either rotate their secrets, patch the flaw you're exploiting, or take further action. |
Is there an existing issue for this? (Please read the description)
Current Behavior
I'm experiencing an Authentication error 400 when I start up Spotube. Everything seems to be working properly, except the bulk downloading of Spotify Playlists. And because this is the main reason for me to use Spotube to begin with, I find it a rather annoying one ;)
I run 4.0.0 on Win10
Is this a known issue?
Expected Behavior
The app running without this error and the playlist download option in working order
Steps to reproduce
The error shows on start up
Logs
[2025-03-14 12:17:44.015229]---------------------
DioException [bad response]: This exception was thrown because the response has a status code of 401 and RequestOptions.validateStatus was configured to throw for this status code.
The status code of 401 has the following meaning: "Client error - the request contains bad syntax or cannot be fulfilled"
Read more about status codes at https://developer.mozilla.org/en-US/docs/Web/HTTP/Status
In order to resolve this exception you typically have either to verify and fix your request code or you have to fix the server code.
#0 DioMixin.fetch (package:dio/src/dio_mixin.dart:520)
#1 CustomSpotifyEndpoints.getFriendActivity (package:spotube/services/custom_spotify_endpoints/spotify_endpoints.dart:113)
#2 FutureHandlerProviderElementMixin.handleFuture.. (package:riverpod/src/async_notifier/base.dart:355)
[2025-03-14 12:17:44.430059]---------------------
FormatException: Invalid number (at character 1)
^
#0 int._handleFormatError (dart:core-patch/integers_patch.dart:135)
#1 int.parse (dart:core-patch/integers_patch.dart:53)
#2 ServiceUtils.checkForUpdates (package:spotube/utils/service_utils.dart:353)
Operating System
Windows 10
Spotube version
v4.0.0
Installation source
Website (spotube.krtirtho.dev), GitHub Releases (Binary)
Additional information
No response
Self grab
The text was updated successfully, but these errors were encountered: