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

/avatarproxy prefer hostname/ip address over external url if provided #1012

Closed
1 task done
Hujgo opened this issue Oct 16, 2024 · 6 comments · Fixed by #1016
Closed
1 task done

/avatarproxy prefer hostname/ip address over external url if provided #1012

Hujgo opened this issue Oct 16, 2024 · 6 comments · Fixed by #1016
Labels
awaiting triage This issue needs to be reviewed enhancement New feature or request released

Comments

@Hujgo
Copy link

Hujgo commented Oct 16, 2024

Description

The user avatar in Jellyfin is retrieved from the path /avatarproxy/jellyfin.domain.com

Desired Behavior

The user avatar can be retrieved from the hostname/IP address using the following path: /avatarproxy/http://hostname:port

Additional Context

Tested the path using /avatarproxy/http://jellyfin:8096/... for Jellyfin user avatar and it works. This was not an issue in v1.19.2

Code of Conduct

  • I agree to follow Jellyseerr's Code of Conduct
@Hujgo Hujgo added awaiting triage This issue needs to be reviewed enhancement New feature or request labels Oct 16, 2024
@Fallenbagel
Copy link
Owner

Fallenbagel commented Oct 16, 2024

If this a bug please reopen with the proper template. If this is a feature request, please elaborate what desired behavior you want

I just re-read this, http://jellyfin:8096/avatarproxy/ you meant this right?

@Hujgo
Copy link
Author

Hujgo commented Oct 16, 2024

Yep

src="/avatarproxy/https://jellyfin.domain.com/Users/a0fbffa3409a447ebbbe5d45ee7266f3/Images/Primary/?tag=8ae1e9faf00aa9ab4e06b0649e682ae5&quality=90" style="color: transparent;"

This is how the avatar is loaded. It'd be nice to prefer the hostname if provided. In my case the tld is not resolvable (IPv6).

src="/avatarproxy/http://jellyfin:8096/Users/a0fbffa3409a447ebbbe5d45ee7266f3/Images/Primary/?tag=8ae1e9faf00aa9ab4e06b0649e682ae5&quality=90" style="color: transparent;"

@kokojako
Copy link

omfg, thanks man, i believed I was mad
I have same errors and thought was my settings

jellyseer_1
jellyseer_2

@kokojako
Copy link

I dont use jellyfin but plex and its the same issue

@Fallenbagel
Copy link
Owner

omfg, thanks man, i believed I was mad
I have same errors and thought was my settings

jellyseer_1
jellyseer_2

Do you have imageproxy turned on in settings? If not can you turn on and check? If turned off vice versa. And send logs

gauthier-th added a commit that referenced this issue Oct 16, 2024
Avatar proxy was allowing every request to be proxied, no matter the original ressource's origin or
filetype. This PR fixes it be allowing only relevant resources to be cached, i.e. Jellyfin/Emby
images and TMDB images.

fix #1012, #1013
@Fallenbagel
Copy link
Owner

🎉 This issue has been resolved in version 2.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

bonswouar pushed a commit to bonswouar/jellyseerr that referenced this issue Nov 10, 2024
* fix: rewrite avatarproxy and CachedImage

Avatar proxy was allowing every request to be proxied, no matter the original ressource's origin or
filetype. This PR fixes it be allowing only relevant resources to be cached, i.e. Jellyfin/Emby
images and TMDB images.

fix Fallenbagel#1012, Fallenbagel#1013

* fix: resolve CodeQL error

* fix: resolve CodeQL error

* fix: resolve review comments

* fix: resolve review comment

* fix: resolve CodeQL error

* fix: update imageproxy path
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting triage This issue needs to be reviewed enhancement New feature or request released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants