mirror of
https://github.com/jpochyla/psst.git
synced 2026-04-27 07:25:52 +03:00
[PR #693] [MERGED] Implement Login5 Authorization #665
Labels
No labels
api
bug
build
documentation
duplicate
enhancement
good first issue
help wanted
idea
invalid
linux
lowprio
macos
pull-request
upstream
windows
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/psst#665
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/jpochyla/psst/pull/693
Author: @Pogodaanton
Created: 9/21/2025
Status: ✅ Merged
Merged: 11/16/2025
Merged by: @jacksongoode
Base:
main← Head:feat/login5-prototype📝 Commits (10+)
01e94f4feat: Add rudimentary login5 auth implementation82cb6e4fix: Enable login5 as access_token source for psst-gui9abd1c1fix: Enable login5 as access_token source for psst-core cdn330b377fix: Add token expiry check to login5 and spclientbc9609frefactor: Consolidate client token usage and system info relevant constants84f9b41fix: Send correct system info to client token servicea44184drefactor: Simplify token structc5291a1chore: Remove excessive logginge13aa2dReview changes587e8caClippy lints📊 Changes
19 files changed (+821 additions, -93 deletions)
View changed files
📝
Cargo.lock(+151 -22)📝
psst-core/Cargo.toml(+6 -0)📝
psst-core/src/cdn.rs(+6 -5)📝
psst-core/src/error.rs(+8 -0)📝
psst-core/src/lib.rs(+1 -0)📝
psst-core/src/player/queue.rs(+2 -7)➕
psst-core/src/session/client_token.rs(+252 -0)➕
psst-core/src/session/login5.rs(+283 -0)📝
psst-core/src/session/mod.rs(+3 -0)➕
psst-core/src/session/token.rs(+20 -0)➕
psst-core/src/system_info.rs(+12 -0)📝
psst-core/src/util.rs(+45 -4)📝
psst-gui/src/data/album.rs(+2 -7)📝
psst-gui/src/data/config.rs(+8 -26)📝
psst-gui/src/data/mod.rs(+4 -8)📝
psst-gui/src/data/promise.rs(+3 -6)📝
psst-gui/src/data/track.rs(+3 -0)📝
psst-gui/src/data/utils.rs(+1 -0)📝
psst-gui/src/webapi/client.rs(+11 -8)📄 Description
Retrieving an
access_tokenover Keymaster broke a while ago. The librespot folks alleviated the auth question by resorting to the Login5 interface instead. This pull-request ports the necessary code for Auth5 to work inpsst-core.Implementation Considerations
Protobuf
The new Auth5 interface requires a lot of new protobuf messages. While we could plug them into
psst-protocol, I realized that the current.protofiles in psst haven't been touched for 5 years. I could not even get thepb-rsbuild script to work without having to edit the existing protobuf files. I'm sure I could eventually figure out the build process, however, Librespot already provides their protobuf code in a neat package (librespot-protocol). I propose slowly moving our code to use it instead.Dependencies
As I am quite a beginner regarding Rust, I have ported the code in a rudimentary way. I pulled in quite a few more dependencies from librespot to make the code work. We need to look into whether we can replace them with existing dependencies.
PR State
The PR is in a reviewable state. All the features I wished to implement are included now. This includes:
TODOs
Fixes #687
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.