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

Wrong scheme in torrent download link when behind reverse proxy #1464

Closed
thexa4 opened this issue Jun 9, 2017 · 3 comments
Closed

Wrong scheme in torrent download link when behind reverse proxy #1464

thexa4 opened this issue Jun 9, 2017 · 3 comments
Labels
Enhancement PR Welcome! We would welcome a volunteer to prepare a PR to solve this problem!

Comments

@thexa4
Copy link
Contributor

thexa4 commented Jun 9, 2017

This can occur when using ssl termination using nginx as a reverse proxy. The download link in the torznab api endpoint returns a link that starts with http://

This results in a problem for applications that don't follow redirects correctly and leaks information when accessing jackett from an untrusted network.

This behavior originates in TorznabController.cs:150, it uses the scheme from the RequestUri which is always http.

Ideally one of these solutions would be added:

Jackett version: 0.7.1483.0
Mono version (if not using Windows): Debian 4.6.2.7+dfsg-1


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@thexa4 thexa4 changed the title Wrong schema in torrent download link when behind reverse proxy Wrong scheme in torrent download link when behind reverse proxy Jun 9, 2017
@ghost
Copy link

ghost commented Jul 27, 2017

+1, encountered this last night. This effectively breaks manual search functionality for me. Good on your for tracing the issue to it's source!

@turtlehead
Copy link

I am also having this problem behind an apache reverse proxy.

@kaso17 kaso17 added Enhancement PR Welcome! We would welcome a volunteer to prepare a PR to solve this problem! labels Aug 29, 2017
@kaso17
Copy link
Collaborator

kaso17 commented Sep 1, 2017

fixed via 3790cbb

An apache config like this should work:

ProxyPreserveHost On
RequestHeader set X-Forwarded-Proto "https"
ProxyPass /jackett http://127.0.0.1:9117/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement PR Welcome! We would welcome a volunteer to prepare a PR to solve this problem!
Projects
None yet
Development

No branches or pull requests

3 participants