theotherp / nzbhydra2

Usenet meta search
Other
1.23k stars 75 forks source link

Enabling outgoing Proxy corrupts indexer URLs? #422

Open ChrisWeiss opened 5 years ago

ChrisWeiss commented 5 years ago

If enable the Socks proxy, it appears that NZBHydra is tweaking the URL endpoints for indexers, adding the IP address to the URL. It's unclear if this is just a visual error in the logging, or if it's a genuine incorrect URL. Either way, the call fails with the Proxy enabled.

Without Proxy enabled: nzbplanet: Calling https://nzbplanet.net/api?apikey=<apikey>&t=search&extended=1[trimmed]

With Proxy enabled: nzbplanet: Failed to connect to nzbplanet.net/104.25.133.13:443

I'm set up for PIA as a Socks proxy using the proxy-nl.privateinternetaccess.com gateway. Have Bypass for local addresses checked and no entry for Bypass domains. I've quadruple-checked my credentials and they work elsewhere.

This started happing in a recent build (I don't know exactly when - within the last few months). The config file has been in use for years, it's possible there are some stale entries that are causing issues?

Using: linuxserver/hydra2:latest from 2019-07-19 03:57:17

theotherp commented 5 years ago

To be honest, the socks implementation is kind of a hack - entirely possible that it's not working properly. I'll take a look when I have time.

ChrisWeiss commented 5 years ago

I'd start with trying to reproduce it. I'm not convinced it's a widespread issue (surely it would have been reported already).

theotherp commented 5 years ago

Sorry for the delay. The socks implementation hasn't been touched since 2017.

I can reproduce the address looking weird with a non-working socks proxy. But I entered the PIA socks address (proxy-nl.privateinternetaccess.com) and my PIA credentials and it's working fine.

theotherp commented 4 years ago

Does this still not work for you?

ChrisWeiss commented 4 years ago

As of 2.7.2, it is still not working for me. That it's working for you makes me think I've got it not configured correctly or something. Here's my config:


  apiKey: "[obscured]"
  configVersion: 8
  backupEverySunday: true
  backupBeforeUpdate: true
  deleteBackupsAfterWeeks: 4
  dereferer: "http://www.dereferer.org/?$s"
  databaseCompactTime: 15000
  instanceCounterDownloaded: true
  host: "0.0.0.0"
  logging:
    consolelevel: "INFO"
    historyUserInfoType: "NONE"
    logIpAddresses: true
    mapIpToHost: false
    logMaxHistory: 30
    logfilelevel: "DEBUG"
    logUsername: false
    markersToLog: []
  port: 5076
  proxyType: "SOCKS"
  proxyHost: "proxy-nl.privateinternetaccess.com"
  proxyPort: 1080
  proxyIgnoreLocal: true
  proxyIgnoreDomains: []
  proxyUsername: "x[obscured]"
  proxyPassword: "[obscured]"
  repositoryBase: "https://github.com/theotherp"
  showNews: true
  shutdownForRestart: true
  sniDisabledFor:
  - "nzbgeek.info"
  ssl: false
  sslKeyStore: null
  sslKeyStorePassword: null
  startupBrowser: true
  theme: "grey"
  urlBase: "/"
  updateCheckEnabled: true
  updateAutomatically: false
  useCsrf: true
  usePackagedCaCerts: true
  verifySsl: true
  verifySslDisabledFor:
  - "sabnzbd"
  welcomeShown: true
  xmx: 512```
theotherp commented 4 years ago

Yep, same for me:

proxyType: "SOCKS"
  proxyHost: "proxy-nl.privateinternetaccess.com"
  proxyPort: 1080
  proxyIgnoreLocal: true
  proxyIgnoreDomains: []
  proxyUsername: "xWHATEVER"
  proxyPassword: "foobar"
walshy002000 commented 4 years ago

Any luck Chris? Same issue here, same config with PIA

ChrisWeiss commented 4 years ago

I have not tried it in a while, but I gave up. It occurs to me that I'm using PiHole as a DNS server and am running Hydra in a container. I know Docker proxies DNS, it's possible that trying to proxy things as losing DNS resolution. Will poke at it s'more.

Hobbabobba commented 2 years ago

I noticed, that this problem just occurs with a SOCKS proxy. When i use a HTTP proxy everything is working fine.