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

Cannot pass BasicAuth in URLs #1027

Closed
1 task done
danwilldev opened this issue Oct 17, 2024 · 3 comments · Fixed by #1062
Closed
1 task done

Cannot pass BasicAuth in URLs #1027

danwilldev opened this issue Oct 17, 2024 · 3 comments · Fixed by #1062
Assignees
Labels
bug Something isn't working confirmed This bug has been reproduced released

Comments

@danwilldev
Copy link

Description

When trying to connect a service, jellyseerr no longer accepts basic auth credentials as part of the URL string.

Version

2.0.1

Steps to Reproduce

Try to connect any service eg Sonarr to Jellyseerr. Pass basic auth as part of the string and observe the below log-line after failing to connect.

Screenshots

No response

Logs

[error][Radarr]: [Radarr] Failed to retrieve profiles: Request cannot be constructed from a URL that includes credentials: https://username:Password@urlhere/radarr/api/v3/qualityProfile?apikey=apiKeyHere

Platform

desktop

Device

Server

Operating System

Ubuntu

Browser

Firefox

Additional Context

As per @fallenbagel on discord. "2.0.0 introduced fetch and url constructor doesn't like basic auth in url."

Code of Conduct

  • I agree to follow Jellyseerr's Code of Conduct
@danwilldev danwilldev added awaiting triage This issue needs to be reviewed bug Something isn't working labels Oct 17, 2024
@fallenbagel fallenbagel added confirmed This bug has been reproduced and removed awaiting triage This issue needs to be reviewed labels Oct 17, 2024
@gauthier-th gauthier-th self-assigned this Oct 17, 2024
fallenbagel added a commit that referenced this issue Oct 31, 2024
This PR adds extraction of basic authentication credentials from the URL and then pass the
credentials as the `Authorization` header. And then credentials are removed from the URL before
being passed to fetch. This is done because fetch request cannot be constructed using a URL with
credentials

fix #1027
fallenbagel added a commit that referenced this issue Oct 31, 2024
This commit adds extraction of basic authentication credentials from the URL and then pass the
credentials as the `Authorization` header. And then credentials are removed from the URL before
being passed to fetch. This is done because fetch request cannot be constructed using a URL with
credentials

fix #1027
@fallenbagel
Copy link
Owner

@danwilldev could you test :preview-fix-basic-auth to see if it works now?
The tag should be available in about half an hour

@danwilldev
Copy link
Author

@fallenbagel I have tested on my machine and can now connect services with basic auth. Thanks for the fix guys :D

bonswouar pushed a commit to bonswouar/jellyseerr that referenced this issue Nov 10, 2024
…enbagel#1062)

This commit adds extraction of basic authentication credentials from the URL and then pass the
credentials as the `Authorization` header. And then credentials are removed from the URL before
being passed to fetch. This is done because fetch request cannot be constructed using a URL with
credentials

fix fallenbagel#1027
@fallenbagel
Copy link
Owner

🎉 This issue has been resolved in version 2.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

thibodelanghe pushed a commit to thibodelanghe/jellyseerr that referenced this issue Dec 18, 2024
…enbagel#1062)

This commit adds extraction of basic authentication credentials from the URL and then pass the
credentials as the `Authorization` header. And then credentials are removed from the URL before
being passed to fetch. This is done because fetch request cannot be constructed using a URL with
credentials

fix fallenbagel#1027
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working confirmed This bug has been reproduced released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants