Kareadita / Kavita

Kavita is a fast, feature rich, cross platform reading server. Built with the goal of being a full solution for all your reading needs. Setup your own server and share your reading collection with your friends and family.
http://www.kavitareader.com
GNU General Public License v3.0
6.09k stars 315 forks source link

OPDS url strips https from url when host name not set #2245

Closed scare376 closed 8 months ago

scare376 commented 1 year ago

Describe the bug When the Host Name is not set in Email settings the opds will use an http url even if the page uses https.

To Reproduce Steps to reproduce the behavior:

  1. Have no Host Name set
  2. Open 3rd party clients page with https url
  3. OPDS URL will have http rather than https

Expected behavior URL mimics the browser url.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

majora2007 commented 1 year ago

I'm reading this issue as the user doesn't have host name, but is accessing via a reverse proxy over https, Kavita is generating as http.

majora2007 commented 1 year ago

From what I'm seeing this happens only when the reverse proxy isn't forwarding X-FORWARDED-FOR