Skip to content
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

Support authentication with the Basic scheme for Invidious instances #5569

Merged
merged 2 commits into from
Aug 23, 2024

Conversation

absidue
Copy link
Member

@absidue absidue commented Aug 14, 2024

Support authentication with the Basic scheme for Invidious instances

Pull Request Type

  • Feature Implementation

Related issue

closes #686

Description

This pull request adds support for using Invidious instances that use the Basic authentication scheme username:[email protected]. Since the original issue was opened a lot had changed and more than just the thumbnails were broken, so this pull request adds support everywhere from the API requests, to the RSS feeds, as well asthe audio and legacy formats and of course the images.

Outside of Electron with the changes in this pull request I only expect the API requests and the RSS feeds to work.

This will likely cause a bunch of conflicts with the shaka PR but I'll clean those up after this is merged and do the neccessary changes to get it working with the shaka stuff too.

Testing

  1. Connect to an Invidious instance that uses the Basic authentication scheme and check that the app works, make sure to use this format when entering it into the Invidious instance field: username:[email protected]
  2. Test that I didn't break the local API or unauthenticated Invidious usage

@TheFrenchGhosty If you want to try/test this pull request before it is merged, here's a build that you can use so that you don't have to setup the development environment: https://github.com/absidue/FreeTube/actions/runs/10394591062 (due to GitHub restrictions you'll have to be logged in to download it)

Desktop

  • OS: Windows
  • OS Version: 10
  • FreeTube version: 122db20

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 14, 2024 20:41
@github-actions github-actions bot added the PR: waiting for review For PRs that are complete, tested, and ready for review label Aug 14, 2024
PikachuEXE
PikachuEXE previously approved these changes Aug 15, 2024
@PikachuEXE
Copy link
Collaborator

I have only checked (2) not (1) coz no idea which instance got Basic authentication scheme

@ChunkyProgrammer
Copy link
Member

ChunkyProgrammer commented Aug 15, 2024

This line needs to be updated to have Url at the end
https://github.com/FreeTubeApp/FreeTube/blob/8b93725fa3ed03f8719e32514498551287d4c2f7/src/renderer/components/playlist-info/playlist-info.js#L207C24-L207C48

image

Once this is fixed, I think it should be good to merge. I'll do a bit more testing but so far everything else seems to be working (I'm using Basic Http Authentication for my testing)

PikachuEXE
PikachuEXE previously approved these changes Aug 18, 2024
@github-actions github-actions bot added PR: merge conflicts / rebase needed and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Aug 19, 2024
Copy link
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Approving after rebased!

Copy link
Contributor

Conflicts have been resolved. A maintainer will review the pull request shortly.

@FreeTubeBot FreeTubeBot merged commit 579d6d3 into FreeTubeApp:development Aug 23, 2024
5 checks passed
@absidue absidue deleted the invidious-basic-auth branch August 23, 2024 15:27
PikachuEXE added a commit to PikachuEXE/FreeTube that referenced this pull request Aug 26, 2024
* shaka-migration:
  Use the HLS manifests for live streams
  Update shaka-player to version 4.10.11
  Translated using Weblate (Japanese)
  Translated using Weblate (Japanese)
  Support authentication with the Basic scheme for Invidious instances (FreeTubeApp#5569)
  Translated using Weblate (Romanian)
  Translated using Weblate (Romanian)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Thumbnails don't load if the Invidious instance is behind an HTTP login
5 participants